internal/

directory
v2.10.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 9, 2026 License: Apache-2.0

Directories

Path Synopsis
api
Package api is the thin driving adapter between the generated strict HTTP server (package apigen) and the engine.
Package api is the thin driving adapter between the generated strict HTTP server (package apigen) and the engine.
gen
Package apigen provides primitives to interact with the openapi HTTP API.
Package apigen provides primitives to interact with the openapi HTTP API.
Package auth is the identity port: who is making this request, and may they do what they are asking.
Package auth is the identity port: who is making this request, and may they do what they are asking.
access
Package access is the Authorizer for an access list (docs/adr/0011, TAXONOMY.md D27): four roles, each a bundle of permissions, and teams that scope a contributor's work.
Package access is the Authorizer for an access list (docs/adr/0011, TAXONOMY.md D27): four roles, each a bundle of permissions, and teams that scope a contributor's work.
proxy
Package proxy is the Authenticator for a deployment behind an authenticating reverse proxy (oauth2-proxy, Pomerium, Authelia, an ingress with OIDC): the proxy verifies the person and forwards their identity in a header, and this adapter trusts that header.
Package proxy is the Authenticator for a deployment behind an authenticating reverse proxy (oauth2-proxy, Pomerium, Authelia, an ingress with OIDC): the proxy verifies the person and forwards their identity in a header, and this adapter trusts that header.
roles
Package roles is a role-based Authorizer: principals in a write role may read and write, principals in a read role may read, everyone else is refused.
Package roles is a role-based Authorizer: principals in a write role may read and write, principals in a read role may read, everyone else is refused.
Package codec is the port between a manifest's text and its document.
Package codec is the port between a manifest's text and its document.
conformance
Package conformance is the suite every codec.Codec adapter must pass: what the engine relies on, written once, run against each syntax.
Package conformance is the suite every codec.Codec adapter must pass: what the engine relies on, written once, run against each syntax.
json
Package json is the JSON codec.
Package json is the JSON codec.
yaml
Package yaml is the YAML codec: yaml.v3 to read, yamlfmt to write, so a file saved by Cartograph keeps the two-space indentation the vaults are written in by hand.
Package yaml is the YAML codec: yaml.v3 to read, yamlfmt to write, so a file saved by Cartograph keeps the two-space indentation the vaults are written in by hand.
Package config is the one place the process reads its environment.
Package config is the one place the process reads its environment.
Package contract embeds the JSON Schema files from contract/schemas so the compiled binary is self-contained.
Package contract embeds the JSON Schema files from contract/schemas so the compiled binary is self-contained.
Package crdt is the port between the engine and the replicated data type under every shared draft.
Package crdt is the port between the engine and the replicated data type under every shared draft.
automerge
Package automerge is the crdt port's adapter: Automerge, compiled to WebAssembly from the crate in crdt/ and run on wazero, so the engine stays pure Go (CGO_ENABLED=0) and speaks the same document format and sync protocol as every interface using the stock Automerge libraries (docs/adr/0007).
Package automerge is the crdt port's adapter: Automerge, compiled to WebAssembly from the crate in crdt/ and run on wazero, so the engine stays pure Go (CGO_ENABLED=0) and speaks the same document format and sync protocol as every interface using the stock Automerge libraries (docs/adr/0007).
conformance
Package conformance is the suite every adapter of the crdt port must pass.
Package conformance is the suite every adapter of the crdt port must pass.
Package decide is the port through which the engine asks typed questions of a piece of text: which of these options it is, or whether a statement holds of it, each answer a calibrated probability (docs/adr/0023).
Package decide is the port through which the engine asks typed questions of a piece of text: which of these options it is, or whether a statement holds of it, each answer a calibrated probability (docs/adr/0023).
conformance
Package conformance is what every decide.Decider must do: answer every question asked, pick a Choice from its own options with probabilities that are probabilities, give a YesNo a probability, and stop when its context is cancelled.
Package conformance is what every decide.Decider must do: answer every question asked, pick a Choice from its own options with probabilities that are probabilities, give a YesNo a probability, and stop when its context is cancelled.
fake
Package fake is a decide.Decider for the gate's tests: it answers each question as a test scripts it, by the question's name, and any question not scripted as a model unsure of it would (every option alike, a yes or no at one half).
Package fake is a decide.Decider for the gate's tests: it answers each question as a test scripts it, by the question's name, and any question not scripted as a model unsure of it would (every option alike, a yes or no at one half).
laya
Package laya is a Decider backed by Laya, an open decision model, run as a sidecar beside Cartograph (deploy/laya): the model needs a runtime the static binary does not carry, so it is reached over HTTP on the same host or network.
Package laya is a Decider backed by Laya, an open decision model, run as a sidecar beside Cartograph (deploy/laya): the model needs a runtime the static binary does not carry, so it is reached over HTTP on the same host or network.
Package document reads a document's text: its sections, by their headings, and the registers its tables hold.
Package document reads a document's text: its sections, by their headings, and the registers its tables hold.
Package engine is the kind-agnostic manifest engine: it validates manifests against their schema, references and kind rules, stores immutable versions, computes diffs, and indexes cross-manifest references.
Package engine is the kind-agnostic manifest engine: it validates manifests against their schema, references and kind rules, stores immutable versions, computes diffs, and indexes cross-manifest references.
Package evaluate judges a change agents use the way docs/EVALUATING.md says: by criteria scored from the server and the trace, never from an agent's report, run after run on one frozen build, until enough pass in a row.
Package evaluate judges a change agents use the way docs/EVALUATING.md says: by criteria scored from the server and the trace, never from an agent's report, run after run on one frozen build, until enough pass in a row.
Package fanout is the port that carries a small message from one replica of the engine to every other (docs/adr/0008).
Package fanout is the port that carries a small message from one replica of the engine to every other (docs/adr/0008).
conformance
Package conformance is the suite every fanout.Bus adapter must pass.
Package conformance is the suite every fanout.Bus adapter must pass.
memory
Package memory is the in-process fanout.Bus: every Bus made from one Hub delivers to every subscriber of that Hub.
Package memory is the in-process fanout.Bus: every Bus made from one Hub delivers to every subscriber of that Hub.
postgres
Package postgres is the fanout.Bus over Postgres LISTEN/NOTIFY, so a deployment whose state is in Postgres needs no second service for fan-out (docs/adr/0008).
Package postgres is the fanout.Bus over Postgres LISTEN/NOTIFY, so a deployment whose state is in Postgres needs no second service for fan-out (docs/adr/0008).
Package identity is who a request runs as and what they ask to do, without HTTP: the part of the identity port (docs/ARCHITECTURE.md) the engine may know.
Package identity is who a request runs as and what they ask to do, without HTTP: the part of the identity port (docs/ARCHITECTURE.md) the engine may know.
Package kinds is the registry of every manifest kind: its schema file and its rules function, if it has one beyond schema and generic reference validation.
Package kinds is the registry of every manifest kind: its schema file and its rules function, if it has one beyond schema and generic reference validation.
goal
Package goal implements the Goal kind's rules beyond its JSON Schema: parent presence by level (a goal has no parent; an objective requires a goal as parent; an outcome requires an objective goal as parent), unique key result ids within the goal, the key result unit-by-kind rule, and the objective must-be-qualitative rule.
Package goal implements the Goal kind's rules beyond its JSON Schema: parent presence by level (a goal has no parent; an objective requires a goal as parent; an outcome requires an objective goal as parent), unique key result ids within the goal, the key result unit-by-kind rule, and the objective must-be-qualitative rule.
kit
Package kit holds the small, dependency-free types that both the engine and the per-kind rule packages need.
Package kit holds the small, dependency-free types that both the engine and the per-kind rule packages need.
kpireadings
Package kpireadings validates a KPI's series beyond its JSON Schema.
Package kpireadings validates a KPI's series beyond its JSON Schema.
operation
Package operation implements the Operation kind's rules beyond its JSON Schema: a service's recurring funding lines (TAXONOMY.md D39) and its mandate's issuer (D43).
Package operation implements the Operation kind's rules beyond its JSON Schema: a service's recurring funding lines (TAXONOMY.md D39) and its mandate's issuer (D43).
portfolio
Package portfolio implements the Portfolio kind's rules beyond its JSON Schema (TAXONOMY.md D32).
Package portfolio implements the Portfolio kind's rules beyond its JSON Schema (TAXONOMY.md D32).
portfoliodecisions
Package portfoliodecisions implements the PortfolioDecisions kind's rules beyond its JSON Schema (TAXONOMY.md D32).
Package portfoliodecisions implements the PortfolioDecisions kind's rules beyond its JSON Schema (TAXONOMY.md D32).
programme
Package programme implements the Programme kind's rules beyond its JSON Schema: the risk list a project and a programme share, checked here without phases, because a programme holds no timeline, and the gap citations they also share.
Package programme implements the Programme kind's rules beyond its JSON Schema: the risk list a project and a programme share, checked here without phases, because a programme holds no timeline, and the gap citations they also share.
project
Package project implements the Project kind's rules beyond its JSON Schema: unique key result ids within each objective, the key result unit-by-kind rule, the objective must-be-qualitative rule, unique deliverable ids, unique success criteria ids, a success criterion's derivedFrom must name exactly one key result or deliverable that actually exists in this project, at most one funding line per currency, and a risk's escalate.reason is required when escalate.flag is true; every local reference resolves to an item this project actually has; and a dependency edge belongs to the dependency type and lands by a phase the timeline actually has.
Package project implements the Project kind's rules beyond its JSON Schema: unique key result ids within each objective, the key result unit-by-kind rule, the objective must-be-qualitative rule, unique deliverable ids, unique success criteria ids, a success criterion's derivedFrom must name exactly one key result or deliverable that actually exists in this project, at most one funding line per currency, and a risk's escalate.reason is required when escalate.flag is true; every local reference resolves to an item this project actually has; and a dependency edge belongs to the dependency type and lands by a phase the timeline actually has.
purpose
Package purpose implements the Purpose kind's one rule beyond its JSON Schema: a workspace states one purpose, so its metadata.id is always "default".
Package purpose implements the Purpose kind's one rule beyond its JSON Schema: a workspace states one purpose, so its metadata.id is always "default".
reportingcycle
Package reportingcycle holds the ReportingCycle kind's rules and the one derivation every reader of a cycle must agree on: which periods it has.
Package reportingcycle holds the ReportingCycle kind's rules and the one derivation every reader of a cycle must agree on: which periods it has.
segment
Package segment validates the slice tree beyond its JSON Schema.
Package segment validates the slice tree beyond its JSON Schema.
settings
Package settings implements the Settings kind's one rule beyond its JSON Schema: it is the only singleton kind, so its metadata.id must always be "default".
Package settings implements the Settings kind's one rule beyond its JSON Schema: it is the only singleton kind, so its metadata.id must always be "default".
stakeholdermap
Package stakeholdermap implements the StakeholderMap kind's rules beyond its JSON Schema: a map is scoped to a piece of work rather than to any manifest at all, and it scores each resource once.
Package stakeholdermap implements the StakeholderMap kind's rules beyond its JSON Schema: a map is scoped to a piece of work rather than to any manifest at all, and it scores each resource once.
team
Package team holds the Team kind's rules.
Package team holds the Team kind's rules.
Package layout is the port through which the workspace graph is placed for drawing.
Package layout is the port through which the workspace graph is placed for drawing.
conformance
Package conformance is what every layout.Layout must do: place every node somewhere finite, the same way every time, keep what is connected nearer than what is not, and keep a group together.
Package conformance is what every layout.Layout must do: place every node somewhere finite, the same way every time, keep what is connected nearer than what is not, and keep a group together.
force
Package force is a force-directed Layout: edges are springs, nodes push apart at short range, and each group drifts towards its own place on a ring, so the same kinds gather and a node sits between what it connects.
Package force is a force-directed Layout: edges are springs, nodes push apart at short range, and each group drifts towards its own place on a ring, so the same kinds gather and a node sits between what it connects.
layered
Package layered is a Layout for a directed acyclic graph: each group is a layer, drawn as a band from the top down in the order the engine numbers them, so every edge runs from a band to one above it or along its own.
Package layered is a Layout for a directed acyclic graph: each group is a layer, drawn as a band from the top down in the order the engine numbers them, so every edge runs from a band to one above it or along its own.
Package legacy reads manifests stored in an earlier release's shape: it rewrites retired names and shapes into the current ones, in place, and says which deprecated fields a document still holds.
Package legacy reads manifests stored in an earlier release's shape: it rewrites retired names and shapes into the current ones, in place, and says which deprecated fields a document still holds.
Package mcp is the MCP front door (docs/adr/0016): agents read, draft and propose through the same engine as people, with their person's authority and no more.
Package mcp is the MCP front door (docs/adr/0016): agents read, draft and propose through the same engine as people, with their person's authority and no more.
Package oauth is Cartograph's own OAuth 2.1 authorization server for agents (docs/adr/0016): the browser flow an MCP client starts, with no client registered anywhere beforehand.
Package oauth is Cartograph's own OAuth 2.1 authorization server for agents (docs/adr/0016): the browser flow an MCP client starts, with no client registered anywhere beforehand.
Package printer is the port through which a rendered document becomes a PDF.
Package printer is the port through which a rendered document becomes a PDF.
chromium
Package chromium prints HTML to PDF with a headless Chromium.
Package chromium prints HTML to PDF with a headless Chromium.
Package reporting is the port for reports: tables over the record for people and BI tools.
Package reporting is the port for reports: tables over the record for people and BI tools.
computed
Package computed is the reporting adapter that works out each report when asked, from the engine's reads: no storage of its own, the same on every store (docs/adr/0014).
Package computed is the reporting adapter that works out each report when asked, from the engine's reads: no storage of its own, the same on every store (docs/adr/0014).
conformance
Package conformance holds a reporting adapter to another's rows over the same record: every standard report, column for column, row for row, in any order.
Package conformance holds a reporting adapter to another's rows over the same record: every standard report, column for column, row for row, in any order.
postgres
Package postgres is the reporting adapter that answers reports from views in the deployment's own Postgres (docs/adr/0014), so SQL and BI tools read the same rows the API serves.
Package postgres is the reporting adapter that answers reports from views in the deployment's own Postgres (docs/adr/0014), so SQL and BI tools read the same rows the API serves.
Package semantic is the port through which the KPIs Cartograph records leave for, and later come back from, a semantic layer: the warehouse's own definitions of what each number is (TAXONOMY.md D57, docs/adr/0026).
Package semantic is the port through which the KPIs Cartograph records leave for, and later come back from, a semantic layer: the warehouse's own definitions of what each number is (TAXONOMY.md D57, docs/adr/0026).
conformance
Package conformance holds any semantic layer exporter to the port's promises: every KPI and data source in the layer is in what it writes, and the same layer always gives the same files.
Package conformance holds any semantic layer exporter to the port's promises: every KPI and data source in the layer is in what it writes, and the same layer always gives the same files.
dbt
Package dbt writes a semantic layer as dbt's: one YAML file of semantic_models and metrics, in the shape dbt's semantic layer reads (dbt 1.6 and later), for an analytics engineer to put in a dbt project beside the models it refers to.
Package dbt writes a semantic layer as dbt's: one YAML file of semantic_models and metrics, in the shape dbt's semantic layer reads (dbt 1.6 and later), for an analytics engineer to put in a dbt project beside the models it refers to.
Package sentence composes the sentences Cartograph stores in parts.
Package sentence composes the sentences Cartograph stores in parts.
Package spa embeds the web interface's build and serves it at "/", falling back to index.html for any path that is not a real file, so client-side routes resolve on a hard refresh.
Package spa embeds the web interface's build and serves it at "/", falling back to index.html for any path that is not a real file, so client-side routes resolve on a hard refresh.
Package spc is statistical process control for a measure read once a period (TAXONOMY.md D58): the individuals and moving range chart, its natural process limits, the signals that the process has changed, and how capable it is of meeting its specification limits.
Package spc is statistical process control for a measure read once a period (TAXONOMY.md D58): the individuals and moving range chart, its natural process limits, the signals that the process has changed, and how capable it is of meeting its specification limits.
Package store defines the two ports the engine is built against (ManifestStore and OperationalStore) and the record shapes they persist.
Package store defines the two ports the engine is built against (ManifestStore and OperationalStore) and the record shapes they persist.
conformance
Package conformance is the one test suite every store adapter must pass, proving the SQLite, in-memory and Postgres adapters are interchangeable behind the store ports.
Package conformance is the one test suite every store adapter must pass, proving the SQLite, in-memory and Postgres adapters are interchangeable behind the store ports.
manifestmeta
Package manifestmeta reads metadata.name and metadata.labels out of a manifest's text, for the store adapters that index both beside each version.
Package manifestmeta reads metadata.name and metadata.labels out of a manifest's text, for the store adapters that index both beside each version.
memory
Package memory is the in-memory ManifestStore and OperationalStore adapter used by tests and by the conformance suite.
Package memory is the in-memory ManifestStore and OperationalStore adapter used by tests and by the conformance suite.
postgres
Package postgres is the Postgres adapter for the ports a stateless deployment needs (docs/adr/0008): store.ManifestStore, store.OperationalStore, store.BundleStore and store.DocStore, over one database through pgx, a pure-Go driver, so the binary stays CGO_ENABLED=0.
Package postgres is the Postgres adapter for the ports a stateless deployment needs (docs/adr/0008): store.ManifestStore, store.OperationalStore, store.BundleStore and store.DocStore, over one database through pgx, a pure-Go driver, so the binary stays CGO_ENABLED=0.
sqlite
Package sqlite is the SQLite adapter for both store.ManifestStore and store.OperationalStore, backed by modernc.org/sqlite (a pure-Go driver, no cgo).
Package sqlite is the SQLite adapter for both store.ManifestStore and store.OperationalStore, backed by modernc.org/sqlite (a pure-Go driver, no cgo).
vault
Package vault implements store.ManifestStore over a directory tree: files are the source of truth.
Package vault implements store.ManifestStore over a directory tree: files are the source of truth.
Package syncserver is the sync socket (GET /api/v1/sync): the automerge-repo network protocol, version 1, over a WebSocket, so the stock @automerge/automerge-repo WebSocket adapter connects to the engine unchanged (docs/adr/0007).
Package syncserver is the sync socket (GET /api/v1/sync): the automerge-repo network protocol, version 1, over a WebSocket, so the stock @automerge/automerge-repo WebSocket adapter connects to the engine unchanged (docs/adr/0007).
Package timing reads when things fall (TAXONOMY.md D47, D48): a timing in its four forms, a target in its shapes, and a project's milestones as a chain of what waits on what.
Package timing reads when things fall (TAXONOMY.md D47, D48): a timing in its four forms, a target in its shapes, and a project's milestones as a chain of what waits on what.
Package trace is the port through which every call an agent makes to Cartograph's MCP server is recorded (docs/adr/0028), for governance and for finding where agents work well and where they vary: which tools are used most, which are refused, where work is redone.
Package trace is the port through which every call an agent makes to Cartograph's MCP server is recorded (docs/adr/0028), for governance and for finding where agents work well and where they vary: which tools are used most, which are refused, where work is redone.
jsonl
Package jsonl keeps traced calls as JSON lines appended to a file, one call a line, for any tool that reads JSON lines (and for cartograph traces) to analyse.
Package jsonl keeps traced calls as JSON lines appended to a file, one call a line, for any tool that reads JSON lines (and for cartograph traces) to analyse.
Package units holds the units every vault starts with (TAXONOMY.md D10): ordinary data, seeded by the engine into a vault that holds none and read when an earlier release's free-text unit is mapped to one.
Package units holds the units every vault starts with (TAXONOMY.md D10): ordinary data, seeded by the engine into a vault that holds none and read when an earlier release's free-text unit is mapped to one.
Package yamlfmt writes YAML the way the vaults are written by hand.
Package yamlfmt writes YAML the way the vaults are written by hand.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL