doc.haus Atlas
Legal-document workflows on OpenCode, bound to their code
Journeys
Newcomer onboarding
From zero to a running doc.haus checkout: what the product is, how to boot it, how to contribute, and which rules govern every change.
5 stops →Legal-runtime authoring
How a lawyer-facing capability is composed: a command launches it, a skill carries the procedure, an agent executes it, and a playbook supplies the firm's positions — with the plugin policy wiring packs underneath.
5 stops →Jurisdiction-pack anatomy
What a jurisdiction pack is, how the loader validates it, and what one pack actually tells the model — read in pack order from registry to prompt text to loading code.
4 stops →V2 specs tour
The upstream OpenCode contracts underneath doc.haus: who owns what, how sessions admit and execute prompts, how tools are built and bounded, and the two accepted decisions on events and provider policy.
5 stops →Storage, ops, and migration
Where doc.haus keeps data, how the services fit together, and how older installations move forward — the operational backbone behind every matter.
4 stops →Getting Started
Start here. The product pitch and first boot (README), the setup walkthrough with provider connection and ports (docs/setup.md), where data lives and how to back it up (docs/storage.md), and the contributor rules that govern every change (AGENTS.md, CLAUDE.md, CONTRIBUTING.md).
- CLAUDE No need to read directly; read AGENTS.md instead.
- Contributing Read before submitting a change, alongside AGENTS.md.
- doc.haus Read first when installing, launching, or describing what doc.haus is.
- doc.haus contributor instructions Read before making any change to this repository.
- Setup Read when installing or configuring a new or isolated copy.
- Storage and backup Read before backing up, restoring, or changing data layouts.
Legal Layer
The doc.haus legal runtime: matter-scoped agents that read, review, draft and redline; the user-facing commands that launch them; the drafting-run owner mode; the reference skills they load (checklists, clause positions, research and verification procedure); and the five executable firm playbooks with byte-exact approved clause text.
- agent-builder Read when creating or maintaining firm custom subagents.
- Assignment and change of control Read when reviewing assignment or change-of-control terms.
- assumption-challenger Read when stress-testing findings before relying on them.
- chronology Read when building or rebuilding a matter timeline.
- chronology Read when launching a chronology run from a matter command.
- Cold-start interview Read when conducting the firm-profile interview.
- compare Read when comparing drafts, counterparty turns, or signed vs agreed form.
- Confidentiality Read when reviewing confidentiality or adjacent restraints.
- CUAD 41-category taxonomy mapped to the 12 checklist areas Read when classifying clauses in CUAD vocabulary or checking coverage.
- Data protection Read when reviewing data-processing terms.
- document-reviewer Read when reviewing documents for cited findings without changing them.
- draft Read when working on drafting-run ownership and stage execution.
- extract Read when filling review-grid cells or answering one question on one document.
- Force majeure Read when reviewing force-majeure or excuse provisions.
- Governing law and dispute resolution Read when reviewing governing law, venue, or dispute terms.
- import-playbook Read when importing an uploaded playbook from a matter command.
- Indemnification Read when reviewing indemnity scope or defense control.
- init Read when orienting on a matter (the legal equivalent of onboarding).
- Intellectual property Read when reviewing IP ownership, licenses, or work-product terms.
- lean-change-plan Read when working on the lean drafting pipeline's adjudication step.
- lean-change-prepare Read when working on the lean pipeline's amendment-preparation step.
- lean-change-review Read when working on the lean pipeline's pre-application review gate.
- lean-changes Read when working on the lean pipeline's amendment-list step.
- lean-checklist-check Read when working on the lean pipeline's checklist-verification step.
- lean-checklist-extract Read when working on the lean pipeline's checklist-extraction step.
- lean-discrepancy Read when working on the lean pipeline's discrepancy-assessment step.
- lean-draft Read when working on the lean pipeline's drafting step.
- lean-drafting-notes Read when working on the lean pipeline's lawyer-facing notes step.
- lean-intake Read when working on the lean pipeline's intake gate.
- lean-merge Read when working on the lean pipeline's concurrent-change merge step.
- lean-package-review Read when working on the lean pipeline's final review gate.
- lean-research Read when working on the lean pipeline's research step.
- lean-research-review Read when working on the lean pipeline's research-verification step.
- lean-review Read when working on the lean pipeline's general review step.
- lean-review-client-disadvantage Read when working on the lean pipeline's client-side review track.
- lean-review-independent Read when working on the lean pipeline's independent-fidelity track.
- lean-review-playbook Read when working on the lean pipeline's playbook-conformance track.
- lean-review-wording Read when working on the lean pipeline's wording track.
- lean-spine Read when working on the lean pipeline's post-research spine step.
- legal-review Read when running or debugging the full multi-agent review pipeline.
- Liability Read when reviewing liability caps and carve-outs.
- Limitation of remedies Read when reviewing remedy limits or damages waivers.
- lint-legal-runtime Read when validating drafting-runtime prompt files.
- narrator Read when working on drafting-run progress communication.
- obligations Read when extracting obligations, deadlines, or a compliance calendar.
- Payment Read when reviewing fee, escalation, or payment mechanics.
- playbook Read when launching a playbook check from a matter command.
- playbook-importer Read when importing or creating firm playbooks.
- playbook-reviewer Read when reviewing documents against a bound firm playbook.
- Q&A holds no editing tools, so the editing skills are off limits too: loading Read when answering questions about what matter documents say.
- redactor Read when permanently removing sensitive content from documents.
- redliner Read when editing matter documents as tracked changes.
- research Read when researching law across matter documents and US case law.
- review Read when launching a full legal review from a matter command.
- router Read when debugging assistant selection or adding a route.
- SKILL Read when reviewing a DPA under GDPR or UK GDPR.
- SKILL Read when reviewing a solicitor engagement letter.
- SKILL Read when reviewing a mutual NDA under US law.
- SKILL Read when reviewing a SaaS or cloud subscription agreement.
- SKILL Read when reviewing a services or consulting agreement.
- SKILL Read whenever quoting, citing, or asserting facts about matter documents or authority.
- SKILL Read when auditing citations before filing or sending.
- SKILL Read when judging market positions or proposing fallback language.
- SKILL Read when reviewing any commercial contract for risk.
- SKILL Read whenever creating a new matter document or template.
- SKILL Read when drafting or reviewing employment agreements and related documents.
- SKILL Read when setting up firm preferences or running firm-calibrated review, draft, or redline work.
- SKILL Read whenever a conclusion turns on what a statute or regulation says.
- SKILL Read after clause review to catch what the document omits entirely.
- SKILL Read before anything leaves the workspace to an outside recipient.
- SKILL Read whenever editing or redlining a matter document.
- SKILL Read before a deliverable is filed, sent, exported, or crosses a stage boundary.
- skill-builder Read when creating or maintaining firm skills.
- summarizer Read when summarizing matter material or review output.
- template-builder Read when creating or maintaining reusable drafting templates.
- Termination Read when reviewing termination, renewal, or exit terms.
- Warranties Read when reviewing warranty or disclaimer terms.
- workflow-builder Read when creating or maintaining review workflows.
Jurisdiction Packs
One prompt pack per supported jurisdiction. Each fixes governing law, authority hierarchy, citation style, official source and drafting conventions for model stages, plus a shared risk-calibration block that grades confidence by structural signals rather than certainty.
- Jurisdiction packs Read before adding a jurisdiction or wiring packs into stages.
- prompt Read when a matter is governed by DIFC law.
- prompt Read when a matter turns on Commonwealth law rather than a state.
- prompt Read when a matter is governed by New South Wales law.
- prompt Read when a matter is governed by Victorian law.
- prompt Read when a matter turns on federal rather than provincial law.
- prompt Read when a matter is governed by British Columbia law.
- prompt Read when a matter is governed by Ontario law.
- prompt Read when a matter is governed by Quebec law; essential civil/common-law divergence briefing.
- prompt Read when a matter is governed by Swiss law.
- prompt Read when a matter is governed by German law.
- prompt Read when a matter turns on EU rather than member-state law.
- prompt Read when a matter is governed by England and Wales law.
- prompt Read when a matter is governed by French law.
- prompt Read when a matter is governed by Hong Kong law.
- prompt Read when a matter is governed by Irish law.
- prompt Read when a matter is governed by Indian law.
- prompt Read when a matter is governed by Northern Ireland law.
- prompt Read when a matter is governed by Dutch law.
- prompt Read when a matter is governed by New Zealand law.
- prompt Read when a matter is governed by Scots law.
- prompt Read when a matter is governed by Singapore law.
- prompt Read when a matter turns on federal rather than state law.
- prompt Read when a matter is governed by California law.
- prompt Read when a matter is governed by Delaware law, especially entities and M&A.
- prompt Read when a matter is governed by Florida law.
- prompt Read when a matter is governed by Illinois law.
- prompt Read when a matter is governed by Massachusetts law.
- prompt Read when a matter is governed by New York law.
- prompt Read when a matter is governed by Texas law.
- prompt Read when a matter is governed by South African law.
Specifications
Upstream OpenCode V2 engineering specifications: current contracts for sessions and tools, accepted decision records for the event stream and provider policy, and one historical record of the catalog/config/plugin lifecycle decision. Authority notes say which package owns each concern.
- Catalog / Config / Plugin Lifecycle Options Read for the why behind catalog transforms; never as API reference.
- Provider Policy Read when gating providers, writing policy statements, or debugging allow/deny outcomes.
- V2 Event Stream Architecture Read when working on event delivery, subscriber overflow, or feed capacity.
- V2 Session Contract Read when working on session admission, execution, retry, compaction, or recovery behavior.
- V2 Specifications Read first when navigating the V2 specs or deciding where a behavior is specified.
- V2 Tools Read when building tools, plugin registration, or execution/bounding behavior.
Packages & SDKs
Upstream OpenCode package documentation: contributor guides (AGENTS.md), package READMEs, E2E and performance benchmark notes, and skill/test fixtures. These describe OpenCode infrastructure, not the doc.haus legal deployment — read them when working inside the package they sit in.
- @opencode/ai Read when calling models or media generation through @opencode/ai.
- @opencode/client Read when consuming OpenCode over HTTP or regenerating clients.
- @opencode/codemode Read before changing packages/codemode.
- @opencode/codemode Read when embedding or calling tools through confined programs.
- @opencode/core Read as a package label; real Core contracts live in specs/v2 and the tool/AGENTS.md below.
- @opencode/http-recorder Read when testing provider integrations with recorded traffic.
- @opencode/httpapi-codegen Read before changing client generation or the generator contract.
- @opencode/sdk Read when embedding OpenCode in an application.
- AGENTS Read before changing packages/app.
- AGENTS Read before writing, changing, or reviewing E2E tests.
- AGENTS Read before adding or running performance benchmarks.
- AGENTS Read before changing session-ui copy or text metrics.
- AGENTS Read when starting the stats site locally (then see its README).
- AGENTS Read before changing shared UI copy or text metrics.
- AI Package Guide Read before changing packages/ai.
- Browser plugin Read when driving the desktop browser from Code Mode.
- CI containers Read when changing CI container images.
- CLAUDE No need to read directly; read the sibling AGENTS.md instead.
- CLAUDE No need to read directly; read packages/app/AGENTS.md instead.
- CLAUDE No need to read directly; read packages/app/e2e/AGENTS.md instead.
- CLAUDE No need to read directly; read the performance AGENTS.md instead.
- CLAUDE No need to read directly; read packages/cli/AGENTS.md instead.
- CLAUDE No need to read directly; read packages/codemode/AGENTS.md instead.
- CLAUDE No need to read directly; read packages/core/src/tool/AGENTS.md instead.
- CLAUDE No need to read directly; read packages/desktop/AGENTS.md instead.
- CLAUDE No need to read directly; read packages/plugin/AGENTS.md instead.
- CLAUDE No need to read directly; read packages/schema/AGENTS.md instead.
- CLAUDE No need to read directly; read packages/session-ui/AGENTS.md instead.
- CLAUDE No need to read directly; read packages/stats/AGENTS.md instead.
- CLAUDE No need to read directly; read packages/tui/AGENTS.md instead.
- CLAUDE No need to read directly; read packages/ui/AGENTS.md instead.
- CLI and TUI development guide Read before changing the CLI or TUI.
- CodeMode Interpreter Support Read when checking whether a language feature runs in CodeMode.
- Completed Markdown Job Lifetime Read when benchmarking Markdown result lifetime and disposal.
- Component browser tests Read when adding or migrating component browser tests.
- Composer History Hydration Read when benchmarking composer history hydration.
- Core Tool Architecture Read before changing Core tool registration or execution.
- CreateEffect Simplification Implementation Spec Read when simplifying reactive effects in packages/app.
- Desktop package notes Read before changing the desktop app.
- Diff Highlighting Read when benchmarking diff highlighting.
- Effect Drizzle SQLite Adapter Read before syncing or changing the Drizzle adapter.
- first Read when working on skill-config fixture behavior.
- GitHub Copilot AI SDK Adapters Read before updating the Copilot adapters.
- Layer Graphs Read when composing or replacing Effect Layer wiring.
- Manual app performance suite Read before running or interpreting app performance benchmarks.
- Media generation in `@opencode/ai` — public API direction Read before extending media generation APIs.
- Native Terminal Benchmark Read when benchmarking native terminal rendering.
- OpenAPI Follow-ups Read before extending OpenAPI-to-tool conversion.
- OpenCode Read when working on OpenCode itself or answering V2 usage questions.
- OpenCode Desktop Read when building, packaging, or benchmarking the desktop app.
- OpenCode Stats Read when working on the stats site.
- OpenCode V2 Effect Plugin API Read when writing Effect-style OpenCode plugins.
- OpenCode V2 Promise Plugin API Read when writing Promise-style OpenCode plugins.
- opencode VS Code Extension Read when using or developing the VS Code extension.
- Patch Group Benchmark Read when benchmarking patch-group rendering.
- Persisted State Read when working on app persistence, migrations, or draft storage.
- Plugin Package Guide Read before changing the plugin package.
- README Read when running doc.haus web release or settings regression tests.
- README Read when running the app's E2E suite or deploying the web app.
- Report an opencode Issue Read when reporting an opencode bug.
- Schema Package Guide Read before changing @opencode/schema.
- second Read when working on skill-config fixture behavior.
- Session-export load benchmark Read when benchmarking session load from real exports.
- SolidStart Read only when scaffolding SolidStart basics in the console app.
- SolidStart Read only when scaffolding SolidStart basics in the enterprise package.
- Starlight Starter Kit: Basics Read only when scaffolding docs-site basics in packages/web.
- Tauri Icons Read when regenerating desktop icons.
- test262 Read when syncing or triaging test262 conformance.
- Timeline Layout Continuity Read when testing timeline stability under stress.
- Timeline Preload Lifetime Read when benchmarking timeline preload and Markdown disposal.
- Timeline Text Projection Benchmark Read when benchmarking streaming text projection throughput.
- TUI Experiments Read before adding or graduating TUI experiments.
- V2 Plugin System Implementation Plan Read for the plugin system's target design and migration; not as API reference.
- Vite TUI entrypoint Read when developing the TUI with hot reload.
Services & Ops
Running doc.haus: the service map and launcher, the in-app updater with its legacy-settings migration path, the retained upstream distribution tooling, synthetic PDF fixtures for ingest tests, website contributor guides, and an ast-grep lint note.
- CLAUDE No need to read directly; read services/www/AGENTS.md instead.
- CLAUDE No need to read directly; read services/www/src/docs/AGENTS.md instead.
- Documentation feature guide Read before changing the website's docs feature or its writing.
- Effect simplification rules Read when touching the effect-simplification lint rules.
- OpenCode Update Read when working on upstream distribution; doc.haus itself updates via docs/updates.md instead.
- OpenCode website Read when changing the upstream website package.
- Public Files Read when working on upstream file distribution (not doc.haus updates).
- Services Read for the service topology and which parts are doc.haus vs upstream.
- Synthetic PDF regression fixtures Read before regenerating fixtures or debugging ingest PDF tests.
- Updates and legacy migration Read before updating doc.haus or migrating an older installation.
- Website guide Read before changing services/www.
Fork Governance
The fork's legal and process backbone: GPLv3 licensing with the upstream MIT boundary, attribution for OpenCode/CUAD/Common Paper/Bonterms sources, the trademark policy, the security reporting route, and the upstream GitHub action and PR template.
- Additional grant no longer required Read when following an old link about an additional license grant.
- Attribution Read when reusing third-party material or checking provenance and license obligations.
- Licensing Read before distributing, modifying, or answering how doc.haus is licensed.
- opencode GitHub Action Read when wiring opencode into GitHub workflows (upstream tooling).
- pull_request_template Read when opening a pull request.
- Security Read before reporting a vulnerability or handling sensitive data.
- Trademark Policy Read before naming or branding a fork or derivative.
Atlas Meta
Documentation about the documentation tooling itself: how to author curated explorer fragments and graphs, the explorer catalog provenance contract, and the recorded provenance of the legal-skill design distillation.
- Authoring spec — curated explorer data fragments Read before hand-authoring explorer assessment or graph fragments.
- doc.haus — Architecture & Technology (code-verified) Read when checking what the code actually does against what the prose docs claim, or when triaging a divergence.
- Explorer catalog contract Read before publishing or consuming explorer catalog bundles.
- Legal skill design provenance Read when checking the design provenance of the legal skills.
- Repository Explorer — analysis pages Read when serving or regenerating the repository-explorer analysis page.
- Skills & Prompts Explorer — doc.haus Read when serving, regenerating, or publishing the skills explorer.