OctoEvidence.Cli 0.0.9

There is a newer version of this package available.
See the version list below for details.
dotnet tool install --global OctoEvidence.Cli --version 0.0.9
                    
This package contains a .NET tool you can call from the shell/command line.
dotnet new tool-manifest
                    
if you are setting up this repo
dotnet tool install --local OctoEvidence.Cli --version 0.0.9
                    
This package contains a .NET tool you can call from the shell/command line.
#tool dotnet:?package=OctoEvidence.Cli&version=0.0.9
                    
nuke :add-package OctoEvidence.Cli --version 0.0.9
                    

OctoEvidence

OctoEvidence is a file-backed evidence, knowledge, and traceability control plane for a software system's full life cycle. Its built-in profile covers stakeholder need, requirements, architecture and design, implementation, integration, verification, validation, deployment/transition, operation, maintenance, and retirement.

The model is informed by ISO/IEC/IEEE 12207:2026. It is a tailorable product profile—not a copy of the standard, a forced waterfall, a substitute for professional judgment, or a certification claim. Stages may overlap, iterate, block, and reopen for controlled rework.

See PRODUCT.md for the product contract, docs/architecture.md for implementation boundaries, and the field guide for the people who use it. The field guide is written for the human who never opens a terminal. It walks eight flows a project actually runs through: day one on an existing codebase, brief to requirements, design, shipping a change, release and operation, drift and incidents, independent audit, and retirement. Every step shows the same three lanes: what the person says in their own words, what the agent does with the tool, and the decision only a human may take.

Supported surface

This greenfield project has one v1 format and no compatibility layer. The CLI exposes:

octoevidence init
octoevidence doctor
octoevidence agent
octoevidence id
octoevidence knowledge
octoevidence lifecycle
octoevidence mcp

Unknown configuration fields, versions, record layouts, roles, platforms, identity kinds, source kinds, statuses, document types, and trace relations fail closed.

Build

The repository targets .NET 10.

dotnet restore OctoEvidence.slnx
dotnet build OctoEvidence.slnx --no-restore
dotnet test OctoEvidence.slnx --no-build

Reviewer console

The reviewer console is a read-only React workspace for lifecycle stages, cumulative gate failures, pending knowledge review, registered source excerpts, freshness, dependency impact, and typed trace. It reads through OctoEvidence.Core; it has no mutation endpoint and does not create another data store.

Prerequisites:

  • .NET 10 ASP.NET Core runtime for the installed tool, or the .NET 10 SDK when running from source;
  • Node.js 22.12 or newer only when building from source or developing the React client;
  • an initialized repository containing octoevidence.json and at least one lifecycle.

From any directory inside an initialized source branch, start the installed tool:

octoevidence portal

The command discovers the nearest octoevidence.json, follows its configured knowledge.root, starts a loopback-only host at http://127.0.0.1:5280, opens the default browser, and stays attached until stopped. To use the current OctoEvidence source branch instead of an installed tool:

dotnet run --project src/OctoEvidence.Cli -- portal

Use another port or suppress browser opening for automation:

octoevidence portal --port 5380 --no-open

The packaged tool contains the reviewer host and React assets; it does not require Node.js or the OctoEvidence source tree at runtime. See src/OctoEvidence.Web/README.md for troubleshooting, API routes, UI development, standalone publishing, and verification commands.

Run from source:

dotnet run --project src/OctoEvidence.Cli -- doctor --directory .

Initialize source and knowledge repositories

Choose the role doing the first work. Initialization inspects the repository, detects its platforms and existing source/test roots, and returns the role's ready prompt:

octoevidence init --directory . --role developer

Friendly role names such as developer, ba, qa, architect, security, and operator map to the closed lifecycle roles. Developer setup fails when no source code exists; it never creates a plausible empty mapping. A new repository can start as coordinator, product, BA, or another non-developer role before code exists. Preview detection without writing anything:

octoevidence init --directory . --role developer --dry-run

Override detection only when the repository needs it:

