{"id":51853609,"url":"https://github.com/jeremylongshore/bobs-big-brain-compiler","last_synced_at":"2026-07-23T22:01:50.201Z","repository":{"id":348828702,"uuid":"1200032869","full_name":"jeremylongshore/bobs-big-brain-compiler","owner":"jeremylongshore","description":"Bob's Big Brain Compiler — reads your files, notes, and web clips and turns them into organized, searchable knowledge with citations back to the source. One of Bob's Big Brain's two engines — the one that reads and organizes (npm: intentional-cognition-os).","archived":false,"fork":false,"pushed_at":"2026-07-19T21:16:43.000Z","size":2434,"stargazers_count":5,"open_issues_count":17,"forks_count":1,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-07-19T23:08:20.908Z","etag":null,"topics":["claude","compile-then-govern","compiler","governed-second-brain","intentional-cognition-os","knowledge-management","knowledge-os","local-first","provenance","rag","sqlite"],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jeremylongshore.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":"SECURITY.md","support":"SUPPORT.md","governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null},"funding":{"github":["jeremylongshore"]}},"created_at":"2026-04-03T01:00:05.000Z","updated_at":"2026-07-19T21:16:46.000Z","dependencies_parsed_at":"2026-05-26T00:01:24.331Z","dependency_job_id":null,"html_url":"https://github.com/jeremylongshore/bobs-big-brain-compiler","commit_stats":null,"previous_names":["jeremylongshore/intentional-cognition-os","jeremylongshore/bobs-big-brain-compiler"],"tags_count":96,"template":false,"template_full_name":null,"purl":"pkg:github/jeremylongshore/bobs-big-brain-compiler","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jeremylongshore%2Fbobs-big-brain-compiler","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jeremylongshore%2Fbobs-big-brain-compiler/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jeremylongshore%2Fbobs-big-brain-compiler/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jeremylongshore%2Fbobs-big-brain-compiler/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jeremylongshore","download_url":"https://codeload.github.com/jeremylongshore/bobs-big-brain-compiler/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jeremylongshore%2Fbobs-big-brain-compiler/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":35817929,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-07-20T02:08:10.276Z","status":"online","status_checked_at":"2026-07-23T02:00:06.683Z","response_time":57,"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":["claude","compile-then-govern","compiler","governed-second-brain","intentional-cognition-os","knowledge-management","knowledge-os","local-first","provenance","rag","sqlite"],"created_at":"2026-07-23T22:01:49.581Z","updated_at":"2026-07-23T22:01:50.195Z","avatar_url":"https://github.com/jeremylongshore.png","language":"TypeScript","funding_links":["https://github.com/sponsors/jeremylongshore"],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003cpicture\u003e\n    \u003csource media=\"(prefers-color-scheme: dark)\" srcset=\"assets/banner-dark.svg\"\u003e\n    \u003cimg alt=\"Bob's Big Brain Compiler — compile knowledge for the machine, distill understanding for the human.\" src=\"assets/banner-light.svg\" width=\"860\"\u003e\n  \u003c/picture\u003e\n\u003c/p\u003e\n\n# Bob's Big Brain Compiler\n\n\u003e Formerly `intentional-cognition-os` — the npm package keeps that name.\n\nBob's Big Brain Compiler reads your documents, notes, and web clips and turns them into an organized, searchable knowledge base — every answer backed by a citation to the source.\n\nA local-first knowledge OS. Point `ico` at a folder of PDFs, markdown notes, and web clips. It compiles them into a queryable wiki you can read, runs grounded Q\u0026A with inline citations, spins up multi-agent research tasks for hard questions, generates spaced-repetition flashcards from what landed, and writes every step to an append-only audit trail. Single CLI. Your data never leaves disk except for the Claude API calls you opt into.\n\n[![License](https://img.shields.io/badge/license-Apache_2.0-blue.svg)](LICENSE)\n[![npm](https://img.shields.io/npm/v/intentional-cognition-os.svg)](https://www.npmjs.com/package/intentional-cognition-os)\n[![CI](https://github.com/jeremylongshore/bobs-big-brain-compiler/actions/workflows/ci.yml/badge.svg)](https://github.com/jeremylongshore/bobs-big-brain-compiler/actions/workflows/ci.yml)\n[![Release](https://img.shields.io/github/v/release/jeremylongshore/bobs-big-brain-compiler)](https://github.com/jeremylongshore/bobs-big-brain-compiler/releases)\n\n\u003e **Part of the [Bob's Big Brain](https://github.com/intent-solutions-io/bobs-big-brain-umbrella) stack** — this is the **compile** layer. It pairs with [Bob's Big Brain Registrar](https://github.com/jeremylongshore/bobs-big-brain-registrar) (govern) and [qmd](https://github.com/tobi/qmd) (retrieve) to turn raw corpus into governed, citation-backed memory. → [Ecosystem overview](https://github.com/intent-solutions-io/bobs-big-brain-umbrella)\n\n---\n\n## What it actually does\n\nYou drop documents into a folder. `ico` reads them, compiles the content into a structured wiki on disk (one markdown file per source, per concept, per topic, per contradiction it found), and then lets you:\n\n- **Ask** a question — get an answer with `[source: filename]` citations next to every claim.\n- **Research** a question that's too big for a single retrieval — `ico` spawns a scoped task workspace with four agents (collector, summarizer, skeptic, integrator) that argue across stages and produce a cited final write-up.\n- **Render** a report or slide deck from any topic, and **promote** that artifact back into the wiki so the next answer can cite it.\n- **Recall** what you ingested — generate flashcards with spaced repetition; export to Anki if you prefer.\n- **Audit** anything. Every API call, file write, and task transition is recorded in append-only JSONL with a SHA-256 hash chain. If a citation looks wrong, you can trace it back to the exact source and prompt.\n\nIt is a cognition runtime, not a chat wrapper. The model proposes; a deterministic kernel owns durable state, traces, and control. **Your data lives in plain markdown + SQLite on your machine.** The model API is called only for the compilation/synthesis/reasoning steps — and only when you trigger them. The backend is a pluggable provider registry: Claude by default, or any OpenAI- or Anthropic-wire provider (OpenAI, Groq, NVIDIA, DeepSeek) or a local server (Ollama, vLLM, LM Studio) via `ICO_PROVIDER` — so you can keep every call on-device if you want to.\n\n---\n\n## Install\n\n```bash\n# the npm name predates the repo rename — intentional\nnpm install -g intentional-cognition-os\nico --version          # → 1.21.0\nexport ANTHROPIC_API_KEY=sk-ant-...\n```\n\nRequires **Node 22+** and an [Anthropic API key](https://console.anthropic.com/). pnpm not required for usage — only for building from source.\n\nFrom source:\n\n```bash\ngit clone https://github.com/jeremylongshore/bobs-big-brain-compiler.git\ncd bobs-big-brain-compiler \u0026\u0026 pnpm install \u0026\u0026 pnpm build\nnode packages/cli/dist/index.js --version\n```\n\n---\n\n## 5-minute quickstart\n\n```bash\n# 1. Create a workspace\nico init my-research\n\n# 2. Tell it where your sources live\nico mount add papers ~/Documents/papers --workspace my-research\n\n# 3. Ingest (parses PDFs/MD/web clips into ./raw/)\nico ingest ~/Documents/papers --workspace my-research\n\n# 4. Compile — the Claude calls happen here\nico compile all --workspace my-research\n\n# 5. Ask\nico ask \"How does self-attention scale with sequence length?\" \\\n    --workspace my-research\n```\n\nYou now have:\n\n- `my-research/wiki/` — readable markdown summary + concept + topic pages, all with frontmatter and inline `[[wikilinks]]`\n- `my-research/audit/log.md` — chronological human-readable record of what just happened\n- `my-research/audit/traces/*.jsonl` — machine-readable trace events for every step\n\n`ico status` shows counts. `ico lint` audits the wiki for schema drift / staleness / orphans. `tail workspace/audit/log.md` answers \"what did I do today.\"\n\n---\n\n## When to use it (and when not to)\n\n| You want to…                                                               | Use `ico`? | Why                                                      |\n| -------------------------------------------------------------------------- | ---------- | -------------------------------------------------------- |\n| Build a personal research base from PDFs + notes                           | ✅ Yes     | Core use case                                            |\n| Answer questions with traceable citations to your own sources              | ✅ Yes     | Citations are first-class, not bolted on                 |\n| Run a multi-step research investigation (literature review, due diligence) | ✅ Yes     | `ico research` spawns scoped agents with a skeptic stage |\n| Study what you've collected with spaced repetition                         | ✅ Yes     | `ico recall` builds + scores cards                       |\n| Replace your team's wiki / shared docs                                     | ❌ No      | Single-user, single-machine for v1                       |\n| Drop into Slack / chat with team-shared memory                             | ❌ No      | No multiplayer, no remote sync yet                       |\n| Build a customer-facing chatbot                                            | ❌ No      | Use LangChain / a managed RAG service                    |\n\n---\n\n## vs. the obvious alternatives\n\n|                                              | **ico**                                    | NotebookLM (Google) | Obsidian + AI plugins                             | Claude Projects / ChatGPT | LangChain / LlamaIndex    | Anki                          |\n| -------------------------------------------- | ------------------------------------------ | ------------------- | ------------------------------------------------- | ------------------------- | ------------------------- | ----------------------------- |\n| **Local-first**                              | ✅ markdown + SQLite on disk               | ❌ cloud            | ✅                                                | ❌ cloud                  | ✅ (library)              | ✅                            |\n| **Source-cited answers**                     | ✅ inline `[source:...]` per claim         | ✅                  | depends on plugin                                 | ✅ but no per-claim audit | you build it              | n/a                           |\n| **Inspectable compiled wiki**                | ✅ readable .md files                      | ❌ chat only        | ✅ (but you write the notes)                      | ❌                        | n/a — you build the store | n/a                           |\n| **Multi-agent research mode**                | ✅ collector→summarizer→skeptic→integrator | ❌                  | ❌                                                | ❌                        | you build it              | ❌                            |\n| **Spaced-repetition recall**                 | ✅ built-in, Anki export                   | ❌                  | plugin only                                       | ❌                        | ❌                        | ✅ (that's the whole product) |\n| **Append-only audit trail**                  | ✅ SHA-256 hash-chained JSONL              | ❌                  | ❌                                                | ❌                        | ❌                        | ❌                            |\n| **Open source / hackable**                   | ✅ Apache-2.0                              | ❌                  | partial (core closed)                             | ❌                        | ✅                        | ✅                            |\n| **Single CLI, no plugin zoo**                | ✅ 16 commands                             | n/a                 | ❌ (Obsidian Sync / Smart Connections / Copilot…) | n/a                       | ❌ you assemble           | n/a                           |\n| **You write the data; the AI just reads it** | ✅ kernel owns state                       | ✅                  | ✅                                                | ✅                        | depends                   | ✅                            |\n\n**The honest summary**: NotebookLM is the closest competitor in _function_, but it's a cloud product with no audit trail and no recall layer. Obsidian + plugins gets you a local wiki but you write every note yourself — `ico` writes the wiki for you by compiling sources. LangChain gives you the parts; `ico` is the assembled tool.\n\n---\n\n## The six layers (architecture in one screen)\n\n```\n   L1 raw/          ← what you put in (PDFs, MD, web clips)            APPEND-ONLY\n       ↓                                                                deterministic\n   L2 wiki/         ← compiled markdown (sources, concepts, topics,    RECOMPILABLE\n                      contradictions, open questions)                   probabilistic\n       ↓\n   L3 tasks/\u003cid\u003e/   ← scoped episodic research workspaces              PER-TASK\n                      (brief, evidence, notes, critique, output)        probabilistic\n       ↓\n   L4 outputs/      ← rendered reports, slides, briefings              PROMOTABLE\n                                                                        probabilistic\n       ↓\n   L5 recall/       ← flashcards, quizzes, retention scores            ADAPTIVE\n                                                                        deterministic\n   L6 audit/        ← trace JSONL + audit log + hash chain             APPEND-ONLY\n                                                                        deterministic\n```\n\nThe hard constraint, drilled through every component: **the model never directly writes to L6 or to promotion tables.** It proposes a summary, a card, a synthesis — the kernel decides whether it lands.\n\n---\n\n## Commands you'll actually use\n\n|                                   |                                                        |\n| --------------------------------- | ------------------------------------------------------ |\n| `ico init \u003cname\u003e`                 | Create a workspace                                     |\n| `ico mount add \u003cname\u003e \u003cpath\u003e`     | Register a source directory                            |\n| `ico ingest \u003cpath\u003e`               | Parse PDFs/MD/web-clips into the raw layer             |\n| `ico compile all`                 | Run the six compiler passes (Claude calls happen here) |\n| `ico ask \"\u003cquestion\u003e\"`            | Grounded Q\u0026A with citations                            |\n| `ico research \"\u003cbrief\u003e\"`          | Multi-agent research task (5 stages, ~5 min)           |\n| `ico render report --topic \u003ct\u003e`   | Generate a markdown report                             |\n| `ico recall generate --topic \u003ct\u003e` | Build flashcards from compiled wiki                    |\n| `ico recall quiz --topic \u003ct\u003e`     | Interactive quiz; tracks retention                     |\n| `ico recall export --format anki` | Anki-importable TSV                                    |\n| `ico lint`                        | Audit the wiki (schema, staleness, orphans)            |\n| `ico status` / `ico inspect`      | Workspace summary / per-subsystem detail               |\n\nGlobal flags on every command: `--workspace \u003cpath\u003e`, `--json`, `--verbose`, `--quiet`. Full reference: `ico --help` or any command with `--help`.\n\n---\n\n## Status\n\n**v1.21.0 — stable.** 1.21.0 tests passing across 5 packages. Used daily by the author. Public release on npm.\n\n- **Stable**: all 16 commands, the compilation passes, ask + research + recall + render + promote, the audit chain.\n- **In progress**: post-v1 coverage uplift on compiler + cli packages; mutation-testing baseline.\n- **Roadmap**: remote/sync (Phase 3), multi-user (Phase 4), plugin system (Phase 5). All deliberately deferred to keep v1 local-first and inspectable.\n\n---\n\n## Documentation\n\nThe detailed specs (architecture, frontmatter schemas, trace event types, promotion rules, etc.) live in [`000-docs/`](000-docs/). Start with [007-PP-PLAN-master-blueprint.md](000-docs/007-PP-PLAN-master-blueprint.md) if you want the authoritative design document, or [003-AT-ARCH-architecture.md](000-docs/003-AT-ARCH-architecture.md) for the system-design view.\n\nDevelopment setup, conventions, PR process: [CONTRIBUTING.md](CONTRIBUTING.md).\n\nVulnerability reporting: [SECURITY.md](SECURITY.md).\n\n---\n\n## License\n\nApache-2.0 — see [LICENSE](LICENSE).\n\n## Author\n\nJeremy Longshore · [intentsolutions.io](https://intentsolutions.io)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjeremylongshore%2Fbobs-big-brain-compiler","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjeremylongshore%2Fbobs-big-brain-compiler","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjeremylongshore%2Fbobs-big-brain-compiler/lists"}