mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-10-21 16:27:18 +02:00
## Thinking Path > - Paperclip is the open source app people use to manage AI agents for work. > - An agent needs personal files across tasks and sessions. > - AGENTS.md is one file in that directory. Supporting files need the same persistence. > - The Instructions Editor and agent runs must share one current directory. > - Concurrent runs should apply only the files they change. The last sync of the same file wins. > - This pull request uses existing file transport and removes temporary copies after sync. > - Old instruction-only sessions keep their restore contract. New saves do not create revision history. ## Linked Issues or Issue Description Refs #14325. This replaces its revision-oriented design with persistent agent files. Keep #14325 unmerged. Transport prerequisite #14416 merged first at `d172197117a14b80a1eb2d2835a0e7cce2679656`. This PR now targets master and remains below 100 changed files. Related work: #4513 and #8798 cover instruction tooling. This change handles run synchronization, cross-task personal files, browser editing, and old-session restoration. ## What Changed - Keep one current directory per company and agent. Point AGENT_HOME at a temporary working copy for each active run. Keep task files and provider HOME separate. - Restore text, binary files, and nested folders through workspace transport. Exclude remote agent files from task Git snapshots with a self-ignoring file inside the reserved runtime directory; never write through repository-controlled Git metadata. - Collect after the provider and child processes have stopped. Keep resumable conversation state. - Apply changed and deleted files under the agent lock. The last sync wins for the same file. Unrelated concurrent changes survive. - Remove temporary copies after successful sync, rejected sync, and staging failure. Register ownership before copying so restart recovery can remove interrupted preparation. Retry transient synchronization up to three times. Preserve the original remote lease reference until deletion succeeds; restart cleanup never acquires a replacement sandbox. Do not create captured directories or a conflict-review queue for new runs. - Keep browser editing, stale-draft protection, and streaming binary downloads. Keep the instruction entry and text editor limited to 1 MiB. - Keep historical agent-folder sync failures on their affected runs instead of repeating them above current saved instructions. Preserve legacy candidate review and current browser-save errors. Avoid duplicate quota warnings while retaining separate sync failures when they describe a different problem. - Require target-scoped caller grants for peer instruction access, while preserving self edits, responsible-user checks, and protected-change consent. - Treat full storage as a nonblocking run warning, never an agent pause or run-admission failure. Restore already-over-quota saved folders so ordinary agent cleanup can recover; warn on each run until cleanup. The run detail view shows the warning. - Allow 256 MiB per file, 2 GiB per directory, and 100,000 entries. Hash large files as streams. Check editor-save quotas with metadata instead of hashing unrelated files. - Preserve old native inputs, instruction-only copies, paths, digests, and pending legacy candidates. Adopt old revision heads once. New writes do not append history rows. - Add idempotent migration 0287 and verify upgrades from the preview tables and receipts. - Add nine interactive stories under **Agents / Persistent files**, including automatic incoming edits, stale browser drafts, and storage-limit diagnostics. ## Verification - Merge candidate: `4f5390107ec6ffd80a76d1d2e85530e66f21d079`, after merging current master and the landed transport prerequisite. Integration required no manual conflict resolution; the feature remains 99 changed files. Full workspace typecheck, production build, token gates, and 715 focused tests passed on this merge candidate. Fresh Greptile review is 5/5 with no unresolved findings. All 55 checks passed, with four conditional skips, including the build, typecheck, browser E2E, and canary dry run. A single retry recovered four jobs interrupted by runner shutdowns; no source changes were required. - Historical-warning UI fix: all 6,834 UI tests across 640 files passed, including regression coverage for three old failures, legacy preserved edits, and warnings scoped to the affected run. Full workspace typecheck, production build, Storybook build, and token gates passed. Browser-verified Storybook playtests passed for Historical Failures After Successful Save, Storage Limit, and Full Storage Run Warning. - Review follow-ups at `4e20c9fb2`: all 18 focused tests passed, including external Git directories, linked worktrees, symlinks, hardlinks, and distinct I/O failures alongside storage warnings. Server and UI typechecks, token gates, and the production build passed. - Storage warning regressions at `0724f3012`: all 33 directory tests and all five heartbeat-list tests passed, with no skips in their successful runs. They cover repeated runs while full, an already-over-quota saved folder, cleanup, warnings retained after unrelated save failures, and bounded warnings in large result JSON. Server typecheck passed after the final warning fixes. - Full workspace typecheck, production build, and token gates passed during this follow-up. Product E2E harness: 631 tests passed across 52 files; harness typecheck passed. Earlier native session/context and directory/legacy collection suites passed 537 tests; Runner unit/transport suites passed 329 tests. - **Real E2E at `0724f3012` (before this follow-up):** legacy local Codex and native Daytona Codex each passed six tasks, one server restart, seven independent assertions, and cleanup verification. Both prove browser-to-agent edits, agent-to-browser edits, nested/binary restoration, per-file last-sync-wins, a successful run after an oversized save rejection, and cleanup clearing the warning. - Native local Codex also passed the six-task quota flow before the final warning-retention fixes. That pass began at `918d1ed02` while the bounded-result warning fix was being edited, so it is not claimed as exact-final-head evidence. Its final-head rerun failed during embedded PostgreSQL bootstrap before any provider run: the macOS host had 87,365 of 87,381 SysV semaphores occupied. No unrelated services or kernel limits were changed. - The final-source report intentionally records **2/3 cells passed**, preserving the blocked native-local attempt: `tests/runner-e2e/results/agent-files-quota-final-20260928-report/`. Earlier failed attempts and provenance notes remain under `tests/runner-e2e/results/agent-files-quota-final-20260928-input/` and the original campaign directories. - Daytona used immutable image `ghcr.io/paperclipai/paperclip-daytona-runner@sha256:5643f0d801417cae3581833a1a3bc6715b325e028602738d2652c44cac5dc6bf` and its exact Linux runner binary. Controller source is `0724f3012`; image source is recorded separately. - Legacy-session compatibility and all three ACP Stop/resume browser regressions passed on the prior validated feature head `169fab46d5af21caa2269b4c1b29b69c933a6951`. They assert the same provider session is retained and interrupted writes are not replayed. Migration upgrade tests also passed earlier. - Nine interactive stories are under **Agents / Persistent files**, including **Full Storage Run Warning**. Its playtest and visual browser inspection passed; the warning states that runs continue and the editor remains available. - Prior-head checks on `4e20c9fb2`: 55 passed, two conditional jobs skipped, no failures or pending checks. All eight browser E2E shards and their aggregate passed. Fresh Greptile review is 5/5 with no findings; all review threads are resolved, the security scan passed, and GitHub reports no merge conflicts. - The broad local follow-up test run was interrupted after host semaphore exhaustion affected isolated PostgreSQL instances. It also encountered the existing macOS long-path fixture failure and two timeout failures. This is not a claim that the full local suite passed. Logs are retained; focused storage/warning tests passed. ## Risks - A later sync can overwrite an earlier edit to the same file, including a saved browser edit. There is no text merge or retained version. This is the intended last-sync-wins policy. - A save that exceeds a storage limit is rejected and its temporary copy is discarded. The run itself continues normally, and later runs restore the last saved files with a warning until cleanup. Transient sync failures get bounded retries. An I/O failure partway through a sync can leave some files updated; a failed receipt does not claim whole-folder success. - Larger folders increase copy time, network traffic, and temporary disk usage. Active runs still need working copies. Terminal runs do not accumulate archives. Operators must provision disk for agents and configured concurrency; these limits are not company-wide quotas. - A restored old native session remains instruction-only until a fresh session starts. Its original conflict fence and existing pending candidates remain compatible. - Provider processes close at the collection boundary. Conversation resume remains available, but warm process reuse is lost. - Backups must include the instance filesystem and database. External bundles keep their existing behavior until explicitly moved to managed storage. ## Model Used OpenAI Codex, GPT-6 family. The session does not expose a more specific model ID or context-window size. Reasoning, code execution, and browser tools assisted this change. Real provider E2E uses `gpt-5.6-sol`. ## Checklist - [x] I have included a thinking path that traces from project context to this change - [x] I have specified the model used (with version and capability details) - [x] I have checked ROADMAP.md and confirmed this PR does not duplicate planned core work - [x] I have searched GitHub for duplicate or related PRs and linked them above - [x] I have either (a) linked existing issues with `Fixes: #` / `Closes #` / `Refs #` OR (b) described the issue in-PR following the relevant issue template - [x] I have not referenced internal/instance-local Paperclip issues or links (only public GitHub `#NNN` / `github.com/paperclipai/paperclip` URLs) - [x] My branch name describes the change (e.g. `docs/...`, `fix/...`) and contains no internal Paperclip ticket id or instance-derived details - [x] I have run tests locally and they pass - [x] I have added or updated tests where applicable - [x] I have updated relevant documentation to reflect my changes - [x] I have considered and documented any risks above - [x] All Paperclip CI gates are green - [x] Greptile is 5/5 with no open P2s, recommendations, or follow-ups - [x] I will address all Greptile and reviewer comments before requesting merge --------- Co-authored-by: Fry (Paperclip) <noreply@paperclip.ing>
372 lines
26 KiB
JSON
372 lines
26 KiB
JSON
{
|
|
"schemaVersion": 1,
|
|
"documentTitle": "Paperclip agent operation groups",
|
|
"evalRepositoryUrl": "https://github.com/paperclipai/paperclip-evals/blob/master/",
|
|
"prpEventFamilyDescriptions": {
|
|
"runner": "Runner connection, drain, and diagnostic lifecycle.",
|
|
"runtime": "Runner phase transitions.",
|
|
"sandbox": "Sandbox resource measurements.",
|
|
"workspace": "Workspace readiness.",
|
|
"harness": "Provider harness startup, readiness, exit, and diagnostics.",
|
|
"session": "Provider-neutral session open, resume, reconciliation, close, and failure.",
|
|
"turn": "Model turn submission through terminal turn disposition.",
|
|
"item": "Provider-neutral model/tool item lifecycle.",
|
|
"mcp_app": "MCP App discovery, initialization, tool, action, host-context, and teardown evidence.",
|
|
"runtime_request": "Runtime permission/input request lifecycle.",
|
|
"interaction": "Issue-thread interaction proposal, materialization, response, delivery, and rejection.",
|
|
"run": "Structured result negotiation and terminal run outcome.",
|
|
"attention": "Continuation and attention routing lifecycle.",
|
|
"work": "Recorded work-assessment evidence.",
|
|
"issue": "Issue-status decision proposal outcome and application evidence.",
|
|
"plan": "Complete provider-authored within-turn checklist snapshots, separate from durable Paperclip Plan documents.",
|
|
"tool": "Provider-neutral process, MCP, dynamic, and built-in execution activity.",
|
|
"research": "Provider-reported search, page-open, and in-page research activity.",
|
|
"delegation": "Child-agent delegation lifecycle and aggregate status.",
|
|
"model": "Requested/effective model routing and verification state.",
|
|
"context": "Context-window compaction markers without hidden summaries.",
|
|
"artifact": "Authorized artifact viewing and structured generated outputs.",
|
|
"review": "Provider review-mode state, separate from Paperclip authority.",
|
|
"hook": "Bounded provider hook lifecycle and blocking outcomes.",
|
|
"memory": "Authorized or unavailable memory citation references.",
|
|
"safety": "Provider safety review state attached to governed work.",
|
|
"terminal": "Content-free terminal input activity metadata.",
|
|
"wait": "Intentional provider waits, distinct from warm idle and human input.",
|
|
"provider": "Redacted provider notices and actionable warnings.",
|
|
"semantic_tool": "Canonical authorized Paperclip tool input and result evidence.",
|
|
"usage": "Provider/model-attributed usage and accounting boundaries."
|
|
},
|
|
"prpCommandFamilyDescriptions": {
|
|
"semantic_tool": "Returns an authorized, correlated Paperclip tool result to the provider through runnerd.",
|
|
"run": "Prepare or cancel a run.",
|
|
"session": "Open, snapshot, or close a normalized provider session.",
|
|
"turn": "Start, steer, interrupt, or stop a model turn.",
|
|
"request": "Resolve a pending runtime request.",
|
|
"interaction": "Acknowledge delivery of an interaction response.",
|
|
"runner": "Drain or shut down the runner process."
|
|
},
|
|
"optionalGrantGroups": [
|
|
{
|
|
"id": "discovery",
|
|
"description": "Company-visible task, agent, project, and goal discovery.",
|
|
"operationIds": ["search_tasks", "list_agents", "get_agent", "list_projects", "list_goals"]
|
|
},
|
|
{
|
|
"id": "projects",
|
|
"description": "Project creation and authorized repository discovery through the live company/run authority.",
|
|
"operationIds": ["create_project", "list_project_repositories"]
|
|
},
|
|
{
|
|
"id": "delegation_dependencies",
|
|
"description": "Create or reassign delegated work and maintain dependency edges.",
|
|
"operationIds": ["create_task", "reassign_task", "set_dependencies", "hire_agent"]
|
|
},
|
|
{
|
|
"id": "governance",
|
|
"description": "Read, request, comment on, and decide approvals under governed-action checks.",
|
|
"operationIds": ["list_approvals", "get_approval", "get_approval_context", "request_approval", "decide_approval", "comment_on_approval"]
|
|
},
|
|
{
|
|
"id": "cases",
|
|
"description": "Read and update case summaries without reusing issue-document authority.",
|
|
"operationIds": ["list_cases", "upsert_case"]
|
|
},
|
|
{
|
|
"id": "workspace_runtime",
|
|
"description": "Inspect and control the active issue workspace runtime.",
|
|
"operationIds": ["get_workspace_runtime", "control_workspace_service"]
|
|
},
|
|
{
|
|
"id": "wake_scheduling",
|
|
"description": "Schedule a bounded continuation wake when the current task owns the future check.",
|
|
"operationIds": ["schedule_wake"]
|
|
},
|
|
{
|
|
"id": "routines",
|
|
"description": "Inspect or manage company routines.",
|
|
"operationIds": ["list_routines", "manage_routine"]
|
|
},
|
|
{
|
|
"id": "company_skills",
|
|
"description": "Create or inspect company skills and synchronize the current agent's skills.",
|
|
"operationIds": ["create_skill", "list_company_skills", "sync_company_skills"]
|
|
},
|
|
{
|
|
"id": "secrets",
|
|
"description": "Inspect secret metadata or use a brokered secret value without exposing plaintext evidence.",
|
|
"operationIds": ["list_secret_metadata", "read_secret_value"]
|
|
},
|
|
{
|
|
"id": "portability_admin",
|
|
"description": "Export portable company state; broad administration remains deferred until split into governed operations.",
|
|
"operationIds": ["export_company", "administer_company"]
|
|
},
|
|
{
|
|
"id": "test_escape_hatch",
|
|
"description": "Controlled skill-test transport only; never product coverage.",
|
|
"operationIds": ["generic_api_request"]
|
|
},
|
|
{
|
|
"id": "api_fallback",
|
|
"description": "Discover and invoke HTTP API operations unsupported by available dedicated tools. Production authority and route authorization remain required.",
|
|
"operationIds": [
|
|
"search_api",
|
|
"call_api"
|
|
]
|
|
}
|
|
],
|
|
"behaviorGroups": [
|
|
{
|
|
"id": "hb",
|
|
"legacyGroup": 1,
|
|
"name": "Heartbeat",
|
|
"owner": "control plane + always tools",
|
|
"operationIds": ["get_task_context"],
|
|
"controlPlaneOperationIds": ["select_work", "enforce_budget"],
|
|
"realSurface": "agent identity, inbox-lite, heartbeat context, budget and active-issue services",
|
|
"mockStateDomains": ["company", "actor", "wake", "task", "budget", "run"],
|
|
"prpEvidence": "runner/session/run context plus bounded task-context tool results",
|
|
"gap": "Production semantic binding is unbound; identity and work selection remain injected/control-plane-owned."
|
|
},
|
|
{
|
|
"id": "co",
|
|
"legacyGroup": 2,
|
|
"name": "Checkout",
|
|
"owner": "control plane",
|
|
"operationIds": [],
|
|
"controlPlaneOperationIds": ["checkout_task"],
|
|
"realSurface": "POST /api/issues/:id/checkout and execution-lock services",
|
|
"mockStateDomains": ["task", "actor", "run", "idempotency", "fault"],
|
|
"prpEvidence": "run preparation and issue-status decision evidence with checkout receipt",
|
|
"gap": "Intentionally no model tool; the production checkout receipt still needs the additive semantic-receipt envelope."
|
|
},
|
|
{
|
|
"id": "st",
|
|
"legacyGroup": 3,
|
|
"name": "Status",
|
|
"owner": "always tools + control-plane arbitration",
|
|
"operationIds": ["answer_status_question", "finish_task", "block_task", "request_review"],
|
|
"controlPlaneOperationIds": ["reconcile_run", "append_audit_record"],
|
|
"realSurface": "issue PATCH, review/liveness policy, and native finalization arbitration",
|
|
"mockStateDomains": ["task", "comments", "interactions", "blockers", "audit", "run"],
|
|
"prpEvidence": "semantic operation receipt, work assessment, issue-status decision, and terminal causality",
|
|
"gap": "Production semantic binding and additive typed operation/conflict receipts remain unimplemented."
|
|
},
|
|
{
|
|
"id": "cm",
|
|
"legacyGroup": 4,
|
|
"name": "Comments",
|
|
"owner": "always tools",
|
|
"operationIds": ["get_task_history", "report_progress"],
|
|
"controlPlaneOperationIds": ["append_audit_record"],
|
|
"realSurface": "issue comment list/get/create routes",
|
|
"mockStateDomains": ["task", "comments", "actor", "idempotency", "audit"],
|
|
"prpEvidence": "bounded read result or idempotent comment-write receipt plus audit reference",
|
|
"gap": "Active-task binding is unbound; cross-task comment mutation is deliberately outside V1."
|
|
},
|
|
{
|
|
"id": "se",
|
|
"legacyGroup": 5,
|
|
"name": "Search",
|
|
"owner": "optional discovery tools",
|
|
"operationIds": ["search_tasks", "list_agents", "get_agent", "list_projects", "list_goals", "list_project_repositories"],
|
|
"controlPlaneOperationIds": [],
|
|
"realSurface": "company issue search and agent/project/goal list/get routes",
|
|
"mockStateDomains": ["company", "task", "actor", "project", "goal"],
|
|
"prpEvidence": "bounded redacted read projections through tool-result item events",
|
|
"gap": "Goal operations remain scenario-only. Project and repository discovery contracts are delivered by the live server authority; they are not implemented by the mock command dispatcher."
|
|
},
|
|
{
|
|
"id": "su",
|
|
"legacyGroup": 6,
|
|
"name": "Subtasks",
|
|
"owner": "optional delegation tools",
|
|
"operationIds": ["create_task", "reassign_task", "hire_agent"],
|
|
"controlPlaneOperationIds": ["route_wake"],
|
|
"realSurface": "company issue create, child issue, guarded reassignment, and wake services",
|
|
"mockStateDomains": ["company", "task", "actor", "blockers", "wake", "audit"],
|
|
"prpEvidence": "company/task state diff, audit reference, and continuation wake evidence",
|
|
"gap": "create_task is production-bound to ordinary active-issue child creation with assignment, dependency-ready wake, company checks, child limits, and durable source-scoped idempotency."
|
|
},
|
|
{
|
|
"id": "bl",
|
|
"legacyGroup": 7,
|
|
"name": "Blockers",
|
|
"owner": "always/optional tools + control plane",
|
|
"operationIds": ["block_task", "set_dependencies"],
|
|
"controlPlaneOperationIds": ["schedule_blocker_wake", "route_wake"],
|
|
"realSurface": "issue relations, blocker projection, liveness validation, and blocker wake services",
|
|
"mockStateDomains": ["task", "blockers", "wake", "actor", "audit", "fault"],
|
|
"prpEvidence": "dependency diff, block receipt, attention routing, and issue-status decision",
|
|
"gap": "set_dependencies is production-bound for the active issue; block_task remains unbound, and cancelled-blocker receipts still need typed additive evidence."
|
|
},
|
|
{
|
|
"id": "dp",
|
|
"legacyGroup": 8,
|
|
"name": "Documents and plans",
|
|
"owner": "always tools; restore optional; destructive lifecycle control-plane-only",
|
|
"operationIds": ["list_documents", "read_document", "list_document_revisions", "write_document"],
|
|
"controlPlaneOperationIds": ["append_audit_record"],
|
|
"realSurface": "issue document list/read/upsert/revision/restore/lock/unlock/delete routes",
|
|
"mockStateDomains": ["task", "documents", "interactions", "idempotency", "audit", "fault"],
|
|
"prpEvidence": "bounded reads and revision-safe write/conflict/denial receipts with revision lineage",
|
|
"gap": "restore_document_revision is an approved optional-tool gap; lock/unlock/delete are intentionally control-plane-only."
|
|
},
|
|
{
|
|
"id": "ix",
|
|
"legacyGroup": 9,
|
|
"name": "Interactions",
|
|
"owner": "always tools + addressed resolver",
|
|
"operationIds": ["request_human_input"],
|
|
"controlPlaneOperationIds": ["route_wake"],
|
|
"realSurface": "issue-thread interaction create/respond/accept/reject/withdraw services",
|
|
"mockStateDomains": ["task", "documents", "interactions", "wake", "actor", "idempotency"],
|
|
"prpEvidence": "interaction proposal/materialization/response/delivery and attention events",
|
|
"gap": "Production binding and semantic resolution receipts are unbound."
|
|
},
|
|
{
|
|
"id": "ap",
|
|
"legacyGroup": 10,
|
|
"name": "Approvals",
|
|
"owner": "optional governance tools + governed approver",
|
|
"operationIds": ["list_approvals", "get_approval", "get_approval_context", "request_approval", "decide_approval", "comment_on_approval"],
|
|
"controlPlaneOperationIds": ["route_wake", "append_audit_record"],
|
|
"realSurface": "company approval, decision, issue-link, comment, and governed-action services",
|
|
"mockStateDomains": ["company", "task", "approvals", "actor", "wake", "audit", "idempotency"],
|
|
"prpEvidence": "governed semantic receipts, audit references, and attention/continuation linkage",
|
|
"gap": "Production binding and additive governed-action receipts are unbound; board-only authority stays outside grants."
|
|
},
|
|
{
|
|
"id": "ar",
|
|
"legacyGroup": 11,
|
|
"name": "Artifacts",
|
|
"owner": "always tools + artifact/work-product services",
|
|
"operationIds": ["register_deliverable"],
|
|
"controlPlaneOperationIds": ["append_audit_record"],
|
|
"realSurface": "attachment upload and issue work-product routes",
|
|
"mockStateDomains": ["task", "artifacts", "workProducts", "workspace", "audit", "idempotency"],
|
|
"prpEvidence": "artifact/work-product reference and durable inspectability receipt; never binary bytes",
|
|
"gap": "Production upload/register composite and additive durable-reference receipt are unbound."
|
|
},
|
|
{
|
|
"id": "er",
|
|
"legacyGroup": 12,
|
|
"name": "Errors and critical rules",
|
|
"owner": "runner/control plane + optional workspace/wake tools",
|
|
"operationIds": ["get_workspace_runtime", "control_workspace_service", "schedule_wake", "inspect_operation_result"],
|
|
"controlPlaneOperationIds": ["release_task", "enforce_budget", "persist_run", "replay_run", "reconcile_run"],
|
|
"realSurface": "workspace runtime, monitor/recovery, budget, run persistence/replay, release, and terminal services",
|
|
"mockStateDomains": ["workspace", "budget", "run", "wake", "audit", "idempotency", "fault"],
|
|
"prpEvidence": "runtime/workspace/attention/run lifecycle, typed denials, replay facts, and terminal causality",
|
|
"gap": "Budget stop reasons and semantic denial/conflict receipts require additive v1 envelopes; inspect_operation_result remains scenario-only."
|
|
},
|
|
{
|
|
"id": "rf",
|
|
"legacyGroup": 13,
|
|
"name": "Reference files",
|
|
"owner": "always instruction tools + optional domain tools + test-only escape hatch",
|
|
"operationIds": ["list_cases", "upsert_case", "list_routines", "manage_routine", "create_skill", "list_company_skills", "sync_company_skills", "list_secret_metadata", "read_secret_value", "export_company", "administer_company", "generic_api_request", "search_api", "call_api", "create_project", "read_agent_instructions", "update_agent_instructions", "get_agent_instruction_history", "restore_agent_instructions"],
|
|
"controlPlaneOperationIds": ["append_audit_record"],
|
|
"realSurface": "agent instruction revisions, project, case, routine, company-skill, secret, portability, and administration services",
|
|
"mockStateDomains": ["company", "cases", "routines", "skills", "secrets", "audit", "fault"],
|
|
"prpEvidence": "bounded domain projections, redacted broker receipts, company diffs, and audit references",
|
|
"gap": "Instruction read/update/history/restore require the live canonical revision service, current responsible-user permissions, and pinned base revisions for writes. Their service, authority, and product E2E tests are separate from the legacy mock scenarios. Project and skill creation and API tools require the live server authority; generic_api_request is test-only and the remaining domain operations are scenario-only. Broad administer_company is deferred and cannot claim product coverage. Production API and paired dedicated-tool regressions are recorded separately in paperclip-evals/evals/runner-api-tools; the legacy scenario count is not evidence of that coverage."
|
|
},
|
|
{
|
|
"id": "mh",
|
|
"legacyGroup": 14,
|
|
"name": "Multi-hop",
|
|
"owner": "composed semantic operations + control-plane continuation",
|
|
"operationIds": ["create_task", "set_dependencies", "request_human_input", "request_approval", "register_deliverable"],
|
|
"controlPlaneOperationIds": ["route_wake", "reconcile_run"],
|
|
"realSurface": "delegation, dependency, interaction, approval, artifact, and terminal orchestration services",
|
|
"mockStateDomains": ["task", "blockers", "interactions", "approvals", "artifacts", "wake", "run", "audit"],
|
|
"prpEvidence": "correlated operation receipts, state diffs, attention hops, work assessment, status decision, and terminal outcome",
|
|
"gap": "No generic transaction tool is allowed; shared mock/real conformance must prove each composed effect."
|
|
},
|
|
{
|
|
"id": "rs",
|
|
"legacyGroup": 15,
|
|
"name": "Restraint and no-call",
|
|
"owner": "policy/exposure layer",
|
|
"operationIds": ["answer_status_question", "read_secret_value", "generic_api_request"],
|
|
"controlPlaneOperationIds": ["enforce_budget"],
|
|
"realSurface": "task-mode, secret-broker, test-scope, pause, and budget policy checks",
|
|
"mockStateDomains": ["actor", "task", "budget", "secrets", "audit", "fault"],
|
|
"prpEvidence": "absence of forbidden effects plus typed policy denial/redaction receipts when a call is attempted",
|
|
"gap": "Typed redaction/authorization receipts need additive v1 evidence; generic_api_request is never a product fallback."
|
|
},
|
|
{
|
|
"id": "wk",
|
|
"legacyGroup": 16,
|
|
"name": "Wake situations",
|
|
"owner": "control plane + always context/history tools",
|
|
"operationIds": ["get_task_context", "get_task_history", "schedule_wake"],
|
|
"controlPlaneOperationIds": ["select_work", "route_wake"],
|
|
"realSurface": "wakeup requests, heartbeat context, comment/interaction/approval/blocker wake routing, and scheduled wake services",
|
|
"mockStateDomains": ["wake", "task", "comments", "interactions", "approvals", "blockers", "run"],
|
|
"prpEvidence": "attention request routing/resolution plus resumed session/run causality",
|
|
"gap": "Production scheduling binding is unbound; control-plane routing remains non-callable."
|
|
}
|
|
],
|
|
"rules": {
|
|
"companyAuthorization": [
|
|
"Every entity read and write is resolved inside the authenticated actor's company; cross-company identifiers fail without disclosing protected facts.",
|
|
"Board actors use active membership and role permissions. Agent writes require a company-scoped run JWT and X-Paperclip-Run-Id; active-task tools cannot accept a caller-selected company or arbitrary task.",
|
|
"Optional tools are omitted unless every required claim, role, and task-mode condition is satisfied. A grant never bypasses approval, budget, pause, execution-lock, interaction-owner, or other governed-action checks."
|
|
],
|
|
"taskModes": [
|
|
"standard permits the full eligible catalog subject to claims and role checks.",
|
|
"ask is answer-only: investigation reads are eligible, while implementation, document mutation, delegation, terminal, and governed writes are absent.",
|
|
"planning permits plan/document/progress/input operations but not delegation or terminal completion; accepting a plan transitions the issue into a fresh standard execution continuation for the exact accepted revision.",
|
|
"skill_test exposes only scenario-admitted tools. generic_api_request additionally requires the explicit test grant and allowlist and never supplies product coverage."
|
|
],
|
|
"redaction": [
|
|
"Tool descriptors declare observable redaction. Secret plaintext may reach only the model-use capsule authorized for a bound secret; it never reaches PRP, logs, artifacts, errors, audit details, or serialized tool results.",
|
|
"Authorization denials reveal stable codes, missing public claims, and remediation only; they do not include protected entity state, credentials, headers, cookies, or another company's policy.",
|
|
"Artifacts carry durable references, hashes, content type, and size on the wire; binary payloads remain in storage transports."
|
|
],
|
|
"idempotency": [
|
|
"Every mutation whose descriptor says required must carry a stable idempotency key. Retrying the same key and equivalent input returns the prior receipt without duplicating side effects.",
|
|
"Reusing a key with different input is an idempotency conflict. Optimistic document writes additionally bind baseRevisionId and return the current revision on conflict.",
|
|
"PRP source event IDs are idempotent, source sequence gaps are evidence, and replay is side-effect free. Replaying a trace cannot repeat control-plane writes."
|
|
],
|
|
"sideEffects": [
|
|
"read operations return bounded projections and do not mutate control-plane state.",
|
|
"task_write and company_write operations emit normalized state diffs and immutable audit references after production authorization succeeds.",
|
|
"governance, workspace_control, secret_read, and admin operations retain their production-specific gates; catalog exposure is necessary but never sufficient authority.",
|
|
"Terminal semantic operations propose intent. The control plane owns checkout, release, budget enforcement, persisted run evidence, replay, wake routing, audit append, and final status arbitration."
|
|
]
|
|
},
|
|
"documentLifecycle": {
|
|
"scope": [
|
|
"Issue documents are active-task working records identified by (activeIssueId, key). Always-present document tools do not accept a company id or arbitrary issue id.",
|
|
"Cross-task document reads require a future explicit optional operation and grant; case documents and future company knowledge are separate resource types.",
|
|
"Locked-document fallback may create a deterministic new key only when lockedDocumentStrategy is create_new_document; the source stays locked and the returned receipt names the redirected key."
|
|
],
|
|
"operations": [
|
|
{"action": "create", "semanticOperation": "write_document", "placement": "always_agent_tool", "contract": "baseRevisionId is null; create revision 1 and return document/revision/audit identity.", "status": "supported contract; production binding unbound"},
|
|
{"action": "read", "semanticOperation": "list_documents / read_document", "placement": "always_agent_tool", "contract": "List metadata or read the current active-task document by stable key.", "status": "supported contract; production binding unbound"},
|
|
{"action": "update", "semanticOperation": "write_document", "placement": "always_agent_tool", "contract": "Require the exact latest baseRevisionId and an idempotency key; append an immutable revision.", "status": "supported contract; production binding unbound"},
|
|
{"action": "revisions", "semanticOperation": "list_document_revisions", "placement": "always_agent_tool", "contract": "Return bounded immutable revision history newest first.", "status": "supported contract; production binding unbound"},
|
|
{"action": "restore", "semanticOperation": "restore_document_revision", "placement": "optional_agent_tool (documents:restore)", "contract": "Validate same-document lineage, reject locked documents, append a new revision, and return source/new revision identity; restoring current is a no-change duplicate.", "status": "approved catalog gap"},
|
|
{"action": "lock", "semanticOperation": "none", "placement": "control_plane_owned", "contract": "Board/administrative lifecycle action; agent writes receive document_locked or use explicit create-new fallback.", "status": "intentionally non-callable"},
|
|
{"action": "unlock", "semanticOperation": "none", "placement": "control_plane_owned", "contract": "Board/administrative lifecycle action; never inferred from a failed write.", "status": "intentionally non-callable"},
|
|
{"action": "delete", "semanticOperation": "none", "placement": "control_plane_owned", "contract": "Destructive audited action; pending targets become stale and the runner never recreates them automatically.", "status": "intentionally non-callable"}
|
|
]
|
|
},
|
|
"legacySemanticTargetDispositions": {
|
|
"injected_actor_context": {"kind": "control_plane", "targets": ["select_work"], "reason": "Identity is launch context, not a model tool."},
|
|
"runner_work_selection": {"kind": "control_plane", "targets": ["select_work"], "reason": "Inbox selection belongs to the control plane."},
|
|
"get_project": {"kind": "folded", "targets": ["list_projects"], "reason": "The bounded discovery operation owns project list/get projection in V1."},
|
|
"wait_for_workspace_service": {"kind": "folded", "targets": ["control_workspace_service"], "reason": "Wait is a bounded action of workspace service control."},
|
|
"get_goal": {"kind": "folded", "targets": ["list_goals"], "reason": "The bounded discovery operation owns goal list/get projection in V1."},
|
|
"semantic_task_disposition": {"kind": "composite", "targets": ["answer_status_question", "finish_task", "block_task", "request_review"], "reason": "Generic issue PATCH is replaced by intent-specific terminal/status operations."},
|
|
"atomic_checkout": {"kind": "control_plane", "targets": ["checkout_task"], "reason": "Checkout is an atomic control-plane transaction."},
|
|
"runtime_release": {"kind": "control_plane", "targets": ["release_task"], "reason": "Release is runner/control-plane cleanup."},
|
|
"restore_document_revision": {"kind": "known_gap", "targets": [], "reason": "Approved optional documents:restore operation is not yet in the canonical catalog."},
|
|
"link_approval": {"kind": "folded", "targets": ["request_approval", "get_task_context"], "reason": "Issue linkage is part of approval request/context composites."},
|
|
"unlink_approval": {"kind": "control_plane", "targets": ["append_audit_record"], "reason": "No standalone agent unlink tool is approved in V1."},
|
|
"test_only_api_escape_hatch": {"kind": "folded", "targets": ["generic_api_request"], "reason": "Compatibility alias for the test-only escape hatch."}
|
|
}
|
|
}
|