Generated by Cortex Memory System - 2026-01-09
- Memory First - Always query
cortex_contextbefore decisions - Document Why - Save reasoning, not just choices
- Verify Before Change - Check existing patterns first
- Incremental Progress - Small commits, frequent checkpoints
- Zero Secrets - Never log, commit, or transmit secrets/PII
- Single Responsibility - One clear purpose per task
- Plan Before Code - Outline approach, get approval, then implement
Purpose: Reduce developer ramp-up time from weeks to hours
- Queries Shared Knowledge Graph to explain why code exists
- References architectural decisions from memory
- Points to relevant documentation
Purpose: Ensure PRs don't contradict architectural consensus
- Queries Decision Trail before reviewing
- Flags "Semantic Drift" when code evolves away from truths
- Uses adversarial review: "What would a senior dev criticize?"
Purpose: Track and surface technical debt early
- Scans for patterns violating Architecture Guardrails
- Logs violations as
cortex_add(type="risk") - Prioritizes by impact and effort
Purpose: Identify vulnerabilities before deployment
- Runs
/security-reviewon changes - Checks for OWASP Top 10 issues
- Validates input handling and auth flows
Store subagent definitions in .claude/agents/:
# .claude/agents/reviewer.yaml
name: Code Reviewer
description: Reviews code for bugs and style
tools: [Read, Search]Pattern: Lead Agent delegates to specialized Subagents
Configure in .claude/settings.json:
{
"hooks": {
"PreToolUse": [{
"matcher": "Write|Edit",
"command": "echo 'Validating...' && biome check"
}],
"PostToolUse": [{
"matcher": "Write",
"command": "biome format --write"
}]
}
}cortex_context("summary of current task")| Event | Memory Type |
|---|---|
| Decisions | decision |
| Patterns | code |
| Facts | fact |
| Risks | risk |
claude --resumeto continue previous session/clearto reset context for new task- Session history stored locally for retrospective
| Tool | Purpose |
|---|---|
cortex_context |
Load task-relevant memories |
cortex_add |
Save new memory |
cortex_search |
Query existing memories |