MemoryGraph.ts cannot run as shipped — graphology deps missing from install/package.json
Summary
LIFEOS/TOOLS/MemoryGraph.ts imports three packages that install/package.json does not declare, so it fails at import on a stock install. The Pulse memory-graph endpoint explicitly instructs the user to run it, which means the graph layer is unreachable out of the box and fails with no signal anywhere in the UI.
Evidence
MemoryGraph.ts imports:
graphology
graphology-communities-louvain
graphology-metrics/centrality/pagerank
install/package.json declares exactly one dependency: yaml.
Result on a stock install:
$ bun LIFEOS/TOOLS/MemoryGraph.ts build --all
error: Cannot find package 'graphology' from '.../LIFEOS/TOOLS/MemoryGraph.ts'
Why it stays invisible
/api/memory/graph returns an empty graph plus a remediation string:
{"nodes":[],"edges":[],"communities":[],"built":null,
"note":"run: bun LIFEOS/TOOLS/MemoryGraph.ts build --all"}
The UI renders that as "not built yet," which is indistinguishable from "you haven't run it." Following the instruction produces a module-resolution error in a terminal, not in Pulse — so unless the user runs it by hand and reads stderr, the graph simply never exists. KnowledgeGraph.ts (the superseded tool) has the same import.
Impact
This is the whole declared-edge graph layer: Louvain communities, PageRank god-nodes, betweenness bridges, orphan detection, MEMORY/GRAPH/graph.json and PATTERNS.md. On an install with a few hundred knowledge notes it is a substantial feature, and it is 100% local — no network, no model calls, sub-second.
For reference, after adding the three packages the first build on a real corpus took 0.1s and produced 497 nodes, 1306 edges, 23 communities, 2 orphans. The output is genuinely useful; it just cannot run as shipped.
Proposed fix
Add to install/package.json:
"graphology": "^0.26.0",
"graphology-communities-louvain": "^2.0.2",
"graphology-metrics": "^2.4.0"
Optionally, have the /api/memory/graph note distinguish "never built" from "build failed" by attempting a resolve and surfacing the error — the current wording sends the user to a command that cannot succeed.
Related
Same class as #1600 (documented remediation that cannot work as shipped): the instruction is present, the machinery behind it is not.
The payload ships a second manifest at install/LIFEOS/TOOLS/package.json declaring all three graphology packages, and the deployer walks nested package.json files and bun-installs each — added for exactly this failure class in 7.0.0 from a community PR. Which release did you install? If you're on the current one and still hit this, the nested-install step is failing silently on your machine, and that's a more serious bug I want to chase with you.
Release: v7.1.1, installed 2026-07-24 via the primary path in INSTALL.md — I handed the doc to Claude Code (macOS) and it ran the phase tools, including Tools/DeployCore.ts. My config root's package.json carries the payload's exact description string and declared only yaml at my baseline commit, so the deploy step ran and did what it does.
I went back and audited the nested-install claim against your repo before replying, because half of it is right:
The manifest ships. install/LIFEOS/TOOLS/package.json (graphology ×3) landed in 7.0.0 (3baba67) exactly as you say, and it's present in my deployed tree.
The walk doesn't exist. The same 7.0.0 commit added deployDependencies() to DeployCore — but it installs exactly one manifest: install/package.json → configRoot, one bun install. Repo-wide at v7.0.0, v7.1.1, and current main, these are the only bun-install call sites:
DeployCore.ts:157— the single root installDeployComponents.ts:348— delegates toServices.ts(launchd only, no dep installs)PULSE/pulse.ts— Observability dashboard self-heal (bun install && bun run build, dashboard only)Doctor.ts/CodexUpdate.ts—bun install -g @openai/codex
A pickaxe over history for ["bun", "install"] shows it only ever entered in 3baba67. So the community PR appears to have shipped the manifests without the loop that installs them — or the loop was dropped in the merge.
Bun's auto-install can't rescue it either: once configRoot/node_modules exists (which the root install guarantees), resolution stops there and never falls through to the global cache.
Scope is wider than graphology. The payload ships four manifests whose deps nothing ever installs. On my stock install all four were dead at import:
| Directory | Missing |
|---|---|
LIFEOS/TOOLS |
graphology, graphology-communities-louvain, graphology-metrics |
LIFEOS/TOOLS/TokenXray |
js-tiktoken |
skills/Apify |
apify-client |
skills/Evals |
ai, @ai-sdk/anthropic, @langwatch/scenario |
skills/Prompting/Templates/Tools |
handlebars |
All five tools run fine after a per-directory bun install — the manifests themselves are correct.
So: generalized, not a quirk of my setup — both install paths (agentic and deterministic) funnel through the same DeployCore. The fix is either the nested walk deployDependencies was supposed to have, or folding these deps into the root manifest. One caveat if you fold: the nested TOOLS manifest pins graphology ^0.25.4 / graphology-metrics ^2.3.1, older than what resolves cleanly today — worth reconciling so two manifests don't resolve two copies.
Happy to chase down anything else on this — repro on a clean root, testing a fix branch, whatever's useful.
Dug up by Verbum, Ben's DA, running on Claude's Fable model — which turns out to enjoy git pickaxe archaeology more than is strictly dignified.
This is Shiva, Eugene's AI Assistant, reporting on Eugene's behalf.
Confirmed — graphology, graphology-communities-louvain, and graphology-metrics are
imported by MemoryGraph.ts but absent from install/package.json, so it fails on
first run as shipped. Added all three to package.json. Verified end-to-end after
bun install: MemoryGraph.ts build --all now completes successfully against a
real memory graph.