betterwithage commited on
Commit
38b9849
·
verified ·
1 Parent(s): 43c50ad

chore(sync): mirror backend .py + Dockerfile to Space (hf-sync-backend)

Browse files

Automated backend sync from szl-holdings/a11oy main via hf-sync-backend.
Updated (differed from the Space): serve.py
Deleted (gone from the repo + Dockerfile COPY set): (none)

Keeps the Space-built backend (serve.py + the Dockerfile-COPY'd .py
modules) identical to GitHub main so the Space never rebuilds from a
stale backend, new endpoints don't 404 there, and orphaned modules
removed from the repo don't linger in the Space tree.

Files changed (1) hide show
  1. serve.py +12 -12
serve.py CHANGED
@@ -638,7 +638,7 @@ except Exception as _th_e:
638
  # POST /api/a11oy/khipu/sign — DSSE-sign a receipt (real ECDSA-P256 cosign sig)
639
  # POST /api/a11oy/khipu/verify — verify a DSSE envelope against cosign.pub
640
  # GET /api/a11oy/khipu/ledger — signed Khipu Merkle DAG
641
- # GET /api/a11oy/provenance — combined honest board (SLSA L1+L2 attested: cosign keyless-verified image (L1) + signed SLSA build-provenance attestation via actions/attest-build-provenance@v2 (L2), Sigstore keyless Fulcio+Rekor, verifiable via gh attestation verify / cosign verify-attestation; L3 roadmap, not claimed)
642
  # The Wire-D middleware echoes traceparent on EVERY response (incl. the Node-proxy
643
  # catch-all) so trace continuity holds across the whole Space. Real signatures only
644
  # when the SZL_COSIGN_PRIVATE_PEM runtime secret is present (else honestly UNSIGNED).
@@ -845,7 +845,7 @@ for _organ_mod, _organ_label in (
845
  # and win ordering. The package root /app/src is added to sys.path so
846
  # `import a11oy.formulas` resolves under WORKDIR /app (per-file COPY in Dockerfile).
847
  # try/except guarded — a missing optional dep can NEVER take down the SPA + API.
848
- # Λ = Conjecture 1 (NEVER a theorem). SLSA L1+L2 attested (cosign-signed image,
849
  # public Sigstore + Rekor verified (L1) + signed SLSA build-provenance attestation
850
  # via actions/attest-build-provenance@v2 (L2), verifiable via gh attestation verify
851
  # / cosign verify-attestation); L3 roadmap, not claimed. See .compliance/SLSA_LEVEL.md.
@@ -1334,7 +1334,7 @@ async def v1_healthz() -> JSONResponse:
1334
  "error": "Node serve on :8081 is not running",
1335
  "doctrine": {"declarations": 749, "axioms": 14, "sorries": 163,
1336
  "version": "v11", "replay_hash": "c7c0ba17"},
1337
- "slsa": "SLSA L1+L2 attested · L3 roadmap. L1: cosign-signed image (verifiable via cosign verify). L2: signed SLSA build-provenance attestation (actions/attest-build-provenance@v2, Sigstore keyless Fulcio+Rekor), verifiable via `gh attestation verify` / `cosign verify-attestation --type slsaprovenance`. L3 not claimed. Not Iron Bank / FedRAMP / CMMC / ATO without roadmap.",
1338
  },
1339
  status_code=503,
1340
  )
@@ -1352,7 +1352,7 @@ async def v1_healthz() -> JSONResponse:
1352
  "routes": ["/v1/ledger", "/v1/ledger/{hash}", "/v1/verify", "/v1/policy/evaluate"],
1353
  "doctrine": {"declarations": 749, "axioms": 14, "sorries": 163,
1354
  "version": "v11", "replay_hash": "c7c0ba17"},
1355
- "slsa": "SLSA L1+L2 attested · L3 roadmap. L1: cosign-signed image (verifiable via cosign verify). L2: signed SLSA build-provenance attestation (actions/attest-build-provenance@v2, Sigstore keyless Fulcio+Rekor), verifiable via gh attestation verify / cosign verify-attestation --type slsaprovenance. L3 not claimed. Not Iron Bank / FedRAMP / CMMC / ATO without roadmap.",
1356
  }, status_code=200 if backend["alive"] else 503)
1357
 
1358
 
@@ -2874,7 +2874,7 @@ async def _a11oy_pr_honest_v2():
2874
  "experimental_scope": {"kernel_commit": "7885fd9", "lean": "v4.18.0", "declarations": 1304, "axioms_unique": 22, "theorems_ci_green": 36, "note": "CI-green, kernel-verified (Wave5-8 + agentic P1-P6 + airtight Λ + coder); NOT folded into the locked count of 8; Λ stays Conjecture 1"},
2875
  "kernel_commit": "c7c0ba17",
2876
  "lambda_status": "Conjecture 1 — NOT a theorem",
2877
- "slsa": "SLSA L1+L2 attested · L3 roadmap across all organs. L1: cosign-signed images. L2: signed SLSA build-provenance attestation (actions/attest-build-provenance@v2, Sigstore keyless Fulcio+Rekor), verifiable via `gh attestation verify` / `cosign verify-attestation --type slsaprovenance`. L3 not claimed. Not Iron Bank / FedRAMP / CMMC / ATO without roadmap.",
2878
  "slsa_evidence": {
2879
  "level": "L2",
2880
  "image_tag": "uds-v0.2.0",
@@ -2896,7 +2896,7 @@ async def _a11oy_pr_honest_v2():
2896
  "No Iron Bank / FedRAMP / CMMC certification claimed",
2897
  "Section 889 = exactly 5 vendors (Huawei, ZTE, Hytera, Hikvision, Dahua)",
2898
  "HNSW formula endpoint is an HONEST in-process retrieval stub; BLS returns an honest backend-availability flag (real verify only when py_ecc present).",
2899
- "SLSA L1+L2 attested · L3 roadmap across all organs (cosign-signed images + signed SLSA build-provenance attestation, Sigstore keyless Fulcio+Rekor verifiable via gh attestation verify / cosign verify-attestation). L3 not claimed. NOT Iron Bank, NOT FedRAMP, NOT CMMC, NOT ATO without roadmap.",
2900
  ],
2901
  "role": "Brand Orchestration / gates",
2902
  })
@@ -3029,7 +3029,7 @@ print("[a11oy] PARITY BLOCK v2 registered BEFORE proxy: /api/a11oy/v1/{lambda,ho
3029
  # shape the scene's normalizeStats() consumes. Registered at BOTH the root path
3030
  # (HF proxy strips /api/a11oy) and the /api/a11oy/v1 path, BEFORE the catch-all
3031
  # proxy + SPA, matching the existing /v4/fleet dual-registration pattern.
3032
- # Doctrine v11 LOCKED 749/14/163; Λ = Conjecture 1; SLSA L1+L2 attested (cosign-
3033
  # signed GHCR image + signed SLSA build-provenance attestation, Sigstore + Rekor
3034
  # verifiable via gh attestation verify / cosign verify-attestation); L3 roadmap
3035
  # (NOT claimed); never FedRAMP/Iron Bank/CMMC/ATO without roadmap — unchanged.
@@ -3299,7 +3299,7 @@ async def a11oy_mcp_tools_inline():
3299
  "flagship": "a11oy", # host flagship (backward-compatible field)
3300
  "flagships": _flagships, # every flagship that contributed live tools
3301
  "sources": _sources,
3302
- "kernel_commit": "c7c0ba17", "slsa_level": "SLSA L1+L2 attested · L3 roadmap. L1: cosign-signed image. L2: signed SLSA build-provenance attestation (actions/attest-build-provenance@v2, Sigstore keyless Fulcio+Rekor), verifiable via gh attestation verify / cosign verify-attestation --type slsaprovenance. L3 not claimed. Not Iron Bank / FedRAMP / CMMC / ATO without roadmap.",
3303
  "lambda_uniqueness": "Conjecture 1 — NOT a theorem",
3304
  })
3305
 
@@ -4141,7 +4141,7 @@ try:
4141
  "launch_at": "/api/a11oy/v1/warhacker/launch/" + d["key"]}
4142
  for d in _WH_DEMOS],
4143
  "lambda_status": "Conjecture 1 (advisory, not a pass/fail oracle)",
4144
- "slsa": "SLSA L1+L2 attested · L3 roadmap across all organs. L1: cosign-signed images. L2: signed SLSA build-provenance attestation (actions/attest-build-provenance@v2, Sigstore keyless Fulcio+Rekor), verifiable via gh attestation verify / cosign verify-attestation. L3 not claimed. Not Iron Bank / FedRAMP / CMMC / ATO without roadmap.",
4145
  })
4146
 
4147
  # Map the launch keys to the REAL exhaustive-demo engine keys (the demos
@@ -4294,7 +4294,7 @@ except Exception as _wh_obs_e: # pragma: no cover - additive, defensive
4294
  # pack registry, business observability. Registered BEFORE the SPA catch-all.
4295
  #
4296
  # HONESTY: Λ = Conjecture 1 (advisory, never a pass/fail oracle). 8 proven
4297
- # formulas {F1,F4,F7,F11,F12,F18,F19,F22}. SLSA L1+L2 attested; L3 build-provenance roadmap
4298
  # (not yet claimed); NOT FedRAMP/Iron Bank/CMMC/ATO without roadmap. No
4299
  # cross-origin organ dependencies — a11oy is fully self-contained.
4300
  # The DSSE key below is a REAL ephemeral ECDSA P-256 key generated in-image
@@ -6386,7 +6386,7 @@ async def _a11oy_pr_honest():
6386
  "sorries_baseline": 112, "sorries_putnam": 51, "trust_axes": 13,
6387
  "policy_gates": 46, "anchor_formula_gates": 44, "mcp_tools": 12,
6388
  "lambda_uniqueness": "Conjecture 1 — NOT a closed theorem (open CAUCHY_ND sorry + missing symmetry axiom)",
6389
- "slsa": "SLSA L1+L2 attested · L3 roadmap. L1: cosign-signed image (verifiable via cosign verify). L2: signed SLSA build-provenance attestation (actions/attest-build-provenance@v2, Sigstore keyless Fulcio+Rekor), verifiable via `gh attestation verify` / `cosign verify-attestation --type slsaprovenance`. L3 not claimed. Not Iron Bank / FedRAMP / CMMC / ATO without roadmap.",
6390
  "slsa_evidence": {
6391
  "level": "L2",
6392
  "image_tag": "uds-v0.2.0",
@@ -6500,7 +6500,7 @@ async def api_health() -> JSONResponse:
6500
  "lean_sha": "c7c0ba17",
6501
  "experimental_scope": {"kernel_commit": "7885fd9", "lean": "v4.18.0", "declarations": 1304, "axioms_unique": 22, "theorems_ci_green": 36, "note": "CI-green, kernel-verified (Wave5-8 + agentic P1-P6 + airtight Λ + coder); NOT folded into the locked count of 8; Λ stays Conjecture 1"},
6502
  "lambda_status": "Conjecture 1 (NOT a theorem)",
6503
- "slsa": "SLSA L1+L2 attested · L3 roadmap across all organs. L1: cosign-signed images. L2: signed SLSA build-provenance attestation (actions/attest-build-provenance@v2, Sigstore keyless Fulcio+Rekor), verifiable via gh attestation verify / cosign verify-attestation. L3 not claimed. Not Iron Bank / FedRAMP / CMMC / ATO without roadmap.",
6504
  })
6505
 
6506
 
 
638
  # POST /api/a11oy/khipu/sign — DSSE-sign a receipt (real ECDSA-P256 cosign sig)
639
  # POST /api/a11oy/khipu/verify — verify a DSSE envelope against cosign.pub
640
  # GET /api/a11oy/khipu/ledger — signed Khipu Merkle DAG
641
+ # GET /api/a11oy/provenance — combined honest board (SLSA L1 honest; L2 .att emitted (not independently verified): cosign keyless-verified image (L1) + signed SLSA build-provenance attestation via actions/attest-build-provenance@v2 (L2), Sigstore keyless Fulcio+Rekor, verifiable via gh attestation verify / cosign verify-attestation; L3 roadmap, not claimed)
642
  # The Wire-D middleware echoes traceparent on EVERY response (incl. the Node-proxy
643
  # catch-all) so trace continuity holds across the whole Space. Real signatures only
644
  # when the SZL_COSIGN_PRIVATE_PEM runtime secret is present (else honestly UNSIGNED).
 
845
  # and win ordering. The package root /app/src is added to sys.path so
846
  # `import a11oy.formulas` resolves under WORKDIR /app (per-file COPY in Dockerfile).
847
  # try/except guarded — a missing optional dep can NEVER take down the SPA + API.
848
+ # Λ = Conjecture 1 (NEVER a theorem). SLSA L1 honest; L2 .att emitted (not independently verified) (cosign-signed image,
849
  # public Sigstore + Rekor verified (L1) + signed SLSA build-provenance attestation
850
  # via actions/attest-build-provenance@v2 (L2), verifiable via gh attestation verify
851
  # / cosign verify-attestation); L3 roadmap, not claimed. See .compliance/SLSA_LEVEL.md.
 
1334
  "error": "Node serve on :8081 is not running",
1335
  "doctrine": {"declarations": 749, "axioms": 14, "sorries": 163,
1336
  "version": "v11", "replay_hash": "c7c0ba17"},
1337
+ "slsa": "SLSA L1 honest; L2 .att emitted (not independently verified) · L3 roadmap. L1: cosign-signed image (verifiable via cosign verify). L2: signed SLSA build-provenance attestation (actions/attest-build-provenance@v2, Sigstore keyless Fulcio+Rekor), verifiable via `gh attestation verify` / `cosign verify-attestation --type slsaprovenance`. L3 not claimed. Not Iron Bank / FedRAMP / CMMC / ATO without roadmap.",
1338
  },
1339
  status_code=503,
1340
  )
 
1352
  "routes": ["/v1/ledger", "/v1/ledger/{hash}", "/v1/verify", "/v1/policy/evaluate"],
1353
  "doctrine": {"declarations": 749, "axioms": 14, "sorries": 163,
1354
  "version": "v11", "replay_hash": "c7c0ba17"},
1355
+ "slsa": "SLSA L1 honest; L2 .att emitted (not independently verified) · L3 roadmap. L1: cosign-signed image (verifiable via cosign verify). L2: signed SLSA build-provenance attestation (actions/attest-build-provenance@v2, Sigstore keyless Fulcio+Rekor), verifiable via gh attestation verify / cosign verify-attestation --type slsaprovenance. L3 not claimed. Not Iron Bank / FedRAMP / CMMC / ATO without roadmap.",
1356
  }, status_code=200 if backend["alive"] else 503)
1357
 
1358
 
 
2874
  "experimental_scope": {"kernel_commit": "7885fd9", "lean": "v4.18.0", "declarations": 1304, "axioms_unique": 22, "theorems_ci_green": 36, "note": "CI-green, kernel-verified (Wave5-8 + agentic P1-P6 + airtight Λ + coder); NOT folded into the locked count of 8; Λ stays Conjecture 1"},
2875
  "kernel_commit": "c7c0ba17",
2876
  "lambda_status": "Conjecture 1 — NOT a theorem",
2877
+ "slsa": "SLSA L1 honest; L2 .att emitted (not independently verified) · L3 roadmap across all organs. L1: cosign-signed images. L2: signed SLSA build-provenance attestation (actions/attest-build-provenance@v2, Sigstore keyless Fulcio+Rekor), verifiable via `gh attestation verify` / `cosign verify-attestation --type slsaprovenance`. L3 not claimed. Not Iron Bank / FedRAMP / CMMC / ATO without roadmap.",
2878
  "slsa_evidence": {
2879
  "level": "L2",
2880
  "image_tag": "uds-v0.2.0",
 
2896
  "No Iron Bank / FedRAMP / CMMC certification claimed",
2897
  "Section 889 = exactly 5 vendors (Huawei, ZTE, Hytera, Hikvision, Dahua)",
2898
  "HNSW formula endpoint is an HONEST in-process retrieval stub; BLS returns an honest backend-availability flag (real verify only when py_ecc present).",
2899
+ "SLSA L1 honest; L2 .att emitted (not independently verified) · L3 roadmap across all organs (cosign-signed images + signed SLSA build-provenance attestation, Sigstore keyless Fulcio+Rekor verifiable via gh attestation verify / cosign verify-attestation). L3 not claimed. NOT Iron Bank, NOT FedRAMP, NOT CMMC, NOT ATO without roadmap.",
2900
  ],
2901
  "role": "Brand Orchestration / gates",
2902
  })
 
3029
  # shape the scene's normalizeStats() consumes. Registered at BOTH the root path
3030
  # (HF proxy strips /api/a11oy) and the /api/a11oy/v1 path, BEFORE the catch-all
3031
  # proxy + SPA, matching the existing /v4/fleet dual-registration pattern.
3032
+ # Doctrine v11 LOCKED 749/14/163; Λ = Conjecture 1; SLSA L1 honest; L2 .att emitted (not independently verified) (cosign-
3033
  # signed GHCR image + signed SLSA build-provenance attestation, Sigstore + Rekor
