What happened
Turning semantic memory off in the config file takes more than enabled: false. The configuration fails to load unless you also name a config_database, and it fails if the semantic_memory section is left out entirely.
Line numbers as of 98f3cde (speedkick), packages/server/src/memmachine_server/common/configuration/__init__.py:
SemanticMemoryConf.config_database is declared Field(...) (line 144), so it is required whatever enabled is.
Configuration.semantic_memory has no default (line 373), so the section itself is required.
Checked against the model directly:
SemanticMemoryConf(enabled=False)
-> 1 validation error for SemanticMemoryConf
config_database Field required [type=missing]
SemanticMemoryConf(enabled=False, config_database="pg") -> OK
Configuration(... semantic_memory section omitted ...)
-> 1 validation error for Configuration
semantic_memory Field required [type=missing]
This contradicts #1580 ("default to no short-term or semantic memory"). Semantic memory is off by default, but the operator still has to write a semantic section and point it at a database that will never be used. Every other semantic field is optional, and _auto_disable_when_incomplete (line 180) already treats a missing storage field as grounds to disable rather than to fail.
Expected
With semantic memory disabled, semantic_memory: should be optional and so should config_database. Either of these should load:
semantic_memory:
enabled: false
or no semantic_memory section at all.
Concretely: make config_database optional (str | None = None), give Configuration.semantic_memory a default, and fold a missing config_database into _auto_disable_when_incomplete for configs that do set enabled: true. SemanticManager.get_semantic_config_storage (common/resource_manager/semantic_manager.py:175) would then need to raise ResourceNotReadyError when it is unset, as the storage getter already does for database.
Related
Investigated and written by Claude (Claude Code), filed from the account of the user who commissioned the investigation.
What happened
Turning semantic memory off in the config file takes more than
enabled: false. The configuration fails to load unless you also name aconfig_database, and it fails if thesemantic_memorysection is left out entirely.Line numbers as of
98f3cde(speedkick),packages/server/src/memmachine_server/common/configuration/__init__.py:SemanticMemoryConf.config_databaseis declaredField(...)(line 144), so it is required whateverenabledis.Configuration.semantic_memoryhas no default (line 373), so the section itself is required.Checked against the model directly:
This contradicts #1580 ("default to no short-term or semantic memory"). Semantic memory is off by default, but the operator still has to write a semantic section and point it at a database that will never be used. Every other semantic field is optional, and
_auto_disable_when_incomplete(line 180) already treats a missing storage field as grounds to disable rather than to fail.Expected
With semantic memory disabled,
semantic_memory:should be optional and so shouldconfig_database. Either of these should load:or no
semantic_memorysection at all.Concretely: make
config_databaseoptional (str | None = None), giveConfiguration.semantic_memorya default, and fold a missingconfig_databaseinto_auto_disable_when_incompletefor configs that do setenabled: true.SemanticManager.get_semantic_config_storage(common/resource_manager/semantic_manager.py:175) would then need to raiseResourceNotReadyErrorwhen it is unset, as the storage getter already does fordatabase.Related
enabled). This issue is only about the config schema.enabled: falseplus aconfig_database).Investigated and written by Claude (Claude Code), filed from the account of the user who commissioned the investigation.