Skip to content

Lookout keeps to its job: remove goals, and keep a lead's task reactions where the call lands - #782

Merged
lydakis merged 6 commits into
mainfrom
claude/project-thread-ybzpqh
Nov 7, 2026
Merged

lydakis merged 6 commits into
mainfrom
claude/project-thread-ybzpqh

Conversation

@lydakis

@lydakis lydakis commented Nov 7, 2026 •

Copy link
Copy Markdown
Owner

Summary

This PR comes from an audit of what the lookout does. George's rule (11-07): the lookout exists for what agents need while no window is open. Anything only the window needs lives with the window and must not burden the lookout or the daemon. This PR moves out the two jobs on main that broke that rule. Fork snapshots, the third, go in #780.

1. Goals removed (commit 1)

George asked for goals to be removed entirely ("I've never used /goal. That's something we can wholesale remove."). The goal check runner was the biggest job in the lookout that wasn't watching and telling: it ran a command for up to an hour as the person, then queued the agent another turn.

What goes:

  • The goal tool (Sonny's served tools, its gate entry and its tests) and /goal in the window.
  • sonny/src/lookout/goals.rs. In the lookout, its event hook, the settlement channel, the replay floor it held, and its file reread. In task updates, the hold on a goal's turns (goaled, GOAL_HOLD, goal_turn / goal_checking / goal_pending / goal_settled), the goal field on turn lines and on turn.ended events, and the goal filter field.
  • The checking and checked task states in the roster and /status, and the screenshot of them.
  • The sky's goal pulse ("keeps at its goal").
  • The process budget's quarter for checks. sonny.tool_processes now belongs to the tool host alone (four times the CPUs by default, as before).
  • The docs: SONNY.md "Goals", the README lines, LOOKOUT.md's goal rows, the SECURITY.md goal-check rows, and the zen skill's /goal mention.

Migration: lookout-goals-gone removes STORE.lookout/goals once per store, recorded in STORE.migrated (retires 0.11.0).

2. A lead's reactions in a task (commit 2)

A lead reacts in one of its tasks by passing react a bot. Until now, the lookout followed every bot's newest message to work out which of the person's words a reaction landed on. It then wrote the task's Picked file for the window to draw. George's framing: a reaction is a fact the model sends, so it is stored where the tool call lands, and the window only displays it.

  • react is now answered by Sonny's tool host (answered_by: sonny), like ask and margin already are. A call with no bot gets "Done." at once. A call naming another agent of the same project is recorded under the person's newest message there while the call is answered (reactions::answer). Any other call is refused (react_refused), so the model hears that it landed nowhere instead of being told "Done.".
  • The lookout drops its reaction tracking (reacting, taken, picked, reacted, project, newest_said). Nothing watches the event stream for reactions anymore.
  • react is not in GATED, so it never waits for an approval.
  • Cost: a reaction now makes one local round trip to the tool host instead of getting a fixed result. In exchange, the lookout no longer reads every event of every bot to track reactions.

The lead, task and superlead profiles are unchanged.

Testing

  • cargo test --workspace: all passed (sonny: 1121 passed, 0 failed).
  • cargo clippy --workspace --all-targets -- -D warnings and cargo fmt --all are clean.
  • New tests: the_goals_folder_goes_once_and_subscriptions_stay, and a_reaction_naming_another_agent_lands_on_the_person_s_newest_words_in_its_project. The second runs against a fake daemon and covers the same project, a nested project, self, another project, and the answer's Done/refused.
  • Removed tests/test_served.py's goal tests along with the feature.

Overlap: #780 (fork snapshots) and #777 (wait-held news) also touch lookout/mod.rs and updates.rs. Whichever of them merges second gets rebased.

🤖 Generated with Claude Code

George never used goals, and their check runner made the lookout run
work (a command for up to an hour, then another turn for the agent)
rather than only watch and tell. Gone with them: the `checking` and
`checked` task states, the lookout's hold on a goal's turns, the sky's
goal pulse, and the tool process budget's quarter for checks, so the
tool host now has all of `sonny.tool_processes`. A one-time migration
removes STORE.lookout/goals (retires 0.11.0).

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

chatgpt-codex-connector Bot commented Nov 7, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

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

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-07T07:29:21.794436Z b0a1fc0 New commits
🔒 Security Review ✅ Completed 2026-11-07T06:29:33.674394Z 34f2990 PR opened
ℹ️ 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.

A lead reacting in one of its tasks named the task, and the lookout
followed every bot's newest message to find which of the person's words
it landed on, then wrote the task's Picked file. That is work only the
window needs, done by the companion that exists for agents while no
window is open.

Sonny's tool host now answers `react`: one naming another agent of the
same project is kept under the person's newest message there as the call
is answered; one on the caller's own messages is answered at once. The
lookout drops its reaction tracking, and nothing watches the stream for
reactions.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_013jkdGGYoqceB21grsa5Q3v
@lydakis lydakis changed the title Remove goals: the goal tool, /goal, and the lookout's check runner Lookout keeps to its job: remove goals, and keep a lead's task reactions where the call lands Nov 7, 2026

@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: 7050c25dd9

ℹ️ 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/reactions.rs Resolved
Comment thread sonny/src/served.rs Resolved
Comment thread sonny/src/reactions.rs Resolved
… refresh

The tool host answered react by spawning a `sonny tool` process like any
other served call, behind the process budget. Now it answers it in its own
process, as it takes the call: a reaction on the caller's own messages is
"Done." with no process, one naming a task lands on what the person had
written when it was taken, and those that write the task's file take
turns, so two never overwrite each other.

A bot made before goals were removed kept `goal` declared through every
refresh, since only this build's tool names counted as Sonny's. A
declared tool Sonny answers (`answered_by: sonny`) now counts as Sonny's
too, so a refresh drops one this build no longer has.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_013jkdGGYoqceB21grsa5Q3v
Conflicts in lookout/updates.rs (the goal hold beside #777's wait reads:
the goal parts go, the wait reads stay) and asks.rs (#776's reading of
an ask, with said_by_person now in reactions).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_013jkdGGYoqceB21grsa5Q3v
…w takes one

#776 and #771 each built on their own; together the deadline cleanup in
asks.rs called trigger::tool with one argument. Same line as #785.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_013jkdGGYoqceB21grsa5Q3v
@lydakis
lydakis merged commit 022c9f5 into main Nov 7, 2026
5 checks passed
@lydakis
lydakis deleted the claude/project-thread-ybzpqh branch November 7, 2026 07:49
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