By pwarnock
Three-tier persistent context infrastructure for AI coding agents — constitution, routing intelligence, and cold memory. Based on 'Codified Context: Infrastructure for AI Agents in a Complex Codebase' (Vasilopoulos, 2025).
Check if project context documents are stale or outdated. Detects drift between codebase state and context documentation.
Initialize codified context infrastructure for the current project. Creates constitution, trigger tables, failure modes, and subsystem map in .claude/context/.
Capture debugging insights, repeated explanations, and architecture decisions as durable context. Implements the "explained it twice, write it down" methodology.
Review the health and completeness of the project's context infrastructure. Shows coverage analysis, quality scores, and improvement recommendations.
Use when checking if project context documents are stale or outdated, when the user says "audit staleness", "check context drift", "are my docs current", or when the session-start hook detected drift. Performs deep analysis of all context documents against current codebase state.
Use when setting up persistent context infrastructure for a project, when the user says "bootstrap context", "set up context", "initialize codified context", or when a project lacks .claude/context/ directory. Creates constitution, trigger tables, failure modes, and subsystem map.
Use when capturing debugging insights, repeated explanations, architecture decisions, or gotchas as durable context. Use when the user says "codify this", "write this down", "remember this", "capture knowledge", or after debugging sessions. Implements the "explained it twice, write it down" methodology.
Use when deciding which agent, skill, or context document to invoke for a given file or task. Consults trigger tables to route work to the right specialist. Activated automatically when working in a project with codified context infrastructure.
Use when reviewing the health and completeness of a project's context infrastructure, when the user says "review context", "context health", "how complete is my context", or periodically during maintenance. Provides infrastructure inventory, coverage analysis, and quality assessment.
Uses power tools
Uses Bash, Write, or Edit tools
Own this plugin?
Verify ownership to unlock analytics, metadata editing, and a verified badge. GitHub access is read-only (username + org membership).
Sign in to claimOwn this plugin?
Verify ownership to unlock analytics, metadata editing, and a verified badge. GitHub access is read-only (username + org membership).
Sign in to claimBased on adoption, maintenance, documentation, and repository signals. Not a security audit or endorsement.
Three-tier persistent context infrastructure for AI coding agents. Based on "Codified Context: Infrastructure for AI Agents in a Complex Codebase" (Vasilopoulos, 2025).
LLM coding agents lose context between sessions. They re-explain concepts, repeat debugging mistakes, and don't know which specialist to invoke for which files.
A Claude Code plugin implementing the paper's three-tier infrastructure:
claude plugin install codified-context
/bootstrap-context
This auto-analyzes your project (type, dependencies, structure, git hotspots), asks 3 questions, and generates:
.claude/context/
├── constitution.md # Core conventions and architecture
├── trigger-tables.md # File pattern → agent/skill routing
├── failure-modes.md # Symptom → Cause → Fix mappings
├── subsystem-map.md # Directory → subsystem ownership
├── .last-session-check # Git SHA for staleness tracking
└── specs/ # On-demand subsystem documentation
/audit-staleness: Deep audit of context freshness with specific fix proposals/codify-knowledge: Capture debugging insights and decisions as durable context/review-context: Health check with coverage analysis and quality scores| Command | Purpose |
|---|---|
/bootstrap-context | Initialize context infrastructure for a project |
/audit-staleness | Check for drift between code and context docs |
/codify-knowledge | Capture session knowledge into context documents |
/review-context | Review context health with quality scoring |
On every session start, a lightweight bash hook:
The constitution includes a "Codification Protocol" (§9) that instructs the AI to self-detect when knowledge should be captured:
The context-routing skill teaches the AI to consult trigger tables when working with files:
If you want the methodology without the full plugin (no hooks, no commands), three standalone skills are available:
| Skill | What it provides |
|---|---|
codified-context-patterns | Three-tier framework overview + all templates |
codification-loop | The "explained it twice, write it down" methodology |
context-health | Coverage analysis rubrics and quality scoring |
Install these in ~/.claude/skills/ or via the skills marketplace.
.
├── .claude-plugin/plugin.json # Plugin manifest
├── commands/ # 4 slash commands
├── agents/context-architect.md # Subsystem analysis agent
├── skills/
│ ├── bootstrap-context/ # Project initialization wizard
│ ├── audit-staleness/ # Deep drift analysis
│ ├── codify-knowledge/ # Knowledge capture loop
│ ├── review-context/ # Health check and scoring
│ └── context-routing/ # Trigger table routing logic
├── hooks/ # Session-start staleness hook
├── lib/context-utils.sh # Shared bash utilities
└── standalone-skills/ # Methodology-only skills (no plugin required)
├── codified-context-patterns/
├── codification-loop/
└── context-health/
MIT
npx claudepluginhub pwarnock/pwarnock-cc-plugins --plugin codified-contextSession retrospective skill with hook-driven prompting. Generates structured session summaries with learnings that feed back into project memory.
Capture meetups, contacts, and interactions from natural language into Notion CRM
Prisma 7 migration and best practices skills for Claude Code
Bridge Gastown cross-session orchestration with in-session subagent parallelization
Curated Vercel developer toolkit: React best practices, web design guidelines, browser automation, and deployment
Persistent context for AI coding assistants
Automatic context engineering — observes your coding sessions and generates rules, suggestions, skills, and hooks so Claude gets smarter on your codebase over time
Auto-capture high-signal coding context into memctl memory
Commands for loading context and priming Claude for specific tasks
Harness for Claude Code — skills, /harness:* slash commands, persona subagents, lifecycle hooks, and MCP tools without per-repo `harness setup`. Sibling plugins exist for Cursor, Gemini CLI, and Codex.
(Alpha) Persistent memory, architectural decisions, and safety guardrails for Claude Code. Your agent starts every session with full project context — stack, decisions, patterns, safety rules, and a handoff from the previous session.