teleo-infrastructure/docs/reports/leo-working-state-20260709/telegram-handler-m3taversal-oos-db-composed-pair-post-validator-20260713.json
twentyOne2x b6408cdbd1
Some checks are pending
CI / lint-and-test (push) Waiting to run
Compose broad Leo answers from live database state (#118)
Validated by 1121 repository tests and a read-only six-question smoke against live VPS Postgres before installation.
2026-07-13 13:59:16 +02:00

237 lines
11 KiB
JSON

{
"before_service": {
"ActiveState": "active",
"ExecMainStartTimestamp": "Mon 2026-07-13 11:36:05 UTC",
"MainPID": "3874471",
"NRestarts": "0",
"SubState": "running"
},
"changed_live_profile": false,
"database_context_all_ok": true,
"database_context_injection_count": 2,
"database_context_trace": [
{
"compiled_response_available": true,
"contract_ids": [
"reply_budget",
"mixed_packet_composition"
],
"contract_sha256": "e93a0c035e7d4084a197d71f11bf293c695024b05944cae01d58a57eb0d595bf",
"event": "pre_llm_call",
"generated_at_utc": "2026-07-13T11:37:09.720412+00:00",
"injected": true,
"query_sha256": "13c255fda3a35cd913ba92960bcda1b4dbcf55a38f3301bdc2a74a8eb040df23",
"source": "kb_tool.py --local context",
"status": "ok"
},
{
"compiled_response_issues": [],
"contract_ids": [
"reply_budget",
"mixed_packet_composition"
],
"delivered_response_sha256": "a5ce84cd29cfb460e51e0aa0f279838b887f192b6e53b6359fd56050031290cc",
"event": "post_llm_call",
"generated_at_utc": "2026-07-13T11:37:24.212345+00:00",
"issues": [
"reply_budget_exceeded"
],
"query_sha256": "13c255fda3a35cd913ba92960bcda1b4dbcf55a38f3301bdc2a74a8eb040df23",
"response_sha256": "6e26bae5f94d7cceec43f2b1390481926e3d9efba2a289d172052ea944bc0069",
"status": "ok",
"transformed": true,
"validated": true
},
{
"compiled_response_available": true,
"contract_ids": [
"reply_budget",
"source_intake"
],
"contract_sha256": "aa7ea45feb00cf01f5e070f4e46dacdd375168a5321b8b8710473161a6e98ec4",
"event": "pre_llm_call",
"generated_at_utc": "2026-07-13T11:37:24.417706+00:00",
"injected": true,
"query_sha256": "45141620c3405af992012e2bd5000cabd8a6bffbc784082e856ea1a18b6aec06",
"source": "kb_tool.py --local context",
"status": "ok"
},
{
"compiled_response_issues": [],
"contract_ids": [
"reply_budget",
"source_intake"
],
"delivered_response_sha256": "3ec2e7f161a6584416893483bde07e72d6bcf4ca90714964ea513b8f9c217cfb",
"event": "post_llm_call",
"generated_at_utc": "2026-07-13T11:37:35.581411+00:00",
"issues": [
"missing_apply_boundary"
],
"query_sha256": "45141620c3405af992012e2bd5000cabd8a6bffbc784082e856ea1a18b6aec06",
"response_sha256": "ee46b9b41443a45053f7a0cb788ee1f8ef98150d65a81800d2ed118e3b30a4cd",
"status": "ok",
"transformed": true,
"validated": true
}
],
"database_response_transform_count": 2,
"database_response_validation_all_ok": true,
"database_response_validation_count": 2,
"db_counts_after": {
"kb_stage.kb_proposals": 26,
"public.claim_edges": 4916,
"public.claim_evidence": 4670,
"public.claims": 1837,
"public.sources": 4145
},
"db_counts_before": {
"kb_stage.kb_proposals": 26,
"public.claim_edges": 4916,
"public.claim_evidence": 4670,
"public.claims": 1837,
"public.sources": 4145
},
"db_counts_changed": false,
"generated_at_utc": "2026-07-13T11:37:06.250667+00:00",
"handler": {
"authorized": true,
"session_key": "agent:main:telegram:group:-5146042086:9070919",
"temp_profile": "/tmp/leo-direct-claim-handler-yfld7w08/profile"
},
"harness_notes": [
"Unchanged broad composition and source-intake canaries after source validator correction.",
"The harness uses a temporary copy of the leoclean profile and does not post to Telegram.",
"This proves handler-level live VPS GatewayRunner behavior, not human-visible Telegram delivery."
],
"mode": "live_vps_gatewayrunner_temp_profile_db_composed_pair_post_validator",
"mutates_kb_by_harness": false,
"pass_runtime": true,
"posted_to_telegram": false,
"remote_report_path": "/tmp/leo-db-composed-pair-post-validator-handler-report-09285fecadeb.json",
"remote_returncode": 0,
"remote_run_id": "09285fecadeb",
"results": [
{
"claim_ceiling": "Live VPS GatewayRunner reply from temp leoclean profile; no Telegram post; no production DB apply authorized.",
"database_context_trace": [
{
"compiled_response_available": true,
"contract_ids": [
"reply_budget",
"mixed_packet_composition"
],
"contract_sha256": "e93a0c035e7d4084a197d71f11bf293c695024b05944cae01d58a57eb0d595bf",
"event": "pre_llm_call",
"generated_at_utc": "2026-07-13T11:37:09.720412+00:00",
"injected": true,
"query_sha256": "13c255fda3a35cd913ba92960bcda1b4dbcf55a38f3301bdc2a74a8eb040df23",
"source": "kb_tool.py --local context",
"status": "ok"
},
{
"compiled_response_issues": [],
"contract_ids": [
"reply_budget",
"mixed_packet_composition"
],
"delivered_response_sha256": "a5ce84cd29cfb460e51e0aa0f279838b887f192b6e53b6359fd56050031290cc",
"event": "post_llm_call",
"generated_at_utc": "2026-07-13T11:37:24.212345+00:00",
"issues": [
"reply_budget_exceeded"
],
"query_sha256": "13c255fda3a35cd913ba92960bcda1b4dbcf55a38f3301bdc2a74a8eb040df23",
"response_sha256": "6e26bae5f94d7cceec43f2b1390481926e3d9efba2a289d172052ea944bc0069",
"status": "ok",
"transformed": true,
"validated": true
}
],
"dimension": "database_composition_judgment",
"ended_at_utc": "2026-07-13T11:37:24.303117+00:00",
"evidence_tier": "live_vps_gatewayrunner_temp_profile",
"mutates_kb": false,
"ok": true,
"prompt": "Suppose a new research packet contains factual observations, a strategic framework, a disputed interpretation, a governance rule, and a correction to an old belief. How should Leo compose the database so it can reason over the packet later without flattening it all into claims? Give the review and apply sequence too, but do not write anything now.",
"prompt_id": "OOS-06",
"reply": "- Map factual observations and disputed interpretations to claims plus sources and evidence; keep competing claims queryable through claim-to-claim edges. Store the strategic framework in reasoning_tools. Put the governance rule in behavioral_rules using rule, rationale, category, rank, and agent_id unless it defines criteria, an evidence_bar, and a pass_condition, in which case use governance_gates. Stage the correction to the old belief as a beliefs update; claim_edges never point to reasoning_tools or beliefs.\n\n- Stage one typed pending_review proposal with exact rows and no canonical writes. Review mappings, evidence, claim-only edge endpoints, and unsupported changes. After explicit authorization, approve_claim applies only claims, sources, evidence, edges, and reasoning_tools. approve_claim supports neither behavioral_rules nor governance_gates; those tables, belief updates, and existing-row updates remain staged until a separate reviewed apply capability exists. The contract keeps behavioral_rules, governance_gates, belief updates, and existing-row updates outside this apply.\n\n- Receipt: proposal-level applied_at, created or updated row IDs, and a postflight readback. Until those exist, staged or approved content is not live canonical knowledge.",
"started_at_utc": "2026-07-13T11:37:06.718719+00:00",
"turn": 1
},
{
"claim_ceiling": "Live VPS GatewayRunner reply from temp leoclean profile; no Telegram post; no production DB apply authorized.",
"database_context_trace": [
{
"compiled_response_available": true,
"contract_ids": [
"reply_budget",
"source_intake"
],
"contract_sha256": "aa7ea45feb00cf01f5e070f4e46dacdd375168a5321b8b8710473161a6e98ec4",
"event": "pre_llm_call",
"generated_at_utc": "2026-07-13T11:37:24.417706+00:00",
"injected": true,
"query_sha256": "45141620c3405af992012e2bd5000cabd8a6bffbc784082e856ea1a18b6aec06",
"source": "kb_tool.py --local context",
"status": "ok"
},
{
"compiled_response_issues": [],
"contract_ids": [
"reply_budget",
"source_intake"
],
"delivered_response_sha256": "3ec2e7f161a6584416893483bde07e72d6bcf4ca90714964ea513b8f9c217cfb",
"event": "post_llm_call",
"generated_at_utc": "2026-07-13T11:37:35.581411+00:00",
"issues": [
"missing_apply_boundary"
],
"query_sha256": "45141620c3405af992012e2bd5000cabd8a6bffbc784082e856ea1a18b6aec06",
"response_sha256": "ee46b9b41443a45053f7a0cb788ee1f8ef98150d65a81800d2ed118e3b30a4cd",
"status": "ok",
"transformed": true,
"validated": true
}
],
"dimension": "autonomous_source_intake_boundary",
"ended_at_utc": "2026-07-13T11:37:35.618013+00:00",
"evidence_tier": "live_vps_gatewayrunner_temp_profile",
"mutates_kb": false,
"ok": true,
"prompt": "I hand Leo a document and say: absorb this as far as safely possible without making me approve every mechanical step. What can Leo capture and stage immediately, what real source identity must be retained, and where does explicit approval begin? Explain only; do not ingest this prompt.",
"prompt_id": "OOS-14",
"reply": "- Local compiler proven; live VPS/chat intake not shipped. Immediately retain artifact plus URL or storage_path plus content hash. A filename, chat label, attachment reference, or source_ref is not source identity.\n\n- extract candidates into a pending_review proposal packet. Deduplicate candidate claims and retain evidence excerpts and contradictions. Do not create public.sources or other canonical rows during capture or staging.\n\n- Explicit approval begins before guarded canonical public.* apply, not before mechanical capture/staging. The receipt should include the retained locator and hash, proposal ID and status, reviewed payload, proposal-level applied_at, created row IDs, and postflight readback. Until apply succeeds, the material is staged rather than live canonical knowledge.",
"started_at_utc": "2026-07-13T11:37:24.317971+00:00",
"turn": 2
}
],
"service_before_after": {
"after": {
"ActiveState": "active",
"ExecMainStartTimestamp": "Mon 2026-07-13 11:36:05 UTC",
"MainPID": "3874471",
"NRestarts": "0",
"SubState": "running"
},
"before": {
"ActiveState": "active",
"ExecMainStartTimestamp": "Mon 2026-07-13 11:36:05 UTC",
"MainPID": "3874471",
"NRestarts": "0",
"SubState": "running"
},
"unchanged_from_preexisting_live_readback": true
},
"source": {
"chat_id": "-5146042086",
"chat_name": "Leo",
"chat_type": "group",
"platform": "telegram",
"user_id": "9070919",
"user_name": "codex handler direct claim"
},
"source_report_path": "/Users/user/Documents/Codex/2026-07-09/019f34eb-d297-72d0-b7e2-b222d5515ab9-load/work/teleo-infra-main/docs/reports/leo-working-state-20260709/telegram-handler-m3taversal-oos-db-composed-pair-post-validator-20260713.json",
"temp_profile_removed": true
}