AI-powered development context tracker - never lose your train of thought
Project description
๐ง Brainet
Never lose your train of thought again.
Brainet is an AI-powered development context tracker that automatically captures what you're working on, why you're working on it, and what's next. Think of it as a second brain for your coding sessions.
๐ What's New in v0.2.0
Major Architecture Overhaul - 5-Source Intelligence System:
- ๐ SOURCE 1 - Git Diffs: Smart chunking with AST-based function extraction
- ๐ SOURCE 2 - Full Files: Complete code context for accurate answers
- ๐ฒ SOURCE 3 - AST Analysis: Deep code structure understanding (classes, methods, imports)
- ๐ฏ SOURCE 4 - Semantic Search: Proactive code discovery related to your queries
- ๐ฆ SOURCE 5 - Project Metadata: Dependencies, file types, and project structure
Critical Bugs Fixed:
- โ Ask command now provides specific, detailed answers with line numbers
- โ Proper diff counting (additions/deletions) in all scenarios
New Features:
- ๐จ Capsule indexing (#01, #02, #03 format)
- ๐๏ธ
brainet preview <index>- View any historical capsule - ๐ฌ Dramatically improved AI responses - specific method listings, accurate context
๐ค The Problem
You're deep in the zone, building a feature. Then...
- ๐ง An urgent email arrives
- ๐ฅ A production bug needs fixing
- โ You take a break
- ๐ It's Friday, you'll continue Monday
Monday morning: "Wait... what was I doing? Why did I change this file? What was the plan?"
You spend 30 minutes scrolling through git commits, reading code, trying to remember. Your flow state? Gone.
โจ The Solution
Brainet captures your coding sessions automatically and uses AI to create human-readable summaries:
$ brainet capture
๐ธ Context Captured
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Added a Character class with methods for combat (attack,
take_damage, heal), progression (gain_experience, level_up),
and status checking (is_alive). Also added Inventory class
with item management.
๐ Stats:
โข 1 files modified
โข 67 lines added
โข 3 TODOs found
โ Capsule saved: 2025-11-02 15:45:53
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Now when you come back, just run brainet history and instantly remember everything.
๐ Quick Start
Installation
# 1. Install brainet
pip install brainet --user
# 2. Add to PATH permanently
echo 'export PATH="$HOME/Library/Python/3.9/bin:$PATH"' >> ~/.zshrc
source ~/.zshrc
Setup
# 1. Check it works
brainet --version
# 2. Get free API key from https://console.groq.com/keys
# 3. Set it permanently
echo 'export GROQ_API_KEY="gsk_your_key_here"' >> ~/.zshrc
source ~/.zshrc
# 4. Start using brainet in any git project!
cd your-project
brainet start
# ... make some changes ...
brainet capture --tag feature -m "Added user authentication"
That's it! Brainet is now tracking your development context.
๐ก Key Features
๐ค AI-Powered Summaries
Brainet uses Claude Sonnet 3.5 (via Groq) to understand your changes and generate intelligent summaries. It knows the difference between:
- Major features vs minor refactors
- Bug fixes vs new functionality
- Breaking changes vs safe updates
๐ Natural Language Querying (Powered by 5 Sources)
Ask questions about your work in plain English - now with comprehensive context:
$ brainet ask "what methods does the Character class have?"
You have a Character class with these methods: __init__
(lines 4-10), take_damage (lines 12-15), heal (lines 17-20),
is_alive (lines 22-23), attack (lines 25-27), gain_experience
(lines 29-32), and level_up (lines 34-39). The TODOs include
adding a magic system with spells, implementing quest tracking,
and adding save/load game functionality.
v0.2.0 Intelligence: Brainet now searches through full file contents, AST structure, and semantically related code to give you accurate, detailed answers with line numbers.
๐ข Multi-Project Support
Working on multiple projects? Brainet handles it seamlessly:
$ brainet workspaces
๐ Active Brainet Sessions (3):
โโโโโโโโโโโโโโโโณโโโโโโโโโโโโโโโโโโโโโโโโโณโโโโโโโโโโโ
โ Project โ Location โ Capsules โ
โกโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฉ
โ api-backend โ ~/projects/api โ 12 โ
โ frontend-app โ ~/projects/frontend โ 8 โ
โ mobile-app โ ~/projects/mobile โ 5 โ
โโโโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโดโโโโโโโโโโโ
๐ Note: The
workspacescommand scans these directories for brainet projects:
~/Desktop- For desktop projects~/Documents- For document-based work~/Projects- For dedicated project foldersKeep your projects in these locations for automatic discovery!
๐ Cross-Project Search
Find where you implemented that feature across all your projects:
$ brainet search "authentication" --all-projects
๐ Found in 3 projects:
โข api-backend: JWT authentication with refresh tokens
โข frontend-app: Google OAuth integration
โข mobile-app: Biometric authentication added
๐ Development Analytics
Understand your coding patterns:
$ brainet stats
๐ Development Insights
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Sessions: 47
Files modified: 234
Most active file: auth.py (23 changes)
Top tags: feature, bugfix, refactor
Recent activity:
โข 15 sessions this week
โข Peak productivity: Tuesday afternoons
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
๐ Commands
| Command | Description |
|---|---|
brainet start |
Initialize tracking in current project |
brainet capture |
Save current session with AI summary |
brainet history |
View all captured sessions with #01, #02 indexing |
brainet preview |
Preview what will be captured next |
brainet preview <N> |
View historical capsule #N |
brainet ask "question" |
Query your work with AI (v0.2.0: 5-source intelligence) |
brainet search "keyword" |
Search across sessions |
brainet workspaces |
List all tracked projects |
brainet stats |
View development analytics |
brainet export |
Export sessions to Markdown |
brainet diff <file> |
View colorized file changes |
brainet switch |
Quick navigation between projects |
Run brainet --help for full command list.
๐ฏ Real-World Use Cases
1. Context Switching
Switch between tasks without losing context:
# Working on Feature A
brainet capture --tag feature-a
# Emergency bug fix needed
brainet pause
cd ~/other-project
brainet start
# Fix bug...
brainet capture --tag hotfix
# Back to Feature A
cd ~/original-project
brainet resume # Instantly recall where you left off
2. Code Reviews
Generate PR descriptions automatically:
brainet export --since yesterday
# Copy the AI-generated summary into your PR
3. Weekly Standups
"What did I work on this week?"
brainet history --since "1 week ago"
# See all your accomplishments summarized
4. Knowledge Transfer
Onboarding a teammate:
brainet export --tag authentication > auth_work.md
# Share the complete history of authentication feature
๐ ๏ธ How It Works
- File Watching - Tracks changes in your git repository
- Git Integration - Captures commits, diffs, and file changes
- TODO Extraction - Finds TODO comments automatically
- AI Analysis - Claude Sonnet 3.5 generates intelligent summaries
- Local Storage - Everything saved locally in
.brainet/folder
Privacy First: All your data stays on your machine. AI summaries are generated via API but your code never leaves your control.
๐ง Configuration
API Keys
Brainet supports two AI providers:
Groq (Recommended) - Free, fast, 500+ tokens/sec
export GROQ_API_KEY="your_key_here"
Anthropic Claude - More powerful, requires paid account
export ANTHROPIC_API_KEY="your_key_here"
Advanced Options
# Capture with custom tags
brainet capture --tag feature --tag auth -m "Added JWT support"
# Export filtered sessions
brainet export --tag bugfix --since "2024-10-01"
# Search in current project only
brainet search "payment integration"
# Clean up old sessions
brainet cleanup --days 90
๐ Best Practices
- Capture Often - At least once per coding session
- Use Tags - Organize with
--tag feature,--tag bugfix, etc. - Add Messages - Use
-mfor important context - Regular Cleanup - Run
brainet cleanupmonthly - Export Important Work - Save milestones to Markdown
- Organize Projects - Keep projects in
~/Desktop,~/Documents, or~/Projectsfor theworkspacescommand to find them automatically
๐ค Contributing
Brainet is open source! Contributions welcome:
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing) - Open a Pull Request
๐ License
MIT License - see LICENSE file for details.
๐ Acknowledgments
- Built with Anthropic Claude
- Powered by Groq for fast AI inference
- Uses Rich for beautiful terminal output
- Created for developers, by developers
๐ฌ Support
- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Email: meetxiv@gmail.com
Stop losing context. Start using Brainet.
Made with โค๏ธ for developers who value flow state
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file brainet-0.2.3.tar.gz.
File metadata
- Download URL: brainet-0.2.3.tar.gz
- Upload date:
- Size: 81.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fafd668a540bcd5bd2e84c5b7f14624287c9bd4e7ca81a393bfa32d8e26eac27
|
|
| MD5 |
f1a23add2d94aad03eefadae9712a585
|
|
| BLAKE2b-256 |
4164ea2567bbc76ad6d3da54900de82154a31a9bef280d9e613922546614ece9
|
File details
Details for the file brainet-0.2.3-py3-none-any.whl.
File metadata
- Download URL: brainet-0.2.3-py3-none-any.whl
- Upload date:
- Size: 85.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
94bddd15938642eeadc797c6e4ae99d96a7059dfb12803d051878212406fbbad
|
|
| MD5 |
684f9188328ad33db95d5bdc12a3150f
|
|
| BLAKE2b-256 |
08addc735d8093e15492a6d6160617c38e3a1b6d98a000f5e3e417f7ead02bb8
|