The ultimate harness for coding agents and beyond. All your agents. All your machines. One command center. Start with code, then follow your curiosity and build across disciplines: CAD, circuits, robots, games and music.
TypeScript 3d-modelingagent-frameworkagent-harnessai-agentscadclaude-codecodexcoding-agentsdeveloper-toolsesp32game-developmentmcp-servermulti-agentopen-hardwareopencodeopenharnesspcbroboticsterminaltmux
Template: Reviewers picked when the PR is ready; one quota order for every assignment (#2693)
0xken159dc5add6aef7
diff --git a/backend/src/superTabs/instructions.test.ts b/backend/src/superTabs/instructions.test.tsindex dba255951..56ccd86db 100644--- a/backend/src/superTabs/instructions.test.ts+++ b/backend/src/superTabs/instructions.test.ts@@ -36,19 +36,19 @@ describe('the built-in template', () => {// groups to hold, batch and triage work. Agents forgot which task they were on (agent context design, section 3).it('the template workflow has one task per request, steps, and the context tools', () => {expect(TEMPLATE_WORKFLOW).toContain('1. One request is one task.')- // Ken, 2026-11-02: the PM sets the task's team once, then stays out of it until the Engineer reports.- expect(TEMPLATE_WORKFLOW).toContain('and its Tester when the change needs one')- expect(TEMPLATE_WORKFLOW).toContain('assigns them to the Reviewer and the Tester the task names')+ // Ken, 2026-11-02: the PM says what the task needs once, then stays out of it until the Engineer reports.+ expect(TEMPLATE_WORKFLOW).toContain('It says which\n reviews and tests the task needs')+ expect(TEMPLATE_WORKFLOW).toContain("That is the PM's part until the Engineer reports.")expect(TEMPLATE_WORKFLOW).toContain('The PM opens no task to hold, batch, triage or list work')expect(TEMPLATE_WORKFLOW).toContain('adds a review step to its task')expect(TEMPLATE_WORKFLOW).toContain('it adds no new step for a second round')expect(TEMPLATE_WORKFLOW).toContain('run `mine`')expect(TEMPLATE_WORKFLOW).toContain('read `task GROUP`')expect(TEMPLATE_WORKFLOW).toContain('read the thread before acting on it')- // Ken, 2026-11-02 (from openharness): the PM names both Reviewers a two-review task needs, and the Engineer picks a- // missing one itself instead of asking the PM.- expect(TEMPLATE_WORKFLOW).toContain('two Reviewers when the task needs two reviews')- expect(TEMPLATE_WORKFLOW).toContain('the Engineer picks a free Reviewer that has not worked on this task itself, without asking the PM')+ // Ken, 2026-11-02 (from openharness): a two-review task gets two review steps; the Engineer picks its Reviewers+ // itself instead of asking the PM (since 2026-11-03, when the pull request is ready).+ expect(TEMPLATE_WORKFLOW).toContain('A task that needs two\n reviews gets two review steps.')+ expect(TEMPLATE_WORKFLOW).toContain('never one that\n worked on this task itself')// Ken, 2026-11-02: an Engineer posted "review and test pass" and then set Done, two messages for one event.expect(TEMPLATE_WORKFLOW).toContain('that status is how the PM hears, once')expect(TEMPLATE_WORKFLOW).toContain('The PM reads `mine` for progress, not `status`.')@@ -89,17 +89,31 @@ describe('the built-in template', () => {expect(workflow).toContain('While the Engineer fixes them, the Reviewer or Tester stays Working on its step')expect(workflow).toContain('blocked and needs_human are only for something a person must do.')})- it('routes by each account\'s weekly quota left per day until its reset, which the route\'s order does not rank by', () => {- // Ken, 2026-11-02: in a week of the autonomous.ai Swarm the PM took the route's first candidate 7% of the time, work piled- // onto one machine, accounts sat at 0% for days while others reset with 95% unused.- const routing = INSTRUCTIONS_TEMPLATE.slice(INSTRUCTIONS_TEMPLATE.indexOf('## Routing'))- expect(routing).toContain('An account\'s share per day is its weekly quota left')- expect(routing).toContain('(20% left resetting in 1 day comes before 80% in 5 days)')- expect(routing).toContain('An idle agent is reused only when its account has the quota for the task')- expect(routing).toContain('Engineers move to the next model and that quota is kept for reviews and urgent work.')- expect(routing).toContain('waits if its 5-hour window resets within 30 minutes')+ it('picks Reviewers and Testers when the pull request is ready, the PM naming one only when the task needs that agent', () => {+ // Ken, 2026-11-03: Reviewers named when a task opened were busy, stopped or out of quota an hour or more later (10 of+ // 36 named in two days reviewed nothing), and 202 reviews in 48 hours ran on the PM's own Mac Studio account.+ const workflow = INSTRUCTIONS_TEMPLATE.slice(INSTRUCTIONS_TEMPLATE.indexOf('## Workflow'), INSTRUCTIONS_TEMPLATE.indexOf('## Routing'))+ .replace(/\n +/g, ' ')+ expect(workflow).toContain('names a Reviewer or Tester only when the task needs that one agent')+ expect(workflow).toContain('It picks each Reviewer and Tester then, by Routing\'s order (the one the PM named, if any)')+ expect(workflow).toContain('If an assignment is refused, the Engineer asks the PM once, naming the step and the agent it picked.')+ expect(workflow).not.toContain('It also names its Reviewer')+ expect(workflow).not.toContain('When the task needs a Reviewer the PM did not name')+ })+ it('orders every assignment by the work\'s needs, the PM\'s own account\'s weekly pace, then the account resetting soonest', () => {+ // Ken, 2026-11-03: the PM reused idle agents on its own machine about 300 times in 48 hours (it took the route's first+ // candidate 11% of the time) until that Claude account, the PM's own, reached 0% with 4 days to its reset. The 5-hour+ // window is never hit, so only the weekly quota counts. No plan size here: projects differ.+ const routing = INSTRUCTIONS_TEMPLATE.slice(INSTRUCTIONS_TEMPLATE.indexOf('## Routing')).replace(/\n +/g, ' ')+ expect(routing).toContain('Every assignment (an Engineer, a Reviewer, a Tester, an idle agent reused) picks in this order:')+ expect(routing).toContain('The PM\'s own account (the engine it runs on, on its machine) keeps the PM running for the whole week.')+ expect(routing).toContain('weekly quota left above the share of its week left (with 5 of 7 days to go, above 71%)')+ expect(routing).toContain('Every other account is used while it has weekly quota left: the one resetting soonest first')+ expect(routing).toContain('An idle agent is reused only between candidates equal so far')+ expect(routing).toContain('"Idle" is not a reason.')+ expect(routing).toContain('hands its pushed branch to an agent on another account.')expect(routing).toContain('Urgent work (production down, security) ignores quota.')- expect(routing).toContain('its order does not rank by them')+ for (const gone of ['share per day', '5-hour', 'Engineers move to the next model', 'Max 20x']) expect(routing).not.toContain(gone)})})diff --git a/backend/src/superTabs/instructionsTemplate.ts b/backend/src/superTabs/instructionsTemplate.tsindex 151acb813..cdbd4351b 100644--- a/backend/src/superTabs/instructionsTemplate.ts+++ b/backend/src/superTabs/instructionsTemplate.ts@@ -50,17 +50,18 @@ export const TEMPLATE_ROLES = `## Rolesexport const TEMPLATE_WORKFLOW = `## Workflow-1. One request is one task. The PM opens it with its goal and "Done when" and assigns an Engineer. It also- names its Reviewer, two Reviewers when the task needs two reviews, and its Tester when the change needs one; when- no agent is free for a role, it starts one.+1. One request is one task. The PM opens it with its goal and "Done when" and assigns an Engineer. It says which+ reviews and tests the task needs (two reviews, a test on a Mac, on a device), and names a Reviewer or Tester only+ when the task needs that one agent; when no agent can take a role, it starts one.That is the PM's part until the Engineer reports. The PM opens no task to hold, batch, triage or list work: thatgoes in its notes or the project chat.2. When the pull request is ready, the Engineer adds a review step to its task, and a test step when the change issomething a user sees or uses (screens, CLI commands, install and release, sign-in, connections between machines,- devices). It assigns them to the Reviewer and the Tester the task names, and messages them directly.+ devices). It picks each Reviewer and Tester then, by Routing's order (the one the PM named, if any), never one that+ worked on this task itself, assigns them and messages them directly.Review and test run in parallel. Refactors, docs and test-only changes get a review only. A task that needs two- reviews gets two review steps. When the task needs a Reviewer the PM did not name,- the Engineer picks a free Reviewer that has not worked on this task itself, without asking the PM.+ reviews gets two review steps. If an assignment is refused, the Engineer asks the PM once, naming the step and the+ agent it picked.3. Findings go straight to the Engineer. The Engineer fixes them and asks the same Reviewer or Tester again in the samestep; it adds no new step for a second round. While the Engineer fixes them, the Reviewer or Tester stays Working on its step:blocked and needs_human are only for something a person must do.@@ -87,18 +88,22 @@ export const TEMPLATE_ROUTING = `## RoutingSol, and after a second to Opus or Astra.- A Tester runs on a machine that has what the change needs: a Mac for Desktop, the machine the device is plugged into forfirmware. The machine comes before the model. A mid-strength model is enough for most testing.-- Between candidates of equal strength, quota decides. An account's share per day is its weekly quota left- divided by the days until it resets; work goes first to the largest share per day, so no account ends its week with- quota left and none runs dry early (20% left resetting in 1 day comes before 80% in 5 days).-- An idle agent is reused only when its account has the quota for the task; otherwise a new agent starts on the account- with the largest share per day.-- An account with less than a day's share for a task takes no new big task. When every account of the strongest models- is under 20% of its week, Engineers move to the next model and that quota is kept for reviews and urgent work.-- An agent that runs out mid-task waits if its 5-hour window resets within 30 minutes; otherwise its pushed branch moves- to an agent on another account.-- Urgent work (production down, security) ignores quota.-- The route's lines show each account's quota left and reset time, but its order does not rank by them: the PM works out- each candidate's share per day from those lines, and gives the reason when it picks another.`+- Every assignment (an Engineer, a Reviewer, a Tester, an idle agent reused) picks in this order:+ 1. What the work needs: the machine, a model strong enough, a machine not paused.+ 2. The PM's own account (the engine it runs on, on its machine) keeps the PM running for the whole week. It takes+ other work only while ahead of its week: weekly quota left above the share of its week left (with 5 of 7 days+ to go, above 71%). At or below that line it takes no new work and idle agents there are not reused.+ 3. Every other account is used while it has weekly quota left: the one resetting soonest first, then the one with+ the most left.+ 4. An idle agent is reused only between candidates equal so far, except the same Reviewer for its next round and+ work that follows straight on from what the agent just did.+ 5. Between equals, the machine with fewer agents working. Then price.+- The route's lines show each account's weekly quota left and reset time, but its order does not rank by them: the PM+ applies this order itself. Picking against it needs a reason in the route's override: urgency, context, or a machine+ the work needs. "Idle" is not a reason.+- An agent whose account runs out of weekly quota mid-task, or whose account is the PM's and falls below its line,+ hands its pushed branch to an agent on another account.+- Urgent work (production down, security) ignores quota.`/** The title and the opening words, which say what the document is for. */export const TEMPLATE_INTRO = `# Project instructions