Skip to content

feat(delegation): add routing preference and child monitoring - #593

Merged
rynfar merged 4 commits into
pylonfrom
feat/delegation-built-in-first
Sep 17, 2026
Merged

rynfar merged 4 commits into
pylonfrom
feat/delegation-built-in-first

Conversation

@rynfar

@rynfar rynfar commented Sep 17, 2026 •

Copy link
Copy Markdown
Collaborator

Pylon delegation encouraged costly supervision and did not make child activity clear in the parent thread. This change defaults to built-in agents, adds a persistent delegation preference, and shows Pylon children in the Agents panel and streaming activity without new polling or provider calls.

Settings → Integrations keeps the enable switch, preferred method, default model, and child permissions visible while delegation is off. Preferences support environment and project scopes; small tasks stay local and explicit user instructions take priority. An on-demand, capability-gated read_delegation_skill exposes the repo's packaged delegation skill in any project. Terminal/blocking status reads return immediately, and result text defaults to 4,000 rather than 20,000 characters.

The parent now retains a compact child summary even after its own turn ends. The Agents panel shows Pylon child status, provider/model, available activity, and an Open thread link. Recognized delegation calls get expandable streaming rows with raw diagnostics retained. “Waiting” requires a matching active provider turn and a positive status-wait request; stopped or stale calls cannot imply the parent is waiting. Native-agent token totals and controls remain separate. Completion explicitly prompts result review.

Limits: this does not add automatic parent continuation, queued feedback, or combined billing. Precise streaming wait recognition currently covers structured Codex/Claude tool events; Prime/OpenCode retain generic tool logs where structured identity is unavailable. Child-shell monitoring works independently of that recognition. Mobile retains existing child navigation, without the new web/desktop monitoring panel.

Validation:

  • 90 focused monitoring tests passed across lifecycle/environment isolation, active/idle streaming states, wrong-server rejection, malformed payloads, panel controls, and navigation.
  • Preference changes passed 311 focused contract/handler/MCP/runtime/settings tests plus 90 persistence/shared-settings tests (overlapping settings coverage). Earlier delegation/skill validation passed 178 and 81 focused tests respectively, including packaged CLI use outside the checkout.
  • Server, contracts, web, mobile, and client-runtime typechecks passed for the relevant changes. Scoped formatting, lint, and whitespace checks passed; existing React lint warnings remain.
  • Independent adversarial review in multiple rounds found and resolved wrong-server classification, misleading native token totals, and stale waiting indicators. Final review reported no blockers.
  • Browser verification covered completed, running, and approval-blocked children, streaming expansion, child navigation, preference persistence and reset. Running/blocked states used isolated UI fixtures; fixtures were restored afterward.
  • The earlier disposable real delegation test used one Luna/low child to implement and test a tiny slug function. Parent reviewed the result, with no merge. A development reload interrupted the first attempt; the same child resumed. Processed-token counters included repeated/cached context and did not demonstrate billing savings. No additional paid-provider trials were run for monitoring.

Earlier before/after settings and live smoke evidence · Monitoring and preference screenshots

Implemented with GPT-6 Astra in Codex; independent adversarial review used built-in agents. The disposable live smoke test used Codex GPT-5.6 Luna at low effort.

@vercel

vercel Bot commented Sep 17, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
pylon-marketing Ready Ready Preview Sep 17, 2026 4:36pm UTC

@github-actions github-actions Bot added vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. size:M labels Sep 17, 2026
@rynfar

rynfar commented Sep 17, 2026

Copy link
Copy Markdown
Collaborator Author

UI verification in an isolated development instance. Before: delegation off hides configuration. After: saved model and permissions remain visible while off. The final image shows the successful one-child disposable feature test.

before after-configured-off smoke-complete

@github-actions

github-actions Bot commented Sep 17, 2026 •

Copy link
Copy Markdown
Contributor

Thread transfer impact

✅ Thread transfer remains within every enforced ceiling.

ℹ️ The exact PR base did not have a successful artifact. Baseline uses the latest successful main measurement shown below.

Provider Metric Main baseline This PR Impact PR ceiling
Codex Total thread wire 14.0 KiB 13.9 KiB −67 B (−0.5%) 15.1 KiB ✅
Codex Thread snapshot wire 7.2 KiB 7.2 KiB −13 B (−0.2%) 7.3 KiB ✅
Codex Live turn WebSocket wire 6.8 KiB 6.7 KiB −54 B (−0.8%) 7.8 KiB ✅
Codex Live turn WebSocket decoded 58.0 KiB 58.0 KiB −88 B (−0.1%) 66.4 KiB ✅
Codex Live turn messages 10 8 −2 (−20.0%) 21 ✅
Claude Total thread wire 14.0 KiB 14.0 KiB +3 B (+0.0%) 15.1 KiB ✅
Claude Thread snapshot wire 7.2 KiB 7.2 KiB 0 B (0.0%) 7.3 KiB ✅
Claude Live turn WebSocket wire 6.8 KiB 6.8 KiB +3 B (+0.0%) 7.8 KiB ✅
Claude Live turn WebSocket decoded 58.9 KiB 58.9 KiB 0 B (0.0%) 66.4 KiB ✅
Claude Live turn messages 10 10 0 (0.0%) 21 ✅

Baseline: f3788ae · PR result: f49191a · Source CI: success

Scenario and decoded snapshot size

10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.

  • Codex decoded thread snapshot: 115.6 KiB
  • Claude decoded thread snapshot: 116.3 KiB

Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed.

@rynfar

rynfar commented Sep 17, 2026

Copy link
Copy Markdown
Collaborator Author

Delegation monitoring visual verification in isolated local state. Images in order: real completed smoke-test child with expanded streaming activity and Agents panel; running-child fixture while parent is idle; approval-blocked fixture; saved Pylon preference while delegation remains off. The two active states are UI fixtures, not additional provider runs. Preference survived reload and was reset to Built-in afterward.

monitoring-completed monitoring-running monitoring-blocked preferred-method

@github-actions github-actions Bot removed the size:L label Sep 17, 2026
@rynfar rynfar changed the title fix(delegation): prefer native agents and reduce supervision overhead feat(delegation): add routing preference and child monitoring Sep 17, 2026
@rynfar
rynfar merged commit 29c9dcf into pylon Sep 17, 2026
20 checks passed
@rynfar
rynfar deleted the feat/delegation-built-in-first branch September 17, 2026 16:57

This branch was successfully deployed

1 active deployment
Preview — f49191af Deployed Sep 17, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XL vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant