Repository navigation
Let leads and tasks run as other profiles, and profiles build on others - #296
Conversation
A project's profile/threads_profile, else the config's [sonny] lead_profile/task_profile, name the profile a lead runs as and the one every other agent is told, with lead and task the defaults. Any profile can build on another with extends (its own name builds on the file it shadows, down to the one Sonny ships) and carry skills whole with skills, Claude Code's subagent key. Variants of lead or task are not offered as peer roles. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGEEJYxYSGKW4TF3BrX
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 0aaa15e3c3
ℹ️ 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".
…ants of variants Address the first Codex round on #296: a profile chain and the skills it carries read no more than still fits in a bot's instructions; a carried skill with an unclosed --- head fails like a profile's; a profile that extends a lead variant is hidden from the index too; and --profile naming the task profile keeps its model and tools while its body is told once. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGEEJYxYSGKW4TF3BrX
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 0973a5bf11
ℹ️ 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".
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGEEJYxYSGKW4TF3BrX
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8681c4e2b8
ℹ️ 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".
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGEEJYxYSGKW4TF3BrX
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8881f7b6b5
ℹ️ 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".
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGEEJYxYSGKW4TF3BrX
A lead runs as it only when its project sets profile = "superlead". It extends lead: the folder holds other projects, so the lead subscribes to their leads and routes between them as between tasks. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGEEJYxYSGKW4TF3BrX
Carried from lead.md (#295 drops it there): the folder's projects' leads report to it, and it hears them through one subscription naming each lead exactly with updates on. Routing itself is the lead's. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGEEJYxYSGKW4TF3BrX
) * Let leads and tasks run as other profiles, and profiles build on others A project's profile/threads_profile, else the config's [sonny] lead_profile/task_profile, name the profile a lead runs as and the one every other agent is told, with lead and task the defaults. Any profile can build on another with extends (its own name builds on the file it shadows, down to the one Sonny ships) and carry skills whole with skills, Claude Code's subagent key. Variants of lead or task are not offered as peer roles. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGEEJYxYSGKW4TF3BrX * Bound a role's files together, reject unclosed skill heads, hide variants of variants Address the first Codex round on #296: a profile chain and the skills it carries read no more than still fits in a bot's instructions; a carried skill with an unclosed --- head fails like a profile's; a profile that extends a lead variant is hidden from the index too; and --profile naming the task profile keeps its model and tools while its body is told once. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGEEJYxYSGKW4TF3BrX * Tell a role named task in full when tasks are told another profile Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGEEJYxYSGKW4TF3BrX * Tell a role's body once only when it is the task profile's own file Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGEEJYxYSGKW4TF3BrX * Use a neutral example profile name Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGEEJYxYSGKW4TF3BrX * Ship an opt-in superlead profile A lead runs as it only when its project sets profile = "superlead". It extends lead: the folder holds other projects, so the lead subscribes to their leads and routes between them as between tasks. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGEEJYxYSGKW4TF3BrX * Give the superlead the leads-of-leads rule and the exact subscription Carried from lead.md (#295 drops it there): the folder's projects' leads report to it, and it hears them through one subscription naming each lead exactly with updates on. Routing itself is the lead's. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGEEJYxYSGKW4TF3BrX * Sonny: offer the person's lead a merge when an upgrade meets an edited skill or role Sonny never writes over a skill or role (lead.md, task.md) the person edited, so an edited one quietly stopped getting Sonny's changes. Now Sonny sets its new text beside the edit, in ~/.agent/sonny/upgrades, keeps whole what it last wrote in ~/.agent/sonny/shipped (what an edit started from), and queues a note to the first bot it opens after the upgrade. The bot tells the person and offers to bring Sonny's changes into their copy. Each new text is told once; the transcript shows the note as one quiet row. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGEEJYxYSGKW4TF3BrX * Sonny: offer only text that changed, and claim the pending offers so one bot tells them Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGEEJYxYSGKW4TF3BrX * Sonny: pending upgrade offers as one file each, claimed by rename into a fresh folder Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGEEJYxYSGKW4TF3BrX --------- Co-authored-by: Claude <[email protected]>
What
lead.mdandtask.mdare now the defaults of a setting rather than fixed names, and any profile can build on another. Sonny still ships only leads and tasks; any other kind of lead is a profile the person writes.Which profile a lead / its tasks run as
~/.agent/config.toml.agents/project.toml[sonny] lead_profileprofile[sonny] task_profilethreads_profilePrecedence goes project file, then config, then
lead/task. If the named profile doesn't exist, Sonny stops withprofile_not_foundand creates no agent.Profiles build on profiles and carry skills
extends: NAME: the base's body comes first, then this one's. The base'smodelandtoolsapply where this profile sets none. Chains can go up to 8 deep. A circle fails withprofile_invalid.lead.mdbuilds on the person's, and the person's builds on the one Sonny ships, so Sonny's updates keep coming. Sonny passes its shipped roles as built-ins (policy::profile_with).skills: [a, b]comes from Claude Code's subagent front matter. Each skill's wholeSKILL.mdbody is added after the role under## Skill: NAME. A missing skill fails withskill_not_found. A role's files and skills are read within the instructions budget together.leadortaskis a variant of that role, so the Profiles index leaves it out, along with variants of those variants. Agents aren't offered them as peer roles.Standards checked (2026-10-28)
agentsetting insettings.jsonand a--agentflag that pick the subagent profile the main session runs as. This PR'sprofile/lead_profilemirror it. Its subagentskills:key preloads whole skills, and this PR adopts it as is.~/.codex/agents/*.toml) and Claude Code subagents each stand alone. Neither has a key for one profile building on another, and the agentskills.io spec has no skill-dependency key. That's why this PR usesextends, the name tsconfig and ESLint use.Tests
policy::a_profile_builds_on_another_and_carries_skillscovers chains, own-name shadowing down to the built-in, skill inheritance and dedupe, the shared budget, unclosed skill heads, index hiding (including variants of variants), circles, missing skills and bad names.project::a_project_sets_the_profile_its_lead_runs_as(Sonny) covers the project file'sprofile, a missing profile and the composed# Role: my-lead.task::a_task_is_told_who_it_works_forgainsthreads_profilecases. These cover explicit--profileof the task profile keeping its tools,taskas an ordinary role, and same-name files that differ only in case.cargo clippy --workspace --all-targetsis clean.agent-clientand Sonny unit tests pass. Three SandFS tests insonny/tests/task.rsfail in the cloud container onmaintoo, because the container has no FUSE.One Codex index edge was deferred to #96: a self-extension whose shadowed file extends
lead.There's no screenshot because nothing visible changed.
🤖 Generated with Claude Code