Skip to content

feat(mcp): let agents create tasks in other projects - #378

Open
gnutix wants to merge 1 commit into
johannesjo:mainfrom
gnutix:feat/cross-project-tasks
Open

gnutix wants to merge 1 commit into
johannesjo:mainfrom
gnutix:feat/cross-project-tasks

Conversation

@gnutix

@gnutix gnutix commented Nov 16, 2026 •

Copy link
Copy Markdown

Summary

An agent working in one project sometimes finds work that belongs to another one. For example, an app's agent hits a bug in a library you also have open in Parallel Code. Today it can only describe the bug: 53a6add made other projects readable, but create_task still creates tasks in the caller's project only.

This adds the write half, kept as narrow as the read half:

  • Setting: "Allow agents to create tasks in other projects" (Settings > Agents, global, off by default, needs orchestration). It sits beside the cross-project read setting and is independent of it.
  • Tool: create_task with relation: 'independent' takes an optional project: an id, or a name matched without regard to case. An unknown name answers with the list of projects, and an ambiguous one with names and ids. Naming the caller's own project is an ordinary independent task. relation: 'child' with project is refused, so children stay in their parent's project.
  • Confirmation per task: each task in another project opens a native dialog naming both projects, the task and the start of its prompt. Deny is the default for Enter and Escape, and dialogs show one at a time. Unlike reads, the call waits for the answer, because the agent needs the result and the user is approving that exact task. The setting, pause, orchestration and session checks run again before the dialog opens and after the user answers, so switching any of them off in the meantime refuses the task.
  • Otherwise an ordinary independent task of the target project: it starts from that project's main branch, uses the creator's agent, sandbox and permission propagation (same rule as today), counts against the creator's independent-task cap, and the user reviews it. The renderer re-checks that the target is a code project.

Main resolves names through the renderer's project list (the request the phone already uses), because project names and removals live there. docs/design-doc.md describes the setting next to the read setting.

Screenshots

Settings > Agents, with agent orchestration on:

Before After
before after
Only the read setting reaches other projects. The new setting sits right below it, off by default.

Test plan

  • npm run check
  • npm test (both suites)
  • New delegation.test.ts cases: refused while off (no listing, no dialog), waits for approval and passes the target project, replays without a second dialog, a reused request ID for another project is refused, denial creates nothing, own project skips the dialog, unknown and ambiguous names list projects, switching the setting off or pausing during the dialog refuses after approval, one dialog at a time, children refused.
  • Renderer: an approved task is created in the target project with the creator's agent and sandbox; document projects are refused. The setting restores and saves.
  • Not exercised in the running app with a real agent: the native dialog and an end-to-end creation.

🤖 Generated with Claude Code (Opus 5.5)

Global setting, off by default. create_task with relation
'independent' takes an optional project, by id or by name ignoring
case; an unknown or ambiguous name lists the projects. Each task in
another project asks the user first in a native dialog that shows
both projects, the task and its prompt, with Deny as the default,
one dialog at a time. The call waits for the answer, and rechecks
the setting, pause, orchestration and session after it. The task is
otherwise an ordinary independent task of the target project: the
creator's agent, sandbox and permission propagation, its main
branch, and the creator's independent-task cap. Children stay in
the creator's project.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
gnutix added a commit to gnutix/parallel-code that referenced this pull request Nov 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant