Resolves #14001
Related: #13999
Preserves the Memory Core partial-export fail-loud path while making its collection identity stable. DatabaseService.#exportCollection() now accepts a caller-supplied collection label for logs, stats, and PARTIAL_COLLECTION_EXPORT errors; exportDatabase() passes the configured memory/session collection names from AiConfig. The regression spec covers a partial export where the Chroma collection object intentionally omits .name.
Evidence: L2 (focused unit/static validation covers the leaf ACs) -> L2 required (collection-label and fail-loud behavior are unit-observable). Residual: none for #14001; the broader live repair and backup-parity work remains in #13999.
Deltas from ticket
This PR comes from splitting the narrow collection-identity slice out of #13999 during close-target review. It deliberately does not claim the parent P0 exportability repair, diagnostic explanation, shadow/copy repair path, or post-repair canonical backup parity.
Test Evidence
npm run agent-preflight -- ai/services/memory-core/DatabaseService.mjs test/playwright/unit/ai/services/memory-core/DatabaseService.backupPath.spec.mjs
git diff --check dev...HEAD
node --check ai/services/memory-core/DatabaseService.mjs
node --check test/playwright/unit/ai/services/memory-core/DatabaseService.backupPath.spec.mjs
npm run test-unit -- test/playwright/unit/ai/services/memory-core/DatabaseService.backupPath.spec.mjs — 2 passed
Post-Merge Validation
Commits
ba7676c1be — fix(ai): preserve Memory Core partial-export collection identity (#14001)
Evolution
The implementation initially sat on the broad #13999 lane. PR-body close-target validation showed that would falsely close the P0 parent, so #14001 was filed as the one-PR-deliverable leaf and this branch was retargeted to it.
Authored by Euclid (GPT-5, Codex Desktop). Session 019efd84-2ba3-7441-9ce6-04896f1c5cb9.
Resolves #14001
Related: #13999
Preserves the Memory Core partial-export fail-loud path while making its collection identity stable.
DatabaseService.#exportCollection()now accepts a caller-supplied collection label for logs, stats, andPARTIAL_COLLECTION_EXPORTerrors;exportDatabase()passes the configured memory/session collection names from AiConfig. The regression spec covers a partial export where the Chroma collection object intentionally omits.name.Evidence: L2 (focused unit/static validation covers the leaf ACs) -> L2 required (collection-label and fail-loud behavior are unit-observable). Residual: none for #14001; the broader live repair and backup-parity work remains in
#13999.Deltas from ticket
This PR comes from splitting the narrow collection-identity slice out of
#13999during close-target review. It deliberately does not claim the parent P0 exportability repair, diagnostic explanation, shadow/copy repair path, or post-repair canonical backup parity.Test Evidence
npm run agent-preflight -- ai/services/memory-core/DatabaseService.mjs test/playwright/unit/ai/services/memory-core/DatabaseService.backupPath.spec.mjsgit diff --check dev...HEADnode --check ai/services/memory-core/DatabaseService.mjsnode --check test/playwright/unit/ai/services/memory-core/DatabaseService.backupPath.spec.mjsnpm run test-unit -- test/playwright/unit/ai/services/memory-core/DatabaseService.backupPath.spec.mjs— 2 passedPost-Merge Validation
Commits
ba7676c1be—fix(ai): preserve Memory Core partial-export collection identity (#14001)Evolution
The implementation initially sat on the broad
#13999lane. PR-body close-target validation showed that would falsely close the P0 parent, so#14001was filed as the one-PR-deliverable leaf and this branch was retargeted to it.Authored by Euclid (GPT-5, Codex Desktop). Session 019efd84-2ba3-7441-9ce6-04896f1c5cb9.