Skip to content

KB/api

GET /api/v1/ai2/verdict

Last verified

Auto-generated. This article is rebuilt from FastAPI route introspection by scripts/build_api_kb.py. Edit the route docstring in app/ and re-run the script β€” do not edit this file directly.

GET /api/v1/ai2/verdict

Handler: app.signals.ai_brief_routes.ai2_verdict
Methods: GET

Description

PUBLIC β€” the AI-2 deterministic verdict for today, the read /tape renders (two-stage system Wave 4).

Two-tier serving, in preference order:

  1. Persisted-first. The newest ai2_verdicts row with variant='deterministic' (via ai2_verdict.read_latest_ai2_verdict), served ONLY when its generated_at falls on the CURRENT ET trade date. A verdict left behind by an earlier day (e.g. a window when ENABLE_AI1_ANALYSIS was on) must NEVER be served as today’s read. Stamped source: "persisted".
  2. Live-compute fallback. Otherwise the verdict is computed on demand from build_signal_pack + the trailing (today-excluded) vol_nowcast_z series, with ai1_read=None β€” a documented first-class case: build_verdict falls back deterministically for whats_happening / likelihood / days_in_regime. Stamped source: "computed". This path deliberately does NOT write to ai2_verdicts: the graded series must contain only verdicts the scheduler actually served on its own cadence β€” a read-triggered row would poison the grading substrate with request-timing artifacts (a popular page would manufacture rows; a quiet one wouldn’t).

Every served string is passed through the vendor-anonymity scrub (anonymize_text) β€” this is the first PUBLIC surface carrying verdict prose.

NEVER 500, NEVER 404 (DOCTRINE P0). Any failure β€” a pack build that raises, an unavailable DB, anything β€” returns HTTP 200 with verdict: null and a plain reason, logged via logger.exception. The page degrades to an honest β€œunavailable” rather than a broken render.

Response shape::

{schema_version, as_of, source: "persisted"|"computed"|null,
 verdict: <object>|null, reason: <string>|null}

Curl

curl -s https://bigclawd.com/api/v1/ai2/verdict