Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .github/workflows/auth-taxonomy-parity.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,15 @@ on:
permissions:
contents: read

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.event_name == 'pull_request' }}

jobs:
auth-taxonomy-parity:
name: Auth-taxonomy parity (DETECT, non-blocking)
runs-on: ubuntu-latest
timeout-minutes: 10
# Non-blocking: surface drift as a signal, never fail the PR on it.
continue-on-error: true

Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/parity-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,15 @@ on:
permissions:
contents: read

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
parity-check:
name: Parity manifest freshness
runs-on: ubuntu-latest
timeout-minutes: 10

steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ jobs:
name: Verify exact main release ref
if: inputs.confirm_publish == true
runs-on: ubuntu-latest
timeout-minutes: 10
permissions:
contents: read
outputs:
Expand Down Expand Up @@ -64,6 +65,7 @@ jobs:
publish:
needs: verify-release-ref
runs-on: ubuntu-latest
timeout-minutes: 30
if: inputs.confirm_publish == true && needs.verify-release-ref.result == 'success'
environment: ${{ inputs.environment || 'testpypi' }}
outputs:
Expand Down Expand Up @@ -218,6 +220,7 @@ jobs:
verify-publication:
needs: [verify-release-ref, publish]
runs-on: ubuntu-latest
timeout-minutes: 10
if: >-
always() &&
needs.verify-release-ref.result == 'success' &&
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/schema-orphan-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,15 @@ on:
permissions:
contents: read

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
schema-orphan-check:
name: Schema reachability report freshness
runs-on: ubuntu-latest
timeout-minutes: 10

steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/spine-trail-gate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ jobs:
spine-trail:
name: spine-trail present
runs-on: ubuntu-latest
timeout-minutes: 10
# No token at all: this job only echoes and reads the PR body out of the
# event payload. It never checks out code and never calls the GitHub API, so
# granting it `contents: read` was privilege it could not use.
Expand Down Expand Up @@ -102,6 +103,7 @@ jobs:
# Promotion of this job to a required check is a separate, later owner
# decision. This job leaves the existing "spine-trail present" job untouched.
runs-on: ubuntu-latest
timeout-minutes: 10
continue-on-error: true
permissions:
contents: read
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/validation-g8-dispatch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ jobs:
dispatch:
name: Dispatch validation-spine G8
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
# TraigentSchema is a PUBLIC repo, so org-level secrets with
# visibility:private (SPINE_RO_TOKEN / VALIDATION_CI_PAT) are invisible
Expand Down
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ Unreleased changes are kept as fragments in changelog.d/; see changelog.d/README
- Some changes inside shared `definitions`/`$defs` were not flagged by the breaking-change check, and some of them narrow what consumers accept.
- A fix that makes the check walk definitions is in progress.

## [7.1.0] - 2026-10-29
## [7.1.0] - 2026-11-03

