nexus-mind
CLAUDE.md2 starsChanged 5 months agoMITView on GitHub
NexusMind is the single source of truth for this codebase. Before guessing, check it. Before finishing, save to it. This protocol is MANDATORY and ALWAYS ACTIVE in this repository. It is not a suggestion. If you skip it, the next session starts blind. Call these DIRECTLY by full name — no ToolSearch. Call store_memory IMMEDIATELY and WITHOUT BEING ASKED after any of these: Self-check after EVERY task: "Did I make a decision, fix a bug, learn something non-obvious, or establish…
- Reads credentials
In this repository13 other files it gives its agents.
- coding-agentSkill
- dust-react-hook-form-writerSkill
- frontend-patternsSkill
- playwright-cliSkill
- product-inventorSkill
- react-hook-form-zodSkill
- receiving-code-reviewSkill
- shadcnSkill
- ui-ux-pro-maxSkill
- webapp-testingSkill
- web-artifacts-builderSkill
- web-design-reviewerSkill
- zod-4Skill
The file
Show its rules and text
We split this CLAUDE.md into the rules it gives an agent
15 rules. About 0 are common, 9 are distinctive, and 6 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈9
Distinctive · estimate
This author's own choices. Worth a look.
6
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 9
Default project for every call: nexus-mind
- Distinctive: line 15
Call these DIRECTLY by full name — no ToolSearch.
- Very specific: line 28
Call store_memory IMMEDIATELY and WITHOUT BEING ASKED after any of these:
- Very specific: line 71
USE topic_key for topics that EVOLVE — saving again with the same key UPDATES the existing memory instead of creating a duplicate.
- Distinctive: line 74
Use it when you expect to revise the same decision later
- Distinctive: line 75
DO NOT use it for one-shot records (a single bug fix, a single session summary)
- Distinctive: line 77
If unsure of the right key, search first — if a similar topic exists, reuse its key.
- Very specific: line 81
Call search_memory PROACTIVELY when:
- Distinctive: line 88
If unsure whether to search — search.
- Very specific: line 94
NEVER pass a bare project/repo name (e.g.
- Distinctive: line 98
Before saying "done", "that's it", "finished" (or the equivalent in any language), call:
- Distinctive: line 128
If you see a compaction message or "FIRST ACTION REQUIRED":
- Very specific: line 131
Call search_memory(query: "nexus-mind") to recover broader context.
- Distinctive: line 132
Only THEN continue working.
- Distinctive: line 134
Do not skip step 1. Without it, everything done before compaction is lost from memory.
≈ “Common” is an estimate: at least 1 in 5 of the 26,980 CLAUDE.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
NexusMind — Claude Code MANDATORY PROTOCOL
NexusMind is the single source of truth for this codebase. Before guessing, check it. Before finishing, save to it.
This protocol is MANDATORY and ALWAYS ACTIVE in this repository. It is not a suggestion. If you skip it, the next session starts blind.
In this repository
- Default
projectfor every call:nexus-mind - Alternates for cross-repo work:
nexusmind-backend,nexusmind-admin,nexusmind-mcp,nexusmind-landing - Default
tool:claude-code
Available MCP tools
Call these DIRECTLY by full name — no ToolSearch.
| Tool | When to use |
mcp__nexusmind__store_memory | Save a decision, bug fix, convention, discovery — PROACTIVELY |
mcp__nexusmind__search_memory | First action on any prompt that references prior work |
mcp__nexusmind__list_memories | Browse recent memories (utility) |
mcp__nexusmind__get_context | Bootstrap a significant session — all team knowledge grouped by type |
mcp__nexusmind__get_memory | Fetch FULL untruncated content by id (previews are not enough) |
mcp__nexusmind__delete_memory | Remove a memory — ONLY when the user explicitly asks |
PROACTIVE SAVE TRIGGERS
Call store_memory IMMEDIATELY and WITHOUT BEING ASKED after any of these:
- Architecture or design decision made
- Convention documented or established
- Bug fix completed (include root cause)
- Feature implemented with non-obvious approach
- Tool or library choice made with tradeoffs
- Configuration or environment change
- Non-obvious discovery about the codebase
- Gotcha, edge case, or unexpected behavior
- Pattern established (naming, structure)
- User preference or constraint learned
Self-check after EVERY task: "Did I make a decision, fix a bug, learn something non-obvious, or establish a convention? If yes, call store_memory NOW."
Required fields on every store_memory call
title— verb + what, 5-10 words ("Fixed N+1 in memory listing")type— pick from the glossary belowproject— alwaysnexus-mindin this repocontent— structured: What, Why, Where, Learnedtopic_key(recommended for evolving topics) — see topic_key section
Type glossary
| Type | Use for |
architecture | System design, component relationships, infrastructure decisions |
bugfix | Root cause + fix. Always include WHAT broke and WHY |
decision | Explicit choices made between alternatives |
discovery | Non-obvious findings about code, APIs, or behavior |
pattern | Established conventions — naming, structure, approach |
config | Environment setup, tool config, credentials schema |
preference | User working style, code style, tool preferences |
project | Goals, stakeholders, milestones, business context |
session_summary | End-of-session state — always save before saying "done" |
feature | Implemented feature with approach and rationale |
refactoring | What changed, why, what to watch for |
feedback | Corrections and confirmations from the user |
manual | Ad hoc save not fitting another type |
topic_key guidance
USE topic_key for topics that EVOLVE — saving again with the same key UPDATES the existing memory instead of creating a duplicate.
- Examples:
architecture/auth-model,config/deploy-pipeline,pattern/repo-naming,convention/commit-style - Use it when you expect to revise the same decision later
- DO NOT use it for one-shot records (a single bug fix, a single session summary)
If unsure of the right key, search first — if a similar topic exists, reuse its key.
WHEN TO SEARCH
Call search_memory PROACTIVELY when:
- The user's FIRST message of a session references a project, feature, bug, or module → search BEFORE responding
- Starting work on something that might have been done before
- The user uses words like "remember", "recall", "we did", "how did we" — search every time
- You are about to make a non-trivial decision — check whether one already exists
If unsure whether to search — search.
HOW to search (avoid lazy project-name queries)
- To load a project's context, use
get_context(project=…)orlist_memories(project=…)— NOTsearch_memory. search_memoryis a semantic search: pass a query describing the specific thing you need (e.g."how auth tokens are validated","deploy pipeline config","why we chose SQLite").- NEVER pass a bare project/repo name (e.g.
"nexus-mind") as thesearch_memoryquery — a semantic engine returns noise for that, not the project's context. Useget_context/list_memoriesfor whole-project loading.
SESSION CLOSE (MANDATORY)
Before saying "done", "that's it", "finished" (or the equivalent in any language), call:
store_memory({
type: "session_summary",
title: "Session: <one-line>",
project: "nexus-mind",
content: """
## Goal
<what we were working on>
## Accomplished
- <completed items with key details>
## Discoveries
- <technical findings, gotchas>
## Next Steps
- <what remains>
## Relevant Files
- path/to/file — <what changed>
"""
})This is NOT optional. If you skip this, the next session starts blind.
AFTER COMPACTION
If you see a compaction message or "FIRST ACTION REQUIRED":
- IMMEDIATELY call
store_memorywithtype: "session_summary"and the compacted summary content — this persists what was done before compaction. - Call
search_memory(query: "nexus-mind")to recover broader context. - Only THEN continue working.
Do not skip step 1. Without it, everything done before compaction is lost from memory.
Configuration
The repo's .mcp.json uses an environment placeholder ${NEXUSMIND_API_KEY} — set this in your shell before launching Claude Code:
export NEXUSMIND_API_KEY=<your-key>The MCP server is launched via npx -y @smart-coder-labs/nexusmind-mcp — no local checkout required.
Quick start
# 1. Start the backend
make backend # or: cd apps/backend && cargo run
# 2. Seed demo data (first time or to reset)
./scripts/reset-demo.sh
# 3. Build the MCP server (only needed for local dev)
make mcp-build
# 4. Set your API key
export NEXUSMIND_API_KEY=<your-key>
# 5. Open Claude Code — the MCP server and hooks connect automaticallyFull setup guide: docs/RUNNING.md
Demo keys (after reset-demo.sh)
| User | Key |
| Acme Corp — admin | nm_demo_acme_admin |
| Acme Corp — Sarah Chen | nm_demo_acme_sarah |
| TechStartup — admin | nm_demo_techstartup_admin |
NexusMind is the single source of truth for this codebase. Before guessing, check it. Before finishing, save to it.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

