One program for building, running, governing and recording an application.
Code is now written faster than anyone can read it. DNA gives a Hale application what a company gives a product: people with final say, which DNA calls the Board; a reviewer with limited authority, an AI-backed role called the Leader; a delivery pipeline that proposes, proves and applies each change; the machines that run it and the monitoring that watches it; the models it may call and the budget it may spend; and an audit log of every decision. Those are usually four systems and a wiki. Here they are one program next to your code, with its working state in a database it owns and its history as commits in your repository.
What hale dna init writes
hale dna init generates the organism next to your code and leaves the application untouched. What it writes is the organization as source: a purpose and a charter, the Board and the Leader and the grant between them, the models and the daily budget, the work it accepts and the workflows that carry it, and a law the compiler holds against the wiring you actually built. It also writes what the organism runs on and what watches it. One program carries the whole loop from then on. You ask for something in a sentence, from a terminal, another clone, GitHub, or the page it serves. The substrate copies the repository, lets a model edit under a grant that is read, edit, format and check and nothing more, and commits the candidate there. The toolchain then checks, verifies and tests it, composes the fleet it would deploy, diffs it against the program's structure, rehearses rolling it back, and keeps every output under its own hash.
One review, three views, pinned to one commit: the source diff, the structural diff, the evidence. The Leader decides inside the grant, a model reading those views and leaving its reasoning on the record. The Board decides outside the grant, or when the law, an effect or the fleet's shape moves, and the Board is people. Approval is a commit. It is expressed, restarted here or redeployed by every node the plan assigns, and watched. An instance that falls over inside the observation window rolls the change back everywhere, and the record names the instance.
The working state lives in a database the organism owns, under its own roles; the nerves are a stream; the vault holds its secrets. The history is refs/dna/journal: one commit per event, in the repository the code lives in, so a teammate with a clone has the whole story and a pull request can be the review. The organism grows the way the code does. A new responsibility, a practice or a wider grant is a proposal, a candidate commit, a verdict and a restart, so the record is the organization.
What one organism holds
- The organization
Purpose and charter. The Board, people with final authority. The Leader, a model-backed position that decides inside a grant the Board wrote. Practices, proposed and settled as Board reviews. All of it is source in
dna/org. - Delivery
An ask becomes a task. A sandbox makes the change. The toolchain formats, checks, verifies and tests it, composes the fleet it would deploy, diffs the program's structure and rehearses the rollback. A review settles it, inside or outside the grant, or as a pull request. Approval applies it.
- Operations
Expression on your machine or across a fleet, with a plan naming each service's seed and node and
hale noderunning one. Senses and reflexes watching it. Roles per client on every backend, secrets in a vault, deployment profiles. A crash inside the observation window rolls back on every node it reached. - Business operations
Which models each position may call and a budget per day, probed by
hale dna models. Spend reserved, settled and compensated under a grant's windows. Receipts filed as customer or confidential and read only as recorded rows. Schedules for recurring work. - Working state
Memory in a database the organism owns, the nerves as a stream, the vault for secrets, brought up together by
hale dna dev. - History
refs/dna/journal, one commit per event: the ask, the sandbox, every model call with its cost and digests, each check with its receipt, the verdict with a name on it, the apply, the deploy, the outcome.hale dna history m1is one change's whole story, from any clone.
One session
The demo application, with the editor on scripted models so the transcript is reproducible. A hosted model gives the same commands and the same record.
$ hale dna init . # the organization, generated next to your code; the app untouched
$ hale dna dev # the organization and the application on this machine
$ hale dna ask document the chat server in main.hl
task t1 born for intent i1a08c0786c5 [pending]
$ hale dna review m1
review m1 [pending]: apply m1 (docs): document the chat server in main.hl?
needs leader · candidate bf94e503c1c002f277248b14b6afd1910bb8ce6f
source diff (git 232dc8f18dde .. bf94e503c1c0):
+// documented by the organism: Echo answers every Ping
semantic diff (hale model diff, baseline .. candidate):
classification: source-only · no semantic differences
evidence (fmt=0 check=0 verify=0 test=0 diff=0 rollback=0 fleet=0):
check yes 0 e3b0c44298fc
test yes 0 184a3407ce31
fleet yes 0 b33b2e832b21
rollback yes 0 89978376be81
$ hale dna review m1 approve --as riley --comment "fine"
review m1 settled: approve by riley
hale dna dev: expression restarted (pid 1875137) as 3c9b9327e480d349 build 7a489ad3e72c
hale dna dev: m1 observed healthy for 5s as 3c9b9327e480d349That is the daily surface: ask, review, status, history, board. A team sets git config dna.github, which turns every pending review into a pull request and every GitHub review into a verdict. A fleet adds a plan that names each service's seed and node; hale node runs a node, and an approval redeploys the instances it touched. The rest is how much the Leader may decide and which models it uses: a grant and a router in a file you own.
Why, in 2026
- More changes than you can read
Agents produce pull requests faster than reviewers absorb them, so review degrades to skimming and CI becomes the only real check. DNA does not make reading unnecessary. It makes each change one thing, already verified, and explains it twice: the source diff, and what changed in the program's shape. A rule that flips is one line in that view and a page of archaeology in the source. It also puts a first reader on every change whose reasoning you can audit: the Leader's verdict is a model call with its digests and its cost on the record, inside a grant only the Board can widen.
- Autonomy as a checkbox
Today an agent's permissions are a toggle in a tool: edit files, run commands, auto-approve. Here the boundary is a constitution the compiler enforces. The editing position cannot reach git, the network, a deployment or the organization's memory; the Leader decides and never commits; and
hale checkholds that against the org chart you wrote. Hand the editor a git handle and the build fails, with the path that shows why. Widening the grant is a reviewed commit, like any other change. - Agents edit repositories; systems run
A change is usually judged by tests, in a checkout, with no idea what is running where. Hale programs are modeled by their compiler, so a candidate is measured on what it does to that model and composed as the fleet it would deploy. A change to one service that breaks a claim over all of them is denied before a person sees a line. Every instance reports the model hash it expresses into the record, so
hale dna fleetcan say which replica runs which version. - Provenance is a chat log
Why a change happened is usually reconstructed from PR descriptions and transcripts. DNA's record has the ask, the sandbox, every model call with its cost and digests (never the prompt), each check with its receipt, the verdict with a name on it, the apply, the deploy and the outcome, as commits next to the code, synced like code.
hale dna history m1is one change's whole story, from any clone. - Rollback is a hope
A change that breaks production is reverted by whoever notices. Here a change that crashes one instance inside the observation window is reset to the commit it started from, on every node it reached, mechanically. A change you reject after the fact goes the same way. A retried apply reads its own record and never commits twice.
- Where it runs
In the
halebinary, on your workstation, with your model key or a local model, with git as the only shared service. No control plane.
The habitat in development
An organism looks after one application and its record. People rarely work inside just one. The same person answers to a team, a company and a customer, and firms cooperate on shared work without sharing their books. The habitat is the layer for that: the records, tools, channels and practices that several organisms and the people in them share, and the rules for sharing them. One effort's organism can be the habitat of several others, and the relationships between them need not form a tree. It never requires incorporation, control of an employer's systems, or a new accounting platform.
- A record is the unit of isolation
A repository and its record, with the backends attached to it: memory, nerves, secrets, senses. A clone is a replica of a record and carries no access of its own. Moving or cloning a record keeps its identity and provenance.
- Sharing is deliberate publication
Two firms keep their private records and agree on a third, shared one. They publish selected facts into it, each carrying its origin, lineage and purpose. Syncing a whole record cannot export part of a private history, so a shared record never receives one.
- Visibility is enforced
Whoever holds a full replica can read it, and a projection that filters rows cannot hide them. Sensitive material therefore lives outside the replicated record, as protected evidence in the record's own memory, read only through a principal-checked boundary. That covers its derivatives too: summaries, embeddings, prompts, the context a worker is given.
- Identity is bound at every entry
The face, the API, the command line, a synced decision, a callback, resumed work. Each checks the actor, the record, the current membership and the policy. A git author, a
--asflag or a position in a view is attribution only; proof comes from the check at the entry. - Three independent choices
Participation: one person, a team on one record, or firms cooperating through a shared record. Deployment: your machine, hosted behind a domain, or another admitted placement. Principal source: explicit local trust, or a verified identity provider. A hosted single user with an identity provider is a normal first profile.
- Authority as part of the graph
The compiler knows who owns a locus and what it can reach. The design adds on whose authority it runs:
runs_under(locus, principal), closed the way ownership is closed. A vault policy, a database role or a broker account then becomes the rendered reach of one principal, which nobody writes by hand, and a credential is cut for one attachment, short-lived and narrowed, never for the seat. - Responsibilities grow; equipment equips them
A new responsibility is a child the organism proposes from evidence of a need and the authority admits. Standard equipment gives it competence: research and decision briefs, qualification and offers, implementation and release, onboarding and support, receipt capture and reconciliation, publication and experiments, access and documents, deployment and recovery. Installing equipment creates no department, appoints no performer and grants no authority.
What exists today
| piece of the design | in the tree today |
|---|---|
| A record per repository, never rewound | Yes. Memory and the record. |
| Deliberate publication between records | Connections and handoffs of single facts with origin, lineage and purpose: hale dna connect, hale dna handoff. |
| Protected evidence outside the replicated record | Receipts filed as customer or confidential are kept in memory alone, and every read is a row: hale dna receipt. |
| Deployment profiles | hale dna new --profile local | remote-body, hale dna profile. |
| A verified principal source | An OIDC-signed head: git config dna.principal oidc. |
| Roles per client on each backend | Memory's roles, one broker account per role and per attached application, and vault slots. |
| Money reserved against grants | Spend reserved, settled and compensated under a grant's windows. |
runs_under, policies as projections, per-attachment credentials | Not built. Reserved as a relation for the compiler's registry. |
| Standard equipment | Not built. |
| Finance capture and books | Not built. No automated payment is part of the first slice. |
Nothing in the design is behaviour to rely on today unless the table says so. The habitat, as designed →
What it needs, and what it does not claim
- git
The record lives in the repository, so
newandinitmake one when there is none. Alone on one machine no remote is needed. A team, or nodes, need one. - docker compose
hale dna devbrings up the organism's private services with it: Postgres for its working state, which DNA calls memory; NATS for messaging between its parts, the nerves; Prometheus for monitoring, the senses. - A model
A key in the vault,
ollamaon your PATH, or a coding harness (claude, elsecodex) on it. The organism still runs without one; the Leader cannot decide anything, and every review waits for you. - Every change waits
Each waits for a verdict: the Leader's, inside a grant a person wrote, or the Board's. A restart is a restart. Live state does not carry across.
- A blind spot
The structural view cannot see what a handler computes. A
+1becoming+100is invisible to it, which is why the source diff is never optional, for people and for the Leader alike. The design was gated on a test of exactly that: reviewers deciding from the structural diff alone, the source alone, and both. The combined view is what shipped, and the structural view is credited with what it earned. It decides shape and rules, and it says when it cannot decide. - The habitat
Designed and partly built. The table above says which pieces are in the tree; the rest is not behaviour to rely on yet.
Start
The organism section of the guide reads the organism first: the map of its parts, getting started, one task end to end, then one chapter per part, and shaping and governing it. The building block underneath, with the record as a git branch, the review's pin and the autonomy rules, is DNA, the building block. The design it implements is Hale DNA, Phase 3, on the RFC.