gsxdsm
eef68fe0b9
FN-8933: capture semantic memory from completed work
...
Add inferred graph relationships and detached recall capture across completed-work memory surfaces.
- Validate and persist deterministic inferred semantic edges with audit outcomes.
- Capture completed tasks, research findings, and insights as bounded recall entries.
- Wire memory semantics through engine, research APIs, and coverage tests.
Files changed:
.changeset/fn-8933-memory-semantics-capture.md | 7 +
AGENTS.md | 1 +
docs/knowledge-graph.md | 10 +-
.../src/__tests__/memory/recall-capture.test.ts | 111 +++++++++++++
.../__tests__/postgres/insight-store.pg.test.ts | 25 +++
.../postgres/research-execution.pg.test.ts | 38 +++++
.../__tests__/research-feature-promotion.test.ts | 39 +++++
.../core/src/async-stores/async-insight-store.ts | 23 ++-
packages/core/src/index.ts | 1 +
.../__tests__/graph-builder-incremental.test.ts | 28 ++++
.../__tests__/inferred-edge-writer.test.ts | 74 +++++++++
packages/core/src/knowledge-graph/graph-builder.ts | 27 ++-
.../src/knowledge-graph/graph-serialization.ts | 2 +-
packages/core/src/knowledge-graph/graph-store.ts | 12 ++
packages/core/src/knowledge-graph/graph-types.ts | 2 +-
packages/core/src/knowledge-graph/index.ts | 1 +
.../src/knowledge-graph/inferred-edge-writer.ts | 96 +++++++++++
packages/core/src/memory/index.ts | 1 +
packages/core/src/memory/recall-capture.ts | 184 +++++++++++++++++++++
.../src/research/research-feature-promotion.ts | 23 ++-
packages/core/src/task-store/task-store-helpers.ts | 13 +-
.../src/__tests__/research-routes.test.ts | 80 ++++++++-
packages/dashboard/src/research-routes.ts | 27 ++-
.../src/__tests__/agent-mission-tools.test.ts | 60 ++++++-
.../src/__tests__/in-process-runtime.pg.test.ts | 28 +++-
.../memory-consolidation-heartbeat-hook.test.ts | 8 +-
.../__tests__/memory-consolidation-ports.test.ts | 17 +-
.../src/__tests__/memory-semantics-pass.test.ts | 115 +++++++++++++
.../engine/src/__tests__/project-engine.test.ts | 65 +++++++-
packages/engine/src/agent-heartbeat.ts | 14 +-
packages/engine/src/agent-tools.ts | 12 +-
packages/engine/src/agents/agent-reflection.ts | 9 +-
packages/engine/src/memory/index.ts | 1 +
.../src/memory/memory-consolidation-adapters.ts | 18 +-
packages/engine/src/memory/memory-consolidation.ts | 13 +-
packages/engine/src/memory/memory-semantics.ts | 67 ++++++++
packages/engine/src/project-engine.ts | 3 +
.../engine/src/research/research-orchestrator.ts | 20 ++-
packages/engine/src/runtimes/in-process-runtime.ts | 12 ++
packages/engine/src/util/run-audit.ts | 11 ++
40 files changed, 1250 insertions(+), 48 deletions(-)
Fusion-Task-Id: FN-8933
Fusion-Task-Lineage: b75a6b23-906f-4255-92f1-7684beb742b8
Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai >
2026-08-11 05:45:36 -07:00
gsxdsm
67cdb33a92
chore: gitignore the knowledge-graph build artifact
...
`.fusion-knowledge/` is `fn knowledge-graph build` output (FN-8920 memory epic):
~85MB of generated JSON, rewritten on every build. edges.json alone is 43MB,
past GitHub's 50MB warning threshold.
It is deterministic and fully regenerable from source — the manifest's SHA-256
fingerprints drive incremental rebuilds — so tracking it preserves nothing a
rebuild cannot reproduce, while adding irreversible, compounding history bloat to
every clone and CI checkout.
docs/knowledge-graph.md previously left this to the operator ("it is not
ignored"); that guidance is updated here so the doc and .gitignore agree. An
operator who explicitly wants a snapshot in history can still force one with
`git add -f .fusion-knowledge/graph`.
Nothing under the path was ever tracked, so no index purge is needed.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com >
2026-08-10 13:49:37 -07:00
gsxdsm
a5e1b0efc2
docs: add docs index back-link to knowledge-graph.md
...
Missing [← Docs index](./README.md) back-link per convention for all
indexed docs. Added during ambient docs audit.
2026-08-10 06:23:35 -07:00
gsxdsm
27cb2d2621
FN-8921: add deterministic knowledge graph tooling
...
Add a committable, provenance-tagged knowledge graph layer with CLI generation and query support.
- Extract TypeScript, Markdown, and FNXC knowledge into deterministic graph nodes and edges.
- Persist recoverable graph artifacts outside ignored Fusion state and expose build/query CLI commands.
- Document configuration and add core and CLI coverage for graph structure, serialization, and recovery.
Files changed:
.changeset/fn-8921-knowledge-graph.md | 7 +
.gitattributes | 3 +
AGENTS.md | 1 +
docs/README.md | 2 +
docs/cli-reference.md | 4 +
docs/knowledge-graph.md | 37 +++++
docs/settings-reference.md | 4 +
docs/storage.md | 2 +
packages/cli/package.json | 3 +-
.../__tests__/knowledge-graph-bundle-shape.test.ts | 4 +
.../src/__tests__/knowledge-graph-command.test.ts | 115 ++++++++++++++
packages/cli/src/bin.ts | 19 +++
packages/cli/src/commands/knowledge-graph.ts | 79 ++++++++++
packages/cli/tsup.config.ts | 2 +
packages/core/package.json | 4 +-
packages/core/src/config/settings-schema.ts | 2 +
packages/core/src/index.ts | 1 +
.../__tests__/derive-modules.test.ts | 11 ++
.../__tests__/extract-file-composition.test.ts | 20 +++
.../knowledge-graph/__tests__/extract-fnxc.test.ts | 33 ++++
.../__tests__/extract-markdown.test.ts | 21 +++
.../__tests__/extract-typescript.test.ts | 30 ++++
.../__tests__/file-discovery.test.ts | 26 ++++
.../graph-artifact-not-gitignored.test.ts | 15 ++
.../__tests__/graph-builder-equivalence.test.ts | 76 ++++++++++
.../__tests__/graph-builder-incremental.test.ts | 52 +++++++
.../__tests__/graph-identity.test.ts | 11 ++
.../knowledge-graph/__tests__/graph-query.test.ts | 13 ++
.../__tests__/graph-serialization.test.ts | 29 ++++
.../__tests__/graph-store-recovery.test.ts | 106 +++++++++++++
.../__tests__/resolve-imports.test.ts | 10 ++
.../core/src/knowledge-graph/derive-modules.ts | 4 +
packages/core/src/knowledge-graph/extract-file.ts | 6 +
packages/core/src/knowledge-graph/extract-fnxc.ts | 168 +++++++++++++++++++++
.../core/src/knowledge-graph/extract-markdown.ts | 9 ++
.../core/src/knowledge-graph/extract-typescript.ts | 107 +++++++++++++
.../core/src/knowledge-graph/file-discovery.ts | 85 +++++++++++
packages/core/src/knowledge-graph/graph-builder.ts | 141 +++++++++++++++++
.../core/src/knowledge-graph/graph-manifest.ts | 4 +
packages/core/src/knowledge-graph/graph-query.ts | 126 ++++++++++++++++
.../src/knowledge-graph/graph-serialization.ts | 134 ++++++++++++++++
packages/core/src/knowledge-graph/graph-store.ts | 97 ++++++++++++
packages/core/src/knowledge-graph/graph-types.ts | 54 +++++++
packages/core/src/knowledge-graph/index.ts | 14 ++
.../core/src/knowledge-graph/resolve-imports.ts | 4 +
packages/core/src/types/settings/settings-scope.ts | 2 +
pnpm-lock.yaml | 12 +-
47 files changed, 1700 insertions(+), 9 deletions(-)
Fusion-Task-Id: FN-8921
Fusion-Task-Lineage: 7014d0f1-fc47-454b-afe5-5f0d9b229f33
Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai >
2026-08-10 06:15:17 -07:00