Codra comprises a local-first system using a Tauri runtime. The frontend handles visualization of complex agent states, while a heavy, modular Rust backend performs the orchestration, systems control, and contextual indexing.
Codra is the local agent within the Talocode ecosystem. All execution, file operations, browser interaction, and agent reasoning happen locally. Talocode will serve as the remote control plane in future phases.
- Desktop Shell (Tauri): Provides the application window, OS-native menus, and inter-process communication (IPC) capabilities.
- Frontend (React): High-performance, reactive interface for viewing tasks, managing approvals, and agent dialog.
- Agent Orchestrator (
codra-core): The main state machine operating the agent. Contains sub-modules for Planning, Building, and Verifying. - Tooling Engine (
codra-tools): Provides filesystem operations, Git management, search indexing, and terminal sandboxing. - Computer-Use Engine (
codra-browser): A discrete sub-system utilizing CDP to spawn and control Chrome/Chromium, strictly separate from the Tauri interface webview. - Shared Data Layer (
codra-memory,codra-protocol): Provides SQLite bindings and shared TS/RS schema representations.
- Built on
Tauri 2, using WRY/Tao for rendering. - Communication with Rust happens exclusively through
tauri::commandhandlers mapped onto an asynchronous event model.
- React 18 + Vite with strictly enforced dark mode styling.
- Tailwind CSS for component-level configuration.
- Three-pane layout: Workspace Navigator (Left), Editor/Diff Visualizer (Center), and Agent/Task Orchestration (Right).
- No frontend persistence for critical state; all truth derives from the Rust core.
Operates as a state machine:
[IDLE] -> [RESEARCH] -> [PLAN] & [AWAIT_APPROVAL] -> [EXECUTE] -> [VERIFY] -> [DONE]
A plugin-like interface standardizing tool signatures for models. Every tool returns deterministic, typed output schemas, ensuring safe auto-parsing. Includes SafeToAutoRun logic to pause runs needing user confirmation.
Built around standard CDP (chrome-devtools-protocol or headless_chrome in Rust).
Responsible for launching targets, injecting JavaScript listeners, extracting DOM snapshots into prompt-friendly formats, and managing screenshot buffers.
- Model requested action over protocol.
- Rust handler applies security filter.
- If mutation or shell command, Rust invokes
ApprovalManagerwhich emits aPendingApprovalevent to Tauri. - UI awaits User confirmation.
- Action runs in PTY or filesystem securely.
- Checkpoints: Written to
.codra/checkpointssecurely. - Metadata: Indexed into
~/.codra-agent/data.sqlite. - Migration Compatibility: Runtime reads legacy
.forgeworkspace data when.codradata is not yet present.
Future versions will add:
- Connection to the Talocode control plane
- Remote task monitoring and mobile control
- Audit logging and permission systems
- Team workspace synchronization
These features will remain opt-in and will not compromise the local-first nature of the core agent.
- Browser runtime is in early development
- Full agent loop (planner → executor → verifier) is partially implemented
- Remote Talocode features are not yet available
See docs/ROADMAP.md for planned milestones.