3034
  # verifiable via gh attestation verify / cosign verify-attestation); L3 roadmap
3035
  # (NOT claimed); never FedRAMP/Iron Bank/CMMC/ATO without roadmap — unchanged.
 
3299
  "flagship": "a11oy", # host flagship (backward-compatible field)
3300
  "flagships": _flagships, # every flagship that contributed live tools
3301
  "sources": _sources,
3302
+ "kernel_commit": "c7c0ba17", "slsa_level": "SLSA L1 honest; L2 .att emitted (not independently verified) · L3 roadmap. L1: cosign-signed image. L2: signed SLSA build-provenance attestation (actions/attest-build-provenance@v2, Sigstore keyless Fulcio+Rekor), verifiable via gh attestation verify / cosign verify-attestation --type slsaprovenance. L3 not claimed. Not Iron Bank / FedRAMP / CMMC / ATO without roadmap.",
3303
  "lambda_uniqueness": "Conjecture 1 — NOT a theorem",
3304
  })
3305
 
 
4141
  "launch_at": "/api/a11oy/v1/warhacker/launch/" + d["key"]}
4142
  for d in _WH_DEMOS],
4143
  "lambda_status": "Conjecture 1 (advisory, not a pass/fail oracle)",
4144
+ "slsa": "SLSA L1 honest; L2 .att emitted (not independently verified) · L3 roadmap across all organs. L1: cosign-signed images. L2: signed SLSA build-provenance attestation (actions/attest-build-provenance@v2, Sigstore keyless Fulcio+Rekor), verifiable via gh attestation verify / cosign verify-attestation. L3 not claimed. Not Iron Bank / FedRAMP / CMMC / ATO without roadmap.",
4145
  })
4146
 
4147
  # Map the launch keys to the REAL exhaustive-demo engine keys (the demos
 
4294
  # pack registry, business observability. Registered BEFORE the SPA catch-all.
4295
  #
4296
  # HONESTY: Λ = Conjecture 1 (advisory, never a pass/fail oracle). 8 proven
4297
+ # formulas {F1,F4,F7,F11,F12,F18,F19,F22}. SLSA L1 honest; L2 .att emitted (not independently verified); L3 build-provenance roadmap
4298
  # (not yet claimed); NOT FedRAMP/Iron Bank/CMMC/ATO without roadmap. No
4299
  # cross-origin organ dependencies — a11oy is fully self-contained.
4300
  # The DSSE key below is a REAL ephemeral ECDSA P-256 key generated in-image
 
6386
  "sorries_baseline": 112, "sorries_putnam": 51, "trust_axes": 13,
6387
  "policy_gates": 46, "anchor_formula_gates": 44, "mcp_tools": 12,
6388
  "lambda_uniqueness": "Conjecture 1 — NOT a closed theorem (open CAUCHY_ND sorry + missing symmetry axiom)",
6389
+ "slsa": "SLSA L1 honest; L2 .att emitted (not independently verified) · L3 roadmap. L1: cosign-signed image (verifiable via cosign verify). L2: signed SLSA build-provenance attestation (actions/attest-build-provenance@v2, Sigstore keyless Fulcio+Rekor), verifiable via `gh attestation verify` / `cosign verify-attestation --type slsaprovenance`. L3 not claimed. Not Iron Bank / FedRAMP / CMMC / ATO without roadmap.",
6390
  "slsa_evidence": {
6391
  "level": "L2",
6392
  "image_tag": "uds-v0.2.0",
 
6500
  "lean_sha": "c7c0ba17",
6501
  "experimental_scope": {"kernel_commit": "7885fd9", "lean": "v4.18.0", "declarations": 1304, "axioms_unique": 22, "theorems_ci_green": 36, "note": "CI-green, kernel-verified (Wave5-8 + agentic P1-P6 + airtight Λ + coder); NOT folded into the locked count of 8; Λ stays Conjecture 1"},
6502
  "lambda_status": "Conjecture 1 (NOT a theorem)",
6503
+ "slsa": "SLSA L1 honest; L2 .att emitted (not independently verified) · L3 roadmap across all organs. L1: cosign-signed images. L2: signed SLSA build-provenance attestation (actions/attest-build-provenance@v2, Sigstore keyless Fulcio+Rekor), verifiable via gh attestation verify / cosign verify-attestation. L3 not claimed. Not Iron Bank / FedRAMP / CMMC / ATO without roadmap.",
6504
  })
6505
 
6506