octoevidence init --directory . --role developer `
  --knowledge-root ..\checkout-knowledge `
  --platform backend --platform web `
  --source "src/**" --source "tests/**"

For several source repositories, run init once in each repository and point every command at the same knowledge root. The first call creates knowledge.json; later calls adopt its existing knw_* identity and append their own distinct rep_* identity. Concurrent first calls also converge: atomic manifest creation selects one knw_*, and only a losing configuration newly created by that init may adopt it. A pre-existing incompatible configuration fails for explicit repair instead of being silently rebound. Apply also rechecks the exact configuration bytes captured by its plan and atomically publishes complete JSON, so stale plans and interrupted writes do not overwrite or expose a partial configuration.

Initialization creates only what is immediately required:

  • octoevidence.json with immutable source-repository and knowledge-workspace identities;
  • <knowledge.root>/knowledge.json with attached source repository ids.

Canonical collection folders and .octoevidence-evidence/ are created lazily by the operation that first needs them. init does not copy schemas, skills, or nine role definitions into every source repository. octoevidence agent setup remains an explicit integration step when project-local agent assets are wanted.

{
  "$schema": "https://octoevidence.dev/schemas/repository-config.v1.json",
  "schemaVersion": 1,
  "repository": {
    "id": "rep_0198d42e0f51733198b5b60311768020",
    "platforms": ["backend"]
  },
  "knowledge": {
    "id": "knw_0198d42e0f51733198b5b60311768021",
    "root": "../checkout-knowledge"
  },
  "bindings": [
    {
      "id": "cmp_0198d42e0f51733198b5b60311768022",
      "unit": "components/cmp_0198d42e0f51733198b5b60311768022",
      "role": "owner",
      "platforms": ["backend"],
      "sources": ["src/**", "tests/**"]
    }
  ],
  "lifecycleRoles": [
    {
      "profile": "octoevidence/software-lifecycle/12207-2026/v1",
      "role": "coordinator"
    }
  ],
  "trust": { "signers": [] }
}

Each source repository has its own rep_*. Several repositories may attach to the same knw_* workspace by pointing --knowledge-root at the same location. Commands validate that octoevidence.json and knowledge.json agree. Re-running developer initialization repairs a missing source binding while preserving the repository, knowledge, trust, and existing binding identities.

Agent-first kickoff

Agents operate; the human reviews. Agents inspect, register sources, extract cited observations, create and revise canonical records, generate BRDs/TRDs, implement changes, run checks, capture evidence, maintain trace, and evaluate gates. Only the human may accept/reject knowledge, approve a lifecycle stage, grant a waiver, or accept residual risk.

octoevidence agent setup --directory . --role developer
octoevidence agent setup --directory . --role developer --prune
octoevidence agent roles
octoevidence agent roles --explain developer
octoevidence agent prompt --role lifecycle-coordinator --mode bootstrap

--prune removes unselected role files only when their content exactly matches the corresponding built-in asset. At the six legacy schema paths, it also removes files whose normalized content has an explicitly allowlisted legacy hash. That schema rule proves path/content identity, not install provenance: omit --prune when an intentionally maintained matching schema must remain. Modified or unknown octoevidence-*.md files and modified schema copies are preserved and reported as conflicts.

Start as Canonical role First responsibility
coordinator Lifecycle coordinator Scope the system, sequence roles, evaluate gates, assemble review.
pm Product manager Capture intended use, outcomes, stakeholders, and success measures.
ba Business analyst Turn cited needs into verifiable requirements and acceptance criteria.
architect Software architect Define component, interface, data, deployment, and trust boundaries.
developer Software developer Map existing code in JSON, create a change, implement, and run checks.
qa Quality engineer Plan and execute separate verification and validation evidence.
security Security engineer Maintain threats, mitigations, security requirements, and residual risks.
operator Platform operator Control release, deployment, rollback, telemetry, and operations.
auditor Lifecycle auditor Inspect evidence and gates without repairing or approving them.

agent roles returns the closed role catalog. agent roles --explain <role> adds the lifecycle stages that role serves, the knowledge collections it writes, the preconditions its repository must already satisfy, and its ready prompt, so the operating surface is discoverable from the tool rather than from prose.

agent prompt binds one session to one role, one mode, and optionally one task and one existing lifecycle:

octoevidence agent prompt `
  --role business-analyst `
  --mode knowledge `
  --task "Reconcile the payment requirements against the current code and list every conflict" `
  --lifecycle lcy_<UUIDv7>

Four modes exist:

Mode Use it for
bootstrap A new product, a missing baseline, or first-time needs, requirements, and architecture.
delivery A feature, fix, release, operational change, maintenance item, or retirement task.
knowledge Building, correcting, or reconciling canonical knowledge with no repository edit and no lifecycle mutation. Safe for any person in any role.
audit An independent check that inspects and reports without repairing the evidence under review.

knowledge mode permits knowledge source, knowledge observation, knowledge record, knowledge inspect, knowledge document generate|list, doctor, lifecycle inspect, and lifecycle list, plus reading any repository file. It forbids repository edits, commits, knowledge review, and every lifecycle outcome|control|transition|evidence|decision call. Everything such a session creates stays proposed.

An unknown role, mode, or lifecycle id fails closed, and a requested task over 2000 characters is rejected rather than pasted into the prompt.

Paste the emitted prompt into the coding agent. It directs the agent to use the full executable knowledge flow rather than inventing ids or writing an informal substitute.

Start a lifecycle and ingest existing material

$lifecycle = (octoevidence lifecycle create checkout `
  --directory . `
  --title "Checkout" `
  --type product `
  --actor human:product-owner | ConvertFrom-Json).lifecycle

$brd = (octoevidence knowledge source add docs/BRD.md `
  --directory . `
  --kind brd `
  --revision (git rev-parse HEAD) `
  --actor agent:business-analyst | ConvertFrom-Json).id

$observation = (octoevidence knowledge observation add `
  --directory . `
  --lifecycle $lifecycle `
  --statement "Customers need one reliable checkout journey." `
  --classification observed `
  --citation "$brd@heading: Business need" `
  --actor agent:business-analyst | ConvertFrom-Json).id

Existing BRDs and TRDs are inputs. Source code, tests, pipelines, infrastructure, runbooks, and incident files can be registered the same way. A source record stores repository id, path, revision, and SHA-256. If the file changes:

octoevidence knowledge source refresh $brd --directory . --revision (git rev-parse HEAD)

Refresh appends source history and marks every dependent observation stale. The agent must create a new observation against the changed bytes.

Human review and canonical records

Agents create proposals. A human records acceptance or rejection:

octoevidence knowledge review $observation `
  --directory . `
  --status accepted `
  --actor human:product-owner `
  --rationale "This matches the approved stakeholder statement."

$need = (octoevidence knowledge record create need `
  --directory . `
  --lifecycle $lifecycle `
  --title "Reliable checkout" `
  --summary "Customers complete checkout without duplicate payment." `
  --platform backend web `
  --observation $observation `
  --property "success-measure=Successful checkout rate is measured." `
  --actor agent:business-analyst | ConvertFrom-Json).id

octoevidence knowledge review $need `
  --directory . `
  --status accepted `
  --actor human:product-owner `
  --rationale "Need and measure are correct."

Canonical kinds are need, requirement, architecture, design, component, change, integration, test-campaign, release, deployment, service, incident, and retirement. Records support typed trace, structured properties, revisions, append-only revision history, and append-only human review decisions.

Revise a record without changing its identity:

octoevidence knowledge record revise $need `
  --directory . `
  --summary "Customers complete a measurable checkout without duplicate payment." `
  --rationale "Clarify the measurable outcome." `
  --actor agent:business-analyst

A revision returns the record to proposed. Accepted records may depend only on accepted observations and accepted trace targets. The one narrow exception is an accepted change's impacts trace to a component that was previously accepted and is now at a later proposed revision because its released baseline was consolidated for renewed human review. Use repeated --observation, --platform, or --trace values to replace those complete sets, --property name=value to add/replace a property, and --remove-property name to remove an obsolete property.

One folder for every distinct change

octoevidence knowledge record create change `
  --directory . `
  --lifecycle $lifecycle `
  --title "Add payment idempotency" `
  --summary "Apply the common behavior across backend and web." `
  --platform backend web `
  --trace "satisfies:$requirementId" `
  --property "backend-repository=rep_<UUIDv7>@<revision>" `
  --property "web-repository=rep_<UUIDv7>@<revision>" `
  --actor agent:software-developer

Every distinct intent creates changes/<chg_id>/record.json. One change can span backend, web, Android, iOS, or multiple repositories. Platform, affected component ids, repository ids, exact revisions, checks, and readiness remain metadata/trace on the change. Paths never encode platform or mutable names.

Consolidate a released change series into core knowledge

After the human has accepted a stable release, its accepted changes, and the affected component, fold the released series into a new proposed component baseline:

octoevidence knowledge baseline consolidate `
  --directory . `
  --component $componentId `
  --release $releaseId `
  --actor agent:software-developer `
  --rationale "Fold the accepted 2.4 release series into the component baseline."

Omit --change to consolidate every accepted change that the release traces with releases and that traces to the component with impacts; repeat --change to select an explicit subset. The operation never deletes or rewrites the change/release history. It revises only the component, records baseline.release and the deterministic baseline.changes list, adds trace to the release and changes, and returns the component to proposed for human review. This is the controlled "merge into core knowledge" step; it does not infer that a release is stable or accepted. Existing accepted changes remain valid through their impacts trace because the component's prior accepted decision and later baseline revision are retained in its history.

Generate BRD and TRD

$generatedBrd = (octoevidence knowledge document generate `
  --directory . --lifecycle $lifecycle --type brd `
  --actor agent:business-analyst | ConvertFrom-Json).id

$generatedTrd = (octoevidence knowledge document generate `
  --directory . --lifecycle $lifecycle --type trd `
  --actor agent:software-architect | ConvertFrom-Json).id

Each run creates:

documents/<doc_id>/
├── record.json   type, lifecycle, status, inputs, fingerprint, digest, decisions
└── content.md    generated review view

The knowledge repository owns these generated documents. content.md is never hand-edited. Change canonical inputs and generate a new document. The human can accept a generated BRD/TRD only when every input observation and record is accepted and unchanged. Document listings expose whether each snapshot is still current. An older snapshot remains auditable, but it cannot satisfy a live lifecycle gate after one of its inputs changes.

Lifecycle outcomes and gates

octoevidence lifecycle outcome $lifecycle `
  --directory . `
  --stage stakeholder-needs `
  --code needs-defined `
  --status achieved `
  --artifact-id $generatedBrd `
  --artifact-type brd `
  --relation defines

octoevidence lifecycle gate $lifecycle --directory . --stage stakeholder-needs

A local achieved outcome cannot point to a plausible-looking id alone. The referenced canonical record must exist, match the stage/type policy, and have human-accepted status. Cumulative gates also require applicable predecessors, required outcomes, proof, controls, and governed decisions.

An outcome that cannot be proven may be waived, but a waiver is an accountable decision rather than a shortcut:

octoevidence lifecycle outcome $lifecycle `
  --directory . `
  --stage stakeholder-needs `
  --code needs-approved `
  --status waived `
  --waiver-rationale "Internal tool; the maintainer is the only stakeholder." `
  --actor human:maintainer

--actor must name an accountable person. An agent actor, an empty actor, and an absent actor are all refused, so an agent cannot waive its way past a missing approval. The manifest records waived_by and waived_at beside the rationale, clearing the waiver removes all three, and doctor rejects a waiver introduced by editing the manifest. Every gate returns the waivers it passed on and sets governed to false while any remain:

{ "stage": "stakeholder-needs", "passed": true, "governed": false,
  "waivers": [ { "outcome": "needs-approved", "waivedBy": "human:maintainer", "waivedAt": "..." } ] }

Generate the current human handoff after updating knowledge and lifecycle state:

octoevidence lifecycle packet $lifecycle --directory . --actor agent:lifecycle-coordinator

This writes <knowledge.root>/lifecycles/<lcy_id>/reviews/current.md with the review queue, document currentness, stage/outcome state, controls, and validation findings. The coordinator may enrich this derived packet with repository work, assumptions, risks, and the exact requested decision; canonical records and generated BRD/TRD content remain tool-managed.

Identities and collections

Ids use a type prefix followed by UUIDv7. They are immutable and never derived from a title, path, platform, repository URL, branch, revision, or sequence.

rep_ knw_ sys_ lcy_ out_ src_ obs_ doc_ nde_ req_ arc_ dsn_ cmp_ chg_
int_ tst_ rel_ dpl_ svc_ inc_ ret_
knowledge.json      sources/           observations/       documents/
lifecycles/         needs/             requirements/       architectures/
designs/            components/        changes/            integrations/
test-campaigns/     releases/          deployments/        services/
incidents/          retirements/

The JSON contracts used to build and validate the tool are in schemas; initialization does not copy them into consumer repositories. Record directories and record bodies must agree on id and kind. doctor validates source freshness, citations, status dependencies, trace targets, generated-document integrity, lifecycle manifests, evidence, and gates. Document review and gates also recompute input freshness.

Evidence trust

Evidence receipts live beneath .octoevidence-evidence/ in the originating source repository and refer to external artifacts by repository-relative path and SHA-256 digest. RSA-SHA256 signatures bind artifact metadata to lifecycle subject, stage, actor, decision, policy, revision, environment, and signer key id. Trust exists only when repository policy authorizes the exact key fingerprint and scope. Private keys remain outside OctoEvidence.

Use octoevidence lifecycle inspect <lcy_id> to obtain the target out_* id, create a contextual YAML receipt whose subject, stage, and policy match that outcome, then attach it:

octoevidence lifecycle evidence $lifecycle `
  --directory . `
  --stage stakeholder-needs `
  --outcome needs-defined `
  --receipt .octoevidence-evidence/needs-review.yml

For a continuous control, use --control configuration-management; its receipt stage is continuous-control/configuration-management. The tool verifies the referenced artifact bytes and context before recording the receipt. Outcome/control state can then become achieved/effective.

MCP

octoevidence mcp --directory .

The MCP server explicitly registers agent, identity, knowledge, and lifecycle tools. Knowledge tools register, refresh, and list sources; create and list observations; create, revise, trace, inspect, list, and review canonical records; and generate/list BRDs/TRDs. Assembly scanning cannot expose unrelated attributed tools.

License

MIT. See LICENSE.txt.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

This package has no dependencies.

Version Downloads Last Updated
0.0.18 171 8/27/2026
0.0.17 120 8/27/2026
0.0.16 131 8/26/2026
0.0.15 135 8/26/2026
0.0.14 130 8/25/2026
0.0.13 139 8/23/2026
0.0.12 124 8/21/2026
0.0.11 135 8/21/2026
0.0.10 137 8/21/2026
0.0.9 137 8/20/2026
0.0.8 133 8/19/2026
0.0.7 139 8/18/2026
0.0.6 148 8/17/2026
0.0.5 156 8/16/2026
0.0.4 125 8/7/2026
0.0.3 151 8/2/2026
0.0.2 155 8/2/2026
0.0.1 158 7/23/2026

- Greenfield lifecycle control plane informed by ISO/IEC/IEEE 12207:2026, from stakeholder needs through retirement.
- One strict repository schema, UUIDv7 identities, canonical typed collections, platform-aware component bindings, and explicit lifecycle roles.
- Separate file-backed knowledge workspaces, cited sources/observations, canonical records, generated BRD/TRD views, contextual evidence, review packets, validation, and gates.
- Context-bound evidence signatures, typed trace links, iterative stage history, and continuous controls.
- Agent-first lifecycle setup with role-specific BA, product, architecture, development, QA, security, operations, coordination, and audit prompts.
- A loopback-only reviewer portal launched directly from the CLI with embedded client assets and repository discovery through octoevidence.json.