brain-ingest-gate
Pre-write quality gate for content entering the brain. No raw copies: a bare cp/mv into the brain repo is a bug. Before any new page lands, resolve named…
Evolve your brain's schema pack. Add page types, propose new ones from corpus scans, backfill page.type on existing pages, audit pack health. Triggers when an agent notices untyped pages, custom domains needing typed entities (researcher, contract, deposition), or wants to see
$ npx -y skills add garrytan/gbrain --skill schema-author --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/schema-authorContext preview
The summary Claude sees to decide when to auto-load this skill.
Evolve your brain's schema pack. Add page types, propose new ones from corpus scans, backfill page.type on existing pages, audit pack health. Triggers when an agent notices untyped pages, custom domains needing typed entities (researcher, contract, deposition), or wants to see
name: schema-author description: Evolve your brain's schema pack. Add page types, propose new ones from corpus scans, backfill page.type on existing pages, audit pack health. Triggers when an agent notices untyped pages, custom domains needing typed entities (researcher, contract, deposition), or wants to see what types the pack declares. tools: - gbrain schema active - gbrain schema list - gbrain schema stats - gbrain schema review-orphans - gbrain schema detect - gbrain schema suggest - gbrain schema lint - gbrain schema graph - gbrain schema explain - gbrain schema fork - gbrain schema use - gbrain schema add-type - gbrain schema remove-type - gbrain schema update-type - gbrain schema add-alias - gbrain schema remove-alias - gbrain schema add-prefix - gbrain schema remove-prefix - gbrain schema add-link-type - gbrain schema remove-link-type - gbrain schema set-extractable - gbrain schema set-expert-routing - gbrain schema sync - gbrain schema reload - mcp:get_active_schema_pack - mcp:list_schema_packs - mcp:schema_stats - mcp:schema_lint - mcp:schema_graph - mcp:schema_explain_type - mcp:schema_review_orphans - mcp:schema_apply_mutations - mcp:reload_schema_pack triggers: - "add a page type" - "add a type to my schema" - "my brain has untyped pages" - "schema isn't matching my notes" - "propose new types from my corpus" - "backfill page types" - "evolve my schema" - "extend the schema pack" - "create a custom type for" - "researcher type" - "make X an expert type" - "schema pack add" - "schema mutate" - "schema sync" - "schema author" brain_first: exempt writes_pages: []
This skill AUTHORS the schema pack (adds page types, link verbs, prefixes, flags). For these adjacent jobs, route elsewhere:
taxonomist routes at WRITE TIME ("where does this note go?"). schema-author changes the rules at AUTHORING TIME ("what types and prefixes exist?").
already has a schema-check phase. Don't duplicate.
directly. This skill is for CHANGING the pack, not READING from it.
schema-author makes a type expert-routable; it does not run the query.
> **Convention:** see [conventions/brain-first.md](../conventions/brain-first.md) for the lookup chain (search → query → get_page → external).
> **Convention:** see [conventions/schema-evolution.md](../conventions/schema-evolution.md) for "when to add a type vs alias vs prefix" — the heuristic.
Invoke when the user (or a sibling skill) says any of:
DON'T invoke for "where does THIS note go" (use brain-taxonomist) or "who knows about X" (use expert-routing / `gbrain whoknows`).
gbrain schema active --json
Output gives you `pack_name`, `version`, `sha8`, `page_types_count`, `source_tier`. If `source_tier === "default"`, the user is on bundled `gbrain-base` and any mutation will need a fork first (Phase 4).
gbrain schema stats --json
Returns per-type page counts, untyped count, and `dead_prefixes` (pack- declared prefixes with zero matching pages — probable mis-declarations). If coverage < 90%, there's untyped content worth typing.
gbrain schema review-orphans --json
Untyped pages drilldown. Look for shared path prefixes (e.g. "12 of these are under `research/papers/`") — those are candidates for a new type.
gbrain schema detect --json
Clusters pages by `source_path` and proposes candidate types. Heuristic only (no LLM call).
gbrain schema suggest --json
LLM-refined candidates with confidence scores. Use the top-3 hit rate as the signal for which to promote.
If the active pack is bundled (`gbrain-base` or `gbrain-recommended`), fork it first:
gbrain schema fork gbrain-base mine gbrain schema use mine
Then add the types one at a time:
gbrain schema add-type researcher \ --primitive entity \ --prefix people/researchers/ \ --extractable \ --expert
For complex multi-mutation refactors (e.g. add a type AND the link verb that points to it), agents reaching this surface over MCP can use the batched `schema_apply_mutations` op:
{"op": "add_type", "name": "researcher", "primitive": "entity", "prefix": "people/researchers/", "extractable": true, "expert_routing":Give the agent you already use a memory you control. GBrain stores explicit facts with their sources, supports corrections and withdrawal, and makes the same memory available across your agents.
Repo: garrytan/gbrain
Pre-write quality gate for content entering the brain. No raw copies: a bare cp/mv into the brain repo is a bug. Before any new page lands, resolve named…
When you report a brain page to the user — created, edited, committed, or relayed from a subagent — a working link is part of the deliverable, in the SAME…
Brain knowledge base operations. The core read/write cycle: brain-first lookup, read-enrich-write loop, source attribution, ambient enrichment, back-linking.…
Deduplicate and synthesize raw concept stubs into a tiered intellectual map (T1 Canon to T4 Riff), tracing idea evolution across sources over time. Transforms…
Token-hygiene audit of the always-loaded context stack — CLAUDE.md, AGENTS.md, auto-memory MEMORY.md, and the bootstrap-rendered identity files (SOUL.md,…
When the user corrects a factual error, root-cause it immediately. Don't just note the correction — trace the error to its source, fix the source, and prevent…