Colleague
Colleague is the AI assistant that knows YOUR company. It is powered by your fine-tuned model (trained by Forge) and designed to improve from every correction.
What It Does
- Answers questions using your company's knowledge
- Learns implicitly from every interaction
- Routes corrections back into the training loop
- Surfaces knowledge through chat, voice, and a visual mind map
Interfaces
| Interface | Stack | Purpose |
|---|---|---|
| Web app | Next.js | Chat, voice, mind view, knowledge safes |
| API server | Express | REST API (port 4000) for native clients |
| Slack bot | Slack Bolt | Ask questions and ingest knowledge |
| macOS app | SwiftUI | Native desktop client |
| macOS widget | SwiftUI | Status bar quick access |
| MCP server | MCP SDK | Claude Code integration with direct DB |
| Background worker | BullMQ | Async job processing |
The Correction Loop
People interact with Colleague daily. When Colleague gets something wrong:
- User corrects the answer
- Correction becomes a new preference pair
- Forge retrains the model
- Colleague improves
This is the designed feedback loop -- every correction is an investment in a better model.
Architecture
Packages
| Package | Purpose |
|---|---|
packages/core | Domain objects, policies, interfaces (no vendor SDKs) |
packages/orchestrator | Use-cases, workflows, knowledge engine |
packages/providers | Adapters: OpenRouter, STT, TTS, Slack, pgvector |
packages/db | Drizzle schema, migrations, repositories |
packages/shared | Config, logger, utilities |
packages/authz | Authorization tuples and audit logging |
packages/worker-sdk | Background job task definitions |
Background Jobs
| Job | Interval | Purpose |
|---|---|---|
| Vault Promotion | 1 hour | Promotes high-connectivity reserves to their own vaults |
| Distillation | 12 hours | Consolidates knowledge within vaults |
Queues: ingestion, distillation, expert-consultation, vault-promotion, watcher-events.
Quick Start
# Install dependencies
make install
# Start web stack (postgres, redis, web app, background worker)
make dev
# Or start native/macOS stack
make dev-native
make dev-macos
Environment Variables
DATABASE_URL=postgres://ody:ody_dev_password@localhost:5433/ody
REDIS_URL=redis://localhost:6379
OPENROUTER_API_KEY=your-key-here