Skip to content

Realize add-client-identity-roster: the client-identity roster contract family (feature 007) - #190

Merged
brettheap merged 22 commits into
mainfrom
007-client-identity-roster
Aug 15, 2026
Merged

brettheap merged 22 commits into
mainfrom
007-client-identity-roster

Conversation

@brettheap

Copy link
Copy Markdown
Contributor

Realizes the ratified OpenSpec change add-client-identity-roster as Speckit feature 007-client-identity-roster. Archive of the OpenSpec change happens only after this PR lands, per release-realization.

What this delivers

  • Contract family: contracts/schemas/xfactory-client-identity-roster.schema.yaml (2 kinds: roster fragment + drift-finding record; closed everywhere, unevaluatedProperties: false at root), canonical validator scripts/validate-client-identity-roster.py (38 rule codes, deterministic, network-free, strict self-test), packaged family examples/client-identity-roster/ (4 truthful example YAMLs — every provider fact cited to real estate evidence — plus README and 31 single-mutation negatives), 8 repo-shaped fixtures, 1 deliberately-synthetic representability fixture (Decision C).
  • The four wirings: domain-conformance-checks pack grown to four (blocking, passes-with-notice where no fragment exists); doc-health sixteenth family client-identity-composition (cross-domain ONLY, CONTESTED convention); credential-contracts issuance_preconditions (closed-propertyNames object, const: true values, three members — live OpsxFactory records verified conformant, verdict line byte-identical); consent-instrument modification (withdrawn as a distinct terminal state across all three enum declarations, governed_identity dependent kind with unresolved-ref posture, cascade widened to withdrawal, contract_schema_version 1→2 on both consent schemas).
  • Registration: bundle contract-v1.32 — 150 manifest rows (2 new, incl. the first-ever row for xfactory-credential-contracts.schema.yaml; 2 consent rows refreshed), CHANGELOG fold, release digests regenerated by the tooling (membership byte-identical to v1.31; nothing hand-added), release verify-commit: pass.
  • Traceability: specs/007-client-identity-roster/traceability.yaml — one row per FR and SC with red-proven columns.

Governed decisions carried (recorded in review/amendment-record-2026-08-14/-15/-15b.md)

  • A: pack enrollment declared as a MODIFIED domain-conformance-checks delta.
  • B: issuance_preconditions declared as a MODIFIED credential-contracts delta.
  • C: the packaged "provider-forced multi-surface reader" relocated to a synthetic representability fixture — no truthful in-vocabulary instance exists (Exchange has a surface-scoped read-only path; BC has none at all), and a governed packaged example must be a truthful worked case.

Reviewer attention (overrulable read-downs): FR-014's "in force" is lifecycle-scoped so a retired entry may cite an ended instrument (adjudicates a ratified self-contradiction: cascade→retirement + retention vs unqualified in-force); the consent and doc-health deltas were rebased/completed so the archive's per-requirement replacement semantics cannot silently rewrite or delete promoted text (proven by executed archive on a scratch copy and an 8-of-8 replacement record across archive history).

Verification

  • openspec validate add-client-identity-roster --strict valid; --all --strict 58/58.
  • Roster self-test: 4 positives clean, 31/31 negatives refused each for its own registered code; killed-flaw set: per-unit pair, duty pair, planned entry, synthetic reader all CLEAN, alias pair REFUSED; 31/31 rules red-proven (suppressing any rule turns the corpus red).
  • FR-030: consent + credential-contracts verdicts byte-identical, code by code, against the green-before baseline; per-directory suites 745 passed, 9 skipped (the 15 baseline conformance-gate tests unmodified).
  • doc-health: 16 families run; the new family SKIPS with an explicit reason (no domain publishes fragments yet — expected); self-gate before/after identical.

Pre-existing failures reviewers will see (unrelated, proven at branch base ae3f5c8)

  1. validate-manifest-digests.py exits 1 — one stale omnigent digest, untouched by this branch (standalone follow-up).
  2. validate-credential-contracts.py <OpsxFactory> exits 1 — one pre-existing shared-secret finding; verdict line byte-identical before/after this branch.
  3. Bare pytest at repo root fails collection on experiments/avatar-brokered-call/tests/offline/ — pre-existing; per-directory suites are the gate.

Deliberately NOT in this PR (named follow-ups per the ratified packet)

Domain roster fragments (incl. OpsxFactory's three investigation findings), domain-gate wiring (pack blocking is nominal at archive — recorded in traceability FR-022/SC-006), live drift-refusal application at domain mint surfaces, pack enrollment naming asymmetry, and the LedgerxFactory multi-tenant Reader/Poster decision (Brett's, untouched).

🤖 Generated with Claude Code

brettheap and others added 20 commits August 14, 2026 17:32
Requirements spec for realizing add-client-identity-roster: the neutral
roster contract (closed business_central|exchange surface vocabulary,
uniqueness on domain/surface/class/blast-radius-unit/duty, observe|mutate
only, granted_permissions[] and a verified admission[] list), the canonical
validator with per-rule negative confirmations plus killed-flaw regression
positives, release registration at contract-v1.32, and the three ratified
wirings (blocking intra-repo conformance, doc-health sixteenth family
cross-domain only, grant-issuance refusal on open drift) with the
consent-instrument governed-identity cascade.

Six prioritized user stories, 35 functional requirements, 12 success
criteria. Eight points of genuine ambiguity are carried to the architect
seat as [NEEDS CLARIFICATION]: fragment placement path (FR-020),
domain-conformance-checks pack membership vs its promoted three-script
enumeration (FR-022), doc-health promoted-count edit timing (FR-025),
neutral expression of the issuance_preconditions refusal (FR-028), roster
completeness (FR-032), admission-evidence freshness (FR-033), vocabulary
closedness for the unratified enumerated fields (FR-034), and
drift-finding representation (FR-035).

Co-Authored-By: Claude Fable 5 <[email protected]>
Technical plan and research decisions for realizing the amended
add-client-identity-roster packet: nine deliverable clusters (roster schema
family, canonical validator, fixture corpus, packaged examples, contract-v1.32
registration, pack membership, doc-health sixteenth family, credential-contracts
issuance_preconditions, consent-instrument cascade), a constitution check, a
ratified-constraint check over all ten binding constraints, and the verification
story naming the specific suite that proves each of FR-030's four modified
capabilities unaffected.

Resolves the four open items the plan phase owed:

- identity_kind derived, not invented: the four mandated example cases and the
  vendor-homed negative converge on ONE object class (entra_app_registration).
  The vendor-homed case forces no second member because residency is carried by
  home_tenant + principal_locations[] + residency_model, and encoding it as a
  kind would recreate the ambiguity design Decision 5 rejected.
- Drift record ships as a SECOND KIND in the roster schema file, not a second
  file: the in-directory xfactory-credential-contracts precedent (five kinds,
  one file), FR-021's singular manifest language preserved literally (one row,
  one sha256, one consumption rule), and the five-element tuple defined once in
  $defs rather than twice behind two digests.
- README OpenSpec Records block (~line 264-272, still naming two Modified
  Capabilities) scheduled as a completion condition of the registration slice,
  the first slice that touches README.md.
- FR-030 additivity: measured, and it is where the plan's most consequential
  finding sits. OpsxFactory's live issuance_preconditions is an OBJECT of
  boolean flags, not a token list, so an array-shaped neutral property would
  invalidate a currently-conformant domain record — forbidden by FR-030, by
  FR-028's "regularizes rather than replaces in place", and by the tree's own
  definition of an additive-minor bump. The vocabulary is therefore an object
  with closed property names carrying the roster-drift token plus the two
  precedent tokens it regularizes. Consent growth stays an added enum member
  plus two optional properties, with the record envelope's schema_version const
  deliberately unchanged.

Also records: xfactory-credential-contracts.schema.yaml has NO manifest row
today, so FR-021's "refresh" is a first registration; the release digest
inventory's membership is the Hermes-runtime surface and roster paths do not
enter it; the FAMILY_IDS report-section gap that already omits proposal-origin;
and the record-immutability rule for the Status: record review files.

Seventeen plan-phase decisions the rulings did not fix are listed for architect
review before implement. No contradiction found between spec.md, the rulings
file, and the amended packet at 4de5bb2.

Co-Authored-By: Claude Fable 5 <[email protected]>
…location

0.1 (A-16 precondition) EXECUTED and FAILED: no permission or directory role
reaching both business_central and exchange read surfaces is citable anywhere
in the estate, Business Central offers no read-only path at all, and Exchange
offers a surface-scoped one — which falsifies the "no single-surface read-only
role" clause outright. Seven candidates refuted on the record.

Escalated rather than synthesized. The architect ruled; that ruling's own
item-5 obligation then fired on ratified packet task 2.3, making the authority
Brett's. Decision C (Brett, 2026-08-15): RELOCATE TO FIXTURE.

- Packet task 2.3 amended in place (three packaged cases) with the sibling
  record review/amendment-record-2026-08-15b.md; both strict validations green
  (change valid; --all 58/58).
- FR-017, FR-019, FR-034, SC-002, plan Clusters C/D, decisions 16 and 22, and
  four checklist items carry the relocation. All forced-breadth machinery,
  reach rules and named negatives are untouched — the ratified requirement is
  conditional, so the contract must carry the capability with no in-vocabulary
  instance, which is what the fixture proves.
- tasks 3.3 -> 4.9 (synthetic representability fixture, dated header, ZERO
  findings); 10.5 amended to reach it so SC-002's fourth positive cannot be
  silently dropped.

0.2 swept CLEAN with full-estate reach: the only status_aliases key anywhere
is `active`; no `withdrawn` key exists, so growing NEUTRAL_STATUSES fires
nowhere. 0.3 baseline captured outside the tree, path recorded in the task;
all five commands green with empty finding-code registers; both external
checkouts resolve.

Co-Authored-By: Claude Fable 5 <[email protected]>
contracts/schemas/xfactory-client-identity-roster.schema.yaml — Draft 2020-12,
contract_schema_version 1, two kinds behind a top-level oneOf, 19 $defs.

- Both kinds declare schema_version const 1 (A-2), so the single manifest row
  is unambiguous.
