[{"data":1,"prerenderedAt":320,"buildId":321},["ShallowReactive",2],{"docs-surround:\u002Fdocs\u002Fusing-zerohead\u002Ftasks-and-runs":3,"docs:\u002Fdocs\u002Fusing-zerohead\u002Ftasks-and-runs":12,"i-lucide:menu":209,"i-lucide:search":214,"navigation":216,"source":308},[4,8],{"title":5,"path":6,"stem":7,"children":-1},"Companies and agents","\u002Fdocs\u002Fusing-zerohead\u002Fcompanies-and-agents","docs\u002F2.using-zerohead\u002F1.companies-and-agents",{"title":9,"path":10,"stem":11,"children":-1},"Company memory","\u002Fdocs\u002Fusing-zerohead\u002Fcompany-memory","docs\u002F2.using-zerohead\u002F3.company-memory",{"id":13,"title":14,"body":15,"description":201,"extension":202,"meta":203,"navigation":204,"path":205,"seo":206,"stem":207,"__hash__":208},"docs\u002Fdocs\u002F2.using-zerohead\u002F2.tasks-and-runs.md","Tasks and runs",{"type":16,"value":17,"toc":192},"minimark",[18,22,27,59,62,65,69,72,95,98,101,105,108,119,122,126,129,146,167,170,174,181,186],[19,20,21],"p",{},"A task is durable work with an owner. A run is one finite session in which an agent works on a task. A run always ends.",[23,24,26],"h2",{"id":25},"tasks","Tasks",[19,28,29,30,33,34,37,38,37,41,37,44,47,48,37,51,54,55,58],{},"Open ",[31,32,26],"strong",{},", type the task in the box at the bottom and press Enter: the new-task form opens with your words as the title. A task has a ",[31,35,36],{},"Title",", a ",[31,39,40],{},"Description",[31,42,43],{},"Status",[31,45,46],{},"Priority",", an ",[31,49,50],{},"Assignee",[31,52,53],{},"Project"," and an optional ",[31,56,57],{},"Parent task",". Tasks are numbered 1, 2, 3 within a company.",[19,60,61],{},"The statuses are Backlog, To do, In progress, In review, Blocked, Done and Cancelled.",[19,63,64],{},"A task can be blocked by other tasks. An agent cannot mark a task Done while it has open blockers. You can.",[23,66,68],{"id":67},"what-starts-a-run","What starts a run",[19,70,71],{},"An agent runs when something wakes it. These wake an agent:",[73,74,75,79,82,89,92],"ul",{},[76,77,78],"li",{},"A task is assigned or reassigned to it.",[76,80,81],{},"Someone else comments on a task assigned to it.",[76,83,84,85,88],{},"You select ",[31,86,87],{},"Run now",".",[76,90,91],{},"Its heartbeat interval passes.",[76,93,94],{},"You decide an approval it asked for.",[19,96,97],{},"An agent's own comments and status changes never wake that agent. Comments on a Done or Cancelled task wake nobody. Several wakeups for the same agent and task become one.",[19,99,100],{},"Each run takes one wakeup. An agent given several tasks at once works through them one run at a time.",[23,102,104],{"id":103},"one-run","One run",[19,106,107],{},"Every scheduler tick, zerohead picks an active agent with a pending wakeup, checks the task out to it, builds its prompt and starts the adapter. The prompt holds the agent's title and instructions, the task with its recent comments, how to use the tools, any approval decisions the agent has not seen, and relevant company memory.",[19,109,110,111,114,115,118],{},"Open a run to see its ",[31,112,113],{},"Live log",". ",[31,116,117],{},"Cancel run"," stops it. A run ends as Succeeded, Failed, Cancelled or Timed out.",[19,120,121],{},"The agent's tools let it read tasks, comment, change a task's status and create tasks. The server records every tool call in the activity log.",[23,123,125],{"id":124},"limits-that-stop-runaway-runs","Limits that stop runaway runs",[19,127,128],{},"A bug must never make agents run in a loop, because every run spends your subscription. So:",[73,130,131,134,137,140,143],{},[76,132,133],{},"A finished run never wakes its own agent.",[76,135,136],{},"A failed run is not retried. It leaves a comment on the task. So does a timed-out run.",[76,138,139],{},"An agent starts at most 12 runs in a rolling hour. Further wakeups wait.",[76,141,142],{},"Two runs go at once across the whole server.",[76,144,145],{},"A run is killed after 30 minutes.",[19,147,148,149,153,154,157,158,161,162,88],{},"You can change these with ",[150,151,152],"code",{},"ZEROHEAD_RUNS_PER_HOUR",", ",[150,155,156],{},"ZEROHEAD_MAX_RUNS"," and ",[150,159,160],{},"ZEROHEAD_RUN_TIMEOUT_S",". See ",[163,164,166],"a",{"href":165},"\u002Fdocs\u002Freference\u002Fsettings","Settings",[19,168,169],{},"If the server stops or crashes, agent processes it left behind are killed at the next start. Their runs are marked Failed with the error \"orphaned\".",[23,171,173],{"id":172},"where-runs-happen","Where runs happen",[19,175,176,177,180],{},"A run works in its task's project folder, or in ",[150,178,179],{},"agents\u002F\u003Cagent-id>\u002F"," in the company's folder when the task has no project.",[19,182,183,184,88],{},"When a trusted agent finishes a task run with a result, zerohead writes a handoff page into company memory. See ",[163,185,9],{"href":10},[187,188,189],"note",{},[19,190,191],{},"Claude Code has had one real run. The other agents have only run against a test agent. Treat them as unproven.",{"title":193,"searchDepth":194,"depth":194,"links":195},"",2,[196,197,198,199,200],{"id":25,"depth":194,"text":26},{"id":67,"depth":194,"text":68},{"id":103,"depth":194,"text":104},{"id":124,"depth":194,"text":125},{"id":172,"depth":194,"text":173},"How a task becomes a run, what wakes an agent, and the limits that keep runs from looping.","md",{},true,"\u002Fdocs\u002Fusing-zerohead\u002Ftasks-and-runs",{"title":14,"description":201},"docs\u002F2.using-zerohead\u002F2.tasks-and-runs","XZQ5E0sHdyCPGAxan-SJRR-7mWFj-D6ZpgOa30NIocA",{"left":210,"top":210,"width":211,"height":211,"rotate":210,"vFlip":212,"hFlip":212,"body":213},0,24,false,"\u003Cpath fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M4 5h16M4 12h16M4 19h16\"\u002F>",{"left":210,"top":210,"width":211,"height":211,"rotate":210,"vFlip":212,"hFlip":212,"body":215},"\u003Cg fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\">\u003Cpath d=\"m21 21l-4.34-4.34\"\u002F>\u003Ccircle cx=\"11\" cy=\"11\" r=\"8\"\u002F>\u003C\u002Fg>",[217],{"title":218,"path":219,"stem":220,"children":221,"page":212},"Docs","\u002Fdocs","docs",[222,239,259,288,299],{"title":223,"path":224,"stem":225,"children":226,"page":212},"Get started","\u002Fdocs\u002Fget-started","docs\u002F1.get-started",[227,231,235],{"title":228,"path":229,"stem":230},"Install","\u002Fdocs\u002Fget-started\u002Finstall","docs\u002F1.get-started\u002F1.install",{"title":232,"path":233,"stem":234},"Pair a browser","\u002Fdocs\u002Fget-started\u002Fpair-a-browser","docs\u002F1.get-started\u002F2.pair-a-browser",{"title":236,"path":237,"stem":238},"Your first task","\u002Fdocs\u002Fget-started\u002Fyour-first-task","docs\u002F1.get-started\u002F3.your-first-task",{"title":240,"path":241,"stem":242,"children":243,"page":212},"Using zerohead","\u002Fdocs\u002Fusing-zerohead","docs\u002F2.using-zerohead",[244,245,246,247,251,255],{"title":5,"path":6,"stem":7},{"title":14,"path":205,"stem":207},{"title":9,"path":10,"stem":11},{"title":248,"path":249,"stem":250},"Budgets and approvals","\u002Fdocs\u002Fusing-zerohead\u002Fbudgets-and-approvals","docs\u002F2.using-zerohead\u002F4.budgets-and-approvals",{"title":252,"path":253,"stem":254},"Connectors","\u002Fdocs\u002Fusing-zerohead\u002Fconnectors","docs\u002F2.using-zerohead\u002F5.connectors",{"title":256,"path":257,"stem":258},"Remote access","\u002Fdocs\u002Fusing-zerohead\u002Fremote-access","docs\u002F2.using-zerohead\u002F6.remote-access",{"title":260,"path":261,"stem":262,"children":263,"page":212},"Agents","\u002Fdocs\u002Fagents","docs\u002F3.agents",[264,268,272,276,280,284],{"title":265,"path":266,"stem":267},"Claude Code","\u002Fdocs\u002Fagents\u002Fclaude-code","docs\u002F3.agents\u002F1.claude-code",{"title":269,"path":270,"stem":271},"Codex","\u002Fdocs\u002Fagents\u002Fcodex","docs\u002F3.agents\u002F2.codex",{"title":273,"path":274,"stem":275},"OpenCode","\u002Fdocs\u002Fagents\u002Fopencode","docs\u002F3.agents\u002F3.opencode",{"title":277,"path":278,"stem":279},"Pi","\u002Fdocs\u002Fagents\u002Fpi","docs\u002F3.agents\u002F4.pi",{"title":281,"path":282,"stem":283},"Cursor","\u002Fdocs\u002Fagents\u002Fcursor","docs\u002F3.agents\u002F5.cursor",{"title":285,"path":286,"stem":287},"Scripts and HTTP","\u002Fdocs\u002Fagents\u002Fscripts-and-http","docs\u002F3.agents\u002F6.scripts-and-http",{"title":289,"path":290,"stem":291,"children":292,"page":212},"Reference","\u002Fdocs\u002Freference","docs\u002F4.reference",[293,295],{"title":166,"path":165,"stem":294},"docs\u002F4.reference\u002F1.settings",{"title":296,"path":297,"stem":298},"Command line","\u002Fdocs\u002Freference\u002Fcommand-line","docs\u002F4.reference\u002F2.command-line",{"title":300,"path":301,"stem":302,"children":303,"page":212},"Contributing","\u002Fdocs\u002Fcontributing","docs\u002F5.contributing",[304],{"title":305,"path":306,"stem":307},"Build from source","\u002Fdocs\u002Fcontributing\u002Fbuild-from-source","docs\u002F5.contributing\u002F1.build-from-source",{"id":309,"clone":310,"description":311,"docsNotice":312,"extension":313,"meta":314,"status":315,"stem":318,"__hash__":319},"source\u002Fsource\u002Fprivate.yml",null,"Run a company of AI agents on your own computer. The source will be published under MIT.","The source is not public yet. It will be published under MIT. The pages under Contributing describe working on it once it is.","yml",{},{"lead":316,"text":317},"Early.","The source is not public yet. It will be published under MIT.","source\u002Fprivate","ZIRSRgoDOBHkU54QRPpdRltyFcq_DTWub-4p70w1DaY",1796109414045,"515e4a29-51e4-43d8-b774-a8b94f7dc369"]