Commit Graph

1 Commits

Author SHA1 Message Date
Valtteri Melkko
ab8540870b Implement task-type router with intelligent model selection and production setup
Major Changes:
- Implement task-type router (src/agents/task-type-router.ts) for intelligent model routing
  * Detects task type from user message (file-analysis, creative, debugging, cli, general)
  * Routes to optimal models: Gemini Flash (file analysis), Llama 3.3 70B (creative),
    Claude Sonnet 4.5 (debugging), Mistral Devstral 2 (CLI/general)
  * Integrated into model selection pipeline for seamless routing

- Integrate task-type routing into model resolution (src/agents/model-selection.ts)
  * Pass userMessage to resolveDefaultModelForAgent for context-aware routing
  * Maintain fallback chain for model availability

- Update attempt runner (src/agents/pi-embedded-runner/run/attempt.ts)
  * Pass prompt context to enable task-type based model selection

- Enhanced security and development (.gitignore)
  * Added comprehensive rules for sensitive files (.env variants, credentials)
  * Excluded API keys, runtime logs, test files, auto-generated skills directories
  * Properly ignored ecosystem.config, build artifacts, package manager locks

- Add technical documentation (README_Tech.md)
  * Process architecture (systemd Gateway, PM2 Dashboard, PM2 AI Product Visualizer)
  * Management commands and troubleshooting guide
  * Configuration summary and deployment checklist
  * Problem log with 6 documented issues and solutions

Result:
- Bot now intelligently routes user requests to optimal models based on message type
- Production-ready with systemd isolation, preventing PM2 conflicts
- Comprehensive documentation for future maintenance and troubleshooting
- Secure version control with quality .gitignore

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
2026-01-29 15:27:12 +00:00