Skip to content

About

Developer productivity tool for capturing the WHY behind decisions and architectural context per file.

Topics

Resources

Contributing

Stars

0 stars

Watchers

0 watching

Forks

ย 
ย 

Latest commit

ย 

History

4 Commits

Folders and files

Repository files navigation

๐Ÿง  Code Context Recorder

Never Lose the WHY Behind Your Code Again

License: MIT PRs Welcome TypeScript VS Code

๐Ÿš€ Quick Start โ€ข ๐Ÿ“– Documentation โ€ข ๐ŸŽฏ Demo โ€ข ๐Ÿ’ฌ Community


Code Context Recorder Hero

๐Ÿ’ฅ The Problem

Ever experienced this? ๐Ÿค”

- "Why did we do it this way?"
- "Who wrote this and why??"
- "What was the reasoning here?"
- Lost critical context forever
- Hours debugging old code
- New devs can't understand decisions

Git tracks WHAT changed
Comments explain HOW it works
But nothing captures WHY


"The most valuable code isn't the code itselfโ€”it's the context around it."


โœจ The Solution

Code Context Recorder is your team's knowledge time machine โฐ

Automatically captures and preserves the complete story behind your code:

Feature Description Status
๐Ÿ“š Research Tracking Links to Stack Overflow, docs, GitHub issues you referenced โœ… Ready
๐Ÿ’ฌ Decision History Associated Slack threads, meeting notes, bug tickets โœ… Ready
๐ŸŽค Voice Notes Audio explanations of tricky decisions ๐Ÿšง Coming Soon
โฑ๏ธ Timeline View Replay the entire decision-making process โœ… Ready
๐Ÿ” AI Search Find context using natural language โœ… Ready
๐Ÿ‘ฅ Team Sync Share context across your entire team ๐Ÿšง Coming Soon

๐ŸŽฏ See It In Action

๐ŸŽฌ Adding Context to Your Code

graph LR
    A[๐Ÿ–Š๏ธ You Write Code] --> B[๐Ÿค” Add Context]
    B --> C[๐Ÿ’พ Auto-Saved]
    C --> D[๐Ÿ” Searchable Forever]
    D --> E[๐Ÿ‘ฅ Team Knowledge]
    
    style A fill:#4CAF50,stroke:#2E7D32,color:#fff
    style B fill:#2196F3,stroke:#1565C0,color:#fff
    style C fill:#FF9800,stroke:#E65100,color:#fff
    style D fill:#9C27B0,stroke:#6A1B9A,color:#fff
    style E fill:#F44336,stroke:#C62828,color:#fff
Loading

๐Ÿ“ Before CCR

// TODO: Fix this later
function calculatePrice(items) {
  return items.reduce((a,b) => 
    a + b.price * 0.87, 0);
}

Why 0.87? Nobody knows anymore ๐Ÿ˜ฐ

โœ… With CCR

// Context: Using 0.87 multiplier for bulk discount
// Decision: After meeting with sales team
// Ticket: JIRA-1234
function calculatePrice(items) {
  return items.reduce((a,b) => 
    a + b.price * 0.87, 0);
}

Full context preserved forever ๐ŸŽ‰

๐ŸŽฅ Live Demo

Open Interactive Demo โ€” Try Code Context Recorder in your browser


๐Ÿš€ Quick Start

Installation is a breeze! Choose your path:

๐ŸŽจ VS Code Extension (Recommended)
# Install from VS Code Marketplace (Coming Soon)
code --install-extension code-context-recorder

# Or install from source
git clone https://github.com/koushik4475/code-context-recorder.git
cd code-context-recorder
npm install
npm run build
cd packages/vscode-extension
npm run install-extension

On Windows PowerShell use ; instead of && between commands, or run each line separately.

Keyboard Shortcuts:

  • Ctrl+Shift+C - Add context
  • Ctrl+Shift+T - View timeline
  • Ctrl+Shift+F - Search contexts
  • Ctrl+Shift+V - Voice note (coming soon)
๐Ÿ’ป CLI Tool
# Install globally
npm install -g @ccr/cli

# Or use in your project
npm install --save-dev @ccr/cli

# Initialize in your project
ccr init
๐Ÿ”— Git Hooks
# Automatically prompt for context on commits
cd your-project
npx ccr-hooks install

๐ŸŽจ Features

๐Ÿ”ฅ Core Capabilities

๐Ÿ“Š Smart Timeline

Timeline Icon

View complete decision history for any file with beautiful visual timeline

๐ŸŽฏ Instant Search

Search Icon

Find context using natural language queries in milliseconds

๐Ÿ”„ Auto-Capture

Auto Icon

Automatically links browser research to your commits

๐Ÿ’ก Usage Examples

๐Ÿ“ Recording Context
# Add context to current file
ccr add "Chose this approach because X API was deprecated" --file src/auth.ts

# Add context with links
ccr add "Following this pattern: https://..." --file src/auth.ts

# Record important decisions (use add with a clear message)
ccr add "Decision: Use PostgreSQL over MongoDB. Need ACID transactions for financial data." --file src/db.ts --tags "decision,architecture"
๐Ÿ” Searching Context
# Natural language search
ccr search "why did we choose PostgreSQL over MongoDB"

# Search by file pattern
ccr search "authentication" --file "*.ts"

# Search by type
ccr search "decision" --type decision
๐Ÿ“ˆ View Analytics
# Show project statistics
ccr stats

# Output:
# ๐Ÿ“Š Total Contexts: 247
# ๐Ÿ“ˆ Avg per Commit: 2.3
# ๐Ÿ”ฅ Most Documented Files:
#    โ”œโ”€ src/auth.ts (45)
#    โ”œโ”€ src/api.ts (32)
#    โ””โ”€ src/utils.ts (28)
โฑ๏ธ View Timeline
# See complete history for a file
ccr timeline src/components/Auth.tsx
ccr timeline src/api.ts

๐Ÿ—๏ธ Architecture

graph TB
    subgraph "User Interfaces"
        A[VS Code Extension]
        B[CLI Tool]
        C[Browser Extension]
        D[Web Viewer]
    end
    
    subgraph "Core Engine"
        E[Context Capture]
        F[Storage Layer]
        G[Search Engine]
    end
    
    subgraph "Integrations"
        H[Git Hooks]
        I[Slack]
        J[Linear/Jira]
    end
    
    A --> E
    B --> E
    C --> E
    D --> G
    E --> F
    F --> G
    H --> E
    E --> I
    E --> J
    
    style A fill:#007ACC,stroke:#005A9C,color:#fff
    style B fill:#4CAF50,stroke:#2E7D32,color:#fff
    style C fill:#FF9800,stroke:#E65100,color:#fff
    style D fill:#9C27B0,stroke:#6A1B9A,color:#fff
    style E fill:#2196F3,stroke:#1565C0,color:#fff
    style F fill:#F44336,stroke:#C62828,color:#fff
    style G fill:#00BCD4,stroke:#00838F,color:#fff
Loading

๐Ÿ“ฆ Project Structure

code-context-recorder/
โ”œโ”€โ”€ ๐ŸŽฏ packages/
โ”‚   โ”œโ”€โ”€ core/              # TypeScript core library
โ”‚   โ”œโ”€โ”€ vscode-extension/  # VS Code integration
โ”‚   โ”œโ”€โ”€ cli/               # Command-line interface
โ”‚   โ”œโ”€โ”€ git-hooks/         # Git integration
โ”‚   โ”œโ”€โ”€ browser-extension/ # Browser tracking
โ”‚   โ””โ”€โ”€ web-viewer/        # React web UI
โ”œโ”€โ”€ ๐Ÿ“– docs/               # Documentation
โ””โ”€โ”€ ๐Ÿงช tests/              # Test suites

๐ŸŽจ Tech Stack

TypeScript Node.js SQLite React VS Code

Core

  • TypeScript (Strict Mode)
  • Node.js
  • SQLite (better-sqlite3)

Search

  • MiniSearch
  • Full-text indexing
  • Fuzzy matching

UI

  • VS Code Extension API
  • React + TailwindCSS
  • WebExtensions API

๐Ÿ“Š Configuration

Create .ccrrc.json in your project root:

{
  "storage": {
    "type": "sqlite",
    "path": ".ccr"
  },
  "capture": {
    "autoCapture": true,
    "includeBrowserHistory": true,
    "includeVoiceNotes": true
  },
  "integrations": {
    "slack": { "enabled": false },
    "linear": { "enabled": false },
    "jira": { "enabled": false }
  },
  "privacy": {
    "excludePatterns": ["*.env", "*.key", "secrets/*"],
    "localOnly": true
  }
}

๐Ÿ—บ๏ธ Roadmap

Where We're Going ๐Ÿš€

gantt
    title Code Context Recorder Development Timeline
    dateFormat  YYYY-MM-DD
    section Phase 1
    Core Engine & Storage     :done, 2024-01-01, 30d
    VS Code Extension MVP     :done, 2024-01-15, 30d
    Git Hooks Integration     :done, 2024-02-01, 15d
    
    section Phase 2
    Voice Note Recording      :active, 2024-02-15, 30d
    Web Viewer UI             :active, 2024-02-20, 45d
    Browser Extension         :active, 2024-03-01, 30d
    
    section Phase 3
    Team Collaboration        :2024-04-01, 45d
    AI-Powered Features       :2024-05-01, 60d
    Mobile App                :2024-06-01, 90d
Loading
โœ… Completed
  • Core storage and API
  • SQLite integration with WAL mode
  • VS Code extension MVP
  • Git hooks integration
  • Full-text search engine
  • Timeline visualization
  • CLI tool
  • Analytics dashboard
๐Ÿšง In Progress
  • Voice note recording (60% complete)
  • Browser extension (40% complete)
  • Web viewer UI (30% complete)
๐Ÿ”ฎ Coming Soon
  • Team collaboration features
  • Slack/Linear/Jira integrations
  • AI-powered context suggestions
  • Semantic search improvements
  • Mobile app for viewing context
  • Real-time sync
  • Cloud backup (optional)

๐Ÿค Contributing

We โค๏ธ contributions! Check out our Contributing Guide

๐ŸŒŸ Contributors

Made with contrib.rocks

Development Setup

# Clone the repository
git clone https://github.com/koushik4475/code-context-recorder.git
cd code-context-recorder

# Install dependencies
npm install

# Run in development mode
npm run dev

# Run tests
npm test

# Build all packages
npm run build

๐Ÿ“š Documentation

๐Ÿ“– Usage Guide

Learn how to use CCR effectively

๐Ÿ—๏ธ Architecture

Technical deep-dive

๐Ÿค Contributing

Join the community


๐ŸŒŸ Why Use Code Context Recorder?

๐ŸŽฏ For Individual Developers

โœ… Never forget why you wrote something
โœ… Resume work instantly after breaks
โœ… Build a knowledge base of your decisions
โœ… Improve code review quality
โœ… Learn from your past choices

๐Ÿ‘ฅ For Teams

โœ… Onboard new developers 10x faster
โœ… Preserve institutional knowledge
โœ… Reduce time debugging legacy code
โœ… Improve team communication
โœ… Create living documentation


๐Ÿ’ฌ Community

Discord Twitter GitHub Discussions


๐Ÿ“„ License

Code Context Recorder is MIT licensed.


๐Ÿ™ Acknowledgments

Built with โค๏ธ by developers who are tired of losing context.

Special thanks to:

  • The amazing open-source community
  • Early adopters and beta testers
  • All contributors who made this possible

โญ Star us on GitHub โ€” it motivates us a lot!

Star History Chart


โฌ† Back to Top

About

Developer productivity tool for capturing the WHY behind decisions and architectural context per file.

Topics

Resources

Contributing

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages