Skip to content

Sonny: zen, one focus with an agent, the rest held back - #478

Merged
lydakis merged 10 commits into
mainfrom
claude/project-thread-v68zd8
Oct 31, 2026
Merged

lydakis merged 10 commits into
mainfrom
claude/project-thread-v68zd8

Conversation

@lydakis

@lydakis lydakis commented Oct 31, 2026 •

Copy link
Copy Markdown
Owner

George asked for zen to be a behaviour, not only a view. You turn it on for a lead or any agent with one subject. The agent still hears the other threads but talks only about that subject, and the window shows only text. The agent can ask you to leave zen when something elsewhere really matters. The pattern is Apple's Focus: some things are held back, one way through, and a summary afterwards.

What it does

  • Starting and ending zen.
    • /zen FOCUS goes to the agent exactly as typed, the way /goal WHAT does. Writing /zen again, or /zen off, ends it.
    • As with a goal, the focus is the agent's to read. A scribble is enough: the agent reads it with what it knows, says in one line what it takes the focus to be, and runs sonny zen READING to put the focus in its own words. The footer then shows those words.
    • The person can also just ask in words ("let's go into zen on the receipts", "let's leave zen"). The agent runs sonny zen … or sonny zen off itself, but only on the person's own word.
  • The zen skill is installed for every agent, like plan, and carries the behaviour:
    • The agent talks about the focus alone. It still reads and handles everything else that reaches it, says nothing about it, and keeps track of what it held back.
    • It interrupts only with its ask tool, for something that blocks the person's work, can't be undone, or loses its chance soon.
    • It learns the person's bar for interruptions from memory, so no triggers are written down (memory over codified behaviour).
    • Only the person ends zen. When zen ends, the agent gives a "while you were focused" digest: what needs the person first, then what it handled.
  • The view while zen is on is all Sonny-side:
    • Only turns the person started are drawn, plus the agent's ask questions. A turn counts as the person's when any message in it is theirs, steers included, across page boundaries.
    • Turns something else started run unseen: no words, no status row, no "Worked" line, no chime (the fleet chimes only for the lead's own question). A hidden reply never becomes what reply, copy or react point at, and entering or leaving zen rebuilds those targets from what the view draws.
    • No calls, folds, rosters, plans, notes, denials or welcome are drawn, and Sonny makes no guess at the next message. The status row says "Working", never the command.
    • The conversation's 100 columns sit in the middle of a wider window, with the margin hidden.
    • The footer shows only zen · FOCUS and ? N needs you.
  • State lives in ~/.agent/sonny/zen/KEY, where KEY is reactions::key: the canonical store plus the agent's durable id.
    • An agent of the same name in another store, or one made again under that name, doesn't inherit the focus.
    • Every window of the agent picks up a change at the next turn's start or end.
  • Commons invites go to another agent, never to one in zen.
  • No daemon change.

Screenshots

Dark (Flexoki Dark), 160 columns. The task update and the agent's "Held: …" reply in that turn are not drawn.

zen wide

Light (GitHub Light), 96 columns: narrower than the column, so nothing is centred.

zen narrow light

NO_COLOR, 160 columns: the marks carry the meaning, and the composer gets a rule instead of its band.

zen no colour

Design pass

Zen has its own section in the design system: Sonny's Design System, "Zen". It records the decisions, has five screenshots, and shows how each rule of the visual and interface systems applies.

  • Colour. No new colours. The ? is the existing "needs you" yellow, and under NO_COLOR the words carry the meaning.
  • Footer. It keeps the normal footer's 2-column indent and right edge. The "where" slot holds the focus.
  • Column. It is symmetric: 30/100/30 at 160 columns.
  • Fixes from the pass:
    • The status row now says "Working" instead of naming the command.
    • The words follow the hint grammar.
    • The welcome isn't drawn in zen.
    • Sonny makes no next-message guess in zen, because that guess reads everything held back.

Tests

  • 13 new tests:
    • What zen draws from history and live.
    • Page boundaries and steers.
    • Zen set from another window, or by the agent and picked up at the turn's end.
    • Reply targets rebuilt.
    • /zen sent as typed.
    • The footer.
    • Centring.
    • No welcome and no guess.
    • The keyed zen file.
  • cargo test -p sonny: 692 passed, after merging main. Clippy and fmt are clean.

FEATURES.md has a new experimental row, and the README has a paragraph and a screenshot.

🤖 Generated with Claude Code

/zen FOCUS goes to the agent as typed; a zen skill says how to talk about
the focus alone, hold back what else reaches it, interrupt only with a
question whose bar it learns from memory, and say what it held on /zen off.
While on, the window draws only the person's turns and the agent's
questions, centred, with a footer of the focus and what needs the person.
The commons invites another agent than one in zen.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_013jkdGFkQq3pPYLZ4zuZ4z1
@lydakis lydakis self-assigned this Oct 31, 2026
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 31, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-31T06:24:16.442549Z c35e661 New commits
🔒 Security Review ✅ Completed 2026-10-31T06:24:49.384708Z c35e661 New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 8747d6d962

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread sonny/src/main.rs Resolved
Comment thread sonny/src/main.rs Resolved
…r windows take zen up

In zen, a history page whose first turn's message is on an older page
reads that turn's prompt to know whether the person started it. Every
window of the agent reads its zen again at each turn, so zen set or left in
one window reaches the others with the message that set it.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_013jkdGFkQq3pPYLZ4zuZ4z1

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b80c4c88d4

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread sonny/src/main.rs Resolved
Comment thread sonny/src/main.rs Resolved
Comment thread sonny/src/main.rs Resolved
…'s steer keeps a split turn theirs

While the lead is in zen only its own questions ring; a reply drawn out of
sight no longer becomes what reply, copy or react point at; and a page that
starts inside a turn counts it as the person's when any of its prompts is
theirs.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_013jkdGFkQq3pPYLZ4zuZ4z1
The /zen description and the notice say /zen ends it, as the other
commands' words do.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_013jkdGFkQq3pPYLZ4zuZ4z1

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 465bb007ec

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread sonny/src/main.rs Resolved
Checked against the interface system: zen draws only what is said, so the
welcome is left out, and the guess at the person's next message is not
made, since it reads everything the agent holds back. Screenshots retaken.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_013jkdGFkQq3pPYLZ4zuZ4z1

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 67619c8a80

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread sonny/src/zen.rs Resolved
The agent reads what follows /zen with what it knows, as it reads a goal,
and writes the focus in its own words to the agent's zen file; the person
may also ask for zen in words, and the agent turns it on or off itself.
Every window takes the file up at the turn's end as well, telling zen
started or ended, and the footer shows the agent's words.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_013jkdGFkQq3pPYLZ4zuZ4z1
Zen is kept under the key reactions and the margin use, the store and the
agent's durable id, so an agent of the same name in another store, or one
made again under the name, does not take it up; the agent sets its own
with `sonny zen`, which finds its key from its turn's environment, and
the commons looks invitees up by the same key. Entering or leaving zen
clears what reply, copy and react point at, found again in what the view
draws.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_013jkdGFkQq3pPYLZ4zuZ4z1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants