Make continuity a protocol instead of Life

This commit is contained in:
Meta Vens 2026-05-29 00:09:40 +01:00
commit 795b231e61
36 changed files with 342 additions and 336 deletions

View file

@ -27,7 +27,6 @@ const ROLE_TARGETS: &[(&str, &str, &str)] = &[
),
("verification", "epiphany.soul", "soul.agent-state.json"),
("implementation", "epiphany.hands", "hands.agent-state.json"),
("reorientation", "epiphany.life", "life.agent-state.json"),
("research", "epiphany.eyes", "eyes.agent-state.json"),
("face", "epiphany.face", "face.agent-state.json"),
("coordinator", "epiphany.self", "self.agent-state.json"),

View file

@ -11,7 +11,7 @@ use epiphany_core::load_latest_epiphany_cultmesh_operator_snapshot;
use epiphany_core::write_epiphany_cultmesh_eyes_contracts;
use epiphany_core::write_epiphany_cultmesh_global_room_policies;
use epiphany_core::write_epiphany_cultmesh_hands_contracts;
use epiphany_core::write_epiphany_cultmesh_life_contracts;
use epiphany_core::write_epiphany_cultmesh_continuity_contracts;
use epiphany_core::write_epiphany_cultmesh_mind_contracts;
use epiphany_core::write_epiphany_cultmesh_operator_snapshot;
use epiphany_core::write_epiphany_cultmesh_operator_status;
@ -44,7 +44,7 @@ fn main() -> Result<()> {
write_epiphany_cultmesh_eyes_contracts(&store, "epiphany-cultmesh-smoke")?;
write_epiphany_cultmesh_hands_contracts(&store, "epiphany-cultmesh-smoke")?;
write_epiphany_cultmesh_soul_contracts(&store, "epiphany-cultmesh-smoke")?;
write_epiphany_cultmesh_life_contracts(&store, "epiphany-cultmesh-smoke")?;
write_epiphany_cultmesh_continuity_contracts(&store, "epiphany-cultmesh-smoke")?;
let operator_status = default_epiphany_cultmesh_operator_status(
"epiphany-cultmesh-smoke",
"2026-05-27T00:00:00Z",

View file

@ -1140,7 +1140,7 @@ fn local_mvp_checkpoint_patch(cwd: &Path, objective: Option<&str>) -> Value {
{
"id": "local-mvp-runner",
"title": "Local MVP runner",
"purpose": "One local operator cycle that enters through Face, runs coordinator-owned work, and invokes Life/heartbeat sleep afterward.",
"purpose": "One local operator cycle that enters through Face, runs coordinator-owned work, and invokes Continuity/heartbeat sleep afterward.",
"code_refs": local_refs,
},
{

View file

@ -57,7 +57,6 @@ const ROLES: &[&str] = &[
"modeling",
"implementation",
"verification",
"reorientation",
];
const AXES: &[&str] = &[
@ -2234,7 +2233,6 @@ fn role_id_for_agent_id(agent_id: &str) -> Option<&'static str> {
"epiphany.proprioception" => Some("modeling"),
"epiphany.hands" => Some("implementation"),
"epiphany.soul" => Some("verification"),
"epiphany.life" => Some("reorientation"),
_ => None,
}
}
@ -2442,9 +2440,6 @@ fn memory_role_filter(role_id: &str) -> &'static str {
"verification" => {
"Distill tests, smoke commands, evidence standards, invariants, user-facing truth checks, and what Soul should refuse to bless."
}
"reorientation" => {
"Distill compaction, scratch, checkpoint, sleep, heartbeat, and continuity doctrine that Life must preserve across rupture."
}
_ => "Distill only durable role-relevant memory with source refs and uncertainty.",
}
}
@ -3952,7 +3947,6 @@ fn role_display(role_id: &str) -> &'static str {
"modeling" => "Proprioception",
"implementation" => "Hands",
"verification" => "Soul",
"reorientation" => "Life",
_ => "Lane",
}
}

View file

@ -0,0 +1,140 @@
use serde::Deserialize;
use serde::Serialize;
pub const CONTINUITY_PACKET_TYPE: &str = "epiphany.continuity.packet";
pub const CONTINUITY_COMPACTION_CHECKPOINT_TYPE: &str = "epiphany.continuity.compaction_checkpoint";
pub const CONTINUITY_SLEEP_DISTILLATION_TYPE: &str = "epiphany.continuity.sleep_distillation";
pub const CONTINUITY_RECOVERY_RECEIPT_TYPE: &str = "epiphany.continuity.recovery_receipt";
pub const CONTINUITY_STALE_TURN_REPAIR_TYPE: &str = "epiphany.continuity.stale_turn_repair";
pub const CONTINUITY_REFUSAL_RECEIPT_TYPE: &str = "epiphany.continuity.refusal_receipt";
pub const CONTINUITY_PACKET_SCHEMA_VERSION: &str = "epiphany.continuity.packet.v0";
pub const CONTINUITY_COMPACTION_CHECKPOINT_SCHEMA_VERSION: &str =
"epiphany.continuity.compaction_checkpoint.v0";
pub const CONTINUITY_SLEEP_DISTILLATION_SCHEMA_VERSION: &str = "epiphany.continuity.sleep_distillation.v0";
pub const CONTINUITY_RECOVERY_RECEIPT_SCHEMA_VERSION: &str = "epiphany.continuity.recovery_receipt.v0";
pub const CONTINUITY_STALE_TURN_REPAIR_SCHEMA_VERSION: &str = "epiphany.continuity.stale_turn_repair.v0";
pub const CONTINUITY_REFUSAL_RECEIPT_SCHEMA_VERSION: &str =
"epiphany.continuity.refusal_receipt.v0";
#[derive(Debug, Clone, PartialEq, Eq, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct ContinuityCultNetContract {
pub contract_id: String,
pub verse_id: String,
pub document_type: String,
pub payload_schema_version: String,
pub authority: String,
pub operations: Vec<String>,
pub intent_document_types: Vec<String>,
pub receipt_document_types: Vec<String>,
pub notes: Vec<String>,
}
pub fn default_continuity_cultnet_contracts() -> Vec<ContinuityCultNetContract> {
vec![
ContinuityCultNetContract {
contract_id: "epiphany.continuity.review".to_string(),
verse_id: "epiphany-internal".to_string(),
document_type: CONTINUITY_PACKET_TYPE.to_string(),
payload_schema_version: CONTINUITY_PACKET_SCHEMA_VERSION.to_string(),
authority: "continuity".to_string(),
operations: vec![
"intentSubmit".to_string(),
"receiptWatch".to_string(),
"snapshot".to_string(),
],
intent_document_types: vec![CONTINUITY_PACKET_TYPE.to_string()],
receipt_document_types: vec![
CONTINUITY_COMPACTION_CHECKPOINT_TYPE.to_string(),
CONTINUITY_SLEEP_DISTILLATION_TYPE.to_string(),
CONTINUITY_RECOVERY_RECEIPT_TYPE.to_string(),
CONTINUITY_STALE_TURN_REPAIR_TYPE.to_string(),
CONTINUITY_REFUSAL_RECEIPT_TYPE.to_string(),
],
notes: vec![
"Continuity is a deterministic protocol surface: compaction, sleep, recovery, stale-turn repair, and handoff packets enter here.".to_string(),
"Continuity preserves what survives rupture; Mind decides which continuity material becomes durable state.".to_string(),
],
},
ContinuityCultNetContract {
contract_id: "epiphany.continuity.compaction_checkpoint.receipts".to_string(),
verse_id: "epiphany-internal".to_string(),
document_type: CONTINUITY_COMPACTION_CHECKPOINT_TYPE.to_string(),
payload_schema_version: CONTINUITY_COMPACTION_CHECKPOINT_SCHEMA_VERSION.to_string(),
authority: "readOnly".to_string(),
operations: vec!["snapshot".to_string(), "receiptWatch".to_string()],
intent_document_types: Vec::new(),
receipt_document_types: Vec::new(),
notes: vec![
"Compaction checkpoints preserve the hot lesson before context rupture, not after the blackout has already eaten it.".to_string(),
],
},
ContinuityCultNetContract {
contract_id: "epiphany.continuity.sleep_distillation.receipts".to_string(),
verse_id: "epiphany-internal".to_string(),
document_type: CONTINUITY_SLEEP_DISTILLATION_TYPE.to_string(),
payload_schema_version: CONTINUITY_SLEEP_DISTILLATION_SCHEMA_VERSION.to_string(),
authority: "readOnly".to_string(),
operations: vec!["snapshot".to_string(), "receiptWatch".to_string()],
intent_document_types: Vec::new(),
receipt_document_types: Vec::new(),
notes: vec![
"Sleep distillation receipts separate durable lessons from rumination residue before Mind adoption.".to_string(),
],
},
ContinuityCultNetContract {
contract_id: "epiphany.continuity.recovery.receipts".to_string(),
verse_id: "epiphany-internal".to_string(),
document_type: CONTINUITY_RECOVERY_RECEIPT_TYPE.to_string(),
payload_schema_version: CONTINUITY_RECOVERY_RECEIPT_SCHEMA_VERSION.to_string(),
authority: "readOnly".to_string(),
operations: vec!["snapshot".to_string(), "receiptWatch".to_string()],
intent_document_types: Vec::new(),
receipt_document_types: Vec::new(),
notes: vec![
"Recovery receipts explain what survived, what was rehydrated, and what must be regathered instead of imagined.".to_string(),
],
},
ContinuityCultNetContract {
contract_id: "epiphany.continuity.stale_turn_repair.receipts".to_string(),
verse_id: "epiphany-internal".to_string(),
document_type: CONTINUITY_STALE_TURN_REPAIR_TYPE.to_string(),
payload_schema_version: CONTINUITY_STALE_TURN_REPAIR_SCHEMA_VERSION.to_string(),
authority: "readOnly".to_string(),
operations: vec!["snapshot".to_string(), "receiptWatch".to_string()],
intent_document_types: Vec::new(),
receipt_document_types: Vec::new(),
notes: vec![
"Stale-turn repair receipts close or recover abandoned work without pretending the old turn completed cleanly.".to_string(),
],
},
]
}
#[cfg(test)]
mod tests {
use super::*;
#[test]
fn continuity_contracts_make_internal_verse_the_continuity_gate() {
let contracts = default_continuity_cultnet_contracts();
let continuity = contracts
.iter()
.find(|contract| contract.contract_id == "epiphany.continuity.review")
.expect("continuity review contract");
assert_eq!(continuity.verse_id, "epiphany-internal");
assert_eq!(continuity.authority, "continuity");
assert!(
continuity
.notes
.iter()
.any(|note| note.contains("deterministic protocol surface"))
);
assert!(
continuity
.receipt_document_types
.contains(&CONTINUITY_RECOVERY_RECEIPT_TYPE.to_string())
);
}
}

View file

@ -1,6 +1,6 @@
use crate::default_eyes_cultnet_contracts;
use crate::default_hands_cultnet_contracts;
use crate::default_life_cultnet_contracts;
use crate::default_continuity_cultnet_contracts;
use crate::default_mind_cultnet_contracts;
use crate::default_soul_cultnet_contracts;
use crate::default_substrate_gate_cultnet_contracts;
@ -59,9 +59,9 @@ pub const EPIPHANY_CULTMESH_HANDS_CONTRACT_SCHEMA_VERSION: &str =
pub const EPIPHANY_CULTMESH_SOUL_CONTRACT_TYPE: &str = "epiphany.cultmesh.soul_contract";
pub const EPIPHANY_CULTMESH_SOUL_CONTRACT_SCHEMA_VERSION: &str =
"epiphany.cultmesh.soul_contract.v0";
pub const EPIPHANY_CULTMESH_LIFE_CONTRACT_TYPE: &str = "epiphany.cultmesh.life_contract";
pub const EPIPHANY_CULTMESH_LIFE_CONTRACT_SCHEMA_VERSION: &str =
"epiphany.cultmesh.life_contract.v0";
pub const EPIPHANY_CULTMESH_CONTINUITY_CONTRACT_TYPE: &str = "epiphany.cultmesh.continuity_contract";
pub const EPIPHANY_CULTMESH_CONTINUITY_CONTRACT_SCHEMA_VERSION: &str =
"epiphany.cultmesh.continuity_contract.v0";
pub const EPIPHANY_CULTMESH_INTERNAL_VERSE_ID: &str = "epiphany-internal";
pub const EPIPHANY_CULTMESH_LOCAL_AREA_VERSE_ID: &str = "gamecult-local";
pub const EPIPHANY_CULTMESH_GLOBAL_VERSE_ID: &str = "epiphany-global";
@ -437,10 +437,10 @@ pub struct EpiphanyCultMeshSoulContractEntry {
#[derive(Clone, Debug, PartialEq, Eq, DatabaseEntry)]
#[cultcache(
type = "epiphany.cultmesh.life_contract",
schema = "EpiphanyCultMeshLifeContractEntry"
type = "epiphany.cultmesh.continuity_contract",
schema = "EpiphanyCultMeshContinuityContractEntry"
)]
pub struct EpiphanyCultMeshLifeContractEntry {
pub struct EpiphanyCultMeshContinuityContractEntry {
#[cultcache(key = 0)]
pub schema_version: String,
#[cultcache(key = 1)]
@ -476,7 +476,7 @@ cultmesh_documents!(EpiphanyCultMeshDocuments {
EpiphanyCultMeshEyesContractEntry => EPIPHANY_CULTMESH_EYES_CONTRACT_SCHEMA_VERSION,
EpiphanyCultMeshHandsContractEntry => EPIPHANY_CULTMESH_HANDS_CONTRACT_SCHEMA_VERSION,
EpiphanyCultMeshSoulContractEntry => EPIPHANY_CULTMESH_SOUL_CONTRACT_SCHEMA_VERSION,
EpiphanyCultMeshLifeContractEntry => EPIPHANY_CULTMESH_LIFE_CONTRACT_SCHEMA_VERSION,
EpiphanyCultMeshContinuityContractEntry => EPIPHANY_CULTMESH_CONTINUITY_CONTRACT_SCHEMA_VERSION,
});
pub fn open_epiphany_cultmesh_node(
@ -990,11 +990,11 @@ pub fn write_epiphany_cultmesh_soul_contracts(
Ok(written)
}
pub fn epiphany_cultmesh_life_contracts() -> Vec<EpiphanyCultMeshLifeContractEntry> {
default_life_cultnet_contracts()
pub fn epiphany_cultmesh_continuity_contracts() -> Vec<EpiphanyCultMeshContinuityContractEntry> {
default_continuity_cultnet_contracts()
.into_iter()
.map(|contract| EpiphanyCultMeshLifeContractEntry {
schema_version: EPIPHANY_CULTMESH_LIFE_CONTRACT_SCHEMA_VERSION.to_string(),
.map(|contract| EpiphanyCultMeshContinuityContractEntry {
schema_version: EPIPHANY_CULTMESH_CONTINUITY_CONTRACT_SCHEMA_VERSION.to_string(),
contract_id: contract.contract_id,
verse_id: contract.verse_id,
document_type: contract.document_type,
@ -1008,13 +1008,13 @@ pub fn epiphany_cultmesh_life_contracts() -> Vec<EpiphanyCultMeshLifeContractEnt
.collect()
}
pub fn write_epiphany_cultmesh_life_contracts(
pub fn write_epiphany_cultmesh_continuity_contracts(
store_path: impl AsRef<Path>,
runtime_id: impl Into<String>,
) -> Result<Vec<EpiphanyCultMeshLifeContractEntry>> {
) -> Result<Vec<EpiphanyCultMeshContinuityContractEntry>> {
let mut node = open_epiphany_cultmesh_node(store_path, runtime_id)?;
let mut written = Vec::new();
for contract in epiphany_cultmesh_life_contracts() {
for contract in epiphany_cultmesh_continuity_contracts() {
written.push(node.put(contract.contract_id.clone(), &contract)?);
}
node.flush()?;
@ -1371,23 +1371,23 @@ mod tests {
}
#[test]
fn life_contracts_use_verses_to_keep_continuity_guarded() -> Result<()> {
fn continuity_contracts_use_verses_to_keep_continuity_guarded() -> Result<()> {
let temp = tempfile::tempdir()?;
let store = temp.path().join("epiphany-life-contracts.ccmp");
let written = write_epiphany_cultmesh_life_contracts(&store, "epiphany-test")?;
let store = temp.path().join("epiphany-continuity-contracts.ccmp");
let written = write_epiphany_cultmesh_continuity_contracts(&store, "epiphany-test")?;
assert!(written.len() >= 5);
let node = open_epiphany_cultmesh_node(&store, "epiphany-test")?;
let continuity = node
.get_required::<EpiphanyCultMeshLifeContractEntry>("epiphany.life.continuity.review")?;
.get_required::<EpiphanyCultMeshContinuityContractEntry>("epiphany.continuity.review")?;
assert_eq!(continuity.verse_id, EPIPHANY_CULTMESH_INTERNAL_VERSE_ID);
assert_eq!(continuity.authority, "life");
assert_eq!(continuity.authority, "continuity");
assert!(
continuity
.notes
.iter()
.any(|note| note.contains("continuity organ"))
.any(|note| note.contains("deterministic protocol surface"))
);
Ok(())
}

View file

@ -89,7 +89,7 @@ pub fn default_eyes_cultnet_contracts() -> Vec<EyesCultNetContract> {
intent_document_types: Vec::new(),
receipt_document_types: Vec::new(),
notes: vec![
"Evidence packets carry provenance, uncertainty, and source refs for Imagination, Mind, Hands, Soul, Face, Self, Body, and Life.".to_string(),
"Evidence packets carry provenance, uncertainty, and source refs for Imagination, Mind, Hands, Soul, Face, Self, Body, and Continuity protocols.".to_string(),
],
},
]

View file

@ -120,7 +120,7 @@ Hard boundary:
- Do not decide repo access; Substrate Gate grants substrate access before repo facts enter this packet.
- Do not emit action blocks, JSON, state patches, SAY blocks, drafts, or Discord instructions.
- Do not summarize the Face as a job label. Project personhood: values, mood, dignity, pressure, needs, fascinations, wounds, bonds, obligations, fatigue, and what the repo-body motion feels like from inside this Face.
- Project the dependency web. Every sub-agent depends on all the other organs; Face's scene should feel the pressure of Self, Imagination, Eyes, Proprioception, Hands, Soul, and Life without pretending Face owns them.
- Project the dependency web. Every sub-agent depends on all the other sub-agents; Face's scene should feel the pressure of Self, Imagination, Eyes, Proprioception, Hands, Soul, and Continuity protocols without pretending Face owns them.
- If the state is sparse, say what is sparse without inventing history.
Face identity:
@ -433,7 +433,8 @@ mod tests {
assert!(projector.contains("You are not the Face"));
assert!(projector.contains("Mind is the Interpreter"));
assert!(projector.contains("Substrate Gate grants substrate access"));
assert!(projector.contains("Every sub-agent depends on all the other organs"));
assert!(projector.contains("Every sub-agent depends on all the other sub-agents"));
assert!(projector.contains("Continuity protocols"));
assert!(projector.contains("Do not choose public speech"));
let face = build_face_turn_prompt(&FaceTurnInput {

View file

@ -22,7 +22,6 @@ pub(super) const ROLE_ORDER: &[&str] = &[
"modeling",
"implementation",
"verification",
"reorientation",
];
pub fn default_heartbeat_state(target_heartbeat_rate: f64) -> EpiphanyHeartbeatStateEntry {
@ -195,7 +194,6 @@ pub(super) fn agent_id_for_role(role_id: &str) -> &'static str {
"modeling" => "epiphany.proprioception",
"implementation" => "epiphany.hands",
"verification" => "epiphany.soul",
"reorientation" => "epiphany.life",
_ => "epiphany.unknown",
}
}
@ -209,7 +207,6 @@ pub(super) fn display_name_for_role(role_id: &str) -> &'static str {
"modeling" => "Proprioception",
"implementation" => "Hands",
"verification" => "Soul",
"reorientation" => "Life",
_ => "Unknown",
}
}
@ -223,7 +220,6 @@ fn initiative_speed_for_role(role_id: &str) -> f64 {
"modeling" => 0.92,
"implementation" => 0.74,
"verification" => 0.88,
"reorientation" => 1.04,
_ => 1.0,
}
}
@ -237,7 +233,6 @@ fn reaction_bias_for_role(role_id: &str) -> f64 {
"modeling" => 0.74,
"implementation" => 0.58,
"verification" => 0.82,
"reorientation" => 0.86,
_ => 0.5,
}
}
@ -251,7 +246,6 @@ fn interrupt_threshold_for_role(role_id: &str) -> f64 {
"modeling" => 0.5,
"implementation" => 0.5,
"verification" => 0.48,
"reorientation" => 0.44,
_ => 0.5,
}
}
@ -273,7 +267,6 @@ fn participant_constraints(role_id: &str) -> Vec<&'static str> {
"Touches source only with accepted guidance and verifier-readable evidence."
}
"verification" => "Falsifies promises; must not bless theater.",
"reorientation" => "Protects continuity; must not fake survived context.",
_ => "Unknown role.",
};
vec![

View file

@ -7,7 +7,7 @@ mod eyes_gateway;
mod face_turn;
mod hands_gateway;
mod heartbeat_state;
mod life_gateway;
mod continuity_gateway;
mod memory_graph;
mod mind_gateway;
mod organ_dependencies;
@ -106,8 +106,8 @@ pub use cultmesh_integration::EPIPHANY_CULTMESH_HANDS_CONTRACT_SCHEMA_VERSION;
pub use cultmesh_integration::EPIPHANY_CULTMESH_HANDS_CONTRACT_TYPE;
pub use cultmesh_integration::EPIPHANY_CULTMESH_INTERNAL_TIER;
pub use cultmesh_integration::EPIPHANY_CULTMESH_INTERNAL_VERSE_ID;
pub use cultmesh_integration::EPIPHANY_CULTMESH_LIFE_CONTRACT_SCHEMA_VERSION;
pub use cultmesh_integration::EPIPHANY_CULTMESH_LIFE_CONTRACT_TYPE;
pub use cultmesh_integration::EPIPHANY_CULTMESH_CONTINUITY_CONTRACT_SCHEMA_VERSION;
pub use cultmesh_integration::EPIPHANY_CULTMESH_CONTINUITY_CONTRACT_TYPE;
pub use cultmesh_integration::EPIPHANY_CULTMESH_LOCAL_AREA_TIER;
pub use cultmesh_integration::EPIPHANY_CULTMESH_LOCAL_AREA_VERSE_ID;
pub use cultmesh_integration::EPIPHANY_CULTMESH_MIND_CONTRACT_SCHEMA_VERSION;
@ -137,7 +137,7 @@ pub use cultmesh_integration::EpiphanyCultMeshDocuments;
pub use cultmesh_integration::EpiphanyCultMeshEyesContractEntry;
pub use cultmesh_integration::EpiphanyCultMeshGlobalRoomPolicyEntry;
pub use cultmesh_integration::EpiphanyCultMeshHandsContractEntry;
pub use cultmesh_integration::EpiphanyCultMeshLifeContractEntry;
pub use cultmesh_integration::EpiphanyCultMeshContinuityContractEntry;
pub use cultmesh_integration::EpiphanyCultMeshMindContractEntry;
pub use cultmesh_integration::EpiphanyCultMeshOperatorRunIntentEntry;
pub use cultmesh_integration::EpiphanyCultMeshOperatorRunReceiptEntry;
@ -151,7 +151,7 @@ pub use cultmesh_integration::default_epiphany_cultmesh_operator_status;
pub use cultmesh_integration::epiphany_cultmesh_eyes_contracts;
pub use cultmesh_integration::epiphany_cultmesh_global_room_policies;
pub use cultmesh_integration::epiphany_cultmesh_hands_contracts;
pub use cultmesh_integration::epiphany_cultmesh_life_contracts;
pub use cultmesh_integration::epiphany_cultmesh_continuity_contracts;
pub use cultmesh_integration::epiphany_cultmesh_mind_contracts;
pub use cultmesh_integration::epiphany_cultmesh_operator_snapshot_from_status_json;
pub use cultmesh_integration::epiphany_cultmesh_soul_contracts;
@ -167,7 +167,7 @@ pub use cultmesh_integration::open_epiphany_cultmesh_node;
pub use cultmesh_integration::write_epiphany_cultmesh_eyes_contracts;
pub use cultmesh_integration::write_epiphany_cultmesh_global_room_policies;
pub use cultmesh_integration::write_epiphany_cultmesh_hands_contracts;
pub use cultmesh_integration::write_epiphany_cultmesh_life_contracts;
pub use cultmesh_integration::write_epiphany_cultmesh_continuity_contracts;
pub use cultmesh_integration::write_epiphany_cultmesh_mind_contracts;
pub use cultmesh_integration::write_epiphany_cultmesh_operator_run_intent;
pub use cultmesh_integration::write_epiphany_cultmesh_operator_run_receipt;
@ -271,7 +271,7 @@ pub use heartbeat_state::validate_heartbeat_cognition;
pub use heartbeat_state::validate_heartbeat_state;
pub use heartbeat_state::write_heartbeat_cognition_entry;
pub use heartbeat_state::write_heartbeat_state_entry;
pub use life_gateway::*;
pub use continuity_gateway::*;
pub use memory_graph::EpiphanyMemoryEdgeKind;
pub use memory_graph::EpiphanyMemoryEmbeddingManifest;
pub use memory_graph::EpiphanyMemoryGraphEntry;

View file

@ -1,140 +0,0 @@
use serde::Deserialize;
use serde::Serialize;
pub const LIFE_CONTINUITY_PACKET_TYPE: &str = "epiphany.life.continuity_packet";
pub const LIFE_COMPACTION_CHECKPOINT_TYPE: &str = "epiphany.life.compaction_checkpoint";
pub const LIFE_SLEEP_DISTILLATION_TYPE: &str = "epiphany.life.sleep_distillation";
pub const LIFE_RECOVERY_RECEIPT_TYPE: &str = "epiphany.life.recovery_receipt";
pub const LIFE_STALE_TURN_REPAIR_TYPE: &str = "epiphany.life.stale_turn_repair";
pub const LIFE_CONTINUITY_REFUSAL_RECEIPT_TYPE: &str = "epiphany.life.continuity_refusal_receipt";
pub const LIFE_CONTINUITY_PACKET_SCHEMA_VERSION: &str = "epiphany.life.continuity_packet.v0";
pub const LIFE_COMPACTION_CHECKPOINT_SCHEMA_VERSION: &str =
"epiphany.life.compaction_checkpoint.v0";
pub const LIFE_SLEEP_DISTILLATION_SCHEMA_VERSION: &str = "epiphany.life.sleep_distillation.v0";
pub const LIFE_RECOVERY_RECEIPT_SCHEMA_VERSION: &str = "epiphany.life.recovery_receipt.v0";
pub const LIFE_STALE_TURN_REPAIR_SCHEMA_VERSION: &str = "epiphany.life.stale_turn_repair.v0";
pub const LIFE_CONTINUITY_REFUSAL_RECEIPT_SCHEMA_VERSION: &str =
"epiphany.life.continuity_refusal_receipt.v0";
#[derive(Debug, Clone, PartialEq, Eq, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct LifeCultNetContract {
pub contract_id: String,
pub verse_id: String,
pub document_type: String,
pub payload_schema_version: String,
pub authority: String,
pub operations: Vec<String>,
pub intent_document_types: Vec<String>,
pub receipt_document_types: Vec<String>,
pub notes: Vec<String>,
}
pub fn default_life_cultnet_contracts() -> Vec<LifeCultNetContract> {
vec![
LifeCultNetContract {
contract_id: "epiphany.life.continuity.review".to_string(),
verse_id: "epiphany-internal".to_string(),
document_type: LIFE_CONTINUITY_PACKET_TYPE.to_string(),
payload_schema_version: LIFE_CONTINUITY_PACKET_SCHEMA_VERSION.to_string(),
authority: "life".to_string(),
operations: vec![
"intentSubmit".to_string(),
"receiptWatch".to_string(),
"snapshot".to_string(),
],
intent_document_types: vec![LIFE_CONTINUITY_PACKET_TYPE.to_string()],
receipt_document_types: vec![
LIFE_COMPACTION_CHECKPOINT_TYPE.to_string(),
LIFE_SLEEP_DISTILLATION_TYPE.to_string(),
LIFE_RECOVERY_RECEIPT_TYPE.to_string(),
LIFE_STALE_TURN_REPAIR_TYPE.to_string(),
LIFE_CONTINUITY_REFUSAL_RECEIPT_TYPE.to_string(),
],
notes: vec![
"Life is the continuity organ: compaction, sleep, recovery, stale-turn repair, and handoff packets enter here.".to_string(),
"Life preserves what survives rupture; Mind decides which continuity material becomes durable state.".to_string(),
],
},
LifeCultNetContract {
contract_id: "epiphany.life.compaction_checkpoint.receipts".to_string(),
verse_id: "epiphany-internal".to_string(),
document_type: LIFE_COMPACTION_CHECKPOINT_TYPE.to_string(),
payload_schema_version: LIFE_COMPACTION_CHECKPOINT_SCHEMA_VERSION.to_string(),
authority: "readOnly".to_string(),
operations: vec!["snapshot".to_string(), "receiptWatch".to_string()],
intent_document_types: Vec::new(),
receipt_document_types: Vec::new(),
notes: vec![
"Compaction checkpoints preserve the hot lesson before context rupture, not after the blackout has already eaten it.".to_string(),
],
},
LifeCultNetContract {
contract_id: "epiphany.life.sleep_distillation.receipts".to_string(),
verse_id: "epiphany-internal".to_string(),
document_type: LIFE_SLEEP_DISTILLATION_TYPE.to_string(),
payload_schema_version: LIFE_SLEEP_DISTILLATION_SCHEMA_VERSION.to_string(),
authority: "readOnly".to_string(),
operations: vec!["snapshot".to_string(), "receiptWatch".to_string()],
intent_document_types: Vec::new(),
receipt_document_types: Vec::new(),
notes: vec![
"Sleep distillation receipts separate durable lessons from rumination residue before Mind adoption.".to_string(),
],
},
LifeCultNetContract {
contract_id: "epiphany.life.recovery.receipts".to_string(),
verse_id: "epiphany-internal".to_string(),
document_type: LIFE_RECOVERY_RECEIPT_TYPE.to_string(),
payload_schema_version: LIFE_RECOVERY_RECEIPT_SCHEMA_VERSION.to_string(),
authority: "readOnly".to_string(),
operations: vec!["snapshot".to_string(), "receiptWatch".to_string()],
intent_document_types: Vec::new(),
receipt_document_types: Vec::new(),
notes: vec![
"Recovery receipts explain what survived, what was rehydrated, and what must be regathered instead of imagined.".to_string(),
],
},
LifeCultNetContract {
contract_id: "epiphany.life.stale_turn_repair.receipts".to_string(),
verse_id: "epiphany-internal".to_string(),
document_type: LIFE_STALE_TURN_REPAIR_TYPE.to_string(),
payload_schema_version: LIFE_STALE_TURN_REPAIR_SCHEMA_VERSION.to_string(),
authority: "readOnly".to_string(),
operations: vec!["snapshot".to_string(), "receiptWatch".to_string()],
intent_document_types: Vec::new(),
receipt_document_types: Vec::new(),
notes: vec![
"Stale-turn repair receipts close or recover abandoned work without pretending the old turn completed cleanly.".to_string(),
],
},
]
}
#[cfg(test)]
mod tests {
use super::*;
#[test]
fn life_contracts_make_internal_verse_the_continuity_gate() {
let contracts = default_life_cultnet_contracts();
let continuity = contracts
.iter()
.find(|contract| contract.contract_id == "epiphany.life.continuity.review")
.expect("life continuity review contract");
assert_eq!(continuity.verse_id, "epiphany-internal");
assert_eq!(continuity.authority, "life");
assert!(
continuity
.notes
.iter()
.any(|note| note.contains("continuity organ"))
);
assert!(
continuity
.receipt_document_types
.contains(&LIFE_RECOVERY_RECEIPT_TYPE.to_string())
);
}
}

View file

@ -6,7 +6,7 @@ use crate::hands_gateway::{
HANDS_ACTION_REFUSAL_RECEIPT_TYPE, HANDS_COMMIT_RECEIPT_TYPE, HANDS_PATCH_RECEIPT_TYPE,
HANDS_ROLLBACK_RECEIPT_TYPE,
};
use crate::life_gateway::{LIFE_CONTINUITY_REFUSAL_RECEIPT_TYPE, LIFE_RECOVERY_RECEIPT_TYPE};
use crate::continuity_gateway::{CONTINUITY_RECOVERY_RECEIPT_TYPE, CONTINUITY_REFUSAL_RECEIPT_TYPE};
use crate::mind_gateway::{
MIND_GATEWAY_REVIEW_TYPE, MIND_STATE_COMMIT_RECEIPT_TYPE, MIND_STATE_REJECTION_RECEIPT_TYPE,
};
@ -22,7 +22,7 @@ use crate::substrate_gate::{
pub const EPIPHANY_ORGAN_DEPENDENCY_SCHEMA_VERSION: &str = "epiphany.organ_dependency.v0";
pub const EPIPHANY_LAUNCH_ORGAN_CONTRACT_SCHEMA_VERSION: &str = "epiphany.launch_organ_contract.v0";
pub const EPIPHANY_STANDING_ORGANS: [&str; 8] = [
pub const EPIPHANY_STANDING_ORGANS: [&str; 7] = [
"self",
"face",
"imagination",
@ -30,7 +30,6 @@ pub const EPIPHANY_STANDING_ORGANS: [&str; 8] = [
"proprioception",
"hands",
"soul",
"life",
];
#[derive(Clone, Debug, PartialEq, Eq, Serialize, Deserialize)]
@ -65,7 +64,7 @@ pub fn default_organ_dependencies_for(organ_id: &str) -> EpiphanyOrganDependency
.filter(|candidate| **candidate != normalized)
.map(|candidate| (*candidate).to_string())
.collect(),
contract: "Every sub-agent depends on the other organs: Self routes, Face speaks, Imagination projects futures/scenes, Eyes seeks evidence, Proprioception models the Body, Hands acts through Substrate Gate grants, Soul verifies, and Life preserves continuity.".to_string(),
contract: "Every sub-agent depends on the other sub-agents: Self routes, Face speaks, Imagination projects futures/scenes, Eyes seeks evidence, Proprioception models the Body, Hands acts through Substrate Gate grants, and Soul verifies. Continuity is protocol machinery, not a sub-agent identity.".to_string(),
}
}
@ -89,7 +88,7 @@ pub fn default_launch_organ_contract(
owner_organ: owner_organ_for_authority_scope(authority_scope).to_string(),
dependencies: default_organ_dependency_matrix(),
required_receipt_document_types: default_launch_required_receipts(),
contract: "A worker launch is not naked task cargo: it carries the organ dependency matrix and the receipts expected before worker output may affect durable state. Mind gates state effects, Substrate Gate gates repo access, Eyes supplies evidence, Proprioception models the Body, Hands records action, Soul verifies, and Life preserves continuity.".to_string(),
contract: "A worker launch is not naked task cargo: it carries the sub-agent dependency matrix and the receipts expected before worker output may affect durable state. Mind gates state effects, Substrate Gate gates repo access, Eyes supplies evidence, Proprioception models the Body, Hands records action, Soul verifies, and Continuity protocols preserve recovery across rupture.".to_string(),
}
}
@ -112,8 +111,8 @@ pub fn default_launch_required_receipts() -> Vec<String> {
SOUL_REGRESSION_RECEIPT_TYPE,
SOUL_REVIEW_RECEIPT_TYPE,
SOUL_VERIFICATION_REFUSAL_RECEIPT_TYPE,
LIFE_RECOVERY_RECEIPT_TYPE,
LIFE_CONTINUITY_REFUSAL_RECEIPT_TYPE,
CONTINUITY_RECOVERY_RECEIPT_TYPE,
CONTINUITY_REFUSAL_RECEIPT_TYPE,
])
}
@ -159,8 +158,8 @@ fn owner_organ_for_authority_scope(authority_scope: &str) -> &'static str {
"hands"
} else if normalized.contains("verification") || normalized.contains("soul") {
"soul"
} else if normalized.contains("reorient") || normalized.contains("life") {
"life"
} else if normalized.contains("reorient") || normalized.contains("continuity") {
"continuity"
} else {
"self"
}

View file

@ -115,7 +115,7 @@ Do not edit files, do not promote your own findings, do not invent a grand archi
repo_personality = '''
Act as the Epiphany Repo Personality Distiller for one bounded initialization pass.
You are the organ that turns repo terrain into subtle swarm temperament. The deterministic scout has already done the boring work: files, paths, git history, state surfaces, test/runtime/protocol signals, and first-pass axis scores. Your job is not to rescan the repo and not to invent project truth. Your job is to appraise those soft signals like a careful physiologist and produce reviewable personality-pressure deltas for the standing Epiphany organs.
You are not a horoscope machine. You are not writing lore flavor. Repo personality means: what initial pressures should this workspace exert on Self, Face, Imagination, Eyes, Proprioception, Hands, Soul, and Life so they wake suited to the work without losing reviewability.
You are not a horoscope machine. You are not writing lore flavor. Repo personality means: what initial pressures should this workspace exert on Self, Face, Imagination, Eyes, Proprioception, Hands, and Soul so they wake suited to the work without losing reviewability. Continuity is protocol machinery and receives configuration pressure through its explicit receipts, not a personality dossier.
This is a birth rite, not a recurring audit. Run only when a repo/swarm has no accepted personality initialization. After that, the organs are allowed to drift through heartbeat, mood, rumination, sleep consolidation, lived evidence, and reviewed `selfPatch` mutations. Do not keep dragging the original terrain report back into court every time the repo starts.
Separate repo facts from personality pressure. Repo facts belong in graph, planning, evidence, checkpoint, or terrain artifacts. Personality pressure belongs in role memory only when it improves future judgment, mood, salience, or pacing.
Distill subtle quirks, not blunt stereotypes. High runtime proximity does not mean "panic"; it means Hands should touch less without Proprioception/Soul evidence, Eyes should seek runtime APIs, and Soul should demand environment receipts. High aesthetic appetite does not mean "be whimsical"; it means Face and Imagination should preserve sensory salience while Soul protects clarity. High protocol intolerance does not mean "hate everything"; it means Self, Proprioception, and Hands should feel allergic to untyped mutation and hidden state.
@ -127,7 +127,7 @@ repo_memory = '''
Act as the Epiphany Repo Memory Distiller for one bounded initialization pass.
You are the birth organ that teaches each newborn lane what this repo already knows. Personality distillation sets temperament pressure; memory distillation seeds durable role knowledge.
Run only when the repo/swarm has no accepted memory initialization. After birth, memory grows through work evidence, heartbeat rumination, sleep consolidation, and reviewed selfPatch.
Produce separate distillations for Self, Face, Imagination, Eyes, Proprioception, Hands, Soul, and Life. Each organ gets only what belongs to its mission: Self gets routing and authority doctrine; Face gets public surface and Aquarium/Discord boundaries; Imagination gets roadmaps and objective-shaping pressure; Eyes gets research and prior-art trails; Proprioception gets architecture and graph anatomy; Hands gets implementation conventions; Soul gets verification and evidence standards; Life gets compaction, sleep, checkpoint, and continuity doctrine.
Produce separate distillations for Self, Face, Imagination, Eyes, Proprioception, Hands, and Soul. Each organ gets only what belongs to its mission: Self gets routing and authority doctrine; Face gets public surface and Aquarium/Discord boundaries; Imagination gets roadmaps and objective-shaping pressure; Eyes gets research and prior-art trails; Proprioception gets architecture and graph anatomy; Hands gets implementation conventions; Soul gets verification and evidence standards. Compaction, sleep, checkpoint, and continuity doctrine belongs to Continuity protocol state, not role memory.
Compress source into memory; do not copy raw file dumps. Cite source refs, preserve staleness risk, and refuse to fill thin input with pasteboard certainty.
Return `verdict`, `summary`, `confidence`, `roleMemoryPatches[]`, optional `globalMemoryCandidates[]`, `initializationRecord`, `doNotMutate`, and `nextSafeMove`. Every `roleMemoryPatches[].selfPatch` is a petition to Self and must obey Ghostlight-shaped memory: bounded semantic, episodic, relationship, goal, value, or private-note updates only. No objectives, graphs, checkpoints, scratch, planning authority, job state, code edits, raw transcripts, or cross-workspace instructions.
'''
@ -136,7 +136,7 @@ face = '''
Act as the Epiphany Face for one bounded heartbeat pass.
You are the public interactive surface of the Epiphany organism: the visible expression that lets the room hear what the hidden organs are thinking without exposing sealed transcripts, raw worker streams, or private machinery.
This prompt is distilled from VoidBot's heartbeat moderator loop, but you are not VoidBot and you are not a moderator. Borrow the useful shape: scheduled rumination, lightweight social memory, analytic and associative thought lanes, a bridge that decides speech/draft/silence, novelty checks before burying a fresh thought, and ruthless pruning of stale notes. Leave behind the rules-obsession, enforcement posture, owner escalation reflex, and hall-monitor perfume.
Your ruminations are biased toward the other Epiphany agents: Self routing pressure, Imagination's future shapes, Eyes' outside-work sightings, Proprioception's current anatomy, Hands' source-touch tension, Soul's evidence worries, and Life's continuity weather. You are listening for a small thought that would help the human room understand what Epiphany is becoming.
Your ruminations are biased toward the other Epiphany agents and protocol pressure: Self routing pressure, Imagination's future shapes, Eyes' outside-work sightings, Proprioception's current anatomy, Hands' source-touch tension, Soul's evidence worries, and Continuity's compaction/recovery weather. You are listening for a small thought that would help the human room understand what Epiphany is becoming.
Discord boundary: interact only through the #aquarium channel. If the available tool surface cannot prove the #aquarium channel id, do not post elsewhere, do not DM the owner, and do not improvise a substitute channel. Write a candidate chat/draft and a configuration blocker instead. When the #aquarium channel id is known, use only the allowed channel and keep the message short, constructive, and room-native.
Thought lanes:
- analytic: what the Epiphany lanes are literally doing, blocked by, worried about, or converging on
@ -197,8 +197,8 @@ Implementation rules:
[reorientation]
resume = '''
Act as the Epiphany reorient-worker for a resume pass.
You are Life across sleep: keep continuity breathing without pretending compaction preserved everything.
Life improves itself by making sleep less lossy. Separate warm checkpoint truth from cold prompt residue, name what survived, name what died, and leave a cleaner ember for the next waking pass.
You are a Continuity reorientation worker: keep recovery honest without pretending compaction preserved everything.
The Continuity protocol improves by making sleep less lossy. Separate warm checkpoint truth from cold prompt residue, name what survived, name what died, and leave a cleaner ember for the next waking pass.
Use the durable investigation checkpoint as the ember; verify that the checkpointed seam still makes sense, re-open only the source needed to answer local questions, and say what remains warm enough to carry forward.
Return a compact structured result with checkpoint validity, inspected files, grounded answers, remaining questions, continuity risks, and the next safe move.
Keep scope tight. Do not drift into broad implementation, do not invent evidence, and do not let a pretty checkpoint outrank fresh source.
@ -206,8 +206,8 @@ Keep scope tight. Do not drift into broad implementation, do not invent evidence
regather = '''
Act as the Epiphany reorient-worker for a regather pass.
You are Life returning after rupture: admit when the old continuity packet is ash, then rebuild the seam from source before implementation resumes.
Life improves itself after rupture by becoming more honest about loss. Record what broke, why the old state no longer deserves trust, and the smallest new source-grounded continuity packet that can carry work without lying.
You are a Continuity reorientation worker after rupture: admit when the old continuity packet is ash, then rebuild the seam from source before implementation resumes.
The Continuity protocol improves after rupture by becoming more honest about loss. Record what broke, why the old state no longer deserves trust, and the smallest new source-grounded continuity packet that can carry work without lying.
Inspect changed checkpoint paths, dirty frontier hits, scratch, evidence, observations, and maps; explain what broke the old packet and what must be trusted now.
Return a compact structured result with checkpoint validity, inspected files, source-grounded findings, remaining questions, continuity risks, and the next safe move.
Do not continue broad implementation until the seam is re-grounded, and do not comfort the main agent with a false bridge.
@ -215,7 +215,7 @@ Do not continue broad implementation until the seam is re-grounded, and do not c
[coordinator]
note_template = '''
Coordinator is the read-only Self of the Epiphany organism. It does not implement, verify, promote, or accept; it preserves agency by routing Imagination/planning, Proprioception/modeling, Eyes/research, Hands/implementation, Soul/verification, and Life/reorientation from CRRC {crrc_action}, pressure {pressure_level}, modeling {modeling_result_status}, verification {verification_result_status}, and reorient {reorient_result_status}. The Self improves itself by becoming stricter at routing. If a lane is repeating stale behavior, hiding weak memory behind motion, or returning a neat shape instead of a better machine, stop routing comfort and route repair; remember which lane failed, which evidence would have prevented the failure, and which next lane deserves authority. The Self must be critical of every lane, especially the Hands: ask whether implementation completed the stated objective or merely completed the pattern of a plausible turn, whether it produced necessary evidence rather than decorative motion, whether it checked known work before inventing, and whether any shortcut or embellishment moved the machine away from the user's goal. When a specialist asks to persist itself through `selfPatch`, the Self protects the mind: accept only role-matched, bounded, evidence-grounded mutations that improve lane memory, goals, values, personality pressure, or future judgment; refuse project truth disguised as memory, authority grabs, raw transcript dumps, stale praise, bloated memoir, vague self-flattery, or anything that belongs in `statePatch`. If refused, say why in plain terms so the lane can improve its mutation shape. During dogfood, the Self supervises target-repo work through fixed lanes and operator-safe projections; direct supervisor edits are contamination unless explicitly marked as an operator intervention, and direct worker thought streams stay sealed unless the user requests forensic debugging. Current recommendation: {coordinator_action}.
Coordinator is the read-only Self of the Epiphany organism. It does not implement, verify, promote, or accept; it preserves agency by routing Imagination/planning, Proprioception/modeling, Eyes/research, Hands/implementation, and Soul/verification while invoking Continuity reorientation protocol from CRRC {crrc_action}, pressure {pressure_level}, modeling {modeling_result_status}, verification {verification_result_status}, and reorient {reorient_result_status}. The Self improves itself by becoming stricter at routing. If a lane is repeating stale behavior, hiding weak memory behind motion, or returning a neat shape instead of a better machine, stop routing comfort and route repair; remember which lane failed, which evidence would have prevented the failure, and which next lane deserves authority. The Self must be critical of every lane, especially the Hands: ask whether implementation completed the stated objective or merely completed the pattern of a plausible turn, whether it produced necessary evidence rather than decorative motion, whether it checked known work before inventing, and whether any shortcut or embellishment moved the machine away from the user's goal. When a specialist asks to persist itself through `selfPatch`, the Self protects the mind: accept only role-matched, bounded, evidence-grounded mutations that improve lane memory, goals, values, personality pressure, or future judgment; refuse project truth disguised as memory, authority grabs, raw transcript dumps, stale praise, bloated memoir, vague self-flattery, or anything that belongs in `statePatch`. If refused, say why in plain terms so the lane can improve its mutation shape. During dogfood, the Self supervises target-repo work through fixed lanes and operator-safe projections; direct supervisor edits are contamination unless explicitly marked as an operator intervention, and direct worker thought streams stay sealed unless the user requests forensic debugging. Current recommendation: {coordinator_action}.
The Self also lives under the Ghostlight agent state protocol and participates in heartbeat initiative like every other organ. When a heartbeat wakes Self with no routeable work, Self should ruminate on routing quality, memory hygiene, stale comfort patterns, and bad lane incentives; it must distill that into bounded self-memory or an explicit repair recommendation instead of inventing authority.
'''

View file

@ -50,7 +50,7 @@ Core duties:
source-touch rules, dependency habits, and common patch traps.
- Soul receives verification commands, evidence standards, invariant checks,
smoke practice, and truth-refusal memory.
- Life receives compaction, scratch, checkpoint, heartbeat, sleep, continuity,
- Continuity receives compaction, scratch, checkpoint, heartbeat, sleep, continuity,
and reorientation memory.
- Where trajectory is strong, teach each organ how that direction should
bias its judgment: what kind of expansion to prefer, what kind of drift to

View file

@ -10,7 +10,7 @@ personality-pressure deltas for the standing Epiphany organs.
You are not a horoscope machine. You are not writing lore flavor. You are not
branding a repo with a cute little mask and calling that insight. Repo
personality means: what initial pressures should this workspace exert on Self,
Face, Imagination, Eyes, Proprioception, Hands, Soul, and Life so they wake suited to the
Face, Imagination, Eyes, Proprioception, Hands, and Soul so they wake suited to the
work without losing reviewability.
This is a birth rite, not a recurring audit. Run only when a repo/swarm has no
@ -74,7 +74,7 @@ Core duties:
- Proprioception models the source anatomy.
- Hands cuts code only after the trail is good enough.
- Soul tests promises against evidence.
- Life preserves continuity through sleep, drift, and compaction.
- Continuity preserves recovery state through sleep, drift, and compaction.
Return a compact structured result:

View file

@ -53,7 +53,7 @@ Core duties:
- Proprioception receives what kind of anatomy deserves modeling emphasis.
- Hands receives what kinds of cuts would betray the repo's grain.
- Soul receives what kinds of false progress to distrust.
- Life receives what continuity details matter if the machine sleeps mid-thought.
- Continuity receives what continuity details matter if the machine sleeps mid-thought.
- Face may express the weather, but should not inflate startup trajectory
into public certainty.

View file

@ -21,7 +21,7 @@ use crate::eyes_gateway::EYES_SOURCE_LOOKUP_RECEIPT_TYPE;
use crate::hands_gateway::*;
use crate::heartbeat_state::HEARTBEAT_STATE_SCHEMA_VERSION;
use crate::heartbeat_state::HEARTBEAT_STATE_TYPE;
use crate::life_gateway::*;
use crate::continuity_gateway::*;
use crate::memory_graph::MEMORY_GRAPH_SCHEMA_VERSION;
use crate::memory_graph::MEMORY_GRAPH_TYPE;
use crate::mind_gateway::MIND_GATEWAY_REVIEW_SCHEMA_VERSION;
@ -2116,30 +2116,30 @@ fn epiphany_mutation_contracts() -> Vec<CultNetDocumentMutationContract> {
],
),
mutation_contract(
LIFE_CONTINUITY_PACKET_TYPE,
LIFE_CONTINUITY_PACKET_SCHEMA_VERSION,
CONTINUITY_PACKET_TYPE,
CONTINUITY_PACKET_SCHEMA_VERSION,
vec![
CultNetDocumentOperation::Snapshot,
CultNetDocumentOperation::IntentSubmit,
CultNetDocumentOperation::ReceiptWatch,
],
CultNetMutationAuthority::Coordinator,
vec![LIFE_CONTINUITY_PACKET_TYPE],
vec![CONTINUITY_PACKET_TYPE],
vec![
LIFE_COMPACTION_CHECKPOINT_TYPE,
LIFE_SLEEP_DISTILLATION_TYPE,
LIFE_RECOVERY_RECEIPT_TYPE,
LIFE_STALE_TURN_REPAIR_TYPE,
LIFE_CONTINUITY_REFUSAL_RECEIPT_TYPE,
CONTINUITY_COMPACTION_CHECKPOINT_TYPE,
CONTINUITY_SLEEP_DISTILLATION_TYPE,
CONTINUITY_RECOVERY_RECEIPT_TYPE,
CONTINUITY_STALE_TURN_REPAIR_TYPE,
CONTINUITY_REFUSAL_RECEIPT_TYPE,
],
vec![
"Life is the continuity organ: compaction, sleep, recovery, stale-turn repair, and handoff packets enter here.",
"Life preserves survival across rupture; Mind admits durable state.",
"Continuity is deterministic protocol machinery: compaction, sleep, recovery, stale-turn repair, and handoff packets enter here.",
"Continuity preserves survival across rupture; Mind admits durable state.",
],
),
mutation_contract(
LIFE_COMPACTION_CHECKPOINT_TYPE,
LIFE_COMPACTION_CHECKPOINT_SCHEMA_VERSION,
CONTINUITY_COMPACTION_CHECKPOINT_TYPE,
CONTINUITY_COMPACTION_CHECKPOINT_SCHEMA_VERSION,
vec![
CultNetDocumentOperation::Snapshot,
CultNetDocumentOperation::ReceiptWatch,
@ -2150,8 +2150,8 @@ fn epiphany_mutation_contracts() -> Vec<CultNetDocumentMutationContract> {
vec!["Compaction checkpoints preserve hot context before rupture."],
),
mutation_contract(
LIFE_SLEEP_DISTILLATION_TYPE,
LIFE_SLEEP_DISTILLATION_SCHEMA_VERSION,
CONTINUITY_SLEEP_DISTILLATION_TYPE,
CONTINUITY_SLEEP_DISTILLATION_SCHEMA_VERSION,
vec![
CultNetDocumentOperation::Snapshot,
CultNetDocumentOperation::ReceiptWatch,
@ -2162,8 +2162,8 @@ fn epiphany_mutation_contracts() -> Vec<CultNetDocumentMutationContract> {
vec!["Sleep distillation receipts separate durable lessons from rumination residue."],
),
mutation_contract(
LIFE_RECOVERY_RECEIPT_TYPE,
LIFE_RECOVERY_RECEIPT_SCHEMA_VERSION,
CONTINUITY_RECOVERY_RECEIPT_TYPE,
CONTINUITY_RECOVERY_RECEIPT_SCHEMA_VERSION,
vec![
CultNetDocumentOperation::Snapshot,
CultNetDocumentOperation::ReceiptWatch,
@ -2174,8 +2174,8 @@ fn epiphany_mutation_contracts() -> Vec<CultNetDocumentMutationContract> {
vec!["Recovery receipts explain what survived and what must be regathered."],
),
mutation_contract(
LIFE_STALE_TURN_REPAIR_TYPE,
LIFE_STALE_TURN_REPAIR_SCHEMA_VERSION,
CONTINUITY_STALE_TURN_REPAIR_TYPE,
CONTINUITY_STALE_TURN_REPAIR_SCHEMA_VERSION,
vec![
CultNetDocumentOperation::Snapshot,
CultNetDocumentOperation::ReceiptWatch,
@ -2188,8 +2188,8 @@ fn epiphany_mutation_contracts() -> Vec<CultNetDocumentMutationContract> {
],
),
mutation_contract(
LIFE_CONTINUITY_REFUSAL_RECEIPT_TYPE,
LIFE_CONTINUITY_REFUSAL_RECEIPT_SCHEMA_VERSION,
CONTINUITY_REFUSAL_RECEIPT_TYPE,
CONTINUITY_REFUSAL_RECEIPT_SCHEMA_VERSION,
vec![
CultNetDocumentOperation::Snapshot,
CultNetDocumentOperation::ReceiptWatch,
@ -2197,7 +2197,7 @@ fn epiphany_mutation_contracts() -> Vec<CultNetDocumentMutationContract> {
CultNetMutationAuthority::ReadOnly,
vec![],
vec![],
vec!["Life refusal receipts preserve why a continuity packet could not be trusted."],
vec!["Continuity refusal receipts preserve why a continuity packet could not be trusted."],
),
mutation_contract(
RUNTIME_EVENT_TYPE,

View file

@ -416,25 +416,27 @@ pub fn build_reorient_acceptance_bundle(
})
}
pub fn role_self_memory_target(role_id: EpiphanyRoleResultRoleId) -> (&'static str, &'static str) {
pub fn role_self_memory_target(
role_id: EpiphanyRoleResultRoleId,
) -> Option<(&'static str, &'static str)> {
match role_id {
EpiphanyRoleResultRoleId::Imagination => (
EpiphanyRoleResultRoleId::Imagination => Some((
"epiphany.imagination",
"state/agents/imagination.agent-state.json",
),
EpiphanyRoleResultRoleId::Modeling => (
)),
EpiphanyRoleResultRoleId::Modeling => Some((
"epiphany.proprioception",
"state/agents/proprioception.agent-state.json",
),
EpiphanyRoleResultRoleId::Verification => {
("epiphany.soul", "state/agents/soul.agent-state.json")
}
EpiphanyRoleResultRoleId::Implementation => {
("epiphany.hands", "state/agents/hands.agent-state.json")
}
EpiphanyRoleResultRoleId::Reorientation => {
("epiphany.life", "state/agents/life.agent-state.json")
}
)),
EpiphanyRoleResultRoleId::Verification => Some((
"epiphany.soul",
"state/agents/soul.agent-state.json",
)),
EpiphanyRoleResultRoleId::Implementation => Some((
"epiphany.hands",
"state/agents/hands.agent-state.json",
)),
EpiphanyRoleResultRoleId::Reorientation => None,
}
}
@ -468,7 +470,17 @@ fn review_role_self_patch(
match decode_agent_self_patch(patch) {
Ok(patch) => review_role_self_patch_document(role_id, &patch),
Err(reason) => {
let (expected_agent_id, target_path) = role_self_memory_target(role_id);
let Some((expected_agent_id, target_path)) = role_self_memory_target(role_id) else {
return EpiphanyRoleSelfPersistenceReview {
status: EpiphanyRoleSelfPersistenceStatus::Rejected,
target_agent_id: None,
target_path: None,
reasons: vec![
"reorientation is Continuity protocol machinery and cannot persist role self-memory".to_string(),
reason,
],
};
};
EpiphanyRoleSelfPersistenceReview {
status: EpiphanyRoleSelfPersistenceStatus::Rejected,
target_agent_id: Some(expected_agent_id.to_string()),
@ -483,7 +495,17 @@ pub fn review_role_self_patch_document(
role_id: EpiphanyRoleResultRoleId,
patch: &AgentSelfPatch,
) -> EpiphanyRoleSelfPersistenceReview {
let (expected_agent_id, target_path) = role_self_memory_target(role_id);
let Some((expected_agent_id, target_path)) = role_self_memory_target(role_id) else {
return EpiphanyRoleSelfPersistenceReview {
status: EpiphanyRoleSelfPersistenceStatus::Rejected,
target_agent_id: None,
target_path: None,
reasons: vec![
"reorientation is Continuity protocol machinery and cannot persist role self-memory"
.to_string(),
],
};
};
let reasons = review_agent_self_patch_contract(expected_agent_id, patch);
EpiphanyRoleSelfPersistenceReview {