{"version":3,"term":{"cols":110,"rows":52},"timestamp":1779128039,"command":"core demo learning-loop","env":{"SHELL":"/bin/zsh"}}
[0.178, "o", "\r\n================================================================================\r\n  Learning Loop — Cold Turn to Grounded Surface, End-to-End (ADR-0055..0057)\r\n================================================================================\r\n\r\nReference: ADR-0055 (Phase B DiscoveryCandidate emission, Phase A audit\r\n+ provenance), ADR-0056 (Phase C1 contemplation), ADR-0057 (Phase C2\r\nTeachingChainProposal + replay gate + operator review).\r\n\r\nA single deterministic prompt drives every scene:\r\n\r\n    \"Why does thought exist?\"\r\n\r\nHeadline claim: CORE, asked a question it cannot ground, emits\r\nstructured evidence that a reviewed chain would have helped.  An\r\noperator authors a proposal from that evidence.  The replay-\r\nequivalence gate confirms no regression.  The operator accepts.  The\r\n**same prompt now produces a deterministic teaching-grounded surface**\r\n— replayable, with full provenance back to the operator's accept.\r\n\r\n  S1.  Cold turn          — runtime returns the universal disclosure;\r\n          "]
[0.000, "o", "                  grounding_source = none.\r\n  S2.  Discovery emission — DiscoveryCandidate emitted to the attached\r\n                            sink; contemplation enriches with pack/\r\n                            corpus evidence.  Active corpus untouched.\r\n  S3.  Operator proposal  — complete chain authored + real replay gate\r\n                            run + replay_equivalent=True → pending.\r\n  S4.  Operator accept    — accept_proposal writes ONE line to a\r\n                            transient corpus (copy of active + new\r\n                            chain).  Active corpus byte-identical.\r\n  S5.  Replay the prompt  — _CORPUS_PATH swapped to the transient;\r\n                            same prompt now teaching-grounded with the\r\n                            new chain's subject / connective / object.\r\n\r\nTrust boundary:\r\n  The demo writes ONLY to a tempdir-scoped transient corpus.  The\r\n  active teaching corpus on disk is byte-identical pre/post — same\r\n  swap pattern the replay-equivalence gate use"]
[0.000, "o", "s.  No clock-time read.\r\n\r\nWhat to expect:\r\n  Per-scene printout with CLAIM, prompt/inputs, outputs, and the\r\n  byte-identical-corpus assertion.  Final BEFORE / AFTER block shows\r\n  the deterministic surface change on the same prompt.\r\n\r\nTest gate:\r\n  tests/test_learning_loop_demo.py (7 tests — loop closes, before is\r\n  ungrounded, after contains new chain atoms, discovery emits ≥1,\r\n  replay gate reports no regression, transient adds exactly 1 line\r\n  while active is byte-identical, same prompt drives both surfaces).\r\n\r\nMachine-readable output:\r\n  core demo learning-loop --json\r\n================================================================================\r\n"]
[0.000, "o", "\r\n"]
[1.066, "o", "\r\n────────────────────────────────────────────────────────────────────────\r\n  S1.  Cold turn — runtime cannot ground the prompt\r\n────────────────────────────────────────────────────────────────────────\r\n  CLAIM: Active corpus has no (thought, cause) chain.  The runtime falls through to the universal insufficient-grounding disclosure.  Identity / safety / ethics gates still run.\r\n\r\n"]
[0.005, "o", "  prompt                  : Why does thought exist?\r\n  surface                 : I don't know — insufficient grounding for that yet.\r\n  grounding_source        : none\r\n  discovery candidates    : 1  (emitted post-turn)\r\n\r\n────────────────────────────────────────────────────────────────────────\r\n  S2.  Discovery candidate — structured evidence, not a mutation\r\n────────────────────────────────────────────────────────────────────────\r\n  CLAIM: The runtime emits a DiscoveryCandidate (ADR-0055 Phase B) documenting that a reviewed (thought, cause) chain WOULD have grounded this turn.  Contemplation (ADR-0056 Phase C1) enriches with pack/corpus evidence pointers.  Active corpus is byte-identical — emission writes to the sink on"]
[0.000, "o", "ly.\r\n"]
[0.000, "o", "\r\n"]
[0.000, "o", "  candidate_id            : 17673a2f15c8da21…\r\n  trigger                 : would_have_grounded\r\n  proposed_chain          : {'connective': None, 'intent': 'cause', 'object': None, 'subject': 'thought'}\r\n"]
[0.000, "o", "  polarity                : undetermined\r\n"]
[0.000, "o", "  claim_domain            : factual\r\n"]
[0.000, "o", "  pack_consistent         : True\r\n  boundary_clean          : True\r\n"]
[0.000, "o", "  evidence (pack-only)    : [{'epistemic_status': 'coherent', 'polarity': 'affirms', 'ref': 'thought', 'source': 'pack'}]\r\n\r\n"]
[0.000, "o", "────────────────────────────────────────────────────────────────────────\r\n  S3.  Operator-authored proposal — replay-equivalence gate runs\r\n────────────────────────────────────────────────────────────────────────\r\n  CLAIM: From the discovery candidate's evidence, the operator authors a complete chain: thought reveals meaning.  Affirming evidence is the existing corpus chain cause_creation_reveals_meaning. The real replay gate (teaching.replay.run_replay_equivalence) runs the cognition public split twice — active corpus vs. transient-with-appended-chain — and reports no regression.\r\n"]
[0.000, "o", "\r\n"]
[1.849, "o", "  proposal_id             : 016252428267e4f339969524988c4794\r\n  proposed_chain          : {'subject': 'thought', 'intent': 'cause', 'connective': 'reveals', 'object': 'meaning'}\r\n  evidence (corpus ref)   : cause_creation_reveals_meaning\r\n  replay baseline         : {'intent_accuracy': 1.0, 'surface_groundedness': 1.0, 'term_capture_rate': 0.9167, 'versor_closure_rate': 1.0}\r\n  replay candidate        : {'intent_accuracy': 1.0, 'surface_groundedness': 1.0, 'term_capture_rate': 0.9167, 'versor_closure_rate': 1.0}\r\n  regressed_metrics       : []\r\n  replay_equivalent       : True\r\n  state                   : pending\r\n\r\n"]
[0.000, "o", "────────────────────────────────────────────────────────────────────────\r\n  S4.  Operator accept — transient corpus, active corpus untouched\r\n────────────────────────────────────────────────────────────────────────\r\n  CLAIM: accept_proposal writes one JSONL line to a TRANSIENT corpus (copy of active + new chain).  The active corpus file bytes are byte-identical pre/post.  Provenance on the new entry: adr-0057:discovery_promoted:<review_date>.\r\n"]
[0.000, "o", "\r\n"]
[0.001, "o", "  appended chain_id       : cause_thought_reveals_meaning\r\n  transient corpus path   : /var/folders/kg/5xbm28qd7jl55j7lv3p001f40000gn/T/learning_loop_demo__5wclh7k/cognition_chains_v1.jsonl\r\n  transient lines  before : 10\r\n  transient lines  after  : 11\r\n  active corpus byte-eq   : True\r\n\r\n────────────────────────────────────────────────────────────────────────\r\n"]
[0.000, "o", "  S5.  Same prompt — now deterministically teaching-grounded\r\n────────────────────────────────────────────────────────────────────────\r\n"]
[0.000, "o", "  CLAIM: With the runtime's corpus path swapped to the transient corpus, the same prompt now returns a teaching-grounded surface containing the operator-accepted chain: thought reveals meaning.  Identical bytes for any replay of the same prompt against this corpus state.\r\n"]
[0.000, "o", "\r\n"]
[0.071, "o", "  prompt                  : Why does thought exist?\r\n  surface                 : thought — teaching-grounded (cognition_chains_v1): cognition.thought; logos.internal. thought reveals meaning (cognition.meaning). No session evidence yet.\r\n  grounding_source        : teaching\r\n"]
[0.000, "o", "\r\n════════════════════════════════════════════════════════════════════════\r\n  BEFORE / AFTER  (single deterministic prompt, one accept between)\r\n════════════════════════════════════════════════════════════════════════\r\n  prompt   : Why does thought exist?\r\n  before   : [none] I don't know — insufficient grounding for that yet.\r\n  after    : [teaching] thought — teaching-grounded (cognition_chains_v1): cognition.thought; logos.internal. thought reveals meaning (cognition.meaning). No session evidence yet.\r\n"]
[0.000, "o", "\r\n"]
[0.000, "o", "  learning_loop_closed         : True\r\n"]
[0.000, "o", "  active corpus byte-identical : True\r\n\r\n"]
[0.014, "x", "0"]
