drift
by dadbodgeoff
Codebase intelligence for AI. Detects patterns & conventions + remembers decisions across sessions. MCP server for any IDE. Offline CLI.
# Add to your Claude Code skills
git clone https://github.com/dadbodgeoff/drift🔍 Drift
Make AI write code that actually fits your codebase.
Drift scans your code, learns your patterns, and tells AI how you do things. No more fixing AI output.
⚡ Quick Start (30 seconds)
npm install -g driftdetect
cd your-project
drift setup
That's it. The setup wizard walks you through everything:
- Pattern scanning
- Auto-approval of high confidence patterns
- Call graph analysis
- Test topology mapping
- Cortex memory initialization
Want defaults without prompts? Run drift setup -y
🚫 Delete Your AGENTS.md
You know that AGENTS.md or CLAUDE.md file you wrote once and forgot about? It's stale. Delete it.
Drift's Cortex Memory System replaces static instruction files with living memory:
# Instead of maintaining a static file:
drift memory add tribal "Always use bcrypt for passwords" --importance critical
drift memory add tribal "Services should not call controllers" --topic Architecture
# AI gets context dynamically:
drift memory why "authentication"
# And learns from corrections:
drift memory learn --original "Used MD5" --feedback "Use bcrypt instead"
| Static AGENTS.md | Cortex Memory | |------------------|---------------| | Written once, forgotten | Learns from corrections | | Gets stale immediately | Confidence decays naturally | | Manual updates required | Self-correcting through feedback | | One-size-fits-all dump | Intent-aware retrieval |
📋 What You Need
- Node.js 18 or newer — Download here
- npm — Comes with Node.js
Check if you have them:
node --version # Should show v18.x.x or higher
npm --version # Should show 9.x.x or higher
🚀 Three Ways to Use Drift
| Path | Best For | Time to Setup | |------|----------|---------------| | 1. CLI Only | Exploring your codebase manually | 2 minutes | | 2. AI + CLI | AI runs drift commands for you | 2 minutes | | 3. MCP Server | Full AI integration (recommended) | 5 minutes |
1. Use Drift Without AI (CLI Only)
Perfect for: Exploring what Drift finds in your codebase before connecting AI.
Install & Setup
npm install -g driftdetect
cd your-project
drift setup
The setup wizard handles everything. Just answer the prompts (or use drift setup -y for defaults).
See What Drift Found
drift status
You'll see something like:
Patterns: 47 discovered, 12 approved
Health Score: 85/100
Languag...