{"id":47234783,"url":"https://github.com/sprklai/zenii","last_synced_at":"2026-05-24T20:05:57.515Z","repository":{"id":343699661,"uuid":"1174140392","full_name":"sprklai/zenii","owner":"sprklai","description":"20 megabytes. AI everywhere. Local AI backend powered by Rust: 114 API routes, native desktop app, plugins in any language","archived":false,"fork":false,"pushed_at":"2026-03-30T00:40:08.000Z","size":7300,"stargazers_count":15,"open_issues_count":16,"forks_count":3,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-03-30T01:31:50.041Z","etag":null,"topics":["ai-agents","ai-backend","cli","desktop-apps","developer-tools","local-ai","mit-license","ollama","open-source","openclaw-alternative","privacy","rust-lang","self-hosted-ai","tauri"],"latest_commit_sha":null,"homepage":"https://zenii.sprklai.com","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sprklai.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-03-06T05:34:31.000Z","updated_at":"2026-03-30T00:58:04.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/sprklai/zenii","commit_stats":null,"previous_names":["sprklai/mesoclaw","sprklai/zenii"],"tags_count":43,"template":false,"template_full_name":null,"purl":"pkg:github/sprklai/zenii","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sprklai%2Fzenii","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sprklai%2Fzenii/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sprklai%2Fzenii/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sprklai%2Fzenii/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sprklai","download_url":"https://codeload.github.com/sprklai/zenii/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sprklai%2Fzenii/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31290778,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-01T13:12:26.723Z","status":"ssl_error","status_checked_at":"2026-04-01T13:12:25.102Z","response_time":53,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai-agents","ai-backend","cli","desktop-apps","developer-tools","local-ai","mit-license","ollama","open-source","openclaw-alternative","privacy","rust-lang","self-hosted-ai","tauri"],"created_at":"2026-03-13T22:01:42.929Z","updated_at":"2026-05-24T20:05:57.506Z","avatar_url":"https://github.com/sprklai.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Zenii *(zen-ee-eye)*\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"assets/zenii-master.gif\" alt=\"Zenii demo\" width=\"720\" /\u003e\n\u003c/p\u003e\n\n\u003ch2 align=\"center\"\u003eOne local AI backend. Every interface.\u003c/h2\u003e\n\n\u003cp align=\"center\"\u003e\n  Run a daemon at \u003ccode\u003elocalhost:18981\u003c/code\u003e. Your desktop app, CLI, TUI, scripts,\n  and MCP clients share the same memory, tools, providers, channels, and scheduler — no sync, no duplication.\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/sprklai/zenii/releases/latest\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/v/release/sprklai/zenii?style=flat-square\" alt=\"Latest release\" /\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/sprklai/zenii/actions/workflows/ci.yml\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/actions/workflow/status/sprklai/zenii/ci.yml?style=flat-square\u0026label=CI\" alt=\"CI\" /\u003e\n  \u003c/a\u003e\n  \u003ca href=\"LICENSE\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/license-MIT-green?style=flat-square\" alt=\"MIT license\" /\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/sprklai/zenii/actions/workflows/ci.yml\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/tests-1790-blue?style=flat-square\" alt=\"1790 tests\" /\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/sprklai/zenii/pulls\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/PRs-welcome-brightgreen?style=flat-square\" alt=\"PRs welcome\" /\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n---\n\n## Start in 60 seconds\n\n```bash\ncurl -fsSL https://raw.githubusercontent.com/sprklai/zenii/main/install.sh | bash\nzenii-daemon \u0026\n\n# Store a fact once\ncurl -s -X POST http://localhost:18981/memory \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\"key\":\"deploy\",\"content\":\"Production database is on port 5434\"}' \u003e/dev/null\n\n# Ask about it later — from a script, cron job, or another machine\ncurl -s -X POST http://localhost:18981/chat \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\"session_id\":\"ops\",\"prompt\":\"What port is the production database on?\"}' | jq -r '.response'\n```\n\nThat is the core contract: write state once, read it from anywhere that speaks HTTP.\n\n\u003e [!TIP]\n\u003e **Interactive API Docs** — once the daemon is running, open\n\u003e **[http://127.0.0.1:18981/api-docs](http://127.0.0.1:18981/api-docs)**\n\u003e in your browser. You get a full Swagger-style explorer: every endpoint documented, live request\n\u003e testing, and code-snippet generation for **curl, Python, Go, TypeScript, Rust**, and more.\n\u003e No separate setup needed — it's built in.\n\n---\n\n## Why Zenii\n\nMost AI tools are per-session and per-interface. You get memory in the chat UI but not in your shell script. You wire a tool to one agent and have to re-wire it to the next.\n\nZenii solves this with a **shared local backend**:\n\n| Without Zenii | With Zenii |\n|---|---|\n| Each script manages its own AI context | One daemon holds memory for all of them |\n| Tools re-implemented per project | 19 tools registered once, available everywhere |\n| Provider API keys scattered across configs | One credential store, one place to rotate |\n| Desktop UI and scripts drift apart | Both call the same gateway |\n| MCP tools only available inside the IDE | Expose the same tools to any MCP client |\n\n---\n\n## Architecture\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"docs/assets/zenii_architecture.png\" alt=\"Zenii system architecture\" width=\"720\" /\u003e\n\u003c/p\u003e\n\nOne Rust library crate (`zenii-core`) holds all business logic. Five thin binary crates (daemon, CLI, TUI, desktop, MCP server) are shell wrappers around the same axum gateway, SQLite database, agent loop, and tool registry.\n\n---\n\n## What Ships Today\n\n**Interfaces**\n\n| Binary | Use it for |\n|---|---|\n| `zenii-daemon` | Local HTTP + WebSocket API server — the core of everything |\n| `zenii` | Quick prompts, shell pipelines, terminal workflows |\n| `zenii-tui` | Interactive terminal UI |\n| `zenii-desktop` | Native Tauri desktop app |\n| `zenii-mcp-server` | Expose all 19 Zenii tools to Claude Code, Cursor, VS Code |\n\n**Capabilities**\n\n| Domain | What it does |\n|--------|-------------|\n| **Memory** | Persistent semantic recall — BM25 field weighting, temporal decay, vector deduplication, content-addressed dedup |\n| **Karpathy LLM Wiki** | Ingest PDFs, DOCX, PPTX, XLSX, images — knowledge graph, AI query, auto-lint |\n| **AI Agent** | Multi-step reasoning, tool use, streaming, delegation with human approvals |\n| **Tools (19)** | Shell, file ops, web search, process control, patch, memory, wiki — one registry, every interface. Tool output compression keeps context lean (configurable per-tool line/result limits) |\n| **Providers (6+)** | OpenAI · Anthropic · Gemini · OpenRouter · Vercel AI Gateway · Ollama · any OpenAI-compatible endpoint |\n| **Workflows** | TOML/YAML DAG chains — tools, conditionals, loops, parallel steps, run history, cancellation |\n| **Scheduler** | Cron + interval jobs, each run as a full agent turn with access to all tools |\n| **Channels** | Telegram · Discord · Slack — inbound routing, unified inbox, threaded conversations (feature-gated) |\n| **MCP** | Server: expose all tools to Claude Code, Cursor, Gemini CLI, Windsurf · Client: consume external MCP servers |\n| **Security** | OS keyring · AES-256-GCM encryption · surface-based permission model (CLI/desktop/TUI/MCP/API) |\n\n---\n\n## Model Routing Hints\n\nPrepend a hint prefix to any prompt to route it to a specialized model without changing your provider config:\n\n```bash\n# Route to a reasoning-capable model\ncurl -s -X POST http://localhost:18981/chat \\\n  -H \"Authorization: Bearer $ZENII_TOKEN\" \\\n  -d '{\"prompt\":\"hint:reasoning Explain how the Raft consensus algorithm handles leader election\"}'\n\n# Route to a fast low-latency model\ncurl -s -X POST http://localhost:18981/chat \\\n  -H \"Authorization: Bearer $ZENII_TOKEN\" \\\n  -d '{\"prompt\":\"hint:fast What time is it?\"}'\n```\n\nConfigure each hint target in `config.toml`:\n\n```toml\nrouting_hint_reasoning = \"claude-opus-4-5\"\nrouting_hint_fast = \"gpt-4o-mini\"\nrouting_hint_vision = \"gpt-4o\"\nrouting_hint_summarize = \"claude-haiku-3-5\"\n```\n\nIf a hint has no configured target, the default model is used and a warning is logged.\n\n---\n\n## Karpathy LLM Wiki\n\nKnowledge compiled at ingestion time, not re-derived at every query. Drop in a document; Zenii extracts, indexes, and links the knowledge so your agent can answer questions against it instantly.\n\n```bash\n# Ingest a runbook, spec, or doc\ncurl -s -X POST http://localhost:18981/wiki/ingest \\\n  -H \"Authorization: Bearer $ZENII_TOKEN\" \\\n  -d '{\"url\": \"https://example.com/runbook.pdf\"}'\n\n# Query it — answers come from the compiled knowledge base\ncurl -s -X POST http://localhost:18981/wiki/query \\\n  -H \"Authorization: Bearer $ZENII_TOKEN\" \\\n  -d '{\"query\": \"What does section 3 say about rollback?\"}'\n```\n\n- Supports PDF, DOCX, PPTX, XLSX, and images via MarkItDown\n- Knowledge graph with force-directed visualization in the web UI\n- Queryable from any interface — CLI, desktop, or agent loop\n- Auto-lint detects inconsistency and gaps across pages\n\nFull guide: [docs.zenii.sprklai.com/wiki](https://docs.zenii.sprklai.com/wiki)\n\n---\n\n## MCP: Server and Client\n\n**As MCP server** — expose all 19 Zenii tools to any agent:\n\n```json\n// .mcp.json — works with Claude Code, Cursor, Gemini CLI, Windsurf, Codex\n{\n  \"mcpServers\": {\n    \"zenii\": {\n      \"command\": \"zenii-mcp-server\",\n      \"args\": [\"--transport\", \"stdio\"]\n    }\n  }\n}\n```\n\n**As MCP client** — Zenii can also consume external MCP servers. Add GitHub, Postgres, Filesystem, or any custom MCP server and its tools become available in your agent loop alongside Zenii's own 19.\n\n**[AGENT.md](AGENT.md)** — a machine-readable guide written for AI coding agents (Claude Code, Cursor, Gemini CLI, Windsurf, Codex). Drop it in your project or point your agent at it to give it a complete map of Zenii's API surface.\n\nFull guide: [docs.zenii.sprklai.com/mcp](https://docs.zenii.sprklai.com/mcp)\n\n---\n\n## Workflows and Scheduler\n\n**Workflows** — chain tools into DAGs with conditionals, loops, and parallel steps:\n\n```yaml\n# ~/.config/zenii/workflows/daily-digest.yml\nname: daily-digest\nsteps:\n  - id: search\n    tool: web_search\n    args: { query: \"Rust ecosystem news today\" }\n  - id: store\n    tool: memory_store\n    args: { key: \"digest/{{date}}\", content: \"{{steps.search.result}}\" }\n```\n\nRun manually: `POST /workflows/daily-digest/run`\n\n**Natural Language Workflow Creation** — describe a workflow in plain English; Zenii generates the TOML and opens the visual builder automatically. Available from the Workflows page (toggle to \"Describe in English\") and from the chat window (⬡ Workflow button, mutually exclusive with Delegate).\n\n**Scheduler** — trigger any prompt or workflow on a cron schedule, executed as a full agent turn with access to all tools:\n\n```bash\ncurl -s -X POST http://localhost:18981/scheduler/jobs \\\n  -H \"Authorization: Bearer $ZENII_TOKEN\" \\\n  -d '{\"name\":\"daily-digest\",\"cron\":\"0 8 * * *\",\"prompt\":\"Run the daily-digest workflow\"}'\n```\n\nFull guide: [docs.zenii.sprklai.com/workflows](https://docs.zenii.sprklai.com/workflows) · [docs.zenii.sprklai.com/scheduler](https://docs.zenii.sprklai.com/scheduler)\n\n---\n\n## Install\n\n### macOS / Linux\n\n```sh\ncurl -fsSL https://raw.githubusercontent.com/sprklai/zenii/main/install.sh | sh\n```\n\nInstalls `zenii` (CLI) and `zenii-daemon` to `~/.local/bin`.\n\n### Windows\n\nDownload and run the desktop installer (`.msi` or `.exe`) from\n[GitHub Releases](https://github.com/sprklai/zenii/releases/latest).\n\nFor headless / CLI-only, grab `zenii.exe` and `zenii-daemon.exe` from the same page.\n\n### Cargo\n\n```sh\ncargo install --git https://github.com/sprklai/zenii zenii zenii-daemon\n```\n\nFull platform notes: [Installation \u0026 Usage](https://docs.zenii.sprklai.com/installation-and-usage)\n\n---\n\n## Build from Source\n\nPrerequisites: Rust 1.85+, Bun, SQLite development libraries.\n\n```bash\ngit clone https://github.com/sprklai/zenii.git\ncd zenii\ncargo build --release -p zenii-daemon       # headless server\ncargo build --release -p zenii-cli          # CLI client\ncd crates/zenii-desktop \u0026\u0026 cargo tauri build # desktop app\n```\n\nFull setup guide: [docs/development.md](docs/development.md)\n\n---\n\n## Good Fit\n\n- Local automations that need shared memory across scripts, bots, and scheduled jobs\n- Developer tooling that wants a single AI backend reachable via HTTP or MCP\n- Self-hosted workflows where privacy and local control matter\n- Projects that want a desktop UI and a scriptable backend without maintaining two stacks\n- Self-hosted on a VPS, Raspberry Pi, or Docker — runs as a systemd service or container behind nginx/Caddy ([Deployment guide](https://docs.zenii.sprklai.com/deployment))\n\n## Zenii PiDog (Raspberry Pi) Demo\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"assets/Zenii-PiDog.gif\" alt=\"Zenii running on a Raspberry Pi PiDog robot\" width=\"540\" /\u003e\n\u003c/p\u003e\n\nZenii runs on ARM — same binary, same API. Deploy it on a Raspberry Pi, attach tools, and your hardware becomes an AI-addressable endpoint over HTTP.\n\n---\n\n## Not a Good Fit\n\n- Multi-user or SaaS deployments (single-user daemon, no multi-tenant auth)\n- Drop-in OpenAI-compatible server (Zenii has its own API surface)\n- Mobile apps (planned, not yet shipped)\n\n---\n\n## Docs\n\n- [Website](https://zenii.sprklai.com)\n- [Documentation](https://docs.zenii.sprklai.com)\n- [Installation \u0026 Usage](https://docs.zenii.sprklai.com/installation-and-usage)\n- [**Interactive API Explorer**](http://127.0.0.1:18981/api-docs) — live Swagger-style docs at `localhost:18981/api-docs` (daemon must be running)\n- [API Reference](https://docs.zenii.sprklai.com/api-reference)\n- [CLI Reference](https://docs.zenii.sprklai.com/cli-reference)\n- [Configuration](https://docs.zenii.sprklai.com/configuration)\n- [LLM Wiki](https://docs.zenii.sprklai.com/wiki)\n- [Architecture](https://docs.zenii.sprklai.com/architecture)\n- [AGENT.md](AGENT.md) — guide for AI coding agents\n- [CHANGELOG.md](CHANGELOG.md)\n- [ROADMAP.md](ROADMAP.md)\n\n---\n\n## Contributing\n\nTypo fixes, tests, and focused bug fixes can go straight to a PR.\nLarger feature work should start with [CONTRIBUTING.md](CONTRIBUTING.md).\n\nIf Zenii is useful to you — [star the repo](https://github.com/sprklai/zenii) and tell a developer friend.\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsprklai%2Fzenii","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsprklai%2Fzenii","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsprklai%2Fzenii/lists"}