How It Works
Git tracks what changed. SnapBack understands who changed it and why.
The Journey
| Timeline | What SnapBack Does | You Get |
|---|---|---|
| Day 1 | Detects AI tools, catches common risks | 94% accuracy out of the box |
| Day 30 | Learns YOUR codebase patterns | βCursor breaks this auth moduleβ |
| Day 90 | Predicts problems proactively | Issues caught before you notice |
Detection
SnapBack monitors every save with two systems:
Identifies which AI tool is active:
- Cursor, GitHub Copilot, Claude Code, Windsurf
- Tracks AI contribution percentage
- 94% accuracy across common tools
Scans for common AI-introduced risks:
| Risk Type | What It Catches |
|---|---|
| Secrets | API keys, JWT tokens, database strings |
| Mocks | Test data in production code |
| Phantom deps | Imports missing from package.json |
Automatic Snapshots
The AutoDecisionEngine decides when to protect:
| Trigger | Action |
|---|---|
| AI tool makes substantial changes | Snapshot |
| Critical files modified (auth, config) | Snapshot |
| Multiple files changed rapidly | Snapshot |
| High-risk patterns detected | Snapshot |
Protected by default: Source code, configs, environment files, documentation.
Not protected: .git/, node_modules/, build outputs, binaries.
Sessions
SnapBack groups related changes automatically:
Session: "Claude refactored auth" (14:05 - 14:23)
βββ src/auth.ts (3 snapshots)
βββ src/user.ts (2 snapshots)
βββ src/index.ts (2 snapshots) β undefined reference!
βββ AI Detection: HIGH RISK
Navigate entire sessions with one click. Not file-by-file like Git or Cmd+Z.
Protection Levels
| Level | Behavior | Default Files |
|---|---|---|
| π’ Watch | Silent auto-snapshots | Source code, docs |
| π‘ Warn | Proceed with risk boost | package.json, tsconfig.json |
| π΄ Block | Hard stop, no write | Lock files, .env* |
Timeline vs Git
| Aspect | Git | SnapBack |
|---|---|---|
| Tracks | Commits you make | Every save, automatically |
| Granularity | Commit-level | Save-level |
| AI awareness | None | Full attribution |
| Context | Commit message | Cursor position, AI tool, risk score |
Use both: Git for version control. SnapBack for understanding AI-assisted development.
Privacy
All analysis happens on your machine. Your code never leaves your device. Optional cloud features use metadata onlyβnever source code.
Stored locally:
- Snapshots and file states
- Pattern learnings and risk scores
- Session metadata
Never collected:
- Source code content
- File diffs
- Proprietary logic
Configuration
Customize with .snapbackrc:
{
"protection": [
{ "pattern": "src/auth/**/*", "level": "block" },
{ "pattern": ".env*", "level": "block" }
],
"ignore": ["*.test.ts"]
}
Recommendation: Let SnapBack learn for 30 days before adding custom rules. The AutoDecisionEngine improves over time.
Next Steps
- Quick Start β Install in 2 minutes
- MCP Integration β AI assistant tools
- CLI Reference β Terminal commands
- Troubleshooting β Common issues