Summary
FalkorDriver (graphiti-core 0.29.0, falkordb 1.6.1) rejects group_id values that Neo4jDriver accepts. Specifically, when add_episode() triggers entity-extraction and an entity name contains a backslash-escaped underscore (\_), FalkorDB writes fail with:
group_id "\_" must contain only alphanumeric characters, dashes, or underscores
The same chunks ingest cleanly into a Neo4j substrate (verified: 1871 entities + 679 episodics with the same corpus + same code-path on the Neo4j-backed instance).
Reproducer
Setup:
- graphiti-core 0.29.0
- falkordb 1.6.1, redis 7.4.0
- LLM: gpt-4o-mini via OpenRouter
- Embedder: Ollama nomic-embed-text
- Cluster: FalkorDB v4.18.3 (
docker run falkordb/falkordb:v4.18.3)
Behavior:
- Build
Graphiti(graph_driver=FalkorDriver(host=..., port=6379), llm_client=..., embedder=...)
- Walk a corpus of markdown files (any chunk whose LLM-extracted entity names contain
\_ or other backslash-escape patterns common in markdown)
- Call
await g.add_episode(name=chunk.id, episode_body=chunk.text, source=EpisodeType.text, source_description=chunk.source_path, reference_time=...) per chunk
- Observe: ~60% of chunks fail with the
group_id regex error; the same code path against Graphiti(uri=neo4j_uri, user=..., password=..., ...) ingests them cleanly
Diagnosis (best guess)
Somewhere in the entity-extraction → write-to-graph path, group_id is being derived from extracted entity names without backslash sanitization. Neo4jDriver accepts \_ as a group_id; FalkorDriver validates against a stricter regex (alphanumeric + dash + underscore only, no backslash) and rejects.
The backslash-escape commonly originates from markdown source: \_internal\_var\_ etc. that the LLM extracts verbatim into entity names.
Expected behavior
Either:
- (a)
FalkorDriver matches Neo4jDriver's permissiveness on group_id (loosen FalkorDB validation regex)
- (b) graphiti-core sanitizes
group_id consistently across drivers before write (probably the right answer — backend-portability layer)
Impact
- Cross-backend swap from Neo4j → FalkorDB (advertised as a drop-in env-var change in some downstream docs) actually fails ~60% of corpus ingest at scale
- Forces fall-back to Neo4j until upstream fix
- Breaks the substrate-portability promise that motivates graphiti-core's multi-driver architecture
Workaround
We're falling back to Graphiti(uri=..., user=..., password=...) (Neo4jDriver) for v1.1 production. Will retry FalkorDriver swap once a fix lands.
Environment
- Python 3.11
- graphiti-core 0.29.0
- falkordb 1.6.1
- neo4j 6.x (working, baseline)
- FalkorDB v4.18.3 server
Filed as part of BluWave's BRAIN-6 evaluation (collective-memory MCP tool over a fleet-skills corpus). Happy to provide a minimal failing repro script if useful — let me know what shape works for triage.
Summary
FalkorDriver(graphiti-core 0.29.0, falkordb 1.6.1) rejectsgroup_idvalues thatNeo4jDriveraccepts. Specifically, whenadd_episode()triggers entity-extraction and an entity name contains a backslash-escaped underscore (\_), FalkorDB writes fail with:The same chunks ingest cleanly into a Neo4j substrate (verified: 1871 entities + 679 episodics with the same corpus + same code-path on the Neo4j-backed instance).
Reproducer
Setup:
docker run falkordb/falkordb:v4.18.3)Behavior:
Graphiti(graph_driver=FalkorDriver(host=..., port=6379), llm_client=..., embedder=...)\_or other backslash-escape patterns common in markdown)await g.add_episode(name=chunk.id, episode_body=chunk.text, source=EpisodeType.text, source_description=chunk.source_path, reference_time=...)per chunkgroup_idregex error; the same code path againstGraphiti(uri=neo4j_uri, user=..., password=..., ...)ingests them cleanlyDiagnosis (best guess)
Somewhere in the entity-extraction → write-to-graph path,
group_idis being derived from extracted entity names without backslash sanitization.Neo4jDriveraccepts\_as a group_id;FalkorDrivervalidates against a stricter regex (alphanumeric + dash + underscore only, no backslash) and rejects.The backslash-escape commonly originates from markdown source:
\_internal\_var\_etc. that the LLM extracts verbatim into entity names.Expected behavior
Either:
FalkorDrivermatchesNeo4jDriver's permissiveness ongroup_id(loosen FalkorDB validation regex)group_idconsistently across drivers before write (probably the right answer — backend-portability layer)Impact
Workaround
We're falling back to
Graphiti(uri=..., user=..., password=...)(Neo4jDriver) for v1.1 production. Will retry FalkorDriver swap once a fix lands.Environment
Filed as part of BluWave's BRAIN-6 evaluation (collective-memory MCP tool over a fleet-skills corpus). Happy to provide a minimal failing repro script if useful — let me know what shape works for triage.