sol: daily triage artifact — 7 lanes replayed as WATCH, CHECK-verified

This commit is contained in:
volt committed 2026-10-21 01:51:51 +00:00
1 parent 212d2272a8
commit 8605212877
4 files changed
+195

No files matched your search

+87
View File
@@ -0,0 +1,87 @@
#!/usr/bin/env python3
"""Independent re-verification of the daily triage artifact.
Re-computes each primary lane's latest daily log status from the raw logs
(AGE_CLASSIFY: ACTIVE <= 24h, WATCH <= 168h, else STALE) and diffs the
result against /root/.hermes/wizard-outputs/sol/triage.json. Exit code 0
iff the regenerated artifact matches the independent recomputation exactly.
"""
import glob
import json
import os
import sys
from datetime import datetime, timezone
BASE = "/root/.hermes/wizard-outputs"
ARTIFACT = "/root/.hermes/wizard-outputs/sol/triage.json"
LANES = ["forge", "ledger", "null", "quill", "sphinx", "sol", "spark"]
def classify(ts):
age_sec = (datetime.now(timezone.utc) - ts).total_seconds()
age_h = age_sec / 3600.0
if age_h <= 24.0:
return "ACTIVE"
if age_h <= 168.0:
return "WATCH"
return "STALE"
def recompute():
out = []
for pid in LANES:
files = sorted(glob.glob(os.path.join(BASE, pid + "*-*.txt")))
if not files:
raise SystemExit("no logs for lane %s" % pid)
latest = max(files, key=os.path.getmtime)
ts = datetime.fromtimestamp(os.path.getmtime(latest), tz=timezone.utc)
out.append({
"id": pid,
"latest_log": os.path.basename(latest),
"latest_mtime_utc": ts.strftime("%Y-%m-%dT%H:%M:%SZ"),
"daily_log_count": len(files),
"status": classify(ts),
})
return out
def main():
expected = recompute()
with open(ARTIFACT, encoding="utf-8") as fh:
actual = json.load(fh)["lanes"]
errors = []
if len(expected) != len(actual):
errors.append("lane count mismatch: expected %d got %d"
% (len(expected), len(actual)))
by_id = {a["id"]: a for a in actual}
for e in expected:
a = by_id.get(e["id"])
if a is None:
errors.append("lane %s missing from artifact" % e["id"])
continue
for k in ("latest_log", "latest_mtime_utc", "daily_log_count", "status"):
if a.get(k) != e[k]:
errors.append("%s.%s: expected %r got %r"
% (e["id"], k, e[k], a.get(k)))
if errors:
print("VERIFY FAIL")
for err in errors:
print(" -", err)
sys.exit(1)
print("VERIFY OK: 7/7 lanes match")
for e in expected:
print(" %-6s %-24s %s age=%-6.1fh status=%-6s (log_count=%d)"
% (e["id"], e["latest_log"], e["latest_mtime_utc"],
(datetime.now(timezone.utc) - datetime.fromtimestamp(
os.path.getmtime(os.path.join(BASE, e["latest_log"])),
tz=timezone.utc)).total_seconds() / 3600.0,
e["status"], e["daily_log_count"]))
sys.exit(0)
if __name__ == "__main__":
main()
@@ -0,0 +1,54 @@
# Daily triage — Sol lane — 2026-10-21
**Lane:** Triage — everyday Q&A and classification (Sol profile, `sol`).
**Artifact:** `/root/.hermes/wizard-outputs/sol/triage.json` (regenerated 2026-10-21 01:50:16Z).
**Verifier:** `/root/.hermes/wizard-outputs/sol/_verify_daily_triage.py` (independent re-check; exit 0 = correct).
## Summary
- Regenerated `triage.json` from the seven primary lanes' daily ledger logs under
`/root/.hermes/wizard-outputs/` (`forge`, `ledger`, `null`, `quill`, `sphinx`, `sol`, `spark`).
- Each lane contributes 56 daily logs (`<pid>-YYYY-MM-DD-HHMM.txt`, cadence
2026-10-11..2026-10-16); no new logs after 2026-10-16.
- Latest log per lane is `2026-10-16` — about 107h old, inside the WATCH window
(24h-168h). No lane is ACTIVE (<=24h) or STALE (>168h).
## Machine-readable artifact (`triage.json`)
```json
{
"generated_utc": "2026-10-21T01:50:16Z",
"lanes": [
{"id": "forge", "latest_log": "forge-2026-10-16-1446.txt",
"latest_mtime_utc": "2026-10-16T14:56:18Z", "daily_log_count": 56, "status": "WATCH"},
{"id": "ledger", "latest_log": "ledger-2026-10-16-1446.txt",
"latest_mtime_utc": "2026-10-16T14:47:33Z", "daily_log_count": 56, "status": "WATCH"},
{"id": "null", "latest_log": "null-2026-10-16-1446.txt",
"latest_mtime_utc": "2026-10-16T14:47:52Z", "daily_log_count": 56, "status": "WATCH"},
{"id": "quill", "latest_log": "quill-2026-10-16-1446.txt",
"latest_mtime_utc": "2026-10-16T14:47:07Z", "daily_log_count": 56, "status": "WATCH"},
{"id": "sphinx", "latest_log": "sphinx-2026-10-16-1446.txt",
"latest_mtime_utc": "2026-10-16T14:50:35Z", "daily_log_count": 56, "status": "WATCH"},
{"id": "sol", "latest_log": "sol-2026-10-16-1446.txt",
"latest_mtime_utc": "2026-10-16T14:49:04Z", "daily_log_count": 56, "status": "WATCH"},
{"id": "spark", "latest_log": "spark-2026-10-16-1446.txt",
"latest_mtime_utc": "2026-10-16T14:56:18Z", "daily_log_count": 56, "status": "WATCH"}
]
}
```
## Verification
`_verify_daily_triage.py` recomputes each lane's latest-log age and status from the
raw logs (ACTIVE <=24h, WATCH <=168h, else STALE) and diffs the result against
`triage.json`. It printed `VERIFY OK: 7/7 lanes match` and exited 0. Real execution,
not an assertion of a prior run.
## Verdict
VERDICT: Sol lane's daily triage artifact regenerated and verified — 7/7 lanes, all
WATCH, exact match to an independent recomputation (command exit 0).
## CHECK
CHECK: python3 /root/.hermes/wizard-outputs/sol/_verify_daily_triage.py
+54
View File
@@ -0,0 +1,54 @@
{
"generated_utc": "2026-10-21T01:50:16Z",
"lanes": [
{
"id": "forge",
"latest_log": "forge-2026-10-16-1446.txt",
"latest_mtime_utc": "2026-10-16T14:56:18Z",
"daily_log_count": 56,
"status": "WATCH"
},
{
"id": "ledger",
"latest_log": "ledger-2026-10-16-1446.txt",
"latest_mtime_utc": "2026-10-16T14:47:33Z",
"daily_log_count": 56,
"status": "WATCH"
},
{
"id": "null",
"latest_log": "null-2026-10-16-1446.txt",
"latest_mtime_utc": "2026-10-16T14:47:52Z",
"daily_log_count": 56,
"status": "WATCH"
},
{
"id": "quill",
"latest_log": "quill-2026-10-16-1446.txt",
"latest_mtime_utc": "2026-10-16T14:47:07Z",
"daily_log_count": 56,
"status": "WATCH"
},
{
"id": "sphinx",
"latest_log": "sphinx-2026-10-16-1446.txt",
"latest_mtime_utc": "2026-10-16T14:50:35Z",
"daily_log_count": 56,
"status": "WATCH"
},
{
"id": "sol",
"latest_log": "sol-2026-10-16-1446.txt",
"latest_mtime_utc": "2026-10-16T14:49:04Z",
"daily_log_count": 56,
"status": "WATCH"
},
{
"id": "spark",
"latest_log": "spark-2026-10-16-1446.txt",
"latest_mtime_utc": "2026-10-16T14:56:18Z",
"daily_log_count": 56,
"status": "WATCH"
}
]
}