Release Date: January 15, 2025
Claude Parser v2.0.0 is a complete rewrite that transforms the tool from a simple parser into a comprehensive disaster recovery and analysis platform for Claude Code conversations. This release introduces Git-like commands, a clean Python API, and a robust architecture built on LNCA principles.
- Full Git-like interface for navigating Claude conversations
cg find- Search for files across all sessionscg checkout- Restore deleted filescg blame- Track file modificationscg reflog- View operation historycg show- Inspect specific operationscg reset- Time travel to any conversation state
- Composable hook runner for Claude Code integrations
- Pluggable executor architecture
- Support for all Claude hook events
- Environment variable configuration
- 30+ public functions across 15 domains
- Clean, intuitive imports
- Plain dict returns (no custom objects)
- Full Pydantic schema normalization
- Filtering: Message filtering by type, tool, content
- Watch: Real-time JSONL file monitoring
- Messages: Message processing utilities
- Models: Data models and utilities
- Direct SQL queries on JSONL files
- No intermediate database required
- Efficient handling of large sessions
- Schema inference and normalization
# v1 (old)
from claude_parser.main import ClaudeParser
# v2 (new)
from claude_parser import load_session, analyze_session- Removed all god objects
- Functions return plain dicts, not custom classes
- Explicit imports required (no wildcard imports)
- New domain-based organization
- Correct path is
~/.claude/projects/(not~/.claude/code/conversations/) - Project-specific files in
/project/.claude/
- Every file <80 LOC for optimal LLM comprehension
- 100% framework delegation - no custom loops or error handling
- Single source of truth - one file per feature
- Pydantic everywhere - consistent schema handling
- analytics - Session analysis
- cli - Command line interfaces
- discovery - File discovery
- filtering - Message filtering
- hooks - Hook system
- loaders - Data loading
- messages - Message utilities
- models - Data models
- navigation - Timeline navigation
- operations - File operations
- queries - SQL queries
- session - Session management
- storage - DuckDB engine
- tokens - Token management
- watch - Real-time monitoring
- 10x faster session loading with DuckDB
- 50% less memory usage with streaming
- Sub-second response times for most operations
- Efficient handling of GB-sized JSONL files
- Fixed schema mismatch in JSONL parsing
- Resolved UNION errors in SQL queries
- Corrected file path handling across platforms
- Fixed token counting for user vs assistant messages
- Resolved LOC violations in all modules
- typer - CLI framework
- rich - Terminal formatting
- duckdb - JSONL querying
- pydantic - Schema validation
- watchfiles - File monitoring (optional)
- Complete API reference
- User guide with real examples
- CLI command documentation
- Architecture overview
- Auto-deployed to GitHub Pages
- Update imports to use new structure
- Replace custom classes with dict operations
- Use CG commands for recovery operations
- Leverage new filtering capabilities
# v1
parser = ClaudeParser()
parser.load_session("file.jsonl")
parser.analyze_everything()
# v2
from claude_parser import load_session, analyze_session
session = load_session("file.jsonl")
analysis = analyze_session(session)# Lost files? Recover them!
cg find "important.py"
cg checkout /path/to/important.pyfrom claude_parser import calculate_session_cost
cost = calculate_session_cost(input_tokens=100000, output_tokens=50000)from claude_parser.filtering import filter_messages_by_type
user_messages = filter_messages_by_type(messages, "user")- Claude Code community for feedback and testing
- Contributors who helped identify v1 limitations
- LNCA principles for guiding the architecture
- 500+ commits since v1
- 15 specialized domains
- 30+ public API functions
- 100% test coverage on critical paths
- 0 known critical bugs
- Advanced pattern matching in
cg find - Multi-session diff capabilities
- Enhanced hook integrations
- Performance optimizations for very large sessions
- Additional export formats
- v1 is now deprecated and will not receive updates
- v2 is the recommended version for all users
- Documentation available at https://alicoding.github.io/claude-parser/
Thank you for using Claude Parser! This v2 release represents months of work to create the ultimate disaster recovery tool for Claude Code users.