doc.haus Atlas Legal-document workflows on OpenCode, bound to their code
219 documents
dochaus/jurisdiction/README.md

How jurisdiction packs work: a matter carries jurisdiction codes, each a directory with profile.json (code matching the directory, name, citation style, descriptive preferredModel) and a prompt.md of governing-law and reasoning guidance; ingest serves packs via GET /jurisdictions, the loader validates codes, stage context supplies packs to substantive stages only, and legal policy injects each pack as a system block. Read before adding a jurisdiction or wiring packs into stages.

⚠ 1 documented claim in this file disagrees with the tree:
  • “Add a directory beneath `dochaus/jurisdiction/` with these files:” — doc claims 2, tree has 3
Full drift report →

Jurisdiction packs

A matter can carry several jurisdiction codes. Packs supply the legal reasoning and citation context for substantive model stages. Add a directory beneath dochaus/jurisdiction/ with these files:

<CODE>/
  profile.json
  prompt.md

Codes must start with a letter or digit and contain only letters, digits, underscores or hyphens. The profile's code must match the directory name.

{
  "code": "EW",
  "name": "England & Wales",
  "citationStyle": "OSCOLA",
  "preferredModel": null
}

name identifies the pack in the interface. citationStyle describes the citation convention. preferredModel is currently descriptive metadata; it does not select a provider, model or inference region. Model selection comes from this installation's explicitly saved primary and fast settings.

Write prompt.md as concise guidance on governing law, the authority hierarchy, citation conventions and any jurisdiction-specific reasoning limits. Ground the guidance in general legal practice and preserve relevant provenance.

The ingest service exposes packs through GET /jurisdictions and stores the user's selected codes in the matter's matter.json jurisdictions array. The pack loader validates codes and loads their profiles and prompt fragments. Stage context supplies the selected packs to substantive stages; draft orchestration, routing and narration receive no jurisdiction packs. Legal policy adds each applicable pack as a <jurisdiction> system block. Missing prompt files produce a warning and profile-only context; unknown or mismatched profiles are not loaded.