Skip to content

Track disposable sandbox principal, runtime tools, and package import contracts #277

@chubes4

Description

@chubes4

Problem

WP Codebox currently compensates for generic agent-substrate gaps when running agents inside disposable WordPress Playground sandboxes:

  • bypasses agents/chat permission filters inside the browser runner
  • injects sandbox runtime tools through Data Machine's datamachine_resolved_tools filter
  • imports Data Machine agent bundles as the practical transport for sandbox agent definitions
  • depends on Data Machine-specific tool names/policy vocabulary for sandbox-safe vs parent-only tools
  • relies on product/Data Machine pending-action adapters where generic approval substrate should be enough

These are reasonable local adaptations today, but the generic substrate should define enough contracts that Codebox can be a clean sandbox runtime consumer rather than a Data Machine-specific adapter.

Related Codebox pressure points:

  • browser runner permission bypass in disposable Playground scope
  • runtime filesystem-write tool registration
  • sandbox Data Machine tool allow/deny policy
  • agent bundle import path
  • pending-action/apply-back integration

Desired direction

Agents API should provide generic contracts for:

  • a trusted disposable sandbox principal / runtime execution scope
  • runtime-local tool source registration and mediation
  • package or agent-definition import usable by ephemeral runtimes
  • scoped tool capability metadata, e.g. safe in disposable runtime vs parent control plane only
  • pending-action mediation hooks usable by products without direct Data Machine helper dependencies

Acceptance criteria

  • Define which pieces already exist in Agents API and which are missing.
  • Propose the smallest substrate additions needed for WP Codebox to remove Data Machine-specific compensation.
  • Keep concrete storage, UI, workflow jobs, and product apply behavior outside Agents API.
  • Link follow-up implementation issues in WP Codebox/Data Machine where consumer migrations are needed.

Source evidence

  • WP Codebox trait-wp-codebox-abilities-browser-runner.php
  • WP Codebox class-wp-codebox-agent-sandbox-runner.php
  • WP Codebox sandbox-datamachine-tool-policy.*
  • WP Codebox class-wp-codebox-data-machine-pending-actions.php

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions