04a7085007220b876c4a328d317110a0801a5829
Add comprehensive REPL commands for session management and introspection: **Session Tracking** (`crates/core/agent/src/session.rs`): - SessionStats: Track messages, tool calls, tokens, timing - SessionHistory: Store conversation history and tool call records - Auto-formatting for durations (seconds, minutes, hours) **REPL Commands** (in interactive mode): - `/help` - List all available commands - `/status` - Show session stats (messages, tools, uptime) - `/permissions` - Display permission mode and tool access - `/cost` - Show token usage and timing (free with Ollama!) - `/history` - View conversation history - `/clear` - Reset session state - `/exit` - Exit interactive mode gracefully **Stats Tracking**: - Automatic message counting - Token estimation (chars / 4) - Duration tracking per message - Tool call counting (foundation for future) - Session uptime from start **Permission Display**: - Shows current mode (Plan/AcceptEdits/Code) - Lists tools by category (read-only, write, system) - Indicates which tools are allowed/ask/deny **UX Improvements**: - Welcome message shows model and mode - Clean command output with emoji indicators - Helpful error messages for unknown commands - Session stats persist across messages **Example Session**: ``` 🤖 Owlen Interactive Mode Model: qwen3:8b Mode: Plan > /help 📖 Available Commands: [list] > Find all Cargo.toml files 🔧 Tool call: glob... ✅ Tool result: 14 files > /status 📊 Session Status: Messages: 1 Tools: 1 calls Uptime: 15s > /cost 💰 Token Usage: ~234 tokens > /exit 👋 Goodbye! ``` Implements core M12 requirements for REPL commands and session management. Future: Checkpointing/rewind functionality can build on this foundation. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Description
Releases
5
Release v0.1.10
Latest
Languages
Rust
99.5%
Shell
0.5%