{"id":50783916,"url":"https://github.com/dbtlr/mimir","last_synced_at":"2026-07-05T03:00:18.767Z","repository":{"id":362697585,"uuid":"1258129112","full_name":"dbtlr/mimir","owner":"dbtlr","description":"Work-state engine over SQLite — one query layer, CLI for humans, MCP server for agents","archived":false,"fork":false,"pushed_at":"2026-07-02T01:36:50.000Z","size":1291,"stargazers_count":0,"open_issues_count":5,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-07-02T03:25:02.884Z","etag":null,"topics":["agentic-workflows","cli","coding-agents","mcp","mcp-server","sqlite","task-management","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/dbtlr.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"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-06-03T09:50:30.000Z","updated_at":"2026-07-02T01:36:45.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/dbtlr/mimir","commit_stats":null,"previous_names":["dbtlr/mimir"],"tags_count":36,"template":false,"template_full_name":null,"purl":"pkg:github/dbtlr/mimir","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dbtlr%2Fmimir","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dbtlr%2Fmimir/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dbtlr%2Fmimir/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dbtlr%2Fmimir/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dbtlr","download_url":"https://codeload.github.com/dbtlr/mimir/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dbtlr%2Fmimir/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":35141966,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-07-05T02:00:06.290Z","response_time":100,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["agentic-workflows","cli","coding-agents","mcp","mcp-server","sqlite","task-management","typescript"],"created_at":"2026-06-12T06:00:35.105Z","updated_at":"2026-07-05T03:00:18.619Z","avatar_url":"https://github.com/dbtlr.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# mimir\n\nMimir is the source of truth for **work state** — tasks, the work hierarchy, and\nthe frozen artifacts attached to them. It is the _work_ tool in a three-part\nsplit along the founding distinction of knowledge vs. work: **Norn** keeps\nknowledge, **Mimir** holds work state, **Saga** weaves them into a session.\n\nWork state is ephemeral and fast-changing, so it lives in a structured store\n(SQLite) where it is the source of truth — markdown is a _projection_, not the\nstore. Status rollups and dependency predicates are **derived live, never\nstored** (caching them is the sync problem Mimir exists to remove). One core\nquery layer, four surfaces: a **CLI** for humans and scripts, **MCP** for\nagents (plus an embedded agent skill the binary installs itself), an **HTTP\nAPI**, and a web **operator console** served by the same binary.\n\n![The operator console — a project board](docs/assets/console-board.png)\n\n\u003e **Status:** **pre-release** (`0.x`), feature-complete for single-operator\n\u003e use: the full read + write verb surface over CLI and MCP, the agent skill\n\u003e (`mimir skill install`) with repo binding (`.mimir.toml`), the HTTP API\n\u003e (`mimir serve`), and the read-only operator console — a kanban/tree PWA\n\u003e embedded in the binary (columns are the status vocabulary; the Ready column\n\u003e in rank order _is_ the queue). Write affordances in the console, and the\n\u003e auth story that must precede them, are the next slices.\n\n## Install\n\n**Standalone binary** (no Bun needed on the target):\n\n```sh\ncurl -fsSL https://raw.githubusercontent.com/dbtlr/mimir/main/install.sh | sh\n```\n\nInstalls the binary for your platform from the latest [release](https://github.com/dbtlr/mimir/releases)\nto `~/.local/bin` (override with `MIMIR_INSTALL_DIR`, pin with `MIMIR_VERSION`).\n\n**From source** (requires [Bun](https://bun.sh) `1.3.14`):\n\n```sh\ngit clone https://github.com/dbtlr/mimir \u0026\u0026 cd mimir \u0026\u0026 bun install\nbun run build    # compiles dist/mimir; or `bun run mimir \u003cverb\u003e` straight from source\n```\n\n## Quickstart\n\n```sh\nmimir --version\nmimir --help\nmimir migrate        # create / migrate the database (applied automatically on first run)\n```\n\nThe database lives at `$XDG_DATA_HOME/mimir/mimir.db` (default\n`~/.local/share/mimir/mimir.db`), so `mimir` works from any directory; set\n`MIMIR_DB` to use a per-project store instead.\n\nEvery entity has one rendered id, spoken by every surface: a project is the\nbare `KEY`, a tree node is `KEY-seq` (`MMR-16`), an artifact is `KEY-aN`\n(`MMR-a1`). Any id position takes the full grammar — the verb rejects what it\ncan't act on.\n\nThe read commands (one intent layer, rendered as CLI or MCP):\n\n```sh\nmimir next                        # ready tasks in rank order — \"what's next\"\nmimir next --scope MMR -p p0      # filter by project / priority (signals, not sort)\nmimir list --status done          # universe: status words, or live|terminal|all\nmimir list --is stale             # verdicts: stale|blocking|orphaned (--not-is negates)\nmimir list --eq priority:p1 --missing size --after created_at:2026-06-01\nmimir get MMR                     # the whole-project view (rollup + roots)\nmimir get MMR-16                  # full record for one node (KEY-seq id)\nmimir get MMR-16 --col history    # add the transition log\nmimir get MMR-a1 --col content    # an artifact, with its frozen body\nmimir status MMR-3                # an initiative/phase rollup (distribution + status)\nmimir next --format json | jq .   # structured, pipe-safe output\n```\n\nSelection is AND-composed: `--status` picks the universe, `--is`/`--not-is`\nverdicts and the field operators (`--eq` `--not-eq` `--in` `--not-in` `--has`\n`--missing` + date ops) filter within it. A value miss (`--eq priority:p9`)\nwarns and returns an empty set (exit 0); an unknown field is a usage error\n(exit 2).\n\nThe write verbs:\n\n```sh\nmimir create task \"wire the API\" --parent MMR-2 --priority p1 --tag api\nmimir start MMR-3 \u0026\u0026 mimir done MMR-3\nmimir depend MMR-4 --on MMR-3     # MMR-4 waits on MMR-3\nmimir tag MMR-3,MMR-a1 spec v2    # tag tasks, projects, artifacts (free-text)\nmimir attach MMR-3 --file plan.md # freeze an artifact (title from basename)\n```\n\nFormats: `table` / `records` (styled TTY) and `ids` / `json` / `jsonl`\n(structural, never styled). The default follows the destination — a table for a\nTTY set, `ids` when piped — and `--format` overrides. Identity selection\n(`get`/`status`) exits non-zero on a missing id; set selection (`next`/`list`)\nexits 0 on an empty result.\n\nRun as an MCP server for an agent:\n\n```sh\nmimir mcp     # JSON-RPC over stdio; the same read + write surface as tools\n```\n\nServe the HTTP API and the operator console:\n\n```sh\nmimir serve   # loopback-only, default port 64647\n```\n\n`http://127.0.0.1:64647/` is the console (the screenshot above): an Overview\nof every project with an attention strip of in-flight and stuck work, and a\nper-project kanban board / tree with a detail drawer on every node. It is an\ninstallable PWA — usable from a phone behind your own reverse proxy — that\npolls while visible and, when the server is unreachable, shows the last-synced\nboard behind an explicit offline banner. This first cut is **read-only**; the\nAPI under `/api/*` carries the same verb surface as the CLI/MCP for writes\n(TLS, hostnames, and exposure belong to the proxy in front — the binary stays\nloopback-only).\n\n## The model\n\n```\nproject → initiative → phase → task        (the work tree, via parent_id)\n```\n\n- **Two status axes** on tasks: `lifecycle` (todo → in_progress → done /\n  abandoned) and a `hold` overlay (none / blocked / parked). Non-leaf nodes\n  store **no** status — their truth is the live **distribution** over children,\n  reduced to one **status word** by a canonical `interpret` cascade.\n- **Rank** is a single relative order that wins over priority; priority/size are\n  orthogonal _signals_ that filter and advise, never the sort.\n- **Derived, never stored:** `ready`, `awaiting`, `blocked`, `blocking`,\n  `stale`, `orphaned`, and every rollup.\n\nThe reasoning behind the model lives in\n[`docs/decisions/`](docs/decisions/README.md) (the ADRs), with the concrete\nschema in [`docs/schema-reference.md`](docs/schema-reference.md) and the\nCLI/MCP output contract in\n[`docs/output-contract-reference.md`](docs/output-contract-reference.md).\n\n## Development\n\n```sh\nbun install\nbun run verify    # the full gate: format, lint, typecheck, test\n```\n\n`verify` is `bun run check` (oxfmt + oxlint + type-aware typecheck, zero-warning)\nplus `bun test` (the suite on in-memory SQLite) plus `bun run test:ui` (the\nconsole's vitest suite) — the same gate CI enforces. For UI work, run\n`vite dev` in `packages/ui` against a running `mimir serve` (localhost CORS is\npre-wired); `bun run build` builds the console and embeds it in the compiled\nbinary. `main` is protected; changes land via PR. See\n[CONTRIBUTING.md](./CONTRIBUTING.md), [CHANGELOG.md](./CHANGELOG.md), and\n[SECURITY.md](./SECURITY.md).\n\nArchitecture — one core, thin transports:\n\n```\npackages/contract/   @mimir/contract — pure DTO + wire types (the dependency-free leaf; the UI imports it)\npackages/bin/        @mimir/bin — the binary\n  src/db/            Kysely instance, schema/migrations, the Migrator\n  src/core/          storage-committed domain logic: derivation, rank, verbs, intent layer\n  src/cli/           the human transport (parseArgs + styled/structured renderers)\n  src/mcp/           the agent transport (official MCP SDK over stdio)\n  src/http/          the UI transport (resource-shaped REST over Bun.serve)\n  src/main.ts        composition root — dispatches subcommands\npackages/ui/         @mimir/ui — the operator console SPA (embedded in the binary)\n```\n\nThe layering `contract ← db ← core ← transports` is enforced by an oxlint\n`no-restricted-imports` rule: `core` may not import a transport, `db` may not\nimport `core`, and the transports may not import each other or `db`.\n\n## License\n\n[MIT](./LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdbtlr%2Fmimir","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdbtlr%2Fmimir","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdbtlr%2Fmimir/lists"}