Spaces:
Running
Running
chore(sync): mirror backend .py + Dockerfile to Space (hf-sync-backend)
Browse filesAutomated 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.
serve.py
CHANGED
|
@@ -1344,6 +1344,20 @@ try:
|
|
| 1344 |
app.add_api_route("/holo", _ptg_serve("holo.html"), methods=["GET"], include_in_schema=False)
|
| 1345 |
app.add_api_route("/a11oy/holo", _ptg_serve("holo.html"), methods=["GET"], include_in_schema=False)
|
| 1346 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1347 |
# /chat + /a11oy/chat -> /code consolidation (founder-directed; the only removal).
|
| 1348 |
async def _ptg_chat_to_code() -> Response:
|
| 1349 |
return _PTG_Redirect(url="/code", status_code=302)
|
|
@@ -7945,6 +7959,23 @@ def _viz_index(name: str) -> Response:
|
|
| 7945 |
return FileResponse(INDEX_HTML, media_type="text/html")
|
| 7946 |
|
| 7947 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 7948 |
@app.get("/viz")
|
| 7949 |
async def viz_gallery() -> Response:
|
| 7950 |
f = VIZ_DIR / "index.html"
|
|
|
|
| 1344 |
app.add_api_route("/holo", _ptg_serve("holo.html"), methods=["GET"], include_in_schema=False)
|
| 1345 |
app.add_api_route("/a11oy/holo", _ptg_serve("holo.html"), methods=["GET"], include_in_schema=False)
|
| 1346 |
|
| 1347 |
+
# WARHACKER SHOWCASE companion pages (public thought-leadership lane). Standalone
|
| 1348 |
+
# sovereign pages (0 runtime CDN, system fonts), each binds LIVE-provable claims to
|
| 1349 |
+
# real a11oy endpoints with an HONEST NO-LIVE-DATA fallback (never a fabricated
|
| 1350 |
+
# value); every maturity claim labelled LIVE / ROADMAP (doctrine v11). The
|
| 1351 |
+
# /signature-is-not-proof page IS the founder-demo PROOF moment ("a signature is not
|
| 1352 |
+
# proof of safety" — the Mini Shai-Hulud signed-supply-chain case study). Both HTML
|
| 1353 |
+
# files are per-file COPY'd in the Dockerfile and declared image_only in
|
| 1354 |
+
# .github/copy-sync-lockstep.json; registered BEFORE the SPA catch-all so the explicit
|
| 1355 |
+
# route wins instead of silently falling through to the generic SPA shell.
|
| 1356 |
+
app.add_api_route("/signature-is-not-proof", _ptg_serve("signature-is-not-proof.html"), methods=["GET"], include_in_schema=False)
|
| 1357 |
+
app.add_api_route("/a11oy/signature-is-not-proof", _ptg_serve("signature-is-not-proof.html"), methods=["GET"], include_in_schema=False)
|
| 1358 |
+
app.add_api_route("/defense-readiness", _ptg_serve("defense-readiness.html"), methods=["GET"], include_in_schema=False)
|
| 1359 |
+
app.add_api_route("/a11oy/defense-readiness", _ptg_serve("defense-readiness.html"), methods=["GET"], include_in_schema=False)
|
| 1360 |
+
|
| 1361 |
# /chat + /a11oy/chat -> /code consolidation (founder-directed; the only removal).
|
| 1362 |
async def _ptg_chat_to_code() -> Response:
|
| 1363 |
return _PTG_Redirect(url="/code", status_code=302)
|
|
|
|
| 7959 |
return FileResponse(INDEX_HTML, media_type="text/html")
|
| 7960 |
|
| 7961 |
|
| 7962 |
+
# ENERGY-OPS dashboard (press-play energy operator). Standalone sovereign page
|
| 7963 |
+
# (0 runtime CDN) that drives the real /api/a11oy/v1/energy/operator/* endpoints
|
| 7964 |
+
# and reads the live ledger/projection — every value carries a MEASURED / MODELED
|
| 7965 |
+
# / SAMPLE honesty chip; revenue is NEVER MEASURED until a real charge clears; no
|
| 7966 |
+
# joules/tokens/dollars are fabricated (doctrine v11). pages/energy-ops.html is
|
| 7967 |
+
# per-file COPY'd into /app/pages by the Dockerfile; on a missing file we fall back
|
| 7968 |
+
# honestly to INDEX_HTML (no fabricated stub). Registered BEFORE the /viz + SPA
|
| 7969 |
+
# catch-all so the explicit demo route wins instead of falling through to the shell.
|
| 7970 |
+
@app.get("/energy-ops")
|
| 7971 |
+
@app.get("/a11oy/energy-ops")
|
| 7972 |
+
async def energy_ops_dashboard() -> Response:
|
| 7973 |
+
f = PAGES_DIR / "energy-ops.html"
|
| 7974 |
+
if f.is_file():
|
| 7975 |
+
return FileResponse(f, media_type="text/html")
|
| 7976 |
+
return FileResponse(INDEX_HTML, media_type="text/html")
|
| 7977 |
+
|
| 7978 |
+
|
| 7979 |
@app.get("/viz")
|
| 7980 |
async def viz_gallery() -> Response:
|
| 7981 |
f = VIZ_DIR / "index.html"
|