Skip to content

Support FTS-only memory indexing (skip embedding provider) #43957

Description

@hannatao

title: Support FTS-only memory indexing (skip embedding provider)
labels: enhancement

Problem

Currently, memory indexing requires an embedding provider to be configured. If the embedding provider is unavailable or not configured, the entire memory indexing pipeline fails with:

"error": "memory embeddings query timed out after 300s"

This means users who don't want to use semantic search (or don't have access to an embedding API) cannot use the memory system at all.

Current Behavior

The memory database already has FTS5 tables (chunks_fts) for full-text search, but they remain empty because the indexing pipeline requires embeddings before storing chunks:

chunks: 0 rows
chunks_fts: 0 rows
files: 0 rows

Proposed Solution

Add a configuration option to skip embedding generation and use FTS-only indexing:

memory:
  skipEmbedding: true

When enabled:

  1. Still chunk and index files into SQLite
  2. Skip embedding generation entirely
  3. Use SQLite FTS5 for text search instead of vector similarity
  4. memory_search would fallback to FTS when no embeddings exist

Benefits

  • Works without external API dependencies
  • Faster indexing (no network calls)
  • Lower cost (no embedding API usage)
  • Still useful for keyword/concept search in memory files

Alternative

Allow memory_search to gracefully fall back to FTS when:

  • disabled: true (embedding provider not configured)
  • Query times out

This would make the system more resilient and usable in more scenarios.


Related code paths:

  • memory_search tool
  • Memory indexing in Gateway
  • SQLite schema at ~/.openclaw/memory/main.sqlite

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    Priority

    None yet

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions