Browse the docs

Labs · Experimental: @putnami/sdd. No compatibility or parity promise, and never default-on. What each status means

ADR 0003 — Every project carries a feature, a spec or a featureAuthority

  • Status: accepted; point 4 superseded on 2026-11-26: the debt list is empty, and decision D-025 no longer names it or checks that putnami.workspace.json keeps it. The statement now reads that every workspace project carries a feature of its own, a spec or a reviewed featureAuthority, and that validate-workspace fails one that carries none
  • Amended: 2026-11-26, §5 and Consequences: Contributor CI runs the step in its squash commit checks (validate-workspace)
  • Scope: @putnami/sdd (feature-coverage-validate and feature-coverage-ratchet-validate, steps of validate-workspace), every workspace that sets options.sdd.featureCoverage, and the protocol modules of this repository

Context

A feature in putnami.features.json and a spec under specs/ link a project's code to the outcome it serves. A project that has neither can state a reviewed featureAuthority in its putnami.json: an owner that names the feature it serves elsewhere, or none with the reason it has no feature. Decisions 9 to 11 add two more answers.

One check read these answers: specs.missing_feature_link, a warning of putnami specs validate. It assesses only the projects that declare a publication channel or that the support catalog lists, and only in an unscoped run. The validate gate never runs it. On main at 7144249f, 29 of 151 projects carried no feature, no spec and no featureAuthority, and the warning named 7 of them.

Decision

  1. A step of validate-workspace judges every project. feature-coverage-validate reads every member the job wire carries, with or without a putnami.json. A project passes when its own root declares a feature or hosts a spec, when its putnami.json declares featureAuthority.none with a reason, or when it declares a featureAuthority.owner that names an authored feature.
  2. featureAuthority is the only exemption. No rule by tag, type or path exempts a project. A template, a sample, a generated client and a protocol answer the same question, each in its own putnami.json, where a reviewer reads the answer.
  3. An owner that names no authored feature covers nothing. The finding names the owner. Otherwise the field becomes the cheapest way to silence the step.
  4. The debt list is committed and exact. options.sdd.featureCoverage.debt in putnami.workspace.json lists the ids of the projects that do not answer yet, and a listed project passes. An entry whose project answers fails, and so does an entry that names no project, so the pull request that pays a debt removes its entry.
  5. The list only shrinks, and a run with a baseline enforces it. feature-coverage-validate reads no history, so it does not refuse a new entry. A second step, feature-coverage-ratchet-validate, reads the debt list in putnami.workspace.json at the merge base of the run's impacted baseline and HEAD, and fails each current entry the merge base does not list with sdd.grown_coverage_debt, naming the entry. A run without an impacted baseline, and a merge base that declares no options.sdd.featureCoverage, pass with a note. A shallow clone fails: its history can stop before the merge base. The step reads Git history, which the candidate cut does not hold, so it is never cached, like breaking-marker-validate. Both change gates run it with --impacted: Contributor CI's squash commit checks run validate-workspace and name the base branch with --baseline, and the hosted Putnami CI runner resolves the trunk or the nearest epic branch. Both check out the whole history, so the rule holds on every pull request.
  6. The workspace opts in. Without options.sdd.featureCoverage, the step passes with a note that counts the projects that would fail. A block the step cannot read fails closed: an unknown member, a missing debt, an entry that is not a project id, or a duplicate entry. Until 2026-11-26, the check of D-025 failed a putnami.workspace.json that dropped the list.
  7. The step reads the candidate cut. It reads the manifests and the specs through the Git candidate files, so an ignored document covers nothing, and the task is cached on the input git:**. That key also holds the workspace membership with each project's configuration, so declaring a featureAuthority moves it.

D-026, settled the same day, decides how the protocols answer:

  1. A protocol owns the feature of its contract. Its spec states what every implementation must do: the wire format, the versions, the validation and the semantics. Each project that implements the protocol depends on it and proves those requirements in its own tests, under a check of its own, because the spec gate blocks a check that two projects report. A protocol that carries featureAuthority.none today keeps it until it gets the feature of its contract.

Two more answers the step checks let a library and a generated client stop repeating one none reason. In one workspace of 147 projects, 105 declared none: 50 repeated one reason for libraries, and 45 repeated one reason for generated clients. No check reads a copied reason, so it cannot go false.

  1. dependents: true covers a library through its dependents. The project has no feature of its own, and the specs of the projects that depend on it state its behavior. The step walks the resolved dependency graph backwards. The project passes when one of its dependents, directly or not, declares a feature or hosts a spec at its own root. A dependent that answers with a featureAuthority does not count: it carries no requirement either. Otherwise the step fails with sdd.uncovered_project.
  2. provider: "<project id>" covers a generated client through its provider. The project passes when the id names a workspace member that passes on its own answer: a feature, a spec or a featureAuthority that resolves. A debt entry is no answer. Otherwise the step fails with sdd.uncovered_project, naming the provider. The Go and TypeScript client generators write this member, with the id of the project they generate from, so a person does not.
  3. none stays for a project that serves no outcome, such as a fixture or a repository tool. Exactly one of owner, none, dependents and provider is set.

Alternatives rejected

  • Extend the specs ratchet. specs.baseline.json freezes requirements that exist. It has no entry for a project that declares nothing, so it cannot see the gap.
  • A project-scoped step. A project-scoped task runs only on the projects that install @putnami/sdd. A project that declares nothing is the most likely not to install it, and the step would skip it without a word.
  • A separate debt file with its own protocol. The list belongs to the workspace's SDD configuration. A new file needs a format, a schema and a reader, for one list of ids.
  • An exemption by tag or by type. A rule such as "a sample needs no feature" exempts every future sample without a review. A featureAuthority states one project's reason where a reviewer reads it.
  • Read the history in feature-coverage-validate. The step would need the base commit, which the git:** key does not hold, so a cached verdict would not follow the base. A separate uncached step keeps that key exact.
  • Refuse a growing list by review alone. Under time pressure, a debt entry is the cheapest way to silence sdd.uncovered_project, and nothing but the reader of the diff stops it.
  • An interactive putnami features coverage --baseline <ref> command. It refuses nothing until a gate runs it, and the change gate already runs validate with a baseline.
  • Compare with the baseline commit itself. A branch behind its base would fail for an entry the base removed after the branch started. The merge base is the list the branch started from.
  • A library names every feature it serves in owner. owner names one feature, so it fits a library with one consumer, not one with several. A list would go stale each time a consumer appears.
  • The step infers a generated client from its generated-client tag. A tag is an exemption by tag, which decision 2 rejects. The provider member names the project a reviewer and the step can check.

Consequences

  • A new project fails the gate until it declares a feature, a spec or a featureAuthority. A debt entry does not defer it: a run with a baseline fails every entry the merge base does not list.
  • A run without an impacted baseline does not refuse a new entry. Without --impacted-strict, a baseline that does not resolve selects every project and names no baseline, so the step passes with a note. Contributor CI's squash commit checks pass --impacted-strict. The hosted Putnami CI runner does not, and relies on its full checkout to hold the trunk.
  • A featureAuthority now passes a gate, not a warning: a reviewer reads every new none reason and every new owner.
  • A library that declares dependents: true fails the day its last dependent with a feature or a spec drops it. A generated client fails the day its provider stops answering.
  • The specs.missing_feature_link warning stays. It applies the same rule to fewer projects.
  • A manifest or a spec that fails to parse covers nothing in this step. The project-scoped validate steps report the document itself.
  • In this repository, 8 projects start in the debt list. The pull request that gives one of them a feature, a spec or a featureAuthority removes its entry.