[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M75Y9CGFARKCW3JSHSP8JP0Q":3,"skill-same:01M75Y9CGFARKCW3JSHSP8JP0Q":44},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":18,"linkOnly":19,"markdownContent":20,"markdownBody":21,"frontMatter":22,"refName":23,"commitSha":24,"skillDirectory":25,"forksCount":13,"repositoryHtmlUrl":26,"repositoryHomepageUrl":6,"ownerHtmlUrl":27,"ownerBlogUrl":6,"ownerDescription":28,"updatedAt":29,"install":30,"resources":43},"01M75Y9CGFARKCW3JSHSP8JP0Q","memex:brain:graph-rebuild",null,"Operator maintenance entry point for the GraphRAG knowledge layer — (re)build the lexical similarity graph over document text (key-free, no embedding provider required), detect hierarchical communities, then generate the missing community reports. Run after a batch of ingests, or whenever the Index has drifted from the derived graph\u002Fcommunity\u002Freport artifacts.","nitekeeper\u002Fmemex","nitekeeper","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F130331363?v=4","01M75Y8ZMS1S9AFVBJN1DY5116","01M75Y8ZNHA5WFYR4A94NKZN76",0,"MIT","https:\u002F\u002Fgithub.com\u002Fnitekeeper\u002Fmemex\u002Fblob\u002Fmain\u002Finternal\u002Fbrain\u002Fgraph-rebuild\u002FSKILL.md",[],[],"2026-11-12 13:55:43",false,"---\nname: memex:brain:graph-rebuild\ndescription: Operator maintenance entry point for the GraphRAG knowledge layer — (re)build the lexical similarity graph over document text (key-free, no embedding provider required), detect hierarchical communities, then generate the missing community reports. Run after a batch of ingests, or whenever the Index has drifted from the derived graph\u002Fcommunity\u002Freport artifacts.\n---\n\n# memex:brain:graph-rebuild\n\n## When to use\n\nThe GraphRAG layer (similarity graph -> communities -> community reports) is a\nDERIVED set of index artifacts that summarize already-indexed documents. It is\nNOT kept live on every write (that would put an LLM call on the write path).\nInstead it is rebuilt on demand by this maintenance entry point:\n\n- after a batch of `memex:brain:ingest` \u002F `capture` \u002F `synthesize` writes,\n- when `global`\u002F`local` ask returns stale themes,\n- on a periodic cadence the operator chooses.\n\nThis path NEVER writes documents — document writes go through the Librarian\n(M3). It only rewrites the `relations` `similar_to` edges, the `communities` \u002F\n`community_members` rows, and the `community_reports` rows.\n\n## Recipe\n\n### Step 1 — Build the similarity graph (deterministic, no LLM, no API key)\n\n```python\nfrom scripts import graph_build\ng = graph_build.build_graph()   # {\"considered\", \"edges_written\", \"k\", \"threshold\"}\n```\n\n**Key-free.** Edges are drawn from a **lexical** similarity (Jaccard over the\nnormalized token-set of each document's `searchable` text) — NO embedding\nprovider, NO API key, NO extra dependency. Works on a Brain with NULL\nembeddings out of the box. Tunables (env): `MEMEX_GRAPH_KNN_K` (default 5),\n`MEMEX_GRAPH_SIM_THRESHOLD` (default 0.1 — Jaccard overlap is sparser than the\nold embedding cosine, so the default threshold is lower than 0.5). Idempotent —\nre-running clears and rewrites the `similar_to` edges without touching\nLibrarian-authored semantic relations. Degrades on \u003C2 docs with usable text (no\nedges, no crash).\n\n### Step 2 — Detect hierarchical communities (deterministic, no LLM)\n\n```python\nfrom scripts import communities\nc = communities.detect_communities()   # {\"levels\", \"communities\", \"members\", \"nodes\"}\n```\n\nTunable (env): `MEMEX_COMMUNITY_SIZE_CAP` (default 10) — communities larger\nthan this recurse into deeper levels. Deterministic (fixed tie-break);\ndegrades on an empty graph (zero communities, no crash).\n\n### Step 3 — Generate the missing community reports (one LLM call each)\n\nReports are lazy\u002Fincremental and built bottom-up (deepest level first so a\nparent can roll up its children):\n\n```python\nfrom scripts.agents import community_reporter\nfor cid in community_reporter.stale_community_ids():   # already deepest-first\n    # follow internal\u002Fbrain\u002Fcommunity-report\u002FSKILL.md for each cid:\n    #   report_prepare -> dispatch reporter subagent -> parse_report\n    #   -> embed summary (tolerate EmbeddingUnavailable) -> report_complete\n    ...\n```\n\nSee `internal\u002Fbrain\u002Fcommunity-report\u002FSKILL.md` for the per-community subagent\ndispatch. Only report-less (stale) communities are processed, bounding cost to\none LLM call per new community.\n\n## Notes\n\n- Steps 1-2 are pure Python and can run head-less (no Claude Code session).\n  Step 3 needs the session because it dispatches the reporter subagent.\n- The whole GraphRAG path (Steps 1-3 + `global`\u002F`local` ask) runs with **zero\n  embedding provider** — no OpenAI\u002FVoyage key, no torch\u002Fsentence-transformers.\n  Embeddings stay an optional enhancement for the `flat` hybrid ask only.\n","# memex:brain:graph-rebuild\n\n## When to use\n\nThe GraphRAG layer (similarity graph -> communities -> community reports) is a\nDERIVED set of index artifacts that summarize already-indexed documents. It is\nNOT kept live on every write (that would put an LLM call on the write path).\nInstead it is rebuilt on demand by this maintenance entry point:\n\n- after a batch of `memex:brain:ingest` \u002F `capture` \u002F `synthesize` writes,\n- when `global`\u002F`local` ask returns stale themes,\n- on a periodic cadence the operator chooses.\n\nThis path NEVER writes documents — document writes go through the Librarian\n(M3). It only rewrites the `relations` `similar_to` edges, the `communities` \u002F\n`community_members` rows, and the `community_reports` rows.\n\n## Recipe\n\n### Step 1 — Build the similarity graph (deterministic, no LLM, no API key)\n\n```python\nfrom scripts import graph_build\ng = graph_build.build_graph()   # {\"considered\", \"edges_written\", \"k\", \"threshold\"}\n```\n\n**Key-free.** Edges are drawn from a **lexical** similarity (Jaccard over the\nnormalized token-set of each document's `searchable` text) — NO embedding\nprovider, NO API key, NO extra dependency. Works on a Brain with NULL\nembeddings out of the box. Tunables (env): `MEMEX_GRAPH_KNN_K` (default 5),\n`MEMEX_GRAPH_SIM_THRESHOLD` (default 0.1 — Jaccard overlap is sparser than the\nold embedding cosine, so the default threshold is lower than 0.5). Idempotent —\nre-running clears and rewrites the `similar_to` edges without touching\nLibrarian-authored semantic relations. Degrades on \u003C2 docs with usable text (no\nedges, no crash).\n\n### Step 2 — Detect hierarchical communities (deterministic, no LLM)\n\n```python\nfrom scripts import communities\nc = communities.detect_communities()   # {\"levels\", \"communities\", \"members\", \"nodes\"}\n```\n\nTunable (env): `MEMEX_COMMUNITY_SIZE_CAP` (default 10) — communities larger\nthan this recurse into deeper levels. Deterministic (fixed tie-break);\ndegrades on an empty graph (zero communities, no crash).\n\n### Step 3 — Generate the missing community reports (one LLM call each)\n\nReports are lazy\u002Fincremental and built bottom-up (deepest level first so a\nparent can roll up its children):\n\n```python\nfrom scripts.agents import community_reporter\nfor cid in community_reporter.stale_community_ids():   # already deepest-first\n    # follow internal\u002Fbrain\u002Fcommunity-report\u002FSKILL.md for each cid:\n    #   report_prepare -> dispatch reporter subagent -> parse_report\n    #   -> embed summary (tolerate EmbeddingUnavailable) -> report_complete\n    ...\n```\n\nSee `internal\u002Fbrain\u002Fcommunity-report\u002FSKILL.md` for the per-community subagent\ndispatch. Only report-less (stale) communities are processed, bounding cost to\none LLM call per new community.\n\n## Notes\n\n- Steps 1-2 are pure Python and can run head-less (no Claude Code session).\n  Step 3 needs the session because it dispatches the reporter subagent.\n- The whole GraphRAG path (Steps 1-3 + `global`\u002F`local` ask) runs with **zero\n  embedding provider** — no OpenAI\u002FVoyage key, no torch\u002Fsentence-transformers.\n  Embeddings stay an optional enhancement for the `flat` hybrid ask only.\n",{"name":5,"description":7},"main","63a7b54c6f668f8d3211623b3199c39105162c68","internal\u002Fbrain\u002Fgraph-rebuild","https:\u002F\u002Fgithub.com\u002Fnitekeeper\u002Fmemex","https:\u002F\u002Fgithub.com\u002Fnitekeeper","Go with the flow!","2026-09-22 07:17:04",{"source":8,"skillName":5,"commands":31,"prompt":41,"zipAvailable":42},[32,35,38],{"tool":33,"command":34},"npx","npx skills add nitekeeper\u002Fmemex --skill \"memex:brain:graph-rebuild\"",{"tool":36,"command":37},"bunx","bunx skills add nitekeeper\u002Fmemex --skill \"memex:brain:graph-rebuild\"",{"tool":39,"command":40},"pnpm","pnpm dlx skills add nitekeeper\u002Fmemex --skill \"memex:brain:graph-rebuild\"","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fnitekeeper\u002Fmemex\u002Fblob\u002Fmain\u002Finternal\u002Fbrain\u002Fgraph-rebuild\u002FSKILL.md",true,[],[45,52,59,66,73,80],{"skillNo":46,"name":47,"nameZh":6,"description":48,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":49,"categories":50,"keywords":51,"publishedAt":18},"01M75YC1J4D3Y84T5DV40V337Y","run","Use to invoke any Memex v2.0 operation. Routes user-facing intents (ingest, ask, capture, lint, synthesize, dashboard) and agent-facing CRUD primitives to the right internal procedure.","https:\u002F\u002Fgithub.com\u002Fnitekeeper\u002Fmemex\u002Fblob\u002Fmain\u002Fskills\u002Frun\u002FSKILL.md",[],[],{"skillNo":53,"name":54,"nameZh":6,"description":55,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":56,"categories":57,"keywords":58,"publishedAt":18},"01M75YBYMEKDRW88VSACQ8BXHH","memex:steward:reconcile-orphan","Authorized fix-up of a flagged orphan. Four actions — delete-index (remove documents row), repair (backfill row_id when target exists), reindex (re-run Librarian; deferred), note (acknowledge). Raises OrphanNotFoundError when index_id is unknown or, for repair, already linked.","https:\u002F\u002Fgithub.com\u002Fnitekeeper\u002Fmemex\u002Fblob\u002Fmain\u002Finternal\u002Fsteward\u002Freconcile-orphan\u002FSKILL.md",[],[],{"skillNo":60,"name":61,"nameZh":6,"description":62,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":63,"categories":64,"keywords":65,"publishedAt":18},"01M75YBVWGDMMATQAPY3S2KYQX","memex:steward:dashboard","Launch a loopback-only, read-only HTTP dashboard over Memex — per-store summary, the federated index, knowledge communities, the code-navigation graph, and the agent registry, plus keyword search, a click-to-read content overlay, and an interactive 3D knowledge-graph view.","https:\u002F\u002Fgithub.com\u002Fnitekeeper\u002Fmemex\u002Fblob\u002Fmain\u002Finternal\u002Fsteward\u002Fdashboard\u002FSKILL.md",[],[],{"skillNo":67,"name":68,"nameZh":6,"description":69,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":70,"categories":71,"keywords":72,"publishedAt":18},"01M75YBS1Y5QYT1JZWN7D90DT0","memex:steward:audit","Run a full integrity audit across the Memex Index and all registered stores. Detects orphans, broken relations, schema drift. Writes a structured audit report to ~\u002F.memex\u002Faudits\u002F. Read-only — never auto-fixes.","https:\u002F\u002Fgithub.com\u002Fnitekeeper\u002Fmemex\u002Fblob\u002Fmain\u002Finternal\u002Fsteward\u002Faudit\u002FSKILL.md",[],[],{"skillNo":74,"name":75,"nameZh":6,"description":76,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":77,"categories":78,"keywords":79,"publishedAt":18},"01M75YBQ7622SDEJDCHC02W8HQ","memex:steward:audit-store","Run an integrity audit scoped to a single registered store (reverse orphans + schema drift). Lighter than full audit.","https:\u002F\u002Fgithub.com\u002Fnitekeeper\u002Fmemex\u002Fblob\u002Fmain\u002Finternal\u002Fsteward\u002Faudit-store\u002FSKILL.md",[],[],{"skillNo":81,"name":82,"nameZh":6,"description":83,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":84,"categories":85,"keywords":86,"publishedAt":18},"01M75YBKEHA8KVK5FM22F4MWJW","memex:index:write","Direct write to the federated Index — the lower-level primitive that memex:brain:ingest and memex:brain:capture build on. Use when a consumer (Atelier, custom plugin) needs to add a document to its own store and have it indexed by the Librarian, without going through the Brain layer. Routes through Librarian subagent + Memex Core.","https:\u002F\u002Fgithub.com\u002Fnitekeeper\u002Fmemex\u002Fblob\u002Fmain\u002Finternal\u002Findex\u002Fwrite\u002FSKILL.md",[],[]]