diff --git a/epiphany-core/src/agent_launch.rs b/epiphany-core/src/agent_launch.rs index ab2129f4..84c22460 100644 --- a/epiphany-core/src/agent_launch.rs +++ b/epiphany-core/src/agent_launch.rs @@ -726,6 +726,45 @@ pub fn epiphany_role_launch_output_schema(role_id: EpiphanyRoleResultRoleId) -> schema } +pub fn epiphany_frontier_verdict_modeling_output_schema(request_id: &str) -> serde_json::Value { + let mut schema = epiphany_role_launch_output_schema(EpiphanyRoleResultRoleId::Modeling); + schema["properties"]["repoFrontierModelingRequestId"] = serde_json::json!({ + "type": "string", + "const": request_id + }); + schema["properties"]["repoModelPatch"]["properties"]["purpose"] = serde_json::json!({ + "type": "object", + "required": ["kind", "route_id", "soul_verdict_receipt_id"], + "properties": { + "kind": {"const": "incorporate_frontier_verdict"}, + "route_id": {"type": "string", "minLength": 1}, + "soul_verdict_receipt_id": {"type": "string", "minLength": 1} + }, + "additionalProperties": false + }); + schema["properties"]["repoModelPatch"]["properties"]["operations"] = serde_json::json!({ + "type": "array", + "minItems": 1, + "maxItems": 1, + "items": { + "type": "object", + "required": ["operation", "item"], + "properties": { + "operation": {"const": "revise_frontier"}, + "item": repo_frontier_item_output_schema() + }, + "additionalProperties": false + } + }); + schema["properties"]["evidenceIds"]["minItems"] = serde_json::json!(1); + schema["required"] + .as_array_mut() + .expect("role schema required must be an array") + .push(serde_json::json!("repoFrontierModelingRequestId")); + schema["allOf"] = serde_json::json!([]); + schema +} + pub fn epiphany_frontier_planning_output_schema() -> serde_json::Value { let mut schema = epiphany_role_launch_output_schema(EpiphanyRoleResultRoleId::Imagination); let properties = schema["properties"] @@ -1118,6 +1157,7 @@ pub fn build_epiphany_frontier_plan_mind_launch_request( frontier_plan_mind_request_id: Some(mind_request_id), imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, }) } @@ -1217,6 +1257,7 @@ pub fn build_epiphany_role_launch_request_with_dynamic_context( frontier_plan_mind_request_id: None, imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, }) } @@ -1380,6 +1421,7 @@ pub fn build_epiphany_job_launch_request( frontier_plan_mind_request_id: None, imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, } } @@ -1653,10 +1695,11 @@ mod tests { ["maxContains"], 1 ); - let ordinary_operations = schema["allOf"][3]["then"]["properties"]["repoModelPatch"] - ["properties"]["operations"]["items"]["anyOf"] - .as_array() - .expect("ordinary Modeling operations"); + let ordinary_operations = + schema["allOf"][3]["then"]["properties"]["repoModelPatch"]["properties"]["operations"] + ["items"]["anyOf"] + .as_array() + .expect("ordinary Modeling operations"); assert_eq!(ordinary_operations.len(), 6); assert!(ordinary_operations.iter().all(|operation| { !operation["properties"]["operation"]["const"] @@ -1674,6 +1717,34 @@ mod tests { assert!(!node_kinds.iter().any(|kind| kind == "claim")); } + #[test] + fn verdict_bound_modeling_schema_exposes_only_exact_frontier_revision_authority() { + let schema = epiphany_frontier_verdict_modeling_output_schema("modeling-request-exact"); + assert_eq!( + schema["properties"]["repoFrontierModelingRequestId"]["const"], + "modeling-request-exact" + ); + assert!( + schema["required"] + .as_array() + .unwrap() + .iter() + .any(|value| value == "repoFrontierModelingRequestId") + ); + assert_eq!( + schema["properties"]["repoModelPatch"]["properties"]["purpose"]["properties"]["kind"]["const"], + "incorporate_frontier_verdict" + ); + let operations = &schema["properties"]["repoModelPatch"]["properties"]["operations"]; + assert_eq!(operations["minItems"], 1); + assert_eq!(operations["maxItems"], 1); + assert_eq!( + operations["items"]["properties"]["operation"]["const"], + "revise_frontier" + ); + assert_eq!(schema["properties"]["evidenceIds"]["minItems"], 1); + } + #[test] fn modeling_node_schema_matches_mind_nonempty_invariants() { let schema = repo_model_node_output_schema(); diff --git a/epiphany-core/src/bin/epiphany-mvp-coordinator.rs b/epiphany-core/src/bin/epiphany-mvp-coordinator.rs index 0e557ae3..47f6d6dd 100644 --- a/epiphany-core/src/bin/epiphany-mvp-coordinator.rs +++ b/epiphany-core/src/bin/epiphany-mvp-coordinator.rs @@ -1409,6 +1409,7 @@ fn launch_role( .ok_or_else(|| anyhow!("cannot launch role without native coordinator state"))?; let state_loaded_ms = started.elapsed().as_millis(); let role = parse_role_id(role_id)?; + let mut repo_frontier_modeling_request_id = None; let expected_revision = expected_revision.and_then(|value| u64::try_from(value).ok()); let focus = epiphany_core::role_launch_context_focus(&state, epiphany_core::epiphany_role_label(role)); @@ -1437,13 +1438,16 @@ fn launch_role( ) .map_err(anyhow::Error::msg)?; } else if role == epiphany_core::EpiphanyRoleResultRoleId::Modeling { - context = epiphany_core::append_modeling_work_loop_telemetry_context( + let modeling_launch_context = epiphany_core::append_modeling_work_loop_telemetry_context( context, runtime_store, &state, proposal_modeling_request_id, ) .map_err(anyhow::Error::msg)?; + context = modeling_launch_context.context; + repo_frontier_modeling_request_id = + modeling_launch_context.repo_frontier_modeling_request_id; } let role_context_augmented_ms = started.elapsed().as_millis(); let mut request = epiphany_core::build_epiphany_role_launch_request_with_dynamic_context( @@ -1456,6 +1460,7 @@ fn launch_role( ) .map_err(anyhow::Error::msg)?; request.proposal_modeling_request_id = proposal_modeling_request_id.map(str::to_string); + request.repo_frontier_modeling_request_id = repo_frontier_modeling_request_id; let request_built_ms = started.elapsed().as_millis(); let launched = service.launch_job( thread_id, diff --git a/epiphany-core/src/coordinator_launch.rs b/epiphany-core/src/coordinator_launch.rs index bc26f39f..7b077b78 100644 --- a/epiphany-core/src/coordinator_launch.rs +++ b/epiphany-core/src/coordinator_launch.rs @@ -340,6 +340,7 @@ fn commit_coordinator_job_launch_in_cache( admitted_model_direction_consideration_request_id: request .admitted_model_direction_consideration_request_id .clone(), + repo_frontier_modeling_request_id: request.repo_frontier_modeling_request_id.clone(), created_at: created_at.clone(), }, )?; @@ -2732,6 +2733,7 @@ pub(crate) mod tests { frontier_plan_mind_request_id: None, imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, created_at: "2026-07-15T09:00:17Z".into(), }, )?; diff --git a/epiphany-core/src/coordinator_launch_context.rs b/epiphany-core/src/coordinator_launch_context.rs index bf89d8b2..d144ce4b 100644 --- a/epiphany-core/src/coordinator_launch_context.rs +++ b/epiphany-core/src/coordinator_launch_context.rs @@ -223,9 +223,7 @@ pub fn append_verification_hands_receipt_context( })?; let gateway_review = crate::runtime_mind_gateway_review(runtime_store_path, &state_commit.gateway_id) - .map_err(|error| { - format!("failed to load Mind gateway review for Soul: {error}") - })? + .map_err(|error| format!("failed to load Mind gateway review for Soul: {error}"))? .ok_or_else(|| { "Soul frontier Mind state commit has no gateway review".to_string() })?; @@ -467,10 +465,9 @@ pub fn has_complete_hands_consequence_after_latest_accepted_boundary( let Some(accepted_at) = latest_accepted_modeling_or_verification_timestamp(state) else { return Ok(false); }; - let chain = runtime_latest_hands_receipt_chain_after(runtime_store_path, accepted_at) - .map_err(|error| { - format!("failed to load Hands receipt chain for coordinator routing: {error}") - })?; + let chain = runtime_latest_hands_receipt_chain_after(runtime_store_path, accepted_at).map_err( + |error| format!("failed to load Hands receipt chain for coordinator routing: {error}"), + )?; let Some(chain) = chain else { return Ok(false); }; @@ -550,23 +547,52 @@ fn debug_variant_snake_case(value: impl std::fmt::Debug) -> String { output } +#[derive(Debug)] +pub struct ModelingWorkLoopLaunchContext { + pub context: String, + pub repo_frontier_modeling_request_id: Option, +} + +impl std::ops::Deref for ModelingWorkLoopLaunchContext { + type Target = str; + + fn deref(&self) -> &Self::Target { + &self.context + } +} + +impl PartialEq<&str> for ModelingWorkLoopLaunchContext { + fn eq(&self, other: &&str) -> bool { + self.context == *other + } +} + pub fn append_modeling_work_loop_telemetry_context( mut context: String, runtime_store_path: &Path, state: &EpiphanyThreadState, proposal_modeling_request_id: Option<&str>, -) -> Result { +) -> Result { if proposal_modeling_request_id.is_some() { - return Ok(context); + return Ok(ModelingWorkLoopLaunchContext { + context, + repo_frontier_modeling_request_id: None, + }); } if accepted_research_is_newest_unmodeled_boundary(state) { context.push_str("\n\n\n"); context.push_str("The current Modeling turn is caused by accepted Eyes evidence newer than the last accepted Modeling boundary. Use the accepted Research finding already present in coordinator context to update the body model. This is not a historical Soul-verdict incorporation turn; do not substitute an older frontier verification route.\n"); context.push_str(""); - return Ok(context); + return Ok(ModelingWorkLoopLaunchContext { + context, + repo_frontier_modeling_request_id: None, + }); } let Some(accepted_verification) = latest_unique_accepted_verification(state)? else { - return Ok(context); + return Ok(ModelingWorkLoopLaunchContext { + context, + repo_frontier_modeling_request_id: None, + }); }; let modeling_request = crate::commit_repo_frontier_modeling_request(runtime_store_path, &accepted_verification) @@ -637,7 +663,10 @@ pub fn append_modeling_work_loop_telemetry_context( ) })? else { - return Ok(context); + return Ok(ModelingWorkLoopLaunchContext { + context, + repo_frontier_modeling_request_id: Some(modeling_request.request_id), + }); }; let soul_receipts = latest_accepted_soul_receipts(state); if !soul_receipts.is_empty() { @@ -684,7 +713,10 @@ pub fn append_modeling_work_loop_telemetry_context( "Update the machine model from this verified consequence before another Hands turn. Do not request a new Eyes step merely to rediscover this already-typed telemetry.\n", ); context.push_str(""); - Ok(context) + Ok(ModelingWorkLoopLaunchContext { + context, + repo_frontier_modeling_request_id: Some(modeling_request.request_id), + }) } fn accepted_research_is_newest_unmodeled_boundary(state: &EpiphanyThreadState) -> bool { @@ -1608,6 +1640,7 @@ mod tests { frontier_plan_mind_request_id: None, imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, created_at: "2026-06-02T00:00:00Z".to_string(), }, )?; @@ -1999,6 +2032,7 @@ mod tests { frontier_plan_mind_request_id: None, imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, created_at: "2026-06-12T00:00:06Z".to_string(), }, )?; @@ -2092,6 +2126,11 @@ mod tests { assert!(modeling_context.contains("accept-verification-context")); assert!(modeling_context.contains("Soul acceptance telemetry")); assert!(modeling_context.contains("")); + let modeling_request_id = modeling_context + .repo_frontier_modeling_request_id + .as_deref() + .expect("Soul-bound Modeling context must return typed launch authority"); + assert!(modeling_context.contains(modeling_request_id)); assert!(modeling_context.contains("soulVerdictReceiptId: soul-verdict-context")); assert!(modeling_context.contains("verificationResultId: result-verification-context")); assert!( diff --git a/epiphany-core/src/lib.rs b/epiphany-core/src/lib.rs index 5183e461..88acc882 100644 --- a/epiphany-core/src/lib.rs +++ b/epiphany-core/src/lib.rs @@ -105,6 +105,7 @@ pub use agent_launch::epiphany_admitted_model_direction_consideration_output_sch pub use agent_launch::epiphany_agent_prompt_with_memory; pub use agent_launch::epiphany_frontier_plan_mind_output_schema; pub use agent_launch::epiphany_frontier_planning_output_schema; +pub use agent_launch::epiphany_frontier_verdict_modeling_output_schema; pub use agent_launch::epiphany_imagination_consideration_output_schema; pub use agent_launch::epiphany_reorient_launch_output_schema; pub use agent_launch::epiphany_role_binding_id; @@ -213,6 +214,7 @@ pub use coordinator_launch::EpiphanyCoordinatorJobLaunchPlan; pub use coordinator_launch::commit_coordinator_job_launch; pub use coordinator_launch::plan_coordinator_job_launch; pub use coordinator_launch_context::EPIPHANY_LOCAL_VERSE_RUNTIME_ID; +pub use coordinator_launch_context::ModelingWorkLoopLaunchContext; pub use coordinator_launch_context::append_modeling_repo_model_shape_context; pub use coordinator_launch_context::append_modeling_work_loop_telemetry_context; pub use coordinator_launch_context::append_verification_hands_receipt_context; @@ -1059,10 +1061,9 @@ pub use runtime_spine::runtime_hands_commit_receipt; pub use runtime_spine::runtime_hands_patch_receipt; pub use runtime_spine::runtime_hands_pr_receipt; pub use runtime_spine::runtime_hands_receipt_chain_after; +pub use runtime_spine::runtime_hands_receipt_chain_matches_current_model; pub use runtime_spine::runtime_has_actionable_eyes_frontier; pub use runtime_spine::runtime_has_actionable_hands_frontier; -pub use runtime_spine::runtime_hands_receipt_chain_matches_current_model; -pub use runtime_spine::runtime_repo_frontier_execution_amendment_for_admission; pub use runtime_spine::runtime_has_actionable_imagination_frontier; pub use runtime_spine::runtime_hello_frame; pub use runtime_spine::runtime_job_snapshot; @@ -1074,6 +1075,7 @@ pub use runtime_spine::runtime_modeling_semantic_projection_input; pub use runtime_spine::runtime_pending_repo_frontier_proposal_modeling_request; pub use runtime_spine::runtime_registered_document_types; pub use runtime_spine::runtime_reorient_worker_result; +pub use runtime_spine::runtime_repo_frontier_execution_amendment_for_admission; pub use runtime_spine::runtime_repo_frontier_planning_eligibility; pub use runtime_spine::runtime_repo_frontier_planning_lifecycle; pub use runtime_spine::runtime_repo_frontier_proposal_modeling_request; diff --git a/epiphany-core/src/runtime_spine.rs b/epiphany-core/src/runtime_spine.rs index 21421c45..5bc91d30 100644 --- a/epiphany-core/src/runtime_spine.rs +++ b/epiphany-core/src/runtime_spine.rs @@ -352,6 +352,8 @@ pub struct EpiphanyRuntimeWorkerLaunchRequest { pub imagination_consideration_request_id: Option, #[cultcache(key = 16, default)] pub admitted_model_direction_consideration_request_id: Option, + #[cultcache(key = 17, default)] + pub repo_frontier_modeling_request_id: Option, } impl EpiphanyRuntimeWorkerLaunchRequest { @@ -789,6 +791,7 @@ pub struct RuntimeSpineHeartbeatJobOptions { pub frontier_plan_mind_request_id: Option, pub imagination_consideration_request_id: Option, pub admitted_model_direction_consideration_request_id: Option, + pub repo_frontier_modeling_request_id: Option, pub created_at: String, } @@ -842,6 +845,7 @@ pub struct EpiphanyJobLaunchRequest { pub frontier_plan_mind_request_id: Option, pub imagination_consideration_request_id: Option, pub admitted_model_direction_consideration_request_id: Option, + pub repo_frontier_modeling_request_id: Option, } #[derive(Debug, Clone, PartialEq)] @@ -1440,6 +1444,7 @@ pub fn open_runtime_spine_heartbeat_job( imagination_consideration_request_id: options.imagination_consideration_request_id, admitted_model_direction_consideration_request_id: options .admitted_model_direction_consideration_request_id, + repo_frontier_modeling_request_id: options.repo_frontier_modeling_request_id, }; cache.put(&job_id, &request)?; Ok(job) @@ -1596,6 +1601,7 @@ pub fn prepare_runtime_spine_heartbeat_job( imagination_consideration_request_id: options.imagination_consideration_request_id, admitted_model_direction_consideration_request_id: options .admitted_model_direction_consideration_request_id, + repo_frontier_modeling_request_id: options.repo_frontier_modeling_request_id, }; let envelopes = vec![ cache.prepare_entry(RUNTIME_IDENTITY_KEY, &identity)?.0, @@ -10076,6 +10082,7 @@ pub(crate) mod tests { frontier_plan_mind_request_id: None, imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, }; let mut cache = runtime_spine_cache(store)?; cache.put(job_id, &request)?; @@ -14120,6 +14127,7 @@ pub(crate) mod tests { frontier_plan_mind_request_id: None, imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, created_at: "2026-05-06T00:02:00Z".to_string(), }, )?; diff --git a/epiphany-core/src/substrate_gate.rs b/epiphany-core/src/substrate_gate.rs index 2b0d2351..5eadbd1a 100644 --- a/epiphany-core/src/substrate_gate.rs +++ b/epiphany-core/src/substrate_gate.rs @@ -284,6 +284,7 @@ mod tests { frontier_plan_mind_request_id: None, imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, }; let grant = substrate_gate_repo_access_grant_for_launch( "grant-1".to_string(), diff --git a/epiphany-core/src/surfaces/worker_launch.rs b/epiphany-core/src/surfaces/worker_launch.rs index d29ab07d..dbc0b719 100644 --- a/epiphany-core/src/surfaces/worker_launch.rs +++ b/epiphany-core/src/surfaces/worker_launch.rs @@ -440,6 +440,7 @@ pub fn build_reorient_job_launch_request( frontier_plan_mind_request_id: None, imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, } } diff --git a/epiphany-openai-runtime/src/bin/epiphany-openai-runtime.rs b/epiphany-openai-runtime/src/bin/epiphany-openai-runtime.rs index c256157b..caaaa222 100644 --- a/epiphany-openai-runtime/src/bin/epiphany-openai-runtime.rs +++ b/epiphany-openai-runtime/src/bin/epiphany-openai-runtime.rs @@ -1028,6 +1028,7 @@ mod tests { frontier_plan_mind_request_id: None, imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, created_at: now(), }, )?; @@ -1121,6 +1122,7 @@ mod tests { frontier_plan_mind_request_id: None, imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, created_at: now(), }, )?; @@ -1202,6 +1204,7 @@ mod tests { frontier_plan_mind_request_id: None, imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, created_at: now(), }, )?; diff --git a/epiphany-openai-runtime/src/lib.rs b/epiphany-openai-runtime/src/lib.rs index 9e9a462d..b7ecbe58 100644 --- a/epiphany-openai-runtime/src/lib.rs +++ b/epiphany-openai-runtime/src/lib.rs @@ -563,7 +563,7 @@ pub fn build_worker_model_request( model: &str, ) -> Result { let launch_document = launch_request.launch_document()?; - let output_schema_json = worker_output_schema_json(&launch_document)?; + let output_schema_json = worker_output_schema_json(launch_request, &launch_document)?; let request_id = format!( "worker-{}-{}", sanitize_request_id(&launch_request.job_id), @@ -1322,7 +1322,10 @@ fn worker_instructions( ) } -fn worker_output_schema_json(document: &EpiphanyWorkerLaunchDocument) -> Result { +fn worker_output_schema_json( + launch_request: &EpiphanyRuntimeWorkerLaunchRequest, + document: &EpiphanyWorkerLaunchDocument, +) -> Result { let schema = match document { EpiphanyWorkerLaunchDocument::Role(document) => { if document.frontier_plan_mind_context.is_some() { @@ -1342,6 +1345,14 @@ fn worker_output_schema_json(document: &EpiphanyWorkerLaunchDocument) -> Result< epiphany_core::epiphany_admitted_model_direction_consideration_output_schema() } else if document.imagination_consideration_context.is_some() { epiphany_core::epiphany_imagination_consideration_output_schema() + } else if role_id == epiphany_core::EpiphanyRoleResultRoleId::Modeling + && launch_request.repo_frontier_modeling_request_id.is_some() + { + let request_id = launch_request + .repo_frontier_modeling_request_id + .as_deref() + .expect("checked verdict-bound Modeling request identity"); + epiphany_core::epiphany_frontier_verdict_modeling_output_schema(request_id) } else { epiphany_core::epiphany_role_launch_output_schema(role_id) } @@ -2052,6 +2063,7 @@ mod tests { frontier_plan_mind_request_id: None, imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, }; let result = role_worker_result_from_ingress( &launch, @@ -2124,6 +2136,7 @@ mod tests { frontier_plan_mind_request_id: None, imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, }; let result = role_worker_result_from_ingress( &launch, @@ -2207,6 +2220,7 @@ mod tests { frontier_plan_mind_request_id: None, imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, }; let failed = failed_frontier_planning_role_result(&launch, "candidate mismatch")? .expect("typed planning failure"); @@ -2247,6 +2261,7 @@ mod tests { frontier_plan_mind_request_id: Some("mind-request-1".into()), imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, }; let result = role_worker_result_from_ingress( &launch, @@ -2492,6 +2507,9 @@ mod tests { frontier_plan_mind_request_id: None, imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: Some( + "frontier-modeling-request-1".to_string(), + ), created_at: now(), }, )?; @@ -2508,6 +2526,9 @@ mod tests { .expect("worker model request should carry role output schema"); assert!(output_schema.contains("\"repoModelPatch\"")); assert!(output_schema.contains("\"frontierNodeIds\"")); + assert!(output_schema.contains("\"const\": \"frontier-modeling-request-1\"")); + assert!(output_schema.contains("\"const\": \"incorporate_frontier_verdict\"")); + assert!(!output_schema.contains("\"const\": \"evolution\"")); assert!(model_request.instructions.contains("Output schema JSON")); assert!(model_request.instructions.contains("\"repoModelPatch\"")); assert_eq!(model_request.reasoning_effort.as_deref(), Some("low")); @@ -2659,6 +2680,7 @@ mod tests { frontier_plan_mind_request_id: None, imagination_consideration_request_id: None, admitted_model_direction_consideration_request_id: None, + repo_frontier_modeling_request_id: None, created_at: now(), }, )?; diff --git a/notes/epiphany-current-algorithmic-map.md b/notes/epiphany-current-algorithmic-map.md index 75ae4dc3..5a45c740 100644 --- a/notes/epiphany-current-algorithmic-map.md +++ b/notes/epiphany-current-algorithmic-map.md @@ -1564,3 +1564,22 @@ construct and pull the append-only CultCache store. The next launch-path cut is one transaction-scoped typed read view plus explicit write boundaries, with phase timings at the same owner seams. A cache wrapper that leaves repeated whole-store pulls authoritative would merely hide the smell. + +## Verdict-bound Modeling output authority + +Live v53 exposed a missing typed boundary after Soul acceptance. The +coordinator committed an exact `RepoFrontierModelingRequest` and rendered it in +dynamic context, but the persisted worker launch did not carry that identity. +The model runtime therefore exposed the generic Modeling schema, and a worker +could choose ordinary Evolution before Mind rejected it. Context was correct; +schema authority was not. + +Owner: the typed worker launch carries the exact +`repo_frontier_modeling_request_id` returned by the request-commit boundary. +The model runtime specializes its provider schema from that field: exact ID +echo, verdict-incorporation purpose, non-empty evidence, and exactly one +`revise_frontier` operation. Prompt text is derived explanation, not authority. +Ordinary Modeling retains its generic schema. Mind still validates route, +verdict receipt, frontier identity, hashes, evidence, and mutation content at +admission. The old path can no longer spend a model turn producing Evolution +under verdict authority and rely on a later rejection to discover the mismatch. diff --git a/notes/fresh-workspace-handoff.md b/notes/fresh-workspace-handoff.md index ee3e3fb3..7d213d5b 100644 --- a/notes/fresh-workspace-handoff.md +++ b/notes/fresh-workspace-handoff.md @@ -12,8 +12,8 @@ machine at its present memory budget. - Thread: `shakedown-v49-hands-relinquishment-r1` - Current release: `sha256-d2e7205a2b714c89892ba623b26c3cc4c98ac6b4f54dfb9a0a2a623f0d92402d` - Release witness: `sha256-399d952e5944450775516e612d447be8b2a106e83399f35e2fb6ffb166d17876` -- Thread-state revision: `36` -- Current action: causal Modeling job `9d7cd7d8-2d43-4165-b3c5-54381126579e` is running with a 600-second budget under PID `29792`. +- Thread-state revision: `56` +- Current action: causal Modeling job `9d7cd7d8-2d43-4165-b3c5-54381126579e` completed, but Mind rejected and superseded its unauthorized Evolution patch. A typed launch/schema repair is under focused verification; do not relaunch on the old runtime. - Sealed evidence: v49 through v52. Do not mutate them. ## Live causal boundary @@ -64,13 +64,25 @@ brief. It also reuses the RepoModel snapshot already loaded for dynamic memory context instead of reopening the whole runtime store to render model shape. All seven launch-context tests and the native coordinator seam test pass. -Poll job `9d7cd7d8-2d43-4165-b3c5-54381126579e` only through an operator-safe -coordinator projection. Accept its first valid verdict-incorporation result, -then inspect Self's next typed action. Do not recreate Eyes, Imagination, Hands, -or Soul work from this circuit. +Job `9d7cd7d8-2d43-4165-b3c5-54381126579e` completed from the correct Soul +boundary, but the static worker-output schema still allowed it to omit the +frontier request identity and emit ordinary Evolution. Mind rejected it with +`Evolution cannot bypass a current route or own verdict-driven frontier +lifecycle` and the coordinator superseded it through +`role-failure-review-962c3f59-fdce-4558-8d40-1448230554d5` at revision 56. +This repeated the prior semantic failure despite corrected context, proving +that prompt context was not the owning seam. -Commit and push the Soul-precedence repair and this Mind refresh. After the -current Modeling boundary lands, attack the iteration path: +The live repair carries `repo_frontier_modeling_request_id` in the typed worker +launch request. The model runtime uses that field to expose a specialized +schema requiring the exact request id, `incorporate_frontier_verdict`, non-empty +evidence, and exactly one `revise_frontier` operation. Generic Evolution is no +longer representable for that launch; Mind remains final admission authority. +Finish focused tests, commit and push, package one authenticated release, then +relaunch the superseded post-Soul Modeling request without overrides. Do not +recreate Eyes, Imagination, Hands, or Soul work from this circuit. + +After the Modeling boundary lands, continue attacking the iteration path: - exact `6f3cdc61` packaging rebuilt 21 first-party release binaries in 6m59s; - Modeling launch-context assembly against the roughly 40 MiB runtime store diff --git a/state/map.yaml b/state/map.yaml index b37d7f9b..7cda8ee7 100644 --- a/state/map.yaml +++ b/state/map.yaml @@ -34,9 +34,9 @@ invariants: - Evidence and git retain history; this map retains only state that changes future decisions. current_status: - summary: Epiphany is a supervised engineering alpha on Starfire, not deployment-ready. Live v53 carries RepoModel revision 6, an exact amended Hands consequence, and an accepted Soul pass. Self correctly derives post-Soul Modeling after repairing verification precedence over generic CRRC/regather routing. One timeout and one miscontextualized Evolution patch were reviewed and superseded. Causal Modeling job 9d7cd7d8-2d43-4165-b3c5-54381126579e now runs from the newer Soul boundary at thread-state revision 36. Persona consequence, retention, endurance, restart closure, and Linux/Yggdrasil cognition remain open. + summary: Epiphany is a supervised engineering alpha on Starfire, not deployment-ready. Live v53 carries RepoModel revision 6, an exact amended Hands consequence, and an accepted Soul pass. Self correctly derives post-Soul Modeling after repairing verification precedence over generic CRRC/regather routing. Three post-Soul Modeling attempts are superseded: one timeout, one stale Eyes handoff, and one correctly contextualized worker that still escaped through the generic output schema as unauthorized Evolution. The repair now carries exact verdict-request authority in the typed worker launch and specializes the provider schema before inference. Persona consequence, retention, endurance, restart closure, and Linux/Yggdrasil cognition remain open. operational_state: - local_worktree: soul_precedence_verified_pending_commit + local_worktree: verdict_bound_modeling_schema_repair_verified_pending_release operator_wireguard: restored yggdrasil: canonical_small_public_crossing_body starfire: temporary_epiphany_cognition_body @@ -53,7 +53,7 @@ current_status: yggdrasil_epiphany_services: absent resident_physiology: heartbeat_and_self_running unresolved_authority: The local execution amendment is user-authorized and packet-hash bound, not Bifrost-signed. Soul passed the amended consequence but reported that derived reorientation checkpoints carry empty evidence_ids; Modeling must preserve that limitation rather than overstate source provenance. The adopted Mind decision also carries a model-supplied 2025 timestamp; coordinator commit-time timestamp ownership remains open. Exact packaging still takes 6m59s after core changes. Removing one redundant RepoModel pull left worker appearance near 48s and full coordinator launch near 83s, so repeated whole-store transactions remain the dominant 40 MiB launch-path defect. - next_action: Poll Modeling job 9d7cd7d8-2d43-4165-b3c5-54381126579e through operator-safe coordinator projection, accept its first valid verdict-incorporation result, and inspect Self's next typed action. Continue collapsing launch context onto one transaction-scoped typed read view and split volatile Self policy from the release mega-package without weakening provenance. + next_action: Finish focused verification and publish the verdict-bound Modeling schema repair. Build one authenticated release, relaunch the superseded post-Soul Modeling request without overrides, accept the first valid frontier-verdict result, and inspect Self's next typed action. Continue collapsing launch context onto one transaction-scoped typed read view and split volatile Self policy from the release mega-package without weakening provenance. active_subgoals: - Prove Persona, Self, Eyes, Modeling, Imagination, Hands, Soul, Mind, Continuity, and nervous-system behavior individually.