Guides

Build mode

Let agents plan and execute task queues — draft a build plan from a goal, or let the agent work through ready-for-dev tasks.

Overview

Build mode lets a project's build agent automatically work through ready-for-dev tasks. The agent processes tasks in strict order (sortOrder ascending), one at a time, completing each before moving to the next.

ModeWhat happens
ManualHuman starts the build; agent works the queue until stopped
DraftAgent plans the queue from a goal, then optionally executes
Draft + GoAgent plans and immediately executes the queue

Setup

Before using build mode, ensure:

  1. 1The project has a build agent assigned (Agents tab > Set build agent).
  2. 2The build agent has a provider API key (teamshare-agent key set).
  3. 3The build agent has a linked project folder (teamshare-agent link).
  4. 4The bridge daemon is running (teamshare-bridge daemon).

Install the bridge

install
npm i -g teamshare-bridge
teamshare-agent connect --agent <agent-id> --key ts_...

Install a harness (optional)

Build mode works with any harness. If you don't have one installed, headless mode (--self) works out of the box with just an LLM API key.

HarnessInstallNotes
opencode (recommended)npm i -g opencode-ai or https://opencode.aiFull file/shell access
Claude Codenpm i -g @anthropic-ai/claude-codeRequires Anthropic account
--self headlessNo install needed — just LLM_API_KEYDeepSeek, OpenRouter, OpenAI...

Draft mode (--draft)

Draft mode uses an LLM to plan a build queue from a free-text goal. The agent creates concrete tasks in the build queue, ordered by dependencies.

Plan a build from a goal
teamshare-agent build --agent <id> --key ts_... --project <projectId> --draft "Build a Next.js landing page with hero, features, pricing, and contact form"

This creates tasks in the build queue, each with readyForDev: true and increasing sortOrder. Dependencies come first.

What the LLM creates

The agent calls create_task via the API for each planned task. Tasks appear in the Build tab of the project immediately.

Draft + Execute (--draft --go)

Add the --go flag to plan and immediately start executing the queue.

Plan and execute in one step
teamshare-agent build --agent <id> --key ts_... --project <projectId> --draft "Build a REST API with CRUD endpoints" --go

Prerequisites for --go

The build agent must have a provider API key, a linked project folder, and the bridge daemon running.

Manual build queue

Without --draft, the agent works through tasks that are already in the build queue (readyForDev: true).

  1. 1Create tasks with readyForDev: true in the Tasks tab.
  2. 2Set sortOrder to control the execution order.
  3. 3Assign the build agent to the project.
  4. 4Start the build from the Build tab or CLI.
Start a manual build
teamshare-agent build --agent <id> --key ts_... --project <projectId>

Agent questions

If the agent encounters ambiguity, it posts a question comment on the task. The build pauses until a human answers.

  1. 1The agent posts a question comment on the task.
  2. 2The build queue shows the task as Blocked.
  3. 3A human answers the question in the task comments.
  4. 4The agent resumes work on the task.

Build tab shows blocked tasks

The Build tab displays blocked tasks with the open question, so you can quickly see what needs human input.