### Added
- **Certification data-flow mode `private_online` (additive minor).** `DataFlowModeV0` gains a third value, accepted by the unsigned manifest `privacy_mode.declared_mode`, the `bind-g1` request `declared_mode` enum and the Python relying-party verifier's closed mode set (`expected_privacy_mode`). Meaning: the server-recorded session privacy policy was active for the run and the run used the online Traigent backend; it does NOT attest complete SDK egress, customer-content confinement or zero egress, and it is derived by the server from its own stamp, never from a client declaration alone. `current_online` stays an explicitly client-declared, unwitnessed mode; `offline` stays reserved for a witnessed zero-backend-egress run (D2, unsupported in v0). The D2 payload constant and the fixed 14 non-claims are unchanged. Existing documents with `offline` or `current_online` validate unchanged. Parity manifest regenerated.
Expand Down
14 changes: 14 additions & 0 deletions changelog.d/schema-audit-contract-alignment.changed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
- **`promotion_policy_schema.json` per-schema version 0.10.0 to 0.11.0** for the #580 constraint tightening below.
- **Annotation-queue and evaluator update bodies need one usable field (BREAKING for clients that sent only a null description, or, on annotation queues, only a blank name or description; the service already refused these with 422) (#723).** `annotation_queue_update_request_schema.json` and `evaluator_update_request_schema.json` gain a root `anyOf`, and an empty body is refused by both. On annotation queues, a body whose only field is a null description, a blank name or a blank description is refused. On evaluators, a body whose only field is a null description is refused; a blank name or description is still accepted by the schema and the backend, which has no strip validator. Both update schemas are referenced via `$ref` from `observability_endpoints.json`.
- **Non-breaking: evaluator update accepts an explicit `null` for `target_type` (#723).** `target_type` is nullable in `evaluator_update_request_schema.json` and `null` means unchanged, matching `EvaluatorDefinitionUpdateRequest` in the backend. A body with another field and a null `target_type` is accepted; a body whose only field is a null `target_type` is refused, as the service refuses it.
- **Tighter request validation (breaking for clients that used the older schema allowances).**
`promotion_policy`: `alpha` in (0, 1), `min_effect` values >= 0, chance-constraint `threshold` in [0, 1], `confidence` in (0, 1) (#580).
Evaluators: the update and execute request bodies are closed (unknown keys are refused); update drops `primary_measure_id`, needs at least one property and declares `target_type`; execute drops `source`; the backfill body is the new closed `evaluator_backfill_request_schema.json` (`target_type`, `filters`, `limit`, `skip_existing_scores`; `target_ids` and `force` removed) (#584).
Annotation queues: the create and update bodies are closed, and `description` is at most 2000 characters before trimming. The backend trims first, so the schema can reject a padded value the service accepts. An update needs at least one property; a body whose only fields are null, or that has only blank name or description, is refused by the schema (#640, #645, #723).
Prompts: `prompt_text` at most 10000 characters before trimming in the three prompt request schemas. The backend trims first, so the schema can reject a padded prompt the service accepts (#650).
Example-set create: `selection_method` and `type` are enums, `tags` at most 100 (#671).
- **Finalize and backfill accept an explicit `null`.** `optimization_outcome` may be `null` on the session finalize request, meaning absent (completed). `target_type` may be `null` on the evaluator backfill request, meaning the evaluator's own target type.
- **Non-breaking: agent create `retrieval_configs` and `model_parameters` allow up to 100 items (was 50), matching the backend cap (#652).** This loosens the schema; no request the service accepts is refused.
- **Identity: `compute_agent_build_digest` now rejects a present `source_digest` that is not `sha256:<64 hex>`, including for dirty builds (#697).**

- **Evaluator backfill result declares `skipped_reasons` and `skipped_reason_counts` (#648). These optional fields constrain values previously accepted as undeclared extensions.** Legacy run-analytics GET endpoints declare their query parameters (`objective`, `limit`, `request_count`, ...) (#641). The project-scoped replacements keep their existing query contracts. The session finalize request declares `optimization_outcome` (`completed`, `failed`, `cancelled`) (#696).
1 change: 1 addition & 0 deletions docs/content-class-manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -868,6 +868,7 @@
"optimization/optimization_endpoints.json#/paths/~1api~1v1~1sessions~1{session_id}~1finalize/post/requestBody/content/application~1json/schema/properties/include_full_history": "closed_enum",
"optimization/optimization_endpoints.json#/paths/~1api~1v1~1sessions~1{session_id}~1finalize/post/requestBody/content/application~1json/schema/properties/metadata": "legacy_content",
"optimization/optimization_endpoints.json#/paths/~1api~1v1~1sessions~1{session_id}~1finalize/post/requestBody/content/application~1json/schema/properties/metadata [keys]": "legacy_content",
"optimization/optimization_endpoints.json#/paths/~1api~1v1~1sessions~1{session_id}~1finalize/post/requestBody/content/application~1json/schema/properties/optimization_outcome": "closed_enum",
"optimization/optimization_endpoints.json#/paths/~1api~1v1~1sessions~1{session_id}~1identity-binding/get/parameters/0/schema": "opaque_ref",
"optimization/optimization_endpoints.json#/paths/~1api~1v1~1sessions~1{session_id}~1intermediate-report/post/parameters/0/schema": "opaque_ref",
"optimization/optimization_endpoints.json#/paths/~1api~1v1~1sessions~1{session_id}~1next-trial/post/parameters/0/schema": "opaque_ref",
Expand Down
4 changes: 2 additions & 2 deletions parity/python-js-sdk.json
Original file line number Diff line number Diff line change
Expand Up @@ -399,8 +399,8 @@
"sdk032Surface": "Manifest Python pin advanced from d56e4353 to 6e8e4a54 (origin/develop, the SDK 0.32.0 release candidate) to cover two root exports the js-public-parity gate flagged unclassified on Traigent/Traigent#2861. requirement (traigent.runtime.decorator) is the runtime latency requirement decorator; traigent-js origin/main and origin/develop both export requirement from src/runtime/index.ts and list it in tests/integration/fixtures/api-surface.snapshot.json, so it is classified matched and added to requiredRootExports next to require. SnapshotBindingError (traigent.utils.exceptions) is the typed error of the Python opt-in snapshot store (S0 before dispatch, S1 from the terminal result, online G1); traigent-js has no snapshot store and no export of it (zero occurrences in src or its api-surface snapshot), so it is classified deferred-backlog, Python-only for now with no open JS design and no ticket. Owner may re-bucket."
},
"schemaRefresh": {
"lastSchemaFileSha": "e1336def76c4e9122fd14a4a4ccd8abb370e7a196a93fabecfabba6e270290c4",
"schemaFileCount": 692,
"lastSchemaFileSha": "9b49344e7c7e4eb3e0683071dcabe347616d76593d02e7b5b23b2b73dd99848b",
"schemaFileCount": 693,
"note": "Auto-stamped by scripts/refresh_parity.py. Do not hand-edit this block."
}
}
7 changes: 6 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -75,11 +75,16 @@ include = [

[tool.ruff]
line-length = 100
target-version = "py310"
target-version = "py311"

[tool.ruff.lint]
select = ["E", "F", "I", "UP", "B"]

# Frozen shipped verifier: its bytes are pinned to the reference by
# tests/test_dataset_record_v1_schema.py, so it cannot take the py311 UP017 rewrite.
[tool.ruff.lint.per-file-ignores]
"traigent_schema/certification/process_record_verifier.py" = ["UP017"]

[tool.mypy]
python_version = "3.11"
warn_return_any = true
Expand Down
20 changes: 12 additions & 8 deletions reports/schema-rebase-result.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,16 +68,19 @@ Result: `schemaFileCount=394`,
Consumer references were refreshed from clean archives of each sibling's
current `origin/develop` ref, then the reachability report was regenerated:

Set `SIBLINGS_ROOT` to the directory containing the sibling checkouts before running the commands.

```bash
: "${SIBLINGS_ROOT:?Set SIBLINGS_ROOT to the directory containing the sibling checkouts}"
for repo in Traigent TraigentBackend TraigentFrontend traigent-js traigent-smartopt; do
git -C <workspace>/$repo fetch origin develop
git -C "$SIBLINGS_ROOT/$repo" fetch origin develop
done
python3 scripts/refresh_consumer_schema_references.py \
--repo Traigent=<workspace>/Traigent \
--repo TraigentBackend=<workspace>/TraigentBackend \
--repo TraigentFrontend=<workspace>/TraigentFrontend \
--repo traigent-js=<workspace>/traigent-js \
--repo traigent-smartopt=<workspace>/traigent-smartopt
--repo "Traigent=$SIBLINGS_ROOT/Traigent" \
--repo "TraigentBackend=$SIBLINGS_ROOT/TraigentBackend" \
--repo "TraigentFrontend=$SIBLINGS_ROOT/TraigentFrontend" \
--repo "traigent-js=$SIBLINGS_ROOT/traigent-js" \
--repo "traigent-smartopt=$SIBLINGS_ROOT/traigent-smartopt"
python3 scripts/schema_reachability.py --update
python3 scripts/schema_reachability.py --check
```
Expand Down Expand Up @@ -191,9 +194,10 @@ Results:
Schema worktree fails and shows the missing field in the generated diff:

```bash
: "${SIBLINGS_ROOT:?Set SIBLINGS_ROOT to the directory containing the sibling checkouts}"
TRAIGENT_SCHEMA_REPO="$PWD" \
<workspace>/Traigent/.venv/bin/python \
<workspace>/Traigent/scripts/generate_schema_types.py \
"$SIBLINGS_ROOT/Traigent/.venv/bin/python" \
"$SIBLINGS_ROOT/Traigent/scripts/generate_schema_types.py" \
--check
```

Expand Down
6 changes: 3 additions & 3 deletions reports/schema_reachability/unreachable_schemas.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@
"reachableByRule": {
"allowlist": 0,
"consumerReference": 33,
"refOrEndpointGraph": 598
"refOrEndpointGraph": 599
},
"reachableCount": 631,
"schemaFileCount": 692,
"reachableCount": 632,
"schemaFileCount": 693,
"unreachableCount": 61
},
"unreachableSchemas": [
Expand Down
Loading
Loading