Persona live organ: one-turn, drain, wake-humans-pace, turn memory (squash of hands/persona-live-drain) #83

Merged
eureka merged 287 commits from hands/persona-live-drain into main 2026-11-28 07:05:45 +00:00
2 changed files with 19 additions and 5 deletions
Showing only changes of commit ac59e002e5 - Show all commits

K18 fix-up: a note to Self runs the echo check (Soul at 0cfc386)

- `suggest` refuses an echo as `say` and `amend` do, before the one-a-turn and
  private checks, whatever the note's kind. Soul's probe filed Nibu's line,
  refused as an echo when said, as her `idea` note.
- A feedback note that passes someone's words on verbatim is refused too: Q-E is
  unanswered, so option A (the echo refusal applies) holds for notes as well. A
  note in her own words is left as before.
- The K18 assertion that an echo-refused line's draft could be a feedback note
  is gone; a refused act still leaves its draft free (the amend case stays).

Verification: the echo draft as an idea note and as a feedback note about Nibu
is refused (say: echo, suggest: echo) and no note is left; a note in her own
words is left.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Meta Vens 2026-11-20 17:19:25 +01:00

View file

@ -492,8 +492,8 @@ pub(crate) fn decide(model: &dyn Model, request_id: &str, packet: &Packet, narra
(reason, _) => refusals.push(refused(Act::Amend, Some(draft), None, reason.unwrap_or(Refusal::NotAmendable))),
}
}
// A note to Self (map 16.18): one whole draft, at most one a turn, refused when the Interpreter judges it carries
// something private. It is recorded in the turn's record and nowhere else; nothing here writes her Mind.
// A note to Self (map 16.18): one whole draft, at most one a turn, refused as an echo as a line is, and when the
// Interpreter judges it carries something private. It is recorded in the turn's record and nowhere else; nothing here writes her Mind.
let mut suggestions: Vec<Value> = Vec::new();
for proposed in parsed.suggest {
let Some(draft) = proposed.draft.and_then(|n| found.numbered(n)) else {
@ -502,6 +502,8 @@ pub(crate) fn decide(model: &dyn Model, request_id: &str, packet: &Packet, narra
};
let reason = if used.contains(&draft.n) {
Some(Refusal::Used)
} else if echo(&draft.text, &packet.bodies) {
Some(Refusal::Echo)
} else if !suggestions.is_empty() {
Some(Refusal::SecondNote)
} else if proposed.private != Some(false) {

View file

@ -594,9 +594,21 @@ fn k18_a_refused_act_does_not_use_up_its_draft_and_is_told() {
assert_eq!((refusals(&decision), decision["suggestions"][0]["text"].as_str()), (vec![("amend".to_owned(), "not_amendable".to_owned())], Some("Couldn't send it after all.")), "{decision}");
let told = crate::projection::outcome::outcome_of(&json!({ "interpreter": decision, "posted": [] })).unwrap().lines(packet().forms);
assert!(told.iter().any(|line| line.starts_with("- Nothing changed, and nothing reached #minds:gamecult.org:")) && told.iter().any(|line| line.starts_with("- He left Self a note:")), "{told:?}");
// An echo-refused line leaves its draft free for a note too.
let echoed = answered(&packet(), "<typed>The economy is still the least-built part!</typed>", json!({ "say": [{ "draft": 1 }], "gaps": [], "suggest": [{ "kind": "feedback", "draft": 1, "about": NIBU, "private": false }] }));
assert_eq!((refusals(&echoed), echoed["suggestions"].as_array().unwrap().len()), (vec![("say".to_owned(), "echo".to_owned())], 1), "{echoed}");
}
/// Soul's probe at 0cfc386: a draft refused as an echo was then left as her idea note. A note runs the echo check as a
/// line and an addition do, whatever its kind.
#[test]
fn an_echo_is_no_note_either() {
let echo = "v0.2.0 is tagged and the economy is still the least built part. I think this looks okay to ship.";
for kind in ["idea", "feedback"] {
let about = if kind == "feedback" { json!(NIBU) } else { Value::Null };
let decision = answered(&packet(), &format!("<typed>{echo}</typed>"), json!({ "say": [{ "draft": 1 }], "gaps": [], "suggest": [{ "kind": kind, "draft": 1, "about": about, "private": false }] }));
assert_eq!((refusals(&decision), decision["suggestions"].as_array().unwrap().len()), (vec![("say".to_owned(), "echo".to_owned()), ("suggest".to_owned(), "echo".to_owned())], 0), "{kind}: {decision}");
}
// A note of her own words is still left.
let own = answered(&packet(), "<typed>The economy wants a pass before we ship.</typed>", json!({ "say": [], "gaps": [], "suggest": [{ "kind": "idea", "draft": 1, "about": null, "private": false }] }));
assert_eq!(own["suggestions"].as_array().unwrap().len(), 1, "{own}");
}
#[test]