Skip to content
Back to skills

Rule Daemon Teams Passes

ASecurity

Teams and passes — the team store, overlays, member health, the one lead, stage passes. A repository rule for apps/daemon/src/v1/teams/**, apps/daemon/src/v1/agents/**/item-seq*; read it before editing a file there.

  • 8 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added November 17, 2026
ai-agentsgonodeawsdatabase

Works with

  • cursor
  • cli
  • mcp

Security analysis

A100/100

Scanned December 4, 2026

npx -y skills add geniro-io/geniro-app --skill rule-daemon-teams-passes --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Rule Daemon Teams Passes?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Rule Daemon Teams Passes
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/geniro-io-rule-daemon-teams-passes/badge)](https://www.skillsdirectory.com/skills/geniro-io-rule-daemon-teams-passes)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: rule-daemon-teams-passes
description: "Teams and passes — the team store, overlays, member health, the one lead, stage passes. A repository rule for apps/daemon/src/v1/teams/**, apps/daemon/src/v1/agents/**/item-seq*; read it before editing a file there."
---
<!-- GENERATED by scripts/sync-agent-rules.mjs from .claude/rules/daemon-teams-passes.md. DO NOT EDIT: edit the source, then run `pnpm sync:agent-rules`. -->

# Teams and passes

`v1/teams/` (library: `*.team.yaml` under `<userData>/teams/`).

- **Project overlays** (`TeamOverlayService`, `TeamOverlayStoreService`, pure `utils/team-overlay.ts` `applyTeamOverlay`, routes `GET /v1/teams/:slug/overlays`, `GET|PUT|DELETE …/overlays/:projectId`, `GET /v1/teams/project-overlays/:projectId` — every team's overlay one project holds, its default team's first): `startRun` places the run first, then applies the project's overlay only when `Project.teamSlug` is the run's team (`TeamOverlayService.effective`); every check, `withResolvedNodeSettings`, the lead and `Run.teamSnapshot` take that effective team, `Run.teamBaseSnapshot` the shared one. An overlay that cannot be read refuses the run `TEAM_OVERLAY_UNREADABLE`, one the team cannot take `TEAM_OVERLAY_INVALID`; a missing file is the shared team. Precedence: the member's own override, then `allMembers[<cli>]`, then the team's value; an `agent` override clears the CLI-bound fields, and an overlay that picks another model drops the team's `contextWindow` and `modelParameters` (`forModel`, in both twins); `members.<id>.pool` replaces the pool whole and `allMembers` leaves its entries alone; `members.<id>.mcpDisabled` replaces the member's MCP switches whole (`[]` = none off), and an `agent` override leaves the switches alone; overlay blocks run under `project:<projectId>:<id>`. Versions, restores and drift read the base snapshot only (`baseTeamSnapshotOf`, `RunDao.baseTeamSnapshots`), so every project's runs stamp the shared version. Setup health (`?projectId=`), instruction sizes (`projectId` + `overlay`) and the autopilot's unattended check (`TaskRunsService`, `TaskQueueService`) read the effective team. Any chat sends `propose_team` a whole `overlay` for the project it names (a project's own chat may leave out its own, `.claude/rules/daemon-projects-tasks.md`; `.claude/rules/daemon-host-tools-team-proposal.md`): one card (`TeamProposal.overlay`, with `diffText`), one approval that writes the overlay (`TeamOverlayService.writeWithTeam`, which writes no team when the team half changes nothing), logged with source `chat`, or `builder` from that team's builder chat. A builder chat opened from the team's page is bound to no project (`TeamChatService` unbinds one bound before), so it names the project like any chat; its overlay path stays only for such an older binding. A `read_teams` token in the overlay's `configDir` is put back like a team's (`restoreOverlayConfigDirs`, `CONFIG_DIR_UNKNOWN`). Stages take no project addendum (user decision); an overlay file written with `stages:` still reads, the key dropped. Analysis target `overlay` (`O-`) is applied through `save_team_change` with `overlay` + `overlayProjectId` + `overlayHash` (`TeamChangeService.saveOverlay`); `view=team` carries the run's `overlay` and the project's `overlayNow` with `active`. An overlay write for a project that defaults to another team is refused `OVERLAY_INACTIVE` (the builder's card and `saveOverlay`), since no run would use it. A board card whose project overlay a run start would refuse is held in `blocked` (kind `overlay`) with that reason, armed or not (`TeamOverlayService.refusalOf`). A deleted team's overlays go in `TeamChatService.deleteTeam`, a deleted project's on its `projects_changed` (`TeamOverlayService.dropIfProjectGone`) and, for one deleted while the daemon was down, in a boot sweep (`TeamOverlayService.sweepOrphans`).
- `calleeSummary` (`utils/callee-text.ts`) is the one line a caller sees about a callee: label plus its public `role`, never its `instructions` or `character`.
- Every turn that answers a call carries `ANSWERING_A_CALL` as its own instruction part (`answeringACallPrompt`, not gated on the call tools), so a callee with no callees hears it too; `ANSWERING_WITH_CALLS_OUT` follows it in the "May call" block and in `call_agent`'s description, which must agree.
- Member setup health (`TeamHealthService`, `GET /v1/teams/:slug/health`, rules in `utils/member-health.ts`): the cheap path reads only memoized and cached facts — the CLI's version, the profile folder, the filed model list, the efforts, and the folderless MCP listing's last reading (`AgentMcpService.knownStatus`, never a dial); `probe=true` (the open team's page only) lists each unique (agent, profile) once through the single-flight cache. A red problem (the CLI of the member the run starts with not installed with no pool member to fall back to, a profile folder gone, no trigger member) refuses a run start `TEAM_NOT_READY` (`assertMembersReady` in `startRun`; a follow-up into a running run is not re-checked); a missing CLI is red only for the member the run starts with (`triggerMemberId`) with no pool member left to fall back to, and a version that could not be read is `cli_unknown` unless the binary is nowhere on `PATH`. Amber ones never refuse. Sign-in is the renderer's (Electron main's probe).
- Node settings are resolved once at run start. An unusable `configDir` or `effort` is dropped with a system row (`DroppedNodeSetting`), never passed on or dropped silently. `effort` is a free string.
- A pass leaves its processes running. Archive and delete end all of them (`endProcesses`: `closeRun` over `<runId>` and `<runId>::…`, then the reaper for what their agents detached).
- Team rows take seq from the shared `ItemSeqAllocator` (a kept process writes between passes).
- A library save may quote the `hash` it was read at (`baseHash`); a file changed since is refused `409 TEAM_CHANGED`, never overwritten. The builder's autosave, a builder chat's approved `propose_team` card and an analysis's applied change all write the same file.
- A pass starts only the run's LEAD (`RunContext.lead`): the trigger's member; every other member is call-only (`onDemandMemberIds`). There is no DAG walk, no producer text and no trigger node. The pass-end `skipped` sweep touches only members still `pending`; a new pass resets only the lead, never another member with state.
- **One lead.** Every team runs with one lead, the trigger's member (`triggerMemberId`); no stage hands a run to another member. A team has no `mode`: a stored `mode` key is ignored on read (`TeamSchema` strips it; migration `0006-team-mode-key` cuts its line from library files, every other byte kept), `team-version` keeps a constant `mode: 'lead'` in the canonical form so a version recorded with `mode: lead` hashes as it did (one recorded with `mode: relay` gets a new current version), and a `handoff` `stage_change` row in a run's history is drawn and ignored by the fold; nothing writes one.
- Every member may call every other member (`calleesOf`, `team-roster.ts`), and its "May call" block lists each one's name and public `role` (`calleeSummary`). A call whose callee owns a running call in the chain the caller's conversation answers is refused `CALL_UP_THE_CHAIN`, naming the chain (`CallBroker.callUpTheChain` over `runningCallEntriesUpFrom`); the depth cap of 3 stays.
- Teams written as node graphs are read through `teamFromWorkflow` (`utils/team-from-workflow.ts`) wherever one is read — library files before migration `0005-team-shape-files`, run snapshots (`parseTeamSnapshot`, whose `legacy` keeps the graph so `snapshotVersionOf` answers the hash its run was stamped with), recorded versions (`teamOfCanonical`), standing proposal cards (`fromLegacyProposal`) and imports — and never rewritten in the database.
- **Restart continuation** (user decision): after a `self-update` or `restart` stop, and for a team run after a `quit` too (`resumesUnattended`; a chat only after `self-update` / `restart`, `continuesUnattended`), the boot reconcile keeps a team run or chat `running`, writes its boot row with `continues: true` ("… — work continues", drawn as a grey note) and records what was cut off in `Run.restartContinuation` (`utils/run-restart-continuation.ts`, never on the wire): own-conversation turns, open calls with the callee's session, the calls the boot closed failed instead (`failedCalls`: one a standing card holds, or one already continued once that a `self-update` or `restart` cut off again — `CALLEE_FAILED[daemon_restart]`; after a `quit`, `crash` or `unknown` such a call is kept like any other, user decision), and the monitor sweep's stopped monitors. The rows that opened a kept turn or call are closed with `continues: true`, as is the turn's `turn_cancelled` the shutdown wrote (Team call runtime); the transcript draws no note for them and a call card never reads one as its ending. A member holding a standing card is left to its answer; archived and cancelled runs are never continued. `RestartContinuationService.drain` (from `onListening`) clears each record, then continues it: a team through `TeamExecutorService.continueAfterRestart` — ONE pass through `walkAgain` with a `system` seed row (never `sendMessage`), starting the lead only when its own turn was cut off, it owns a stopped monitor or a call of its failed (`RestartPass.leadTurn`; otherwise `seedPrompt` is never sent), each call through `CallBroker.resumeCall`, each other member whose own conversation was cut off through `CallBroker.wakeOwnConversation`, a caller that cannot be reached owed the news (`oweKeyNote`) — and a chat through a host turn (`ownTurn`). Every conversation hears one short `[geniro]` message (`restartContinuationPrompt`): what stopped it, that the stop was geniro's so the CLI's own "the user doesn't want to proceed … stop and wait" note does not apply, to check what is done and run the interrupted command again (checking first that it is not still running), its calls that continue or failed, its stopped monitors; the user's message is never re-sent. A conversation with no saved session, or a call whose saved session its CLI never wrote or saved no prompt in (`AgentAdapter.sessionResumable`), gets the transcript excerpt a pool hand-off gives (`RESTART_TRANSCRIPT_LEAD`); a call on a thread whose session never saved its new brief is resumed with that brief given again (`restartContinuationPrompt`'s `brief`). A pass the user already started takes the lead's place. `RUN_BUSY` retries (`RESTART_CONTINUE_RETRY_MS`, `RESTART_CONTINUE_ATTEMPTS`); a continuation that cannot start ends the run as today (`abandonRestartContinuation`: the red row, `CALLEE_FAILED: interrupted`, `failed`). After a `crash` or `unknown` stop (user decision: GEN-97's no-blind-resend rule) a team run is kept the same way but its record is `held`: its boot row says it continues once the user chooses, the drain skips it, and only the user continues it — from the start-up dialog (`GET /v1/interrupted-runs`, `POST /v1/interrupted-runs/answer`, `RestartContinuationService.answerHeld`: a chosen run continues as above; a declined one, when still `running`, ends through `abandonRestartContinuation(…, declined)`, and its monitors' owners are owed the stopped-monitor note), or by writing into the run (`TeamExecutorService.sendMessage`, through the hook `setHeldContinuation` installs: `continueWithMessage` continues it in ONE pass whose seed is the user's row and whose lead gets its continuation note followed by the message, so the message is never refused while that pass starts; a run whose last pass is still finishing stays held and the message is refused `RUN_BUSY`). Stop on a held run declines it. A kept row of a held record carries `held: true`, and `closeOpenMemberWork` also closes every turn whose last row is a `continues` one (`turnsLeftForContinuation`), so a declined or abandoned run leaves no call reading as working. A held record stays held through every later boot, under its own cause (`mergeRestartContinuations`), and a crash boot holds every team record an earlier stop left (`holdTeamContinuations`); a boot after a stop chats do not continue after drops the chats' records (`clearChatRestartContinuations`), both in `closeInterruptedRuns`.
- Team member auto-compaction: see `.claude/rules/daemon-auto-compaction.md`.
- **Run-only team changes** (`TeamExecutorService.changeRunTeam`, from `run_team`'s change card — `.claude/rules/daemon-host-tools-team-proposal.md`): `Run.teamSnapshot` is no longer frozen for a run's own changes. A change writes the snapshot and `Run.teamDeparted` (JSON `[{memberId, leftAt}]`, `readTeamDepartures`), never `teamBaseSnapshot` (so versions and stats keep the team the run started from), refused when the snapshot moved since the card's `baseHash`, and gives each new member a `pending` `node_state` row. The run's newest pass takes it at once through its `liveRosters` hook, whether its turn still runs or has ended — a wake (a card's verdict, a monitor) continues the lead in that pass: it updates the pass's members in place (`nodes`, `nodesById`), refills the callees (`calleeMapOf`: a departed member keeps calling but is nobody's callee), the on-demand set and the blocks, re-registers every member's host-tool sinks and call token (`registerMemberTools`), and registers the run's calls with the broker when the pass started with nobody to call (`registerCalls`), so an added member is launchable and callable at once. With no pass since the daemon started, the next pass reads the change off the run. A removed member stays in the snapshot so its rows resolve, finishes the call it is answering, and its kept process closes with the idle window. A changed member's next turn composes the new instructions, which change its adapter's `sessionKey`, so a new process resumes the same session. A resumed claude or codex session keeps the instructions it started with (`AdapterConfig.resumeKeepsInstructionsReason`, measured), so the executor records, per session key, a hash of the team instructions each conversation last ran under — its blocks, instructions, character, answering-a-call note and "May call" block — on `Run.conversationInstructions` (it outlives a restart), and opens the first resumed plain turn whose team instructions differ with the new text (`changedInstructionsNote`). A promotion records the lead's chat session as having run under none, so the lead's first team turn is told its team instructions; a member's changed callees reach its next resumed turn the same way. cursor's ACP driver re-sends its changed block itself. Each pass reads the departed set off the run (`departedMembers`).
- **Chat teams** (`teamOrigin: 'chat'`, `teamId` `chat:<runId>`, `isChatTeamRun` / `isChatTeamId`): a chat promoted in place into a team run it leads (`promoteChat`). Everything after the flip reads it as a team run. Readers keyed on a library slug skip it: the team ledger stamps no version (`TeamLedgerService.stampVersion`), usage rows name no team (`teamNameOf`), memory and knowledge scope it to no team (`ProjectScopeService.placeOf`), and `RunTeamService.teamOf` never falls back to the library. The run wire carries `teamOrigin`, `chatTeamSize` (`chatTeamSizeOf`) and `departedMembers`.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.