Apache Maka: The Open-Source AI Agent Workspace With 3,000+ GitHub Stars That Applies Event Sourcing to AI Execution
Apache Maka is a local-first AI agent workspace that records every model message, tool call, and decision in an append-only log. Learn how event sourcing makes AI agents reproducible, debuggable, and recoverable.
If you've ever debugged an AI agent that behaved differently on consecutive runs, or wondered why your agent made a specific decision three turns ago, you've hit the observability wall that plagues modern AI development. Most AI agent frameworks treat execution as ephemeral—once a turn completes, the intermediate reasoning, tool calls, and context decisions vanish into the void.
Apache Maka takes a radically different approach: it treats every AI agent interaction as a recoverable execution fact. Built on event sourcing principles, Maka records model messages, tool invocations, tool results, permission decisions, and termination events into an append-only log stored in SQLite. The result? A local-first AI workspace where you can replay, branch, and audit every decision your agent ever made.
With 3,093 GitHub stars and 411 stars gained today alone, Maka is trending as developers discover that AI agents need the same observability and reproducibility guarantees we've long demanded from production backend systems.
What Is Apache Maka?
Apache Maka (Incubating) is an open-source AI agent workspace currently undergoing incubation at The Apache Software Foundation. Unlike cloud-first AI platforms that send your data to external servers, Maka runs entirely on your machine. You bring your own model—whether that's a cloud API (OpenAI, Anthropic), a local model (Ollama, llama.cpp), or a compatible gateway—and Maka handles the orchestration, tool execution, and persistent logging.
The core philosophy is simple: your machine, your data, your record. Sessions, settings, and run records stay local by default. The append-only execution log becomes the single source of truth, and both the UI and subsequent model calls are projections of that record—not the only copy.
Key Architectural Principles
- Event Sourcing: Every agent interaction is an immutable event. Model messages, tool calls, and decisions are written to an append-only log before any side effects occur.
- Local-First: All data lives in SQLite on your machine. No cloud dependency, no data exfiltration.
- Sandbox Boundary: Tools that write files or execute shell commands must pass through a sandbox permission layer.
- Bring Your Own Model: Maka doesn't bundle a model account. You configure your own API keys or local model connections.
- One Runtime Host: Desktop, CLI, and evaluation interfaces all route through the same Runtime Host, ensuring consistent behavior across entry points.
Event Sourcing for AI Agents: Why It Matters
Event sourcing is a pattern borrowed from distributed systems and CQRS (Command Query Responsibility Segregation) architectures. Instead of storing only the current state, you store every state change as an immutable event. To reconstruct state, you replay the event log from the beginning.
For AI agents, this pattern solves three critical problems:
1. Reproducibility
AI agents are notoriously non-deterministic. The same prompt can yield different tool calls, different reasoning paths, and different final outputs depending on model temperature, context window state, and timing. With event sourcing, you can replay an exact execution sequence to understand why an agent made a specific decision.
// Maka's event log structure (simplified)
{
"event_type": "tool_call",
"timestamp": "2026-08-25T10:15:32Z",
"session_id": "sess_abc123",
"turn_id": "turn_42",
"tool_name": "bash",
"tool_input": { "command": "npm test" },
"tool_output": { "exit_code": 0, "stdout": "..." },
"permission_granted": true,
"sandbox_boundary_crossed": true
}
2. Debuggability
When an AI agent fails mid-task—say, after 15 tool calls and 3 branching decisions—traditional frameworks give you nothing but a stack trace and the final error message. Maka's event log lets you inspect every intermediate state: what the model saw, what it decided, which tool failed, and why the turn terminated.
The UI provides a timeline view of tool calls, making it trivial to spot where an agent went off the rails. You can branch from any turn, retry with different parameters, or regenerate a response while preserving the execution history.
3. Crash Recovery and Resume
AI agent runs can take minutes or hours. If your laptop sleeps, your network drops, or the process crashes, you typically lose all progress. Maka's append-only log means you can resume an interrupted turn from the last recorded event. The agent picks up where it left off, reusing cached tool results and avoiding redundant work.
# Resume an interrupted turn (CLI)
maka run --resume turn_42
# Or enable auto-resume in Desktop
export MAKA_RUNTIME_SAFE_BOUNDARY_RESUME=1
The Architecture: Desktop, CLI, and Eval
Maka provides three entry points, all backed by the same Runtime Host:
| Entry Point | Best For | Current Capability |
|---|---|---|
| Desktop | Daily interaction, file workflows, model setup | Electron + React with streaming sessions, tool timelines, branching, search, and recovery |
| TUI / CLI | Terminal-based workflows, non-interactive runs | maka, maka run; shares workspace and model connections with Desktop |
| Eval | Reproducible benchmark experiments | maka eval run <spec> --out <directory> |
Built-In Tools and Extensibility
Maka ships with a core set of tools: Read, Write, Edit, Bash, Glob, and Grep. These cover the 80% use case for code manipulation, file system operations, and text search. Optional tools like Computer Use (for GUI automation) and catalog skills can be enabled per-session.
The tool system enforces a sandbox boundary: any tool that writes to the file system or executes a shell command must be explicitly approved. This prevents runaway agents from corrupting your workspace or executing dangerous commands without oversight.
// Tool execution flow
AgentRun → ToolCall → SandboxCheck → PermissionGranted? → Execute → LogResult
// If permission denied:
{
"event_type": "tool_call_denied",
"tool_name": "bash",
"reason": "sandbox_boundary_violation",
"user_action_required": true
}
Real-World Example: Debugging a Multi-Step Refactoring
Imagine you ask Maka to refactor a large codebase: rename a function, update all call sites, run tests, and commit the changes. The agent makes 12 tool calls, modifies 8 files, and runs the test suite. But the tests fail on the third run, and you're not sure why.
With Maka's event log, you can:
- Inspect the timeline: See every file modification, test run, and model decision in chronological order.
- Branch from turn 8: The agent made a questionable rename decision at turn 8. Branch from that point and try a different approach.
- Compare branches: Run both branches side-by-side to see which refactoring strategy produces fewer test failures.
- Resume after crash: If the test suite hangs and you kill the process, resume from the last recorded event without re-running the first 7 tool calls.
# Branch from a specific turn
maka branch --from turn_8 --name "alternative-refactor"
# Compare two branches
maka diff main alternative-refactor
# View the event log for a specific turn
maka log turn_8 --verbose
This level of introspection is impossible with most AI agent frameworks, which treat each turn as a black box. Maka makes AI agent execution transparent, reproducible, and debuggable.
Key Benefits of Apache Maka
- Full Observability: Every agent decision is logged and queryable. No more "why did it do that?" mysteries.
- Reproducibility: Replay exact execution sequences to debug flaky agent behavior or validate fixes.
- Crash Recovery: Resume interrupted turns without losing progress or re-executing expensive tool calls.
- Local-First Privacy: All data stays on your machine. No cloud dependency, no data leakage.
- Sandbox Safety: Dangerous operations require explicit approval, preventing runaway agents.
- Branching and Experimentation: Fork agent runs at any point to explore alternative strategies.
- Model Agnostic: Use any LLM provider or local model. Maka doesn't lock you into a specific vendor.
- Open Source: Apache License 2.0. Inspect, modify, and contribute to the codebase.
Getting Started with Apache Maka
Maka is currently available for macOS (Apple Silicon), with Windows in preview and Linux support coming soon. Since it's an Apache Incubating project, you'll need to build from source until official releases are published.
Prerequisites
- Node.js 22.19 or newer (CI uses Node.js 24)
- npm (the lockfile uses npm 11)
- Git
- ripgrep (used by the Grep tool)
Installation
# Clone the repository
git clone https://github.com/apache/maka.git
cd maka
# Install dependencies
npm ci
# Start the Desktop development environment
npm run dev
On first launch, you'll need to configure a model connection:
- Open Settings → Models
- Add an API, local-model, or supported account connection
- Test the connection and choose a default model
- Return to the workspace and start a task
CLI Usage
# Build workspaces first
npm run build
# Start the TUI
npm run cli:dev
# Run a single non-interactive turn
npm run cli:dev -- run "Summarize this repository and identify risks"
# Run with graph visualization
npm run cli:dev -- run --graph "Implement two slices, integrate, then review"
How Maka Compares to Other AI Agent Frameworks
Most AI agent frameworks prioritize ease of use over observability. Tools like LangChain, AutoGen, and CrewAI provide high-level abstractions for building agents, but they treat execution as ephemeral. Once a turn completes, the intermediate state is discarded.
Maka takes the opposite approach: it prioritizes durability and introspection over convenience. The append-only log adds storage overhead, but it gives you unprecedented control over agent execution. For production systems where agent failures are costly, this trade-off is worth it.
If you're building AI agents for critical workflows—code refactoring, data pipelines, infrastructure automation—Maka's event sourcing model provides the safety net you need. If you're prototyping or experimenting, lighter-weight frameworks may be more appropriate.
FAQ
Is Apache Maka production-ready?
Maka is currently in Apache Incubation, which means it's under active development and not yet endorsed as a fully stable project. The macOS desktop build is an early public release, and data formats, CLI commands, and APIs may change. It's suitable for experimentation and non-critical workflows, but you should evaluate stability for production use cases.
Does Maka send my data to the cloud?
No. Maka is local-first by design. All sessions, settings, and execution logs are stored in SQLite on your machine. The only external communication is with the model provider you configure (e.g., OpenAI, Anthropic, or a local Ollama instance). API keys are stored in a local plaintext file readable only by your OS account.
Can I use local models with Maka?
Yes. Maka supports any model provider that exposes an OpenAI-compatible API, including local models running via Ollama, llama.cpp, or other inference servers. You configure the model connection in Settings → Models on first launch.
What happens if my agent crashes mid-task?
Maka's append-only log enables crash recovery. If a turn is interrupted, you can resume from the last recorded event using maka run --resume <turn_id> or by enabling auto-resume with MAKA_RUNTIME_SAFE_BOUNDARY_RESUME=1. The agent picks up where it left off, reusing cached tool results.
How does Maka handle dangerous operations?
Maka enforces a sandbox boundary for tools that write files or execute shell commands. These operations require explicit user approval before execution. If a tool call violates the sandbox policy, it's logged as denied and the agent must request permission again or abort.
Can I branch an agent run and explore different paths?
Yes. Maka's event log allows you to branch from any turn, creating a fork of the execution history. You can run multiple branches in parallel, compare their outcomes, and merge successful strategies. This is particularly useful for debugging or exploring alternative agent behaviors.
What platforms does Maka support?
Maka currently supports macOS (Apple Silicon, arm64) as the primary platform. Windows is available as an unsigned preview, and Linux support is planned but not yet available. The CLI and TUI work on any platform with Node.js, but the Desktop app is macOS-only for now.
Is Maka free to use?
Yes. Maka is open-source under the Apache License 2.0. You can use, modify, and distribute it freely. However, you'll need to provide your own model API keys or run a local model, which may incur costs depending on your provider.
Ready to build production-grade AI agents? Learn the fundamentals of AI development with CoddyKit's comprehensive courses. Master the skills you need to build, debug, and deploy AI systems that work reliably in the real world.