4.6 KiB
4.6 KiB
| id | slug | title | status | kind | priority | labels | created_at | updated_at | assignee | |||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 20260531-022821-pod-tool-surface-restore-list | pod-tool-surface-restore-list | Pod tools: unify pod listing and rename restore operation | closed | task | P2 |
|
2026-05-31T02:28:21Z | 2026-05-31T03:00:15Z | null |
Background
The current LLM-callable Pod tool surface has overlapping concepts:
ListPodsis registry-oriented and lists Pods spawned by the current Pod.ListVisiblePodsis state/visibility-oriented and lists visible live/stored Pods.InspectPodprovides a named detail lookup.AttachOrRestorePodhas an ambiguous name: the "attach" branch mostly detects an existing live socket and returns connection information; it does not clearly mean that the target becomes a comm-registered child forSendToPod/ReadPodOutput.
Recent multi-agent workflow incidents also showed that stopped/restorable child Pods and missing/unreachable children are not clearly represented. For LLM tool use, fewer, more precise operations are preferable.
User decision:
- Integrate
ListVisiblePodssemantics intoListPods. - Remove
InspectPodfrom the LLM tool surface. - Rename
AttachOrRestorePodtoRestorePod.
Requirements
- Replace the old
ListPodsresult semantics with the state/visibility-aware listing currently represented byListVisiblePods.- The tool should list Pods visible to the current Pod, not host-wide Pods.
- Visible set should include self and spawned children according to current visibility rules.
- Preserve enough fields to distinguish live/reachable, stored/restorable, missing/corrupt/unrestorable, and comm/registry state where available.
- If preserving exact
PodList/PodListEntrystructures is easier, use them; do not keep two nearly identical listing tools.
- Remove
ListVisiblePodsas a separate LLM-callable tool.- Update tool registration, tool descriptions, tests, prompts/docs if they mention it.
- If protocol enum compatibility must remain for non-LLM/TUI callers, keep internal compatibility only and do not expose it as an LLM tool; otherwise remove it cleanly.
- Remove
InspectPodfrom the LLM-callable tool surface.- Update tool registration, tool descriptions, schema, tests, prompts/docs.
- Prefer
ListPodsfor discovery/detail andRestorePodfor action. - If protocol enum compatibility must remain, keep it internal/non-advertised only; otherwise remove it cleanly.
- Rename
AttachOrRestorePodtoRestorePodin the LLM-callable surface.- The operation should restore a visible stopped/restorable Pod, or report that a visible Pod is already live.
- Avoid using “attach” terminology in tool name/description unless a real comm-registry materialization semantics is implemented.
- Update tool schema, descriptions, registration, tests, and prompts/docs.
- Decide whether to keep a backwards-compatible protocol alias internally; avoid exposing both names to the LLM.
- Preserve scope, visibility, and safety boundaries.
- Do not make host-wide Pod enumeration available.
- Do not allow restoring Pods outside the caller’s visibility set.
- Do not broaden delegated scope handling in this ticket.
- Keep behavior for
SpawnPod,SendToPod,ReadPodOutput, andStopPodcoherent with the new listing/restore tools.- If full stopped/restorable child semantics require a larger registry change, document it as follow-up rather than half-implementing it.
Non-goals
- Full redesign of stopped/restorable child lifecycle and delegated scope reclaim semantics.
- Changing Pod registry durable authority or parent restore pruning behavior.
- Host-wide Pod management tools.
- TUI dashboard redesign.
Acceptance criteria
- The LLM-visible tool list exposes
ListPodsandRestorePod, and no longer exposesListVisiblePods,InspectPod, orAttachOrRestorePod. ListPodsreturns visibility/state-aware data sufficient for the LLM to decide whether a Pod is live, stopped/restorable, or unavailable.RestorePodreplaces the oldAttachOrRestorePodname in tool descriptions and tests.- Existing tests are updated and new/renamed tests cover:
ListPodsincludes visible stored/live entries formerly covered byListVisiblePods;RestorePodrejects invisible/missing Pods;RestorePodreports already-live visible Pods without spawning another process;- removed tools are not registered in the LLM tool registry.
- Any intentional protocol compatibility aliases are documented in code comments and are not advertised to the LLM.
cargo fmt --check, focused Pod/tools tests,cargo checkfor affected crates,./tickets.sh doctor, andgit diff --checkpass.