- Six closed vocabularies, every MEMBER carrying a description: each
  admission_surface member names its admission act and scoping mechanism
  (business_central carries BOTH acts; exchange carries the application access
  policy and its mail-enabled security group — ratified and live-verified, so
  1.2's own escalation clause does not trigger), and each set names its
  extension route. Destructive is unrepresentable.
- $defs.identity_key: element 3 is authority_class_intended (R-N1), defined
  once and referenced by the uniqueness rule and the drift record.
- client_tenant required on the fragment (G2) as the declared residency
  comparand; provider_object_ref optional (G4) and documented as an OBJECT
  identifier, not a tenant identifier.
- admission[] minItems 1 (A-N3, not 2); evidence_ref/verified_at
  dependentRequired BOTH ways so verified/unverified are the only two
  representable states and a claimed-but-unevidenced verification is refused;
  exceeds_governed_unit required.
- vendor_tenant_multi's five obligations as an if/then IN THE SCHEMA so a
  validator refactor cannot lose them; residency branches on nothing else.
- Drift kind: identity_ref as the tuple OBJECT, roster_value and
  observed_value both required, status closed (the seventh set), and
  disposition_ref required only under status: disposed.

Closure: 11 objects additionalProperties:false, 3 maps closed via
propertyNames, 0 open, root unevaluatedProperties:false. Verifications:
check_schema passes; 30/30 expressibility probes behave as expected; the
constraint-1 grep finds no authority_class in any residency branch.

Co-Authored-By: Claude Fable 5 <[email protected]>
scripts/validate-client-identity-roster.py — deterministic, network-free,
clock-free, one positional target-repo argument, Findings emitting
ERROR [kebab-code], exit 0/1/2. 30 rules in six groups.

- Closed vocabularies are DERIVED FROM THE SCHEMA rather than restated in
  Python, so the two declarations of one closed set cannot silently disagree.
  Every refusal names the set AND its extension route.
- Record-internal rules run to completion even when the schema already refused
  the document, reading the mapping defensively — without this the named
  refusals would exist nowhere and their expectations-table entries would be
  unregisterable.
- Uniqueness and the alias rule compare entries WITHIN ONE FRAGMENT only.
  Alias is the three-predicate conjunction and no broader, with the "free
  tokens ONLY" wider reading so inventing two spellings evades nothing.
- Effective reach is COMPUTED over verified acts and reported as a note; the
  scope-excess rule fires on a verified act declaring exceeds_governed_unit
  with no declared_excess.
- FR-010's name check carries the G6 cure conjunct; residency compares against
  the fragment's declared client_tenant by EQUALITY, never containment;
  consent_ref resolution is intra-repo with the in-force test lifecycle-scoped
  per G1; misplacement is EXACT-PATH per G3 and complementary with the flat
  validating glob.
- Absence is never a finding and no code path derives an expected entry set.

The per-unit "left unused" rule was CORRECTED by its own discrimination
partner: a per-ACT reading fired on the mandated BC positive, whose
application user USES the principal while its admin-center act cannot, having
no scope selector. The predicate is per-SURFACE; the false-claim rule stays
per-act. Recorded in task 2.6 with the consequence for 4.1's fixture.

Verifications: no argument exits 2 with usage; self-scan of this checkout
exits 0 with the absence notice and reports none of its own corpus misplaced;
46/46 inline rule probes behave as expected including both misplacement arms,
the retired/enrolled consent discrimination, and determinism. FR-030
re-measured: the four MODIFIED suites are identical to the 0.3 baseline.

Co-Authored-By: Claude Fable 5 <[email protected]>
Four truthful worked cases under examples/client-identity-roster/, every
provider fact cited by repo + path + commit:

- farheap/opsxfactory: the Business Central case (one identity, TWO admission
  acts on ONE surface, union effective reach, declared excess) plus the
  planned Production entry with its unverified act.
- farheap/ledgerxfactory: the genuine duty pair and the genuine per-unit pair.
- lxtest_opensoft/ledgerxfactory: the retired entry, relocated to its own
  fragment because no retired identity exists for either farheap pair and a
  fragment is per (client, domain). Also the corpus's only packaged exchange
  instance.
- the drift finding, open and therefore undispositioned.

negative/ lands in the same commit: the self-test goes strict the moment the
family directory exists. All four positives confirmed clean; a self-scan of
this checkout exits 0 and reports no misplacement of its own corpus.

Also amends spec.md FR-001 to enumerate vendor_tenant_multi_obligations and
the standing_credential_attestation subfields, each with its forced-by-
implication rationale.

Co-Authored-By: Claude Fable 5 <[email protected]>
31 packaged negatives, 8 repo-shaped fixtures, 1 synthetic fixture — the
plan's counts exactly.

The self-test is now FULLY STRICT: 4 positives clean, 31 negatives refused for
their registered code, 28 of them detail-pinned. Every negative raises its own
code and no other rule's code; where the violation is also schema-visible the
generic schema code accompanies it, which is the rule engine running to
completion rather than returning at the first schema failure — 15 negatives
exercise that overlap and a dedicated assertion proves the named code still
fires in each.

tests/client-identity-roster/ (41 passed) carries the eight tmp_path repos —
conformant (two clients sharing the whole tuple, plus a retired entry citing a
terminated instrument), the gate exit, absence, the unresolvable gate
obligation, both misplacement arms, and both consent-resolution arms — plus
the SC-002 discrimination in one run, the synthetic multi-surface fixture and
its spanned-surfaces discrimination, the ratified field list, the FR-016
coverage table, the SC-013 source-level negative guarantee, and the self-test's
five failure modes broken and measured in a throwaway sandbox.

FR-030 holds: the four MODIFIED capabilities' suites are 636 passed + 9 skipped
against the baseline's 645, and both sibling validators report their baseline
verdicts unchanged.

Co-Authored-By: Claude Fable 5 <[email protected]>
The domain-conformance-checks pack grows to four. The roster check is
exercised HERE as a PACK MEMBER — the exit the domain gate reads — across the
four behaviours the two deltas specify: an entry nonconformance exits nonzero,
a conformant repo exits 0, a repo publishing no fragment exits 0 with an
explicit notice naming the absence, and the roster delta's mutate-without-
ratified-capability scenario is an ERROR rather than a report (with the
cross-domain composition classes asserted absent from this member's output).

The three existing checks' 15 tests are unmodified; only the module docstring
changes, which is 5.2's own edit and the only pack COUNT site this feature
owns. The promoted domain-conformance-checks spec is untouched — the archive
step rewrites promoted text.

Co-Authored-By: Claude Fable 5 <[email protected]>
`client-identity-composition` assembles the per-client roster fragments each
pinned domain repository publishes and reports exactly two CROSS-DOMAIN
concerns: shared identity material (two disjuncts — equal identity_ref, or an
equal provider_object_ref both entries declare, never principal_locations[],
which carries tenant identifiers and would refuse the ratified FR-024
non-finding) and undeclared cross-domain reach. No intra-repo rule is
duplicated, no completeness rule exists, and both skips are explicit.

Resolution classes are per finding (the three late families' precedent, no
blanket FAMILY_RESOLUTION row): a reach carried by a declared_excess is
CONTESTED, because curing it reverses breadth declared as provider-forced,
bound to a resolving gate obligation and held under a ratified capability;
shared material keeps the dataclass default, because ratified_by ratifies an
identity's authority and never a sharing arrangement.

The fixture corpus is four repos and five clients, every fragment intra-repo
CONFORMANT — 6.7 runs the blocking canonical validator over each repo and
asserts exit 0, which is what makes the composition finding provably
composition-only rather than a re-report of a gate refusal. 2.9 closes here:
the self-scan of this checkout stays green with the corpus present.

Count-bearing prose: families.py's docstring goes to sixteen and names the
sixteenth module. The promoted doc-health spec, and every ordinal, are
untouched — the archive step rewrites promoted text.

Co-Authored-By: Claude Fable 5 <[email protected]>
…luster H)

Decision B's neutral home. The requirement item gains an optional
`issuance_preconditions` object — minProperties 1, additionalProperties false,
three declared members, every value `const: true` — so a refusal is declarable
against a pinned neutral contract instead of a domain-local extra key riding a
schema that neither declared nor forbade it. `const: true` because a
precondition is declared or not declared; `false` is a declaration that reads
as governance while asserting nothing.

The semantic mirror is structurally required, not decorative: the self-test
adjudicates registered negatives against _semantic_findings ONLY, so a
schema-only implementation would make its own negatives unregisterable and
leave the refusal with no probe. One code, both failure shapes, naming the
closed set and the extension route.

THE LOAD-BEARING REGRESSION (7.4), measured rather than asserted: the two live
OpsxFactory records carrying issuance_preconditions still pass. The domain
checkout's verdict line is byte-identical before and after the change —
`11 contract(s) checked, 27 skipped, 1 error(s)` — that one error being a
PRE-EXISTING shared-secret-identity finding on platform-bindings.yaml, proven
pre-existing by running the HEAD validator against the same checkout. Zero new
findings, zero changed findings, no file in the domain repo modified
(requirements.yaml md5 unchanged).

The self-test counts grow 2+3 -> 3+5, which is the one count-bearing assertion
in the existing suite that this corpus growth necessarily moves.

Co-Authored-By: Claude Fable 5 <[email protected]>
… cascade (Cluster I)

The closed lifecycle grows by `withdrawn` at every normative declaration
together — the record status, the status_history entry, and the class
registry's status_aliases value constraint — with contract_schema_version
bumped 1 -> 2 on both schema files. The RECORD envelope's schema_version stays
const 1: changing it would invalidate every instrument in the estate, the
opposite of additive. `withdrawn` is a DISTINCT member, never an alias of
`terminated`, because withdrawal by the consenting party and termination are
distinct events that both raise the cascade obligation.

The count-bearing prose ships with the enum: the schema's 'CLOSED five-state
lifecycle' comment and the validator's alias-target-not-neutral message both
become six-state. A grep for 'five-state' across contracts/schemas and scripts
now returns nothing; the PROMOTED spec still says five and is left alone, which
is the archive step's to rewrite.

dependent_refs gains `governed_identity` as a NAMED kind (never the `other`
escape) with two optional evidence siblings, and `ref` gains a description
stating the convention AND the posture: fragment path plus identity_ref,
UNRESOLVED — no fragment opened, no entry existence confirmed, no repository
boundary crossed, the same posture as the roster's evidence_ref and for the
same reason. A source-level check confirms check_termination_cascade opens
nothing.

The cascade gate widens from terminated to (terminated, withdrawn). Stated as
what it is: the REACH of termination-without-cascade-evidence now covers
withdrawn instruments; the code SPELLING is retained for continuity. Beside it,
identity-cascade-incomplete fires when a governed_identity dependent on either
terminal event lacks the identity's removal or its admission's withdrawal —
credential revocation alone leaves standing access in the client's tenant.

FR-030, measured code by code rather than by exit status: all five pre-existing
positives and all five pre-existing negatives produce byte-identical finding-code
sets under the HEAD validator+schemas and the current ones. Zero differences.

Co-Authored-By: Claude Fable 5 <[email protected]>
Cuts the bundle the roster family ships in, atomically (constitution VI).

contracts/manifest.yaml — bundle contract-v1.31 -> contract-v1.32. Two NEW
rows: client-identity-roster (one row, one sha256, one consumption_rule
stating BOTH the declared placement and that validate-credential-contracts.py's
skip-with-notice over that path is expected and blessed) and
credential-contracts, which is a FIRST-EVER registration rather than a
refresh — the schema was promoted at DTN-004 without a manifest row, so the
digest consumers are told to verify did not exist for the file they pin. Two
REFRESHED consent rows carrying the contract_schema_version 1 -> 2 bump in
prose, each restating that the per-row schema_version mirrors the RECORD
envelope's const and not the file's contract_schema_version.

G5-rider completion: the consent-instrument row's consumption_rule said "the
closed five-state lifecycle" — a third count-bearing prose site the ruling did
not name, reachable only once the row was touched for its digest. It now says
six-state.

contracts/CHANGELOG.md — the ## Unreleased openxwallet item is FOLDED IN
rather than left beside the new ## contract-v1.32 entry, per the block's own
header instruction. The additivity argument is stated item by item against
docs/contract-versioning-policy.md:130-132: a new contract, an OPTIONAL
property, an ADDED enum member, and the deliberate decision to leave both
consent schemas' RECORD envelope schema_version at const 1.

contracts/README.md — three new registration rows (roster schema; validator +
examples; credential-contracts) and the two consent rows amended to six-state
with the governed_identity dependent kind.

contracts/releases/contract-v1.32.digests.yaml — GENERATED last inside the
cluster, after the manifest/CHANGELOG/README edits landed, because all three
are in RELEASE_SURFACE_PATHS. 190 entries, membership byte-identical to v1.30
and v1.31: no roster path enters and none was hand-added.

README.md — the roster family joins the Conformance index, and the OpenSpec
Records block now names FOUR modified capabilities (adding
domain-conformance-checks and credential-contracts) with Decisions A, B and C.

Measured, not assumed: validate-manifest-digests.py goes 132 -> 134 digests
checked with the failure set byte-identical before and after — one
pre-existing unrelated mismatch on contracts/omnigent/omnigent-domain-overlay.schema.yaml,
proven pre-existing at ae3f5c8 and left for its own owning change. Every row
this change touches verifies.

Closes 1.10, whose verification was this commit's manifest consumption_rule.
traceability.yaml in the 006 shape, extended: 53 rows, one per FR-001..FR-039
AND SC-001..SC-014, each carrying statement, artifact, enforced_by,
negative_confirmation and red_proven. Coverage checked mechanically against
spec.md — missing=[], extra=[], and no field left unset on any row.

red_proven is MEASURED, which is why the plan deferred this file to
implementation. Task 2.2's break-one-negative procedure was applied to EVERY
registered code rather than one sample: the validator was loaded 31 times, one
finding code neutered per load, self_test() run. Control GREEN with 0 errors;
31 of 31 codes turn the packaged corpus RED when suppressed.

The FR-022 and SC-006 rows carry the ruling A-N2 residual verbatim in
substance — pack blocking is NOMINAL at archive, domain-gate wiring is a named
follow-up out of scope by FR-030/SC-012 — which closes task 5.3. Task 1.10
closed at phase 9.

The green bar, measured against the 0.3 baseline: openspec strict valid and
--all --strict 58/58; consent 6+7+2, credential-contracts 3+5, roster 4+31;
the five per-directory suites at 745 passed / 9 skipped, every growth additive
and no pre-existing test changed; doc-health's sixteenth family SKIPS with an
explicit reason in the real aggregation run, and a before/after self-gate pair
is IDENTICAL across critical/error/warning.

Two wording reconciliations of the 7.4 class, amended rather than reported as
passes. validate-credential-contracts.py over OpsxFactory exits 1 and always
did — one pre-existing shared-secret-identity error, with the entire before/
after output diff being ONE line, this feature's own self-test growth.
validate-manifest-digests.py goes 132 -> 134 checked with a byte-identical
failure set. Both read as zero new, zero changed findings.

Adds the FR-027 no-mutation confirmation as a shipped source-level test, since
US6's Independent Test asks for it and a schema description is not a
verification: three AST arms over every feature module (no write-capable call,
with replace discriminated by arity; every open() a read; no os/shutil/
subprocess/network/provider import), red-proven against a mutating probe.

Delta fidelity asserted mechanically before archive: all seven promoted
doc-health scenarios restated, both consent requirements intact, nothing
promoted deleted on landing.

70 of 70 tasks [x]; 3.3 stays [~] permanently by ruling, as the relocated task.
Copilot AI lite review requested due to automatic review settings August 15, 2026 15:14

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @brettheap! 👋

Your private repo does not have access to Sourcery.

Please upgrade to continue using Sourcery ✨

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request realizes the ratified OpenSpec change add-client-identity-roster as Speckit feature 007-client-identity-roster, introducing the client-identity roster contract family and wiring it into existing governance/validation surfaces (doc-health, consent-instrument, credential-contracts, and the domain conformance pack), along with release registration at contract-v1.32.

Changes:

  • Adds the cross-domain doc-health family client-identity-composition with fixture repositories exercising composition scenarios.
  • Extends credential-contracts with a closed issuance_preconditions vocabulary and updates validator + tests + examples accordingly.
  • Extends consent-instrument lifecycle and cascade validation to include withdrawn and governed identity cascade evidence, with updated schema, validator, and examples; updates release documentation (README/CHANGELOG) and feature checklists.

Reviewed changes

Copilot reviewed 118 out of 120 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
tests/doc-health/fixtures/client-identity-composition/gammaxFactory/credentials/client-identity-roster/client-solo.yaml Adds a single-fragment (skip) fixture for composition.
tests/doc-health/fixtures/client-identity-composition/gammaxFactory/credentials/client-identity-roster/client-object.yaml Adds a composition fixture keyed by shared provider_object_ref.
tests/doc-health/fixtures/client-identity-composition/gammaxFactory/consent/gamma-consent-v1.yaml Adds consent instrument fixture referenced by gamma roster entries.
tests/doc-health/fixtures/client-identity-composition/deltaxFactory/credentials/client-identity-roster/client-object.yaml Adds delta half of shared-object composition fixture.
tests/doc-health/fixtures/client-identity-composition/deltaxFactory/consent/delta-consent-v1.yaml Adds consent instrument fixture referenced by delta roster entries.
tests/doc-health/fixtures/client-identity-composition/betaxFactory/credentials/client-identity-roster/client-spanning.yaml Adds “other half” fixture for undeclared cross-domain reach scenario.
tests/doc-health/fixtures/client-identity-composition/betaxFactory/credentials/client-identity-roster/client-shared.yaml Adds beta half of shared identity material (disjunct i) fixture.
tests/doc-health/fixtures/client-identity-composition/betaxFactory/credentials/client-identity-roster/client-separate.yaml Adds beta half of ratified non-finding (separate identities) fixture.
tests/doc-health/fixtures/client-identity-composition/betaxFactory/consent/beta-consent-v1.yaml Adds consent instrument fixture referenced by beta roster entries.
tests/doc-health/fixtures/client-identity-composition/alphaxFactory/workflows/alpha.yaml Adds workflow/gate fixture to keep obligations resolvable intra-repo.
tests/doc-health/fixtures/client-identity-composition/alphaxFactory/credentials/client-identity-roster/client-spanning.yaml Adds alpha half of undeclared cross-domain reach scenario fixture.
tests/doc-health/fixtures/client-identity-composition/alphaxFactory/credentials/client-identity-roster/client-shared.yaml Adds alpha half of shared identity material (disjunct i) fixture.
tests/doc-health/fixtures/client-identity-composition/alphaxFactory/credentials/client-identity-roster/client-separate.yaml Adds alpha half of ratified non-finding (separate identities) fixture.
tests/doc-health/fixtures/client-identity-composition/alphaxFactory/consent/alpha-consent-v1.yaml Adds consent instrument fixture referenced by alpha roster entries.
tests/credential_contracts/test_dispatch_credential_contract.py Updates credential-contracts self-test expectations and example presence checks.
specs/007-client-identity-roster/plan-gate-rulings-2026-08-14.md Records plan-gate rulings and verification obligations for the feature.
specs/007-client-identity-roster/checklists/versioning-registration.md Adds registration/versioning checklist for release-gating.
specs/007-client-identity-roster/checklists/validator-determinism.md Adds determinism/hermeticity checklist for validator + doc-health family.
specs/007-client-identity-roster/checklists/traceability.md Adds traceability checklist to ensure requirement↔artifact coverage.
specs/007-client-identity-roster/checklists/scope-containment.md Adds checklist ensuring feature stays within ratified scope boundaries.
specs/007-client-identity-roster/checklists/reporting-diagnostics.md Adds checklist for output diagnosability and reporting requirements.
specs/007-client-identity-roster/checklists/record-immutability-lifecycle.md Adds checklist for governance document lifecycle/immutability constraints.
specs/007-client-identity-roster/checklists/measurability.md Adds checklist ensuring claims are run-verifiable (not inspection-only).
specs/007-client-identity-roster/checklists/edge-case-coverage.md Adds checklist covering edge cases and scenario-class coverage.
specs/007-client-identity-roster/checklists/dependency-sequencing.md Adds checklist for phase ordering, prerequisites, and stop conditions.
specs/007-client-identity-roster/checklists/consent-cascade.md Adds checklist for consent cascade changes and lifecycle growth.
specs/007-client-identity-roster/checklists/conformance-wiring.md Adds checklist for pack membership, doc-health reporting, and refusal wiring.
specs/007-client-identity-roster/checklists/authority-safety.md Adds checklist for authority roots, safety constraints, and fail-closed defaults.
specs/007-client-identity-roster/analyze-round-8.md Adds analysis record for review round 8 and post-fix re-sweep.
specs/007-client-identity-roster/analyze-round-7.md Adds analysis record for review round 7 (summary-surface composition).
specs/007-client-identity-roster/analyze-round-4.md Adds analysis record for review round 4 findings/fixes.
specs/007-client-identity-roster/analyze-round-3.md Adds analysis record for review round 3 findings/fixes.
specs/007-client-identity-roster/a16-escalation-ruling-2026-08-15.md Adds escalation ruling record for the multi-surface reader example decision.
scripts/validate-credential-contracts.py Adds semantic enforcement for closed issuance_preconditions vocabulary.
scripts/validate-consent-instruments.py Extends lifecycle to include withdrawn and enforces identity cascade evidence.
scripts/doc_health/families.py Registers the new doc-health family in the dispatcher.
scripts/doc_health/init.py Adds client-identity-composition to the report-family list (with noted omission).
README.md Updates top-level documentation for new contract family and modified capabilities.
openspec/changes/add-client-identity-roster/tasks.md Amends packaged example requirements per Decision C and records rationale.
openspec/changes/add-client-identity-roster/specs/domain-conformance-checks/spec.md Adds the delta specifying pack growth to four checks and roster gate behavior.
openspec/changes/add-client-identity-roster/specs/doc-health/spec.md Updates doc-health delta to include roster composition family execution semantics.
openspec/changes/add-client-identity-roster/specs/credential-contracts/spec.md Adds credential-contracts delta for issuance_preconditions vocabulary.
openspec/changes/add-client-identity-roster/specs/consent-instrument/spec.md Adds consent-instrument delta for withdrawn and cascade behavior.
openspec/changes/add-client-identity-roster/review/amendment-record-2026-08-14.md Adds amendment record documenting Decisions A and B.
openspec/changes/add-client-identity-roster/proposal.md Updates proposal to reflect amendments and modified capability list.
examples/credential-contracts/roster-drift.requirements.example.yaml Adds positive example declaring the roster-drift issuance precondition.
examples/credential-contracts/negative/issuance-precondition-valued-false.yaml Adds negative example for false-valued issuance precondition.
examples/credential-contracts/negative/issuance-precondition-out-of-vocabulary.yaml Adds negative example for out-of-vocabulary issuance precondition.
examples/consent-instrument/README.md Documents the new withdrawn example and new identity cascade negative fixtures.
examples/consent-instrument/negative/identity-cascade-incomplete-on-withdrawn.yaml Adds negative: governed identity half-cascade on withdrawn.
examples/consent-instrument/negative/identity-cascade-incomplete-on-terminated.yaml Adds negative: governed identity half-cascade on terminated.
examples/consent-instrument/consent-instrument-withdrawn.example.yaml Adds valid withdrawn instrument example with governed identity cascade evidence.
examples/client-identity-roster/negative/vendor-tenant-multi-missing-obligations.yaml Adds roster negative exercising vendor multi-tenant obligations.
examples/client-identity-roster/negative/vendor-homed-declared-client-resident.yaml Adds roster negative for residency model/home tenant mismatch.
examples/client-identity-roster/negative/unverified-act-counted-as-access.yaml Adds roster negative for half-declared verification (pair rule).
examples/client-identity-roster/negative/undeclared-reach.yaml Adds roster negative for undeclared permission reach.
examples/client-identity-roster/negative/undeclared-act-surface.yaml Adds roster negative for undeclared admission act surface.
examples/client-identity-roster/negative/scope-exceeds-unit-undeclared.yaml Adds roster negative for exceeded unit without declared excess.
examples/client-identity-roster/negative/residency-model-out-of-vocabulary.yaml Adds roster negative for invalid residency model enum value.
examples/client-identity-roster/negative/provider-enforced-without-per-unit-principal.yaml Adds roster negative for invalid provider_enforced claim without principal.
examples/client-identity-roster/negative/per-unit-principal-undeclared.yaml Adds roster negative for missing per-unit principal map key.
examples/client-identity-roster/negative/per-unit-principal-available-but-logical.yaml Adds roster negative for logical enforcement when principal exists (surface-level).
examples/client-identity-roster/negative/name-understates-achieved-authority.yaml Adds roster negative for name token contradicting achieved authority.
examples/client-identity-roster/negative/mutate-without-ratified-capability.yaml Adds roster negative for mutate entry lacking domain-qualified ratification ref.
examples/client-identity-roster/negative/missing-enforcement-test.yaml Adds roster negative for missing enforcement test reference when declaring excess.
examples/client-identity-roster/negative/lifecycle-state-out-of-vocabulary.yaml Adds roster negative for invalid lifecycle_state enum value.
examples/client-identity-roster/negative/legend-token-missing.yaml Adds roster negative for missing legend binding for used token.
examples/client-identity-roster/negative/legend-token-declared-twice.yaml Adds roster negative for token collision across legend axes.
examples/client-identity-roster/negative/identity-kind-out-of-vocabulary.yaml Adds roster negative for invalid identity kind enum value.
examples/client-identity-roster/negative/full-tuple-duplicate.yaml Adds roster negative for duplicate identity key tuple within a fragment.
examples/client-identity-roster/negative/false-standing-credential-attestation.yaml Adds roster negative for contradictory standing credential attestation.
examples/client-identity-roster/negative/evidence-ref-malformed.yaml Adds roster negative for malformed evidence_ref shape.
examples/client-identity-roster/negative/entry-without-consent-instrument.yaml Adds roster negative for missing consent instrument citation.
examples/client-identity-roster/negative/enforcement-mode-out-of-vocabulary.yaml Adds roster negative for invalid enforcement mode enum value.
examples/client-identity-roster/negative/drift-finding-without-roster-value.yaml Adds drift-finding negative for missing roster_value.
examples/client-identity-roster/negative/drift-finding-without-observed-value.yaml Adds drift-finding negative for missing observed_value.
examples/client-identity-roster/negative/drift-finding-status-out-of-vocabulary.yaml Adds drift-finding negative for invalid status enum value.
examples/client-identity-roster/negative/destructive-authority-class.yaml Adds roster negative for destructive authority class proposal.
examples/client-identity-roster/negative/consent-recorded-as-access.yaml Adds roster negative for recording consent without admission acts.
examples/client-identity-roster/negative/alias-pair-observationally-identical.yaml Adds roster negative for alias-pair detection without rationale.
examples/client-identity-roster/negative/admission-surface-out-of-vocabulary.yaml Adds roster negative for invalid admission surface enum value.
examples/client-identity-roster/negative/achieved-exceeds-intended-undeclared.yaml Adds roster negative for achieved>intended without declared_excess.
examples/client-identity-roster/negative/achieved-class-contradicted-by-permissions.yaml Adds roster negative for achieved class contradicting declared permission achieves.
examples/client-identity-roster/client-identity-roster-lxtest-ledgerx.example.yaml Adds a truthful packaged roster fragment worked case (retired, Exchange).
examples/client-identity-roster/client-identity-drift-finding.example.yaml Adds a truthful drift finding worked case.
contracts/schemas/xfactory-credential-contracts.schema.yaml Adds issuance_preconditions schema vocabulary (closed, const true).
contracts/schemas/consent-instrument.schema.yaml Bumps contract schema version and adds withdrawn + governed identity fields.
contracts/schemas/consent-instrument-class-registry.schema.yaml Bumps contract schema version and aligns alias targets with withdrawn.
contracts/CHANGELOG.md Adds contract-v1.32 release notes and folds prior unreleased entry.
Suppressed comments (1)

README.md:284

  • This summary repeats the roster tuple as “authority class”, but the contract’s key uses authority_class_intended. Using the precise term here avoids ambiguity for readers cross-referencing the spec and schema.
  — authored 2026-08-14 from the Business Central admission investigation:
  the neutral identity layer beneath credential-contracts and
  consent-instrument. Which identities stand in a paying client's tenant,
  keyed on (domain, admission surface, authority class, blast-radius unit,
  duty); verified admission with achieved scope; structural scoping
  preferred; declared provider-forced breadth; report-only drift that

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +31 to +34
### Requirement: The Lifecycle Enum Is Closed With Declared Aliases
The instrument status SHALL be the closed six-state lifecycle `draft →
pending_signatures → executed → amended → terminated`, with `withdrawn` a
second terminal state reachable once the instrument is past execution;
Comment thread README.md
Comment on lines +232 to +237
- Client identity roster: [xfactory-client-identity-roster schema](contracts/schemas/xfactory-client-identity-roster.schema.yaml),
`scripts/validate-client-identity-roster.py <domain-repo>` and the packaged
corpus at [examples/client-identity-roster](examples/client-identity-roster/README.md)
— which identities a domain holds STANDING inside a paying client's provider
tenant, keyed on (domain, admission surface, authority class, blast-radius
unit, duty), with verified admission and achieved scope, and a report-only
Comment thread contracts/CHANGELOG.md
Comment on lines +29 to +32
kinds behind one top-level `oneOf`, because the fragment and the drift record
that cites it are produced and consumed by one lane and the five-element
uniqueness tuple — (domain, admission surface, authority class, blast-radius
unit, duty) — must be defined once and referenced by both. Entries carry
…ntract-v1.33 after main's intervening v1.32

PR #187 (add-subject-overlay-contract, 7733158) cut contract-v1.32 on main
while this branch was in flight, and this branch had cut contract-v1.32 too.
House precedent f62744c: merge main IN, never rebase. Our registration is
re-cut as contract-v1.33 on top of main's v1.32.

Conflicts and their resolution:

- contracts/manifest.yaml auto-merged (main's rows sit at ~840, ours at
  ~1740+): ALL of main's rows including the new hermes-subject-overlay row
  and main's omnigent digest correction, plus all four of our row changes
  (client-identity-roster and credential-contracts NEW, the two consent rows
  refreshed with their six-state prose). contract_bundle_version ->
  contract-v1.33, and every consumption_rule naming OUR cut moves to v1.33.
  The openxwallet row's "FOLDED INTO the contract-v1.32 cut" sentence stays
  at v1.32 because that is now TRUE of main's cut, which discharged the
  Unreleased block.

- contracts/CHANGELOG.md: main's ## contract-v1.32 entry is byte-identical
  to origin/main and keeps the openxwallet fold-in it discharged. Our entry
  is re-headed ## contract-v1.33 and sits above it, WITHOUT the duplicate
  openxwallet bullet (v1.33 does not re-discharge a block v1.32 already
  discharged), and its inventory-membership claim now reads "unchanged from
  v1.30, v1.31 and v1.32".

- contracts/releases/contract-v1.32.digests.yaml was an add/add conflict —
  both lanes generated one. Main's is kept BYTE-IDENTICAL; ours is
  regenerated as contract-v1.33.digests.yaml by
  `validate-contract-release.py build --tag contract-v1.33`, entries=190,
  membership IDENTICAL to v1.30/v1.31/v1.32 (zero paths added or removed,
  no roster path, nothing hand-added). The digest diff v1.32 -> v1.33 is
  exactly the three release-surface files this cut edits: manifest,
  CHANGELOG and contracts/README.md.

- README.md auto-merged: main's three new active-change entries
  (add-subject-overlay-contract, add-staged-topic-outline-template,
  add-doxbench-editing-phase-a) AND our rewritten add-client-identity-roster
  entry are all present; no entry lost.

Composition check (b533a1f..origin/main): main touched NOTHING this feature
composes with — no scripts/doc_health, no promoted doc-health,
consent-instrument, credential-contracts or domain-conformance-checks spec,
no consent or credential-contracts schema, no consent/credential validator.
Family counts and enum text are unaffected; the re-cut is a renumber, not a
reconciliation.

Re-verified over the merged tree:

- validate-contract-release.py build --tag contract-v1.33 -> pass, 190
  entries.
- validate-manifest-digests.py -> OK, 135 digests verify, exit 0. HONEST
  CHANGE OF STATE: the single pre-existing omnigent-domain-overlay mismatch
  this feature reported and deliberately left is GONE, cured by main's own
  v1.32 in the lane that owned it; main's subject-overlay row is the 135th.
  traceability.yaml FR-021 red_proven now records both measures.
- openspec validate add-client-identity-roster --strict -> valid;
  --all --strict -> 61 passed, 0 failed (was 58; main added three active
  changes).
- The 10.7 delta-fidelity assertion RE-RUN mechanically against the promoted
  specs as they now stand: doc-health "Deterministic check families"
  promoted 7 / delta 8, MISSING FROM DELTA []; consent-instrument's two
  restated requirements 1/2 and 2/3, nothing missing; every promoted bullet
  present. Nothing promoted is deleted on landing.
- pytest tests/client-identity-roster tests/credential_contracts
  tests/conformance-gate -> 61 passed, 2 skipped.
- Validator self-tests: roster 4 positives clean + 31 negatives refused for
  their registered reason, PASS; consent 6 valid + 7 negative + 2 purpose
  probes, 0 errors 0 warnings; credential-contracts 3 positive + 5 negative,
  PASS.

Dated records left standing as written: the analyze-round records, the
clarify rulings, the review amendment records, research.md, the checklists,
and the **DONE 2026-08-15** blocks in tasks.md. One dated line is added to
task 9.4 explaining the re-cut where the bundle number lives.

Co-Authored-By: Claude Fable 5 <[email protected]>
Copilot AI review requested due to automatic review settings August 15, 2026 15:37
…ts/README.md

Both assert OUR cut and were missed by the line-prefix sweep because they sit
mid-row in the registration table: the consent-instrument row's "`withdrawn`
added at contract-v1.32 as a second terminal state", and the
credential-contracts row's "contract-v1.32 closes that gap and registers its
one additive growth in the same cut". Both now read contract-v1.33.

contracts/README.md is in RELEASE_SURFACE_PATHS, so the v1.33 digest inventory
is REGENERATED over the edit rather than left stale (entries=190, membership
unchanged). No v1.32 string remains in contracts/README.md.

Co-Authored-By: Claude Fable 5 <[email protected]>
@brettheap
brettheap merged commit 71674ed into main Aug 15, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 118 out of 120 changed files in this pull request and generated no new comments.

Suppressed comments (1)

README.md:231

  • PR description states the registration bundle is contract-v1.32, but this README documents first registration / new family as landing in contract-v1.33 (and the branch also contains contracts/manifest.yaml + contracts/releases/contract-v1.33.digests.yaml). Please reconcile the PR description vs the realized bundle tag so reviewers/consumers aren’t left unsure which release this change targets.
- Credential contracts: [xfactory-credential-contracts schema](contracts/schemas/xfactory-credential-contracts.schema.yaml)
  and `scripts/validate-credential-contracts.py <domain-repo>` — the five
  credential record kinds under `credentials/` (DTN-004). Registered in
  `contracts/manifest.yaml` for the first time at `contract-v1.33`, which also
  adds the optional `issuance_preconditions` vocabulary
  (`add-client-identity-roster`).

Copilot AI review requested due to automatic review settings August 15, 2026 15:42

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 118 out of 120 changed files in this pull request and generated no new comments.

Suppressed comments (2)

openspec/changes/add-client-identity-roster/specs/consent-instrument/spec.md:34

  • The lifecycle sequence is described as a “closed six-state lifecycle” but the inline arrow list omits withdrawn, which makes the statement internally inconsistent. This should list all six states (or explicitly show terminated|withdrawn as alternative terminal states).
    specs/007-client-identity-roster/checklists/versioning-registration.md:8
  • This checklist still references contract-v1.32 as the target bundle, but the release documentation updated in this PR (e.g., contracts/CHANGELOG.md and README.md) describes the roster work as landing in contract-v1.33. To avoid confusing reviewers and future reruns of the checklist, the referenced bundle version should be updated to match the realized release tag.

brettheap pushed a commit that referenced this pull request Aug 15, 2026
…ted as client-identity-roster (PR #190)

Co-Authored-By: Claude Opus 5 <[email protected]>
brettheap added a commit that referenced this pull request Sep 4, 2026
#637)

Copilot review finding on the sibling adoption PRs (codexFactory #190,
xFactory #231, openXwallet #15): the ::error annotation interpolated the
untrusted PR-body first line ($first) directly into the workflow command
message, which GitHub Actions percent-decodes — a crafted body line could
inject additional workflow commands into the runner log. The annotation
is now fully static; the offending line is still surfaced, via a plain
echo before the annotation instead of inside it.

Also fixes the exemption comment: it said "bots are exempt by ACTOR" but
the condition keys on github.event.pull_request.user.type, the PR AUTHOR,
not the actor. Reworded to say PR AUTHOR type explicitly.

This is the appendix errata for lane-collision-protocol-amendment-1.md's
Rule 8 appendix, applied to the copy already merged here as #631
(b1d492a).

Lane: openxfactory-f2

Claude-Session: https://claude.ai/code/session_01KeBPLWRL4rhgRbmjP8Li41

Co-authored-by: Claude Fable 5.1 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants