Unify proposal Modeling queue ownership
This commit is contained in:
parent
16be92f430
commit
a1d80d40b1
5 changed files with 136 additions and 20 deletions
|
|
@ -929,12 +929,19 @@ pub fn ingest_resident_self_domain_pressure(
|
|||
created_at_millis: now_millis, status: "pending".into(), consumed_by_grant_id: None, private_state_exposed: false,
|
||||
})?);
|
||||
}
|
||||
for selection in crate::promote_autonomous_direction_options_for_modeling(
|
||||
crate::promote_autonomous_direction_options_for_modeling(
|
||||
runtime_store,
|
||||
repository,
|
||||
workspace,
|
||||
&requested_at,
|
||||
)? {
|
||||
)?;
|
||||
// Autonomous promotion may select several Imagination options at once.
|
||||
// Runtime request order is the single scheduler: expose pressure only for
|
||||
// its current head, then let that request's exact launch binding reveal
|
||||
// the next one on a later ingestion cycle.
|
||||
if let Some(selection) =
|
||||
crate::runtime_pending_repo_frontier_proposal_modeling_request(runtime_store)?
|
||||
{
|
||||
inserted += usize::from(enqueue_resident_self_pressure_idempotent(
|
||||
resident_store,
|
||||
&ResidentSelfPressure {
|
||||
|
|
@ -1791,20 +1798,22 @@ mod tests {
|
|||
fn seed_proposal_modeling_request(
|
||||
store: &Path,
|
||||
request_id: &str,
|
||||
proposal_id: &str,
|
||||
runtime_id: &str,
|
||||
thread_id: &str,
|
||||
selected_at: &str,
|
||||
) -> Result<()> {
|
||||
let cache = crate::runtime_spine_cache(store)?;
|
||||
let request = crate::RepoFrontierProposalModelingRequest {
|
||||
schema_version: crate::REPO_FRONTIER_PROPOSAL_MODELING_REQUEST_SCHEMA_VERSION.into(),
|
||||
request_id: request_id.into(),
|
||||
proposal_id: "proposal-1".into(),
|
||||
proposal_id: proposal_id.into(),
|
||||
proposal_payload_sha256: "sha256:proposal-1".into(),
|
||||
runtime_id: runtime_id.into(),
|
||||
thread_id: thread_id.into(),
|
||||
repository: "GameCult/Epiphany".into(),
|
||||
workspace: absolute("workspace").display().to_string(),
|
||||
selected_at: "2026-07-18T00:00:00Z".into(),
|
||||
selected_at: selected_at.into(),
|
||||
contract: crate::REPO_FRONTIER_PROPOSAL_MODELING_REQUEST_CONTRACT.into(),
|
||||
};
|
||||
let (entry, _) = cache.prepare_entry(request_id, &request)?;
|
||||
|
|
@ -2082,8 +2091,10 @@ mod tests {
|
|||
seed_proposal_modeling_request(
|
||||
&policy.runtime_store,
|
||||
"selection-1",
|
||||
"proposal-1",
|
||||
&policy.release_runtime_id,
|
||||
"implementation-thread-proposal",
|
||||
"2026-07-18T00:00:00Z",
|
||||
)?;
|
||||
enqueue_resident_self_pressure(
|
||||
&store,
|
||||
|
|
@ -2117,6 +2128,97 @@ mod tests {
|
|||
Ok(())
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn ingestion_exposes_only_the_runtime_owned_proposal_modeling_queue_head() -> Result<()> {
|
||||
let temp = tempfile::tempdir()?;
|
||||
let resident_store = temp.path().join("resident.cc");
|
||||
let runtime_store = temp.path().join("runtime.cc");
|
||||
let persona_store = temp.path().join("persona.cc");
|
||||
crate::initialize_runtime_spine(
|
||||
&runtime_store,
|
||||
crate::RuntimeSpineInitOptions {
|
||||
runtime_id: "test-runtime".into(),
|
||||
display_name: "Test runtime".into(),
|
||||
created_at: "2026-07-18T00:00:00Z".into(),
|
||||
},
|
||||
)?;
|
||||
seed_proposal_modeling_request(
|
||||
&runtime_store,
|
||||
"selection-1",
|
||||
"proposal-1",
|
||||
"test-runtime",
|
||||
"implementation-thread-proposal",
|
||||
"2026-07-18T00:00:01Z",
|
||||
)?;
|
||||
seed_proposal_modeling_request(
|
||||
&runtime_store,
|
||||
"selection-2",
|
||||
"proposal-2",
|
||||
"test-runtime",
|
||||
"implementation-thread-proposal",
|
||||
"2026-07-18T00:00:02Z",
|
||||
)?;
|
||||
|
||||
assert_eq!(
|
||||
ingest_resident_self_domain_pressure(
|
||||
&resident_store,
|
||||
&runtime_store,
|
||||
&persona_store,
|
||||
"test-runtime",
|
||||
"GameCult/Epiphany",
|
||||
absolute("workspace").to_str().expect("UTF-8 workspace"),
|
||||
1,
|
||||
)?,
|
||||
1
|
||||
);
|
||||
let pressures = state_cache(&resident_store)?.get_all::<ResidentSelfPressure>()?;
|
||||
assert_eq!(pressures.len(), 1);
|
||||
assert_eq!(
|
||||
pressures[0].provenance_ref,
|
||||
"cultcache://repo-frontier-proposal-modeling/selection-1"
|
||||
);
|
||||
|
||||
let runtime_cache = crate::runtime_spine_cache(&runtime_store)?;
|
||||
let launch = crate::RepoFrontierProposalModelingLaunchBinding {
|
||||
schema_version: crate::REPO_FRONTIER_PROPOSAL_MODELING_LAUNCH_BINDING_SCHEMA_VERSION
|
||||
.into(),
|
||||
binding_record_id: "selection-1-launch".into(),
|
||||
proposal_modeling_request_id: "selection-1".into(),
|
||||
proposal_id: "proposal-1".into(),
|
||||
proposal_payload_sha256: "sha256:proposal-1".into(),
|
||||
job_id: "modeling-job-1".into(),
|
||||
binding_id: "modeling-checkpoint-worker".into(),
|
||||
runtime_id: "test-runtime".into(),
|
||||
thread_id: "implementation-thread-proposal".into(),
|
||||
launched_at: "2026-07-18T00:00:03Z".into(),
|
||||
worker_launch_document_sha256: "33".repeat(32),
|
||||
contract: crate::REPO_FRONTIER_PROPOSAL_MODELING_LAUNCH_BINDING_CONTRACT.into(),
|
||||
};
|
||||
let (entry, _) = runtime_cache.prepare_entry(&launch.binding_record_id, &launch)?;
|
||||
SingleFileMessagePackBackingStore::new(&runtime_store).push(&entry)?;
|
||||
|
||||
assert_eq!(
|
||||
ingest_resident_self_domain_pressure(
|
||||
&resident_store,
|
||||
&runtime_store,
|
||||
&persona_store,
|
||||
"test-runtime",
|
||||
"GameCult/Epiphany",
|
||||
absolute("workspace").to_str().expect("UTF-8 workspace"),
|
||||
2,
|
||||
)?,
|
||||
1
|
||||
);
|
||||
let mut pressures = state_cache(&resident_store)?.get_all::<ResidentSelfPressure>()?;
|
||||
pressures.sort_by(|left, right| left.pressure_id.cmp(&right.pressure_id));
|
||||
assert_eq!(pressures.len(), 2);
|
||||
assert_eq!(
|
||||
pressures[1].provenance_ref,
|
||||
"cultcache://repo-frontier-proposal-modeling/selection-2"
|
||||
);
|
||||
Ok(())
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn standard_heartbeat_owns_self_grant_selection() -> Result<()> {
|
||||
let temp = tempfile::tempdir()?;
|
||||
|
|
|
|||
|
|
@ -1272,8 +1272,11 @@ proposal-Modeling request. These are selected work items, not candidates still
|
|||
awaiting preference. `runtime_pending_repo_frontier_proposal_modeling_request`
|
||||
therefore schedules the oldest unclaimed request by `selected_at`, then stable
|
||||
request ID. A launch binding removes only its exact request from the pending
|
||||
queue, exposing the next. Self owns queue order; it does not silently discard
|
||||
or rank Imagination's already-selected options.
|
||||
queue, exposing the next. Resident ingestion queries that same head and emits
|
||||
pressure for only that request. It does not mirror every selected request into
|
||||
a second independently ordered pressure queue. Self owns queue order; it does
|
||||
not silently discard or rank Imagination's already-selected options, and
|
||||
heartbeat owns opportunity without acquiring a second scheduling opinion.
|
||||
|
||||
## Exact release build cache ownership
|
||||
|
||||
|
|
|
|||
|
|
@ -24,10 +24,21 @@ proposal-Modeling work, but status then failed because the pending projection
|
|||
required exactly one unclaimed request.
|
||||
|
||||
The current worktree treats selected proposal-Modeling requests as an
|
||||
oldest-first execution queue. A launch binding consumes only its exact request
|
||||
and exposes the next. The focused queue test proves both ordering and
|
||||
single-request consumption; both native status tests also pass. v35 is sealed
|
||||
at the cardinality failure boundary.
|
||||
oldest-first execution queue. Exact `16be92f4` packages as
|
||||
`sha256-998dbac0877ee2249f723796501f4f82c50cc9dcb8ae205117a50cde04bab3e6`
|
||||
with witness
|
||||
`sha256-4975a3b043012f62eecfd9c9b6c9f431bbf66a48ff1f46117bd1532c8b0dba28`.
|
||||
v36 proved status derives `launchModeling` instead of rejecting cardinality and
|
||||
completed one proposal Modeling turn. The oldest request nevertheless remained
|
||||
pending because v35 had emitted pressure for every option and heartbeat had
|
||||
selected a later pressure first. This falsified the partial repair: runtime and
|
||||
resident pressure were still separate schedulers.
|
||||
|
||||
The current worktree emits resident pressure only for the runtime-owned pending
|
||||
head. Its exact launch binding exposes the next request on a later ingestion
|
||||
cycle. All 17 resident-Self tests pass; focused tests prove runtime ordering,
|
||||
single-request launch consumption, and head-only pressure emission. v35 and v36
|
||||
are sealed failure boundaries.
|
||||
|
||||
Fresh runtime `F:\Projects\.epiphany-runtime\shakedown\live-20260808-v31`
|
||||
accepted initial and proposal-bound Modeling for thread
|
||||
|
|
@ -98,12 +109,12 @@ thread.
|
|||
|
||||
## Next action
|
||||
|
||||
1. Commit, push, package, and authenticate the proposal-Modeling queue repair.
|
||||
2. Preserve v31 through v35 as failure evidence; clone v35 into v36 and publish
|
||||
the exact successor release.
|
||||
1. Commit, push, package, and authenticate the single-owner ingestion repair.
|
||||
2. Preserve v31 through v36 as failure evidence; replay from a boundary before
|
||||
duplicate proposal pressures were created.
|
||||
3. Run persistent resident supervision from an approved `.epiphany-dogfood`
|
||||
root and prove the selected Imagination options launch Modeling one at a
|
||||
time in stable request order.
|
||||
root and prove selected Imagination options launch Modeling one at a time in
|
||||
runtime request order.
|
||||
4. In a fresh runtime, re-run pressure ingestion twice and resident launch.
|
||||
Prove autonomous direction consideration, proposal-bound Modeling,
|
||||
canonical Imagination, dedicated Mind adoption, and exact Hands authority.
|
||||
|
|
|
|||
Binary file not shown.
|
|
@ -34,15 +34,15 @@ 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. Exact 8a9439ca is authenticated as sha256-39e12132f829fbb782cc4ba33308e44c641f6bd4a1136850ce9246b1179c3cbd with witness sha256-d57bdeb6e6b14cc3b7500d461fa7ea26455d319b4f1d904cda2fa6e0317407be. v35 proved its resident launch preserved the typed request's original implementation thread and completed autonomous Imagination. Status then exposed multiple unclaimed proposal-Modeling requests because one direction result produced several explicitly selected options while the pending projection incorrectly required global singularity. The current worktree schedules those selected requests as a stable oldest-first queue and consumes them by exact launch binding. Focused queue and status tests pass. Persona consequence, retention, endurance, and Linux/Yggdrasil cognition remain open.
|
||||
summary: Epiphany is a supervised engineering alpha on Starfire, not deployment-ready. Exact 16be92f4 packages as sha256-998dbac0877ee2249f723796501f4f82c50cc9dcb8ae205117a50cde04bab3e6 with witness sha256-4975a3b043012f62eecfd9c9b6c9f431bbf66a48ff1f46117bd1532c8b0dba28. v36 proved its oldest-first runtime projection derives launchModeling and completed one proposal Modeling turn, but the same oldest request remained pending: resident ingestion had mirrored every option into a separate pressure queue and heartbeat selected a later pressure first. The current worktree makes runtime pending-request order the only scheduler and emits resident pressure only for its head. All 17 resident-Self tests plus the runtime queue test pass. Persona consequence, retention, endurance, and Linux/Yggdrasil cognition remain open.
|
||||
operational_state:
|
||||
local_worktree: proposal_modeling_queue_verified_pending_commit
|
||||
local_worktree: single_owner_proposal_modeling_queue_verified_pending_commit
|
||||
operator_wireguard: restored
|
||||
yggdrasil: canonical_small_public_crossing_body
|
||||
starfire: temporary_epiphany_cognition_body
|
||||
starfire_runtime_identity: epiphany-starfire
|
||||
starfire_swarm_brake: released
|
||||
starfire_release: authenticated_8a9439ca_request_thread_successor_pending_publish
|
||||
starfire_release: authenticated_16be92f4_queue_projection; single_owner_successor_pending
|
||||
starfire_repository_body: bound_and_observed
|
||||
starfire_verse_topology: bound_to_current_repository_body
|
||||
starfire_native_status: supervised_shakedown_active
|
||||
|
|
@ -52,8 +52,8 @@ current_status:
|
|||
bifrost_feedback_crossing: authenticated_transport_only
|
||||
yggdrasil_epiphany_services: absent
|
||||
resident_physiology: heartbeat_and_self_running
|
||||
unresolved_authority: v31's generic user proposal produced a lawful direct Hands gate, but the active objective requires the autonomous Imagination-origin path and dedicated Mind adoption, so that gate remains inert. v35 proved request-owned Imagination continuation, then exposed that multi-option autonomous promotion and singular pending-request projection disagreed about queue cardinality. The queue repair is locally verified but not packaged/live. Canonical proposal Modeling, dedicated Mind adoption, exact Hands binding, bounded-worker failure/restart/closure, Persona consequence, retention, endurance, and Linux/Yggdrasil cognition remain open.
|
||||
next_action: Commit, package, and authenticate the proposal-Modeling queue repair; clone sealed v35 into v36 and prove each selected Imagination option receives one Modeling launch in stable order. Then continue canonical Imagination planning, dedicated Mind, Hands, and bounded-worker failure/restart/Soul closure.
|
||||
unresolved_authority: v31's generic user proposal produced a lawful direct Hands gate, but the active objective requires the autonomous Imagination-origin path and dedicated Mind adoption, so that gate remains inert. v35 proved request-owned Imagination continuation; v36 proved the cardinality repair but falsified split scheduling between runtime request order and resident pressure order. The single-owner ingestion repair is locally verified but not packaged/live. Canonical proposal Modeling, dedicated Mind adoption, exact Hands binding, bounded-worker failure/restart/closure, Persona consequence, retention, endurance, and Linux/Yggdrasil cognition remain open.
|
||||
next_action: Commit, package, and authenticate single-owner proposal-Modeling ingestion; replay from a pre-duplicate-pressure boundary and prove each selected Imagination option receives one Modeling launch in runtime order. Then continue canonical Imagination planning, dedicated Mind, Hands, and bounded-worker failure/restart/Soul closure.
|
||||
|
||||
active_subgoals:
|
||||
- Prove Persona, Self, Eyes, Modeling, Imagination, Hands, Soul, Mind, Continuity, and nervous-system behavior individually.
|
||||
|
|
|
|||
Reference in a new issue