Architecture
Raiken is built as an Nx monorepo with a clear separation between the CLI, dashboard, and core logic.
Modules
| Module | Location | Responsibility |
|---|---|---|
| CLI | apps/cli | Fastify server, SSE output, tRPC API, serves dashboard in production |
| Dashboard | apps/dashboard | React + Vite UI for prompts, results, and approvals |
| Core | libs/core | LangGraph agent, tools, browser session, DOM capture, DB, testing |
| Shared | libs/shared | tRPC router and shared types |
Data flow
- User submits a prompt in the dashboard.
- CLI receives the prompt and streams agent output via SSE.
- Orchestrator runs the LangGraph agent with tool calls.
- Core tools execute browser actions, file operations, and test runs.
- Results are persisted locally in
.raiken/raiken.db.
Local persistence
Raiken keeps local state under .raiken/ so it can:
- store the code graph, keywords, embeddings, and memory
- cache analysis for faster follow-up prompts
- track test run history and outcomes
Ports
- CLI server + dashboard:
http://localhost:7101