Skip to content

[Story] Run uf-forge multi-agent work in one FullSend sandbox #518

Description

@beatrizmcouto

👤 User Story

As a
team running uf swarm / forge work

I want to
uf-forge to delegate via OpenCode sub-agents inside a single FullSend sandbox

So that
FullSend still sees one agent while uf keeps multi-agent behavior and local/FullSend parity holds for the last SDD stage

🎯 Acceptance Criteria

  • uf-forge harness runs in one sandbox; OpenCode sub-agent delegation is used (FullSend is not asked to orchestrate N agents)
  • uf gate applies before PR
  • Security-hook controls apply
  • Documented parity: local forge vs FullSend forge for a representative change
  • Adoption note for other teams: same upstream OpenCodeRuntime + their own .opencode/ — no second methodology to maintain

🚫 Out of Scope

  • Dewey MCP / Ollama in the image
  • Per-org FullSend install
  • Hybrid Approach C starter skill

Dependencies

  • Increment 4 uf-code
  • uf gate
  • security-hook gap closed

Increment 5. Multi-agent + ops/failure modes inside one sandbox. Comparable to L integration/orchestration items (council-review-action, gaze JSON-RPC analyzer), not XL because runtime and gate already exist.

🏁 Definition of Done — 🛠️ Quality & Testing

  • Code has been peer-reviewed for bugs and vulnerabilities.
  • Proper testing has been completed and passes (Unit, Integration, E2E via GitHub Actions).
  • The feature has been demonstrated/validated successfully in the target environment.

🏁 Definition of Done — 📝 Architecture & Docs

  • Usage documentation or changelog updated (if user-facing changes introduced).
  • Local ADR written and verified by Tech Lead if technical architecture deviated.
  • Any newly introduced technical debt has been logged as a GitHub issue.

Context


Implementation Notes (added by @jflowers, Aug 2026)

Architecture: uf-forge runs in one FullSend sandbox using OpenCode's sub-agent delegation (FullSend does NOT orchestrate N separate agents — that's the key architectural distinction).

How it works: the primary forge agent delegates to sub-agents (coordinator, workers, etc.) within a single OpenCode session. FullSend sees one agent run with one sandbox, one set of metrics, one transcript. Multi-agent coordination happens inside OpenCode, not inside FullSend.

Gate enforcement: uf gate --phase pr before the forge output is merged — final quality check.

Security: all controls from #515 must be in place (write-capable, multi-agent).

Parity: document local vs FullSend forge behavior differences. Key divergence: MCP servers (Dewey, Replicator) are disabled in sandbox (--pure); forge must work without them or selective MCP enablement must be addressed.

Adoption note for other teams: same upstream OpenCodeRuntime + their own .opencode/ directory. No second methodology required — the BYOA is the runtime + image + harnesses, while the methodology lives in the repo's .opencode/.

Dependencies: Inc4 (#517) — implement must work first; uf gate (#514); security hook gap (#515) closed.


Design note: --pure mode vs. forge MCP coordination (added Aug 2026, per review feedback)

Conflict identified: --pure disables all MCP tools for security isolation, but forge coordination depends on Replicator MCP tools (comms_init, comms_reserve, hivemind_*). These are mutually exclusive — Inc5 cannot work with --pure as currently specified.

Recommended direction: For Inc5 only, drop --pure and instead ship a scoped opencode.json / OPENCODE_CONFIG_CONTENT that:

  1. Enables only the Replicator MCP server (coordination tools)
  2. Disables Dewey and any other external MCP servers
  3. Applies permission denials for tools not needed by forge (e.g., webfetch: deny, websearch: deny)

This achieves selective allowlisting rather than all-or-nothing MCP control. The security surface is wider than Inc1-4 (which use --pure), so this approach is explicitly gated on #515 (security-hook gap closure).

Spike needed: Before #518 enters the spec pipeline, confirm:

  • OpenCode's per-server MCP granularity (enabled/disabled per server in opencode.json — believed supported)
  • Whether per-tool filtering within a server is available (if not, filesystem-based coordination is the fallback)
  • Residual risk profile of enabling Replicator without --pure

Fallback: If MCP granularity is insufficient, switch to filesystem-based coordination in one sandbox (no MCP). This changes the forge communication model but preserves single-sandbox isolation.

Dependency reaffirmed: This story MUST NOT start before #515 closes the security-hook gap.

Activity

  1. added
    enhancement
    llm_assisted
    on Aug 17, 2026
  2. added this to the FullSend BYOA milestone on Aug 18, 2026
  3. yvonnedevlinrh commented on Aug 18, 2026

    @yvonnedevlinrh
    Contributor

    Review feedback

    The triage panel returned NEEDS-CLARIFICATION (3/5) with a blocking architectural concern:

    --pure mode vs. forge coordination: --pure disables all MCP tools for security isolation. However, forge coordination depends on Replicator MCP tools — specifically comms_init, comms_reserve, and hivemind_*. These are mutually exclusive. This story cannot work as currently designed.

    This is not a clarification — it's a design conflict that needs resolution at the Discussion #437 level before this story can be scoped. I've flagged it there as well.

    Additional concerns from the panel:

    • All three dependencies (uf gate, uf-code, security-hook) have zero codebase evidence — the dependency chain is entirely
      unverifiable
    • The panel recommended decomposition into 4 child issues and noted this likely requires Speckit-tier specification (cross-repo scope:
      containerfile/image, OpenCode runtime, Replicator MCP)
    • Resource scaling is a concern — the current sandbox defaults (8GB/4CPU) may be insufficient for N concurrent sub-agents

    Recommendation: Park this story until the --pure/MCP conflict is resolved architecturally and dependencies #514, #515, #517 have landed. This is the correct last increment in the sequence — it doesn't need to be actionable yet.

  4. yvonnedevlinrh commented on Aug 31, 2026

    @yvonnedevlinrh
    Contributor

    Nested sub-agent hook coverage (referenced from #515)

    #515's contract discussion referenced a nested-sub-agent hook-coverage note here, but it was never added. Recording it now:

    Verified on dev: OpenCode's Task tool spawns a child session that runs the same prompt loop (session/prompt.ts), so nested sub-agent tool calls also fire tool.execute.before/after. This means the #515 security-hook plugin covers the forge multi-agent case (this story) without extra per-sub-agent wiring — stronger than ADR 0090's top-level-shaped model assumes.

    Residual (scope confirmation, not a blocker): confirm fullsend treats ADR 0090's contract as covering nested Task calls (vs.
    top-level-only intended scope). To be surfaced in the OpenCodeRuntime PR description, not a pre-emptive ask. This is the increment where nested coverage becomes load-bearing, so verify it as part of the "Security-hook controls apply" acceptance criterion.

    (Unrelated open item on this story — the --pure vs. Replicator MCP coordination conflict — is tracked separately in the review-feedback comment above and is the actual gating concern for scoping #518.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementllm_assisted

    Projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions