7000pctAUTO 2b6c98bc3c
Some checks failed
CI / test (push) Failing after 8s
Add UI modules and tests
2026-01-30 09:11:31 +00:00
2026-01-30 09:11:31 +00:00
2026-01-30 09:11:31 +00:00
2026-01-30 09:08:41 +00:00

DevTrace

License Python Version Version

A CLI tool that automatically snapshots and indexes your entire development workflow in real-time, tracking file changes, terminal commands, git operations, and errors into a local searchable database with natural language query capabilities.

Features

  • Real-time File Monitoring: Track file creations, modifications, deletions, and moves
  • Command Capture: Log all terminal commands executed during development sessions
  • Git Operation Tracking: Monitor commits, branches, merges, pushes, and pulls
  • Semantic Search: Search your workflow using natural language queries
  • Timeline View: Visualize your development session as an interactive timeline
  • Export Capabilities: Export session data to JSON for external analysis

Installation

From Source

git clone https://7000pct.gitea.bloupla.net/7000pctAUTO/devtrace.git
cd devtrace
pip install -e .

Development Installation

pip install -e ".[dev]"

Quick Start

  1. Initialize DevTrace:

    devtrace init
    
  2. Start a monitoring session:

    devtrace start --project "My Project"
    
  3. View session timeline:

    devtrace timeline 1
    
  4. Search your workflow:

    devtrace search "modified Python files"
    
  5. Ask natural language questions:

    devtrace ask 1 "What commands did I run?"
    

Commands

Command Description
devtrace init Initialize DevTrace database
devtrace start Start a new monitoring session
devtrace stop Stop a monitoring session
devtrace timeline View session timeline
devtrace search Search workflow history
devtrace ask Ask natural language questions
devtrace sessions List all sessions
devtrace events Show events by type
devtrace export Export session to JSON
devtrace status Show DevTrace statistics

Configuration

Environment Variables

Variable Description Default
DEVTRACE_DIR Base directory for DevTrace data ~/.devtrace
DEVTRACE_DB SQLite database path Auto-generated
DEVTRACE_EMBEDDING_MODEL Sentence-transformers model all-MiniLM-L6-v2
DEVTRACE_WATCH_PATTERNS File patterns to watch *.py,*.js,*.ts,*.html,*.css

Configuration File

Create a .devtracerc file in your project root:

[devtrace]
db_path = /path/to/devtrace.db
watch_patterns = *.py,*.js,*.ts,*.html,*.css,*.md
ignored_patterns = __pycache__,.git,node_modules,.venv
embedding_model = all-MiniLM-L6-v2

Architecture

devtrace/
├── src/
│   ├── main.py          # Entry point
│   ├── cli.py           # Click CLI commands
│   ├── monitor/         # Monitoring modules
│   │   ├── filesystem.py   # File monitoring
│   │   ├── commands.py     # Command capture
│   │   └── git.py          # Git tracking
│   ├── storage/         # Data persistence
│   │   ├── database.py     # SQLite operations
│   │   └── models.py       # Data models
│   ├── search/          # Search functionality
│   │   ├── embeddings.py   # Embedding management
│   │   ├── semantic.py     # Semantic search
│   │   └── query.py        # Query engine
│   └── ui/              # User interface
│       ├── timeline.py     # Timeline view
│       └── display.py      # Display utilities
├── tests/               # Unit tests
└── requirements.txt     # Dependencies

Testing

Run the test suite:

# Run all tests
pytest tests/ -v

# Run with coverage
pytest tests/ --cov=src

# Run specific test file
pytest tests/test_storage.py -v

Contributing

  1. Fork the repository
  2. Create a feature branch: git checkout -b feature/new-feature
  3. Make your changes and add tests
  4. Run tests: pytest tests/ -v
  5. Submit a pull request

License

MIT License - see LICENSE file for details.

Description
Local development workflow tracker with real-time monitoring and semantic search
Readme 61 KiB
v0.1.0 Latest
2026-01-30 09:12:19 +00:00
Languages
Python 100%