This week, a dev running an AI consulting agency published the full architecture of his persistent company context system for Claude Code. The interesting part is not the files. It’s what decides which files to load.
What’s New
The system organizes company knowledge into three layers of Markdown files:
- Identity: who the company is, services, pricing, active clients, ROI benchmarks. One master file that every task reads first.
- Behavior: concrete operative rules covering tone-of-voice, exact color hex codes, typography hierarchy for print vs. web vs. presentations. Not abstract values. Actual rules.
- Artifacts: output templates for proposals, invoices, outreach emails. Defines structure, not content.
That’s a solid knowledge base. But the routing layer is where it gets interesting.
The Twist
Most systems load all context all the time. This one routes it.
A global CLAUDE.md acts as a dispatcher. It reads the task type, loads only the relevant files, and skips everything else. Writing a proposal? Load AGENCY.md and tone-of-voice.md. Building a website page? Swap in nubyte-webdesign.md. Creating a presentation? Add typography.md.
The model never sees more context than it needs. Fewer tokens, less noise, better output. And it all lives in version-controlled files, not buried in chat history that disappears the moment you close the tab.
Step-by-Step: From Google Doc to Published Page 🔧
Here’s what happens when you run /nubyte-page-creator <File-ID> on a Google Docs article:
- 📋 Load context in parallel: web design guide, tone rules, color system
- Analyze project structure: routing, nav schema, sitemap
- Fetch article via OAuth2 to Google Drive API
- Derive page structure from content alone: route, SEO meta, hero, sections, which component fits each section
- Generate full TypeScript React component with animations, schema markup, and analytics events
- Commit 5 files via GitHub MCP: page component, App.tsx route, nav entry, homepage card, sitemap.xml
- Summary report with route, changed files, and manual QA items
No further input from the developer. One command, 11 autonomous steps, done.
Pro Tips
You don’t need 17 files to get value from this. Three is enough to start:
IDENTITY.md: who you are, services, pricing, clientsVOICE.md: how you communicate, prohibited phrases, tone rulesTEMPLATES.md: structure of your core outputs
Reference them in a global CLAUDE.md and you already have a measurably different experience from generic LLM usage.
One more: version-control the whole library. Prices change, clients rotate, brand strategy shifts. Git makes every update traceable and every state recoverable. The context is an asset now, and assets need version history.
The Core Insight
The companies getting the most out of AI right now don’t have the best model. They have the best context. A generic model that knows who you are and only loads what it needs beats a smarter model every time. 🧠
That’s not AI hype. That’s information architecture.
Three files. One router. Ship the first page. 🚀
Frequently Asked Questions
Q: When should I build this custom system vs use a tool like Needle app or MemPalace?
Build custom if you have specific tone rules, pricing structures, or brand standards that change frequently, you update one Markdown file instead of reconfiguring multiple tools. Use pre-built tools if you’re non-technical or want to minimize glue code. Custom scales better for teams with strong internal standards; pre-built wins on speed-to-value for small projects.
Q: How is this different from Karpathy’s LLM Wiki or MemPalace?
This approach is specific to Claude Code: it integrates project-level context (`CLAUDE.md`) that persists across every chat session in your IDE, rather than manual context injection. Karpathy’s LLM Wiki is more general documentation; MemPalace is a different product. This system is designed for agencies and small teams who want company rules (tone, colors, pricing) automatically available to Claude without copy-paste.
Q: Do I need to be technical to maintain this?
No. You’re just organizing Markdown files, anyone can edit `tone-of-voice.md` or `colors.md`. The technical part (integrating with Claude Code) is a one-time setup. After that, maintaining context is as simple as updating a few text files when your company policies change.
Q: What’s the maintenance overhead once it’s set up?
Minimal. You update files when brand guidelines, pricing, or communication standards change, not per-project. Since all skills and sessions reference the same files, one update ripples everywhere. No glue code to refactor; just Markdown files that live in version control.
Built a persistent company context system for Claude Code: global router + project-level CLAUDE.md. Here’s the full architecture.
by u/nnamfuak in PromptEngineering