This commit adds 6 new documentation files to fill critical gaps:
- CONTRIBUTING.md: Developer onboarding guide with setup, workflow,
code style, testing, and adding features
- TROUBLESHOOTING.md: Common issues and solutions for errors,
model issues, tool issues, channel issues, gateway issues,
configuration issues, and memory/database issues
- docs/api/PROTOCOL.md: Gateway JSON-RPC protocol documentation
with connection, authentication, message format, methods,
events, error codes, and example client implementation
- docs/api/TOOLS.md: Tools API documentation covering tool interface,
input schema format, result format, tool patterns,
tool registration, tool policy, execution flow, and
builtin tools reference
- docs/deployment/PRODUCTION.md: Production deployment guide
covering Docker deployment, systemd service, security,
configuration, monitoring, backup & recovery, and
performance tuning
- docs/performance/TUNING.md: Performance optimization guide
covering context management, model routing, tool execution,
memory & embeddings, session management, database
performance, gateway performance, and resource usage
These files complement the existing excellent documentation
(README.md, AGENTS.md, ARCHITECTURE.md, STRUCTURE.md,
CONVENTIONS.md) to provide complete coverage for users,
developers, and operators.
Store per-session config in SQLite and route /model and /reset through command fast-paths so channel sessions keep independent model selection across reconnects and restarts.
Add runtime truthfulness modes and autonomy-level tool gating with audit metadata for overrides/denials.
Wire policy through prompt assembly, tool execution context, and daemon/gateway agent paths; update tests and planning state for Phase 3 PR #2 completion.
Replace manual process management with systemctl --user commands.
Uses ollama.service and llama-server.service units for proper lifecycle
management, VRAM cleanup, and integration with system services.
Track PIDs of backends started by /backend command and only kill those
specific PIDs. Previous implementation used pkill which would kill all
Ollama/llama-server processes including those started by the user or
systemd services. Now we only terminate processes we started.
- Add local_providers with ollama and llamacpp configurations
- /backend command now stops current daemon before starting new one
- Start backends as detached processes to avoid blocking TUI
- Wait 500ms for daemon to initialize before switching
- Add session_config SQLite table for per-session settings
- Update routing to support session override → agent config → global default resolution chain
- Upgrade WebChat SessionBridge from NativeAgent to AgentOrchestrator
- Add /model, /local, /cloud commands to Telegram adapter
- Add /model command to WebChat gateway handlers
- Clear session overrides on /reset command
- Pass memoryStore and config through to SessionBridge
- Add comprehensive tests for all new functionality
Fixes model persistence bug where TUI model changes didn't affect WebChat/Telegram sessions. Now:
- TUI /model sets global default (persists across restarts, affects all new sessions)
- WebChat/Telegram /model sets session override (only that conversation, cleared on /reset)
- WebChat sessions gain AgentOrchestrator features (delegation, compaction, memory)
- README.md: Update audio config format to match schema (enabled + provider.* fields instead of old transcription_endpoint fields), add whisper.cpp server Docker example
- CHANGELOG.md: Add '### Fixed' section with voice message failure handling details
- config/default.yaml: Update audio section with new schema format and Docker setup example
- Send user feedback when voice/audio download fails instead of silent failure
- Send graceful message when audio transcription is not configured instead of empty text which crashes API