delegate-agent-cli 0.27.0__tar.gz → 0.29.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (197) hide show
  1. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/CHANGELOG.md +110 -1
  2. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/CONTRIBUTING.md +3 -3
  3. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/PKG-INFO +11 -4
  4. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/README.md +10 -3
  5. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/bin/delegate-profile-shim +31 -2
  6. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/docs/agent-setup.md +3 -3
  7. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/docs/cli-reference.md +93 -15
  8. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/docs/configuration.md +6 -1
  9. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/docs/delegate-workflows.md +10 -0
  10. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/docs/development.md +5 -1
  11. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/docs/live-runtime.md +7 -3
  12. delegate_agent_cli-0.29.1/docs/publishing-checklist.md +111 -0
  13. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/docs/security-model.md +20 -16
  14. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/docs/troubleshooting.md +46 -3
  15. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/pyproject.toml +1 -1
  16. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/__init__.py +1 -1
  17. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/cli.py +55 -36
  18. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/cli_parser.py +6 -0
  19. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/command_help.py +48 -15
  20. delegate_agent_cli-0.29.1/src/delegate_agent/failover_state.py +201 -0
  21. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/harness_discovery.py +88 -9
  22. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/harness_events.py +119 -19
  23. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/inspection_commands.py +59 -4
  24. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/model_discovery.py +0 -32
  25. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/profile_guard.py +9 -13
  26. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/profiles.py +23 -3
  27. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/prompt_instructions.py +2 -1
  28. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/rendering.py +24 -2
  29. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/request_build.py +12 -1
  30. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/request_models.py +2 -0
  31. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/retention.py +77 -32
  32. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/run_metadata.py +58 -0
  33. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/run_registry.py +25 -7
  34. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/run_status.py +9 -2
  35. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/runner.py +465 -126
  36. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/workflows/commands.py +13 -1
  37. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/workflows/runtime.py +6 -1
  38. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/worktree_execution.py +26 -9
  39. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent_cli.egg-info/PKG-INFO +11 -4
  40. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent_cli.egg-info/SOURCES.txt +6 -0
  41. delegate_agent_cli-0.29.1/tests/test_call_text_fixtures.py +64 -0
  42. delegate_agent_cli-0.29.1/tests/test_child_root_env.py +94 -0
  43. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_codex_thread_resilience.py +10 -1
  44. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_command_help.py +22 -1
  45. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_config_commands.py +96 -8
  46. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_delegate_help_cli.py +7 -0
  47. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_execution_worktree_run.py +135 -0
  48. delegate_agent_cli-0.29.1/tests/test_failover_state.py +105 -0
  49. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_harness_discovery.py +109 -2
  50. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_harness_events.py +133 -0
  51. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_inspection_commands.py +333 -0
  52. delegate_agent_cli-0.29.1/tests/test_launch_error_hints.py +40 -0
  53. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_model_discovery.py +45 -63
  54. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_profiles.py +292 -10
  55. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_retention.py +115 -1
  56. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_run_registry.py +6 -2
  57. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_runner_capture.py +684 -40
  58. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_setup_commands.py +1 -6
  59. delegate_agent_cli-0.29.1/tests/test_tracked_output_bounds.py +167 -0
  60. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_utility_modules.py +2 -1
  61. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_workflow_commands.py +73 -0
  62. delegate_agent_cli-0.27.0/docs/publishing-checklist.md +0 -73
  63. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/LICENSE +0 -0
  64. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/MANIFEST.in +0 -0
  65. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/SECURITY.md +0 -0
  66. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/bin/delegate.py +0 -0
  67. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/config.example.json +0 -0
  68. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/docs/assets/delegate-agent-header.png +0 -0
  69. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/docs/worktrees.md +0 -0
  70. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/examples/task.claude.json +0 -0
  71. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/examples/task.codex.json +0 -0
  72. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/examples/task.cursor.json +0 -0
  73. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/examples/task.droid.json +0 -0
  74. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/examples/task.grok.json +0 -0
  75. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/examples/task.judge.json +0 -0
  76. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/examples/task.kimi.json +0 -0
  77. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/setup.cfg +0 -0
  78. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/archived_logs.py +0 -0
  79. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/argv_builders.py +0 -0
  80. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/argv_utils.py +0 -0
  81. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/bundled_models.py +0 -0
  82. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/capability_commands.py +0 -0
  83. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/child_failures.py +0 -0
  84. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/command_errors.py +0 -0
  85. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/config.py +0 -0
  86. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/config_commands.py +0 -0
  87. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/constants.py +0 -0
  88. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/describe_payload.py +0 -0
  89. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/errors.py +0 -0
  90. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/git_utils.py +0 -0
  91. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/isolation.py +0 -0
  92. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/json_types.py +0 -0
  93. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/log_output.py +0 -0
  94. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/mail.py +0 -0
  95. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/mail_core.py +0 -0
  96. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/mail_push.py +0 -0
  97. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/personas.py +0 -0
  98. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/private_io.py +0 -0
  99. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/profile_commands.py +0 -0
  100. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/prompt_transport.py +0 -0
  101. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/reasoning.py +0 -0
  102. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/redaction.py +0 -0
  103. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/resume_command.py +0 -0
  104. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/run_output_commands.py +0 -0
  105. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/safe_workspace.py +0 -0
  106. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/seatbelt.py +0 -0
  107. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/setup_commands.py +0 -0
  108. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/snapshot_view.py +0 -0
  109. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/structured_output.py +0 -0
  110. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/wait_cancel_commands.py +0 -0
  111. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/workflows/__init__.py +0 -0
  112. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/workflows/registry.py +0 -0
  113. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/workflows/schema.py +0 -0
  114. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/workflows/script.py +0 -0
  115. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/worktree_commands.py +0 -0
  116. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/worktree_gc.py +0 -0
  117. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/worktree_mgmt.py +0 -0
  118. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/worktree_records.py +0 -0
  119. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/worktree_remove.py +0 -0
  120. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/worktree_summary.py +0 -0
  121. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent/wsl.py +0 -0
  122. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent_cli.egg-info/dependency_links.txt +0 -0
  123. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent_cli.egg-info/entry_points.txt +0 -0
  124. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent_cli.egg-info/requires.txt +0 -0
  125. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/src/delegate_agent_cli.egg-info/top_level.txt +0 -0
  126. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_capability_commands.py +0 -0
  127. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_child_failures.py +0 -0
  128. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_codex_pure_sandbox.py +0 -0
  129. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_delegate_isolation.py +0 -0
  130. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_delegate_parser.py +0 -0
  131. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_delegate_validation.py +0 -0
  132. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_end_to_end_tracking.py +0 -0
  133. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_engine_argv.py +0 -0
  134. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_execution_argv_and_prompt.py +0 -0
  135. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_execution_dry_run.py +0 -0
  136. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_execution_worktree_failure_cleanup.py +0 -0
  137. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_execution_worktree_preflight.py +0 -0
  138. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_kimi_commands.py +0 -0
  139. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_bounds.py +0 -0
  140. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_contract.py +0 -0
  141. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_delivery.py +0 -0
  142. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_eligibility.py +0 -0
  143. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_framing.py +0 -0
  144. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_gating.py +0 -0
  145. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_identity.py +0 -0
  146. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_io.py +0 -0
  147. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_parser.py +0 -0
  148. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_prune.py +0 -0
  149. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_push.py +0 -0
  150. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_push_adapters.py +0 -0
  151. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_push_batch.py +0 -0
  152. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_push_cursor.py +0 -0
  153. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_push_gating.py +0 -0
  154. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_push_seams.py +0 -0
  155. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_reply.py +0 -0
  156. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_resolution.py +0 -0
  157. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_mail_rules.py +0 -0
  158. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_model_selection_wave1a.py +0 -0
  159. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_model_selection_wave1b.py +0 -0
  160. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_omp_read_only_behavior.py +0 -0
  161. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_packaging.py +0 -0
  162. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_persona_capability.py +0 -0
  163. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_persona_claude.py +0 -0
  164. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_persona_contract.py +0 -0
  165. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_persona_framer.py +0 -0
  166. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_persona_opencode.py +0 -0
  167. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_persona_parser.py +0 -0
  168. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_persona_records.py +0 -0
  169. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_persona_resolution.py +0 -0
  170. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_persona_size_guard.py +0 -0
  171. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_persona_validation.py +0 -0
  172. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_persona_workflow.py +0 -0
  173. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_pure_call.py +0 -0
  174. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_reasoning_capabilities.py +0 -0
  175. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_resume_attachment.py +0 -0
  176. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_resume_capture.py +0 -0
  177. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_resume_inheritance.py +0 -0
  178. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_resume_parser.py +0 -0
  179. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_resume_projections.py +0 -0
  180. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_resume_refusals.py +0 -0
  181. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_resume_size_guard.py +0 -0
  182. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_resume_stale.py +0 -0
  183. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_resume_trust.py +0 -0
  184. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_safe_workspace_isolation.py +0 -0
  185. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_slash_passthrough.py +0 -0
  186. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_snapshot_redaction.py +0 -0
  187. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_snapshot_rendering.py +0 -0
  188. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_snapshot_run_output.py +0 -0
  189. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_snapshot_view.py +0 -0
  190. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_structured_output.py +0 -0
  191. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_tracked_timeout.py +0 -0
  192. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_wait_cancel_commands.py +0 -0
  193. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_wave4_launch_features.py +0 -0
  194. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_worktree_list_show.py +0 -0
  195. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_worktree_prune_gc.py +0 -0
  196. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_worktree_remove.py +0 -0
  197. {delegate_agent_cli-0.27.0 → delegate_agent_cli-0.29.1}/tests/test_wsl_guardrails.py +0 -0
@@ -5,7 +5,113 @@ All notable changes to this project are documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
- ## [Unreleased]
8
+ ## [0.29.1] - 2026-08-11
9
+
10
+ ### Changed
11
+
12
+ - The PyPI artifact handoff now uses the official Node 24 upload and download
13
+ actions, removing the deprecation warnings emitted during the 0.29.0 publish.
14
+
15
+ ### Fixed
16
+
17
+ - `workflow run --resume` now turns a completed workflow dry-run into live
18
+ execution under the same workflow ID. Simulated agent and budget events stay
19
+ in the journal for audit but never satisfy replay or consume live budget.
20
+
21
+ ## [0.29.0] - 2026-08-11
22
+
23
+ ### Added
24
+
25
+ - `delegate runs` and `delegate ps` now report listing honesty: the JSON
26
+ payload gains `total` (pre-limit match count) and `truncated`, text mode
27
+ prints `showing N of M runs (raise --limit to see more)`, and a zero-row
28
+ result under `--group`/`--harness` explains itself — naming the status
29
+ filter to drop when `--running`/`--stale`/`--active` emptied the result, or
30
+ noting the run Registry is workspace-scoped otherwise.
31
+ - Retained event text now carries truncation metadata on both surfaces: raw
32
+ `events.jsonl` `stream.line` records and normalized Snapshot `recentEvents`
33
+ add `truncated: true` plus `textChars` (original length) only when the
34
+ 500-character bound actually clipped, and the final unterminated child
35
+ stdout line is now written to `events.jsonl` instead of silently dropped.
36
+ All child-controlled normalized-event strings (including tool targets,
37
+ `error`, and `run.completed`) are bounded through the same helper.
38
+ - The tracked launcher shim template (`bin/delegate-profile-shim`) passes
39
+ through the read-only workflow actions
40
+ (`check|status|watch|events|result|wait|list`) without a selected profile,
41
+ mirroring the Python CLI's guard; a parity test fails on drift.
42
+ - Tracked Cursor completion JSON now includes the CLI-reported token `usage`
43
+ object when present.
44
+
45
+ ### Changed
46
+
47
+ - Devin model discovery now uses the prompt-free, fingerprinted
48
+ `devin models list --format json` catalog for setup, capability refresh, and
49
+ one-off live queries. Older or unauthenticated CLIs degrade to a version-only
50
+ record instead of receiving a prompt-like invalid-model probe.
51
+ - Child-launch failures with `EPERM` now hint that sandboxed parent shells can
52
+ forbid launching harness binaries; `prompt_too_large` names the engines
53
+ whose prompt rides a file/stdin transport, derived from the transport table.
54
+ - The test suite hardens hermeticity against ambient delegate-lane
55
+ environment (`DELEGATE_RUN_ID`, mail identity, root-provenance and profile
56
+ variables), and the documented discovery command is
57
+ `python3 -m unittest discover -s tests -t .` everywhere, including CI and
58
+ the contributor wiki.
59
+ - CI and publishing now use the official Node 24 GitHub Action releases, and
60
+ the public publishing checklist builds exported source in isolated temporary
61
+ environments instead of modifying the maintainer's ambient Python install.
62
+
63
+ ### Fixed
64
+
65
+ - An explicit `DELEGATE_CONFIG` now survives profile selection: the profile
66
+ shim and profile env resolution load the selected profile's credentials but
67
+ keep the incoming `DELEGATE_CONFIG` as the runtime-policy config instead of
68
+ replacing it, and codex quota fallback no longer forwards `DELEGATE_CONFIG`
69
+ into the fallback child environment.
70
+ - Tracked runs now stop after an explicit harness terminal event and fail closed
71
+ when either raw output stream exceeds 16 MiB, preventing a completed or
72
+ runaway child from filling disk with cumulative stream payloads.
73
+ - Tracked stream decoding preserves UTF-8 characters split across read chunks;
74
+ normalized events retain a bounded head/tail with an exact total, and raw
75
+ `events.jsonl` mirrors at most 500 stdout lines plus a truncation marker so
76
+ many short lines cannot amplify a bounded child stream into an unbounded
77
+ event journal or in-memory event list.
78
+ - Tracked Cursor retries now report cumulative token usage, transient Devin
79
+ catalog failures retain the last-known-good catalog, and Devin help no longer
80
+ advertises unsupported reasoning effort.
81
+ - Slow raw-log archival no longer holds the Registry mutation lock, concurrent
82
+ ambient retention passes skip instead of waiting, and transient Registry-lock
83
+ contention can no longer crash a tracked run's stdout drain thread.
84
+
85
+ ## [0.28.0] - 2026-08-05
86
+
87
+ ### Added
88
+
89
+ - Added `delegate runs --structural` and `delegate ps --structural` for
90
+ content-free local status collection, including lifecycle, model, group,
91
+ status, timestamp, and root initiator provenance.
92
+ - Tracked runs now retain a validated root initiator across nested Delegate
93
+ launches and persistent-worktree execution.
94
+
95
+ ### Changed
96
+
97
+ - Codex quota fallback is now explicitly configured with
98
+ `codex.fallbackProfile`, supports arbitrary profile definitions, and keeps
99
+ temporary blocks by resolved credential identity rather than profile alias.
100
+ Default work/personal credential homes continue to interoperate with legacy
101
+ profile launchers without allowing remapped aliases to share state.
102
+ - Codex-only failover no longer depends on private Claude shim names or hidden
103
+ runtime controls. Retry and persistent-worktree paths retain the account
104
+ that is actually serving the run.
105
+
106
+ ### Fixed
107
+
108
+ - Structural run listings now exclude raw terminal/provider events and apply
109
+ normal secret redaction to retained fields.
110
+ - Fallback failures persist the correct account block and provider-reported
111
+ reset time; a blocked fallback is skipped, and retries no longer return to a
112
+ blocked primary after a preflight swap.
113
+ - Failover tests isolate their state from the user's home directory, and
114
+ `delegate ps --help` now advertises its supported structural view.
9
115
 
10
116
  ## [0.27.0] - 2026-08-01
11
117
 
@@ -888,6 +994,9 @@ Usage-audit fix wave: 82 sessions and 1,241 delegate invocations from one week o
888
994
 
889
995
  - Releases before 0.1.3 predate this changelog.
890
996
 
997
+ [0.29.1]: https://github.com/treygoff24/delegate-agent/compare/v0.29.0...v0.29.1
998
+ [0.29.0]: https://github.com/treygoff24/delegate-agent/compare/v0.28.0...v0.29.0
999
+ [0.28.0]: https://github.com/treygoff24/delegate-agent/compare/v0.27.0...v0.28.0
891
1000
  [0.27.0]: https://github.com/treygoff24/delegate-agent/compare/v0.26.0...v0.27.0
892
1001
  [0.26.0]: https://github.com/treygoff24/delegate-agent/compare/v0.25.0...v0.26.0
893
1002
  [0.25.0]: https://github.com/treygoff24/delegate-agent/compare/v0.24.0...v0.25.0
@@ -7,9 +7,9 @@ Thanks for your interest in Delegate Agent. The project is early, so small, well
7
7
  ```bash
8
8
  python3 -m venv .venv
9
9
  . .venv/bin/activate
10
- python -m pip install -e ".[dev]"
10
+ python3 -m pip install -e ".[dev]"
11
11
  python3 bin/delegate.py --json describe
12
- python3 -m unittest discover -s tests
12
+ python3 -m unittest discover -s tests -t .
13
13
  ```
14
14
 
15
15
  Use `python3 bin/delegate.py` from this repository when validating development changes. Do not overwrite an installed `delegate` shim, `~/.delegate/config.json`, or any live runtime unless an operator explicitly asks for promotion.
@@ -35,7 +35,7 @@ Run the narrowest useful checks for your change, then the full suite before prop
35
35
  ```bash
36
36
  python3 -m compileall -q src tests bin
37
37
  git diff --check
38
- python3 -m unittest discover -s tests
38
+ python3 -m unittest discover -s tests -t .
39
39
  ruff check .
40
40
  ruff format --check .
41
41
  ```
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: delegate-agent-cli
3
- Version: 0.27.0
3
+ Version: 0.29.1
4
4
  Summary: A tiny CLI for delegating bounded agent tasks across coding-agent runtimes.
5
5
  Author: Trey Goff
6
6
  License-Expression: MIT
@@ -81,7 +81,7 @@ git clone https://github.com/treygoff24/delegate-agent.git
81
81
  cd delegate-agent
82
82
  python3 -m venv .venv
83
83
  . .venv/bin/activate
84
- python -m pip install -e .
84
+ python3 -m pip install -e .
85
85
  python3 bin/delegate.py --json describe
86
86
  ```
87
87
 
@@ -158,6 +158,7 @@ delegate --json describe
158
158
  delegate --json models
159
159
  delegate --json models codex # per-engine advisory catalog
160
160
  delegate --json models cursor --live # merge live harness probe when supported
161
+ delegate --json models devin --live # query Devin's prompt-free account catalog
161
162
  delegate --json models opencode --live # query every model visible to OpenCode
162
163
  delegate --json models pi --live # query every model visible to Pi
163
164
  delegate --json models omp --live # query every model visible to Oh My Pi
@@ -167,6 +168,8 @@ delegate --json capabilities refresh # refresh the active profile's discovery
167
168
 
168
169
  Discover commands as you go: `delegate <command> --help` prints focused help for any command path, and `delegate --json <command> --help` returns an agent-friendly spec of its usage, arguments, and options. For launch and `dry-run` commands, `--json` and `--isolation` may also appear before inline prompt text begins, for example `delegate codex work --prompt-file task.md --json`. `delegate --json describe` includes a `commands` catalog of the whole surface. Cached `models` and `capabilities` reads launch no child process. `models <engine> --live` performs a one-off probe without updating the cache; rerun `delegate setup` or `delegate capabilities refresh` when ordinary launches should consume newly discovered models or effort levels.
169
170
 
171
+ Codex tracked runs can opt into a one-run quota fallback with `codex.fallbackProfile`; hashed credential namespace is canonical, while default work/personal credential homes also mirror compatible legacy alias keys so existing launchers share blocks. Remapped aliases remain isolated. See [Configuration](docs/configuration.md).
172
+
170
173
  From this development checkout, use `python3 bin/delegate.py ...` instead of an installed `delegate` shim.
171
174
 
172
175
  ### WSL setup notes
@@ -355,6 +358,9 @@ selector explicitly. Tracked runs also carry a `resultQuality` classification
355
358
  (`ok` / `housekeeping_noop` / `empty` / `suspect_short` / `no_assistant_text`),
356
359
  and failed or cancelled runs always get a completion report — synthesized when
357
360
  the child produced none — so `--completion-report` never dead-ends.
361
+ Each tracked raw stream is capped at 16 MiB. A child that exceeds the cap is
362
+ terminated with `output_limit_exceeded`; a child that lingers after an explicit
363
+ harness terminal event receives a short exit grace and is then stopped.
358
364
 
359
365
  Block on background runs instead of polling, and cancel them cleanly:
360
366
 
@@ -449,8 +455,9 @@ Delegate resolves the profile once per request and injects its env into every sp
449
455
  If `AI_PROFILE=work|personal` points at a missing profile overlay, Delegate
450
456
  blocks launch and mutation commands, but lets read-only diagnostics
451
457
  (`profiles`, `runs`, `run-output`, `snapshot`, cached `capabilities`,
452
- `worktree show`, `worktree list`, `describe`, `models`) continue with a
453
- warning. This guarantee is enforced in the Python CLI itself (`delegate_agent.cli:main`), so it holds no matter how you invoke Delegate: the
458
+ `worktree show`, `worktree list`,
459
+ `workflow check|status|watch|events|result|wait|list`, `describe`, `models`)
460
+ continue with a warning. This guarantee is enforced in the Python CLI itself (`delegate_agent.cli:main`), so it holds no matter how you invoke Delegate: the
454
461
  pip console script, `python -m delegate_agent.cli`, `bin/delegate.py`, or a
455
462
  shell shim in front of any of those. The tracked launcher shim template,
456
463
  `bin/delegate-profile-shim`, applies the same check earlier, before Python
@@ -48,7 +48,7 @@ git clone https://github.com/treygoff24/delegate-agent.git
48
48
  cd delegate-agent
49
49
  python3 -m venv .venv
50
50
  . .venv/bin/activate
51
- python -m pip install -e .
51
+ python3 -m pip install -e .
52
52
  python3 bin/delegate.py --json describe
53
53
  ```
54
54
 
@@ -125,6 +125,7 @@ delegate --json describe
125
125
  delegate --json models
126
126
  delegate --json models codex # per-engine advisory catalog
127
127
  delegate --json models cursor --live # merge live harness probe when supported
128
+ delegate --json models devin --live # query Devin's prompt-free account catalog
128
129
  delegate --json models opencode --live # query every model visible to OpenCode
129
130
  delegate --json models pi --live # query every model visible to Pi
130
131
  delegate --json models omp --live # query every model visible to Oh My Pi
@@ -134,6 +135,8 @@ delegate --json capabilities refresh # refresh the active profile's discovery
134
135
 
135
136
  Discover commands as you go: `delegate <command> --help` prints focused help for any command path, and `delegate --json <command> --help` returns an agent-friendly spec of its usage, arguments, and options. For launch and `dry-run` commands, `--json` and `--isolation` may also appear before inline prompt text begins, for example `delegate codex work --prompt-file task.md --json`. `delegate --json describe` includes a `commands` catalog of the whole surface. Cached `models` and `capabilities` reads launch no child process. `models <engine> --live` performs a one-off probe without updating the cache; rerun `delegate setup` or `delegate capabilities refresh` when ordinary launches should consume newly discovered models or effort levels.
136
137
 
138
+ Codex tracked runs can opt into a one-run quota fallback with `codex.fallbackProfile`; hashed credential namespace is canonical, while default work/personal credential homes also mirror compatible legacy alias keys so existing launchers share blocks. Remapped aliases remain isolated. See [Configuration](docs/configuration.md).
139
+
137
140
  From this development checkout, use `python3 bin/delegate.py ...` instead of an installed `delegate` shim.
138
141
 
139
142
  ### WSL setup notes
@@ -322,6 +325,9 @@ selector explicitly. Tracked runs also carry a `resultQuality` classification
322
325
  (`ok` / `housekeeping_noop` / `empty` / `suspect_short` / `no_assistant_text`),
323
326
  and failed or cancelled runs always get a completion report — synthesized when
324
327
  the child produced none — so `--completion-report` never dead-ends.
328
+ Each tracked raw stream is capped at 16 MiB. A child that exceeds the cap is
329
+ terminated with `output_limit_exceeded`; a child that lingers after an explicit
330
+ harness terminal event receives a short exit grace and is then stopped.
325
331
 
326
332
  Block on background runs instead of polling, and cancel them cleanly:
327
333
 
@@ -416,8 +422,9 @@ Delegate resolves the profile once per request and injects its env into every sp
416
422
  If `AI_PROFILE=work|personal` points at a missing profile overlay, Delegate
417
423
  blocks launch and mutation commands, but lets read-only diagnostics
418
424
  (`profiles`, `runs`, `run-output`, `snapshot`, cached `capabilities`,
419
- `worktree show`, `worktree list`, `describe`, `models`) continue with a
420
- warning. This guarantee is enforced in the Python CLI itself (`delegate_agent.cli:main`), so it holds no matter how you invoke Delegate: the
425
+ `worktree show`, `worktree list`,
426
+ `workflow check|status|watch|events|result|wait|list`, `describe`, `models`)
427
+ continue with a warning. This guarantee is enforced in the Python CLI itself (`delegate_agent.cli:main`), so it holds no matter how you invoke Delegate: the
421
428
  pip console script, `python -m delegate_agent.cli`, `bin/delegate.py`, or a
422
429
  shell shim in front of any of those. The tracked launcher shim template,
423
430
  `bin/delegate-profile-shim`, applies the same check earlier, before Python
@@ -5,6 +5,7 @@
5
5
  # AI_PROFILE shells to matching ~/.delegate/config.<profile>.json files, while
6
6
  # letting known read-only diagnostics run when the profile config is missing.
7
7
 
8
+ _delegate_incoming_config="${DELEGATE_CONFIG-}"
8
9
  _delegate_profile_config="${HOME}/.delegate/config.${AI_PROFILE:-}.json"
9
10
 
10
11
  _delegate_subcommand() {
@@ -198,6 +199,31 @@ _delegate_is_readonly_request() {
198
199
  ;;
199
200
  esac
200
201
  ;;
202
+ workflow)
203
+ # The parser consumes --json tokens before the action, so the action is
204
+ # the first non-option token after `workflow`; trailing flags/paths
205
+ # never decide classification.
206
+ while [ "$#" -gt 0 ]; do
207
+ case "$1" in
208
+ --json)
209
+ shift
210
+ ;;
211
+ *)
212
+ break
213
+ ;;
214
+ esac
215
+ done
216
+ # Parity with profile_guard.READ_ONLY_WORKFLOW_ACTIONS is enforced by
217
+ # tests; update both together.
218
+ case "${1:-}" in
219
+ check|status|watch|events|result|wait|list)
220
+ return 0
221
+ ;;
222
+ *)
223
+ return 1
224
+ ;;
225
+ esac
226
+ ;;
201
227
  *)
202
228
  return 1
203
229
  ;;
@@ -208,11 +234,11 @@ _delegate_profile_fix_message() {
208
234
  cat >&2 <<EOF
209
235
  delegate: AI_PROFILE=${AI_PROFILE} but ${_delegate_profile_config} is missing/unreadable; refusing to run a launch or mutation command on the wrong account.
210
236
  Fix: create the profile config from config.example.json, or run 'env -u AI_PROFILE delegate config sync-profiles' to materialize missing profile overlays.
211
- Temporary bypasses: 'env -u AI_PROFILE delegate ...' uses the base config (work Claude, ambient Codex), or set 'DELEGATE_CONFIG=/path/to/config.json delegate ...'.
237
+ Temporary bypass: 'env -u AI_PROFILE delegate ...' uses the base config (work Claude, ambient Codex).
212
238
  EOF
213
239
  }
214
240
 
215
- if [ -z "${DELEGATE_CONFIG:-}" ] && [ -n "${AI_PROFILE:-}" ]; then
241
+ if [ -n "${AI_PROFILE:-}" ]; then
216
242
  case "${AI_PROFILE}" in
217
243
  personal|work)
218
244
  if [ ! -r "$_delegate_profile_config" ]; then
@@ -229,6 +255,9 @@ if [ -z "${DELEGATE_CONFIG:-}" ] && [ -n "${AI_PROFILE:-}" ]; then
229
255
  # ponytail: current keys.zsh files are plain exports; switch to parsing if
230
256
  # they ever need zsh-only syntax.
231
257
  [ -f "$_delegate_keys" ] && . "$_delegate_keys"
258
+ if [ -n "$_delegate_incoming_config" ]; then
259
+ export DELEGATE_CONFIG="$_delegate_incoming_config"
260
+ fi
232
261
  fi
233
262
  ;;
234
263
  *)
@@ -7,7 +7,7 @@ This guide covers both human setup and non-interactive setup for agents or CI jo
7
7
  1. Install Delegate from the source repository:
8
8
 
9
9
  ```bash
10
- python3 -m pip install "delegate-agent @ git+https://github.com/treygoff24/delegate-agent.git"
10
+ python3 -m pip install "delegate-agent-cli @ git+https://github.com/treygoff24/delegate-agent.git"
11
11
  ```
12
12
 
13
13
  For a development checkout, prefer:
@@ -15,7 +15,7 @@ This guide covers both human setup and non-interactive setup for agents or CI jo
15
15
  ```bash
16
16
  python3 -m venv .venv
17
17
  . .venv/bin/activate
18
- python -m pip install -e .
18
+ python3 -m pip install -e .
19
19
  python3 bin/delegate.py --json describe
20
20
  ```
21
21
 
@@ -243,7 +243,7 @@ where needed:
243
243
 
244
244
  ```bash
245
245
  python3 -m compileall -q src tests bin
246
- python3 -m unittest discover -s tests
246
+ python3 -m unittest discover -s tests -t .
247
247
  ```
248
248
 
249
249
  Real runtime authentication is only required for integration smoke tests that intentionally launch a child agent.
@@ -169,7 +169,7 @@ matches an alias key; otherwise it is passed through verbatim as a raw model ID
169
169
  both. With neither, Droid uses `droid.defaultModel` when set. Discover aliases
170
170
  and advisory catalogs with `delegate models`, `delegate models <engine>`, and
171
171
  `delegate models <engine> --live`. Every harness except Claude exposes a live
172
- model probe; see [Discovery](#discovery) for the evidence and Devin caveats.
172
+ model probe; see [Discovery](#discovery) for the evidence each probe records.
173
173
 
174
174
  `--reasoning-effort LEVEL` is optional and parsed only before prompt text begins.
175
175
  Engines with exact capability metadata reject unsupported model/effort pairs
@@ -334,6 +334,39 @@ delegate grok call "Summarize this context in three bullets."
334
334
  delegate --isolation worktree grok work "Implement the feature in a persistent worktree."
335
335
  ```
336
336
 
337
+ ### `delegate devin`
338
+
339
+ Wraps Devin CLI print mode. Safe mode is unsupported because Devin may perform
340
+ filesystem surveys through its generic `exec` tool, which Delegate cannot allow
341
+ without weakening the read-only boundary.
342
+
343
+ ```bash
344
+ delegate [--json] [--isolation auto|none|worktree] devin work [--model <alias-or-model>] [--progress] [--timeout SECONDS] [--forbid-commit] [--prompt-file PATH] [prompt...]
345
+ delegate [--json] devin call [--read-only] [--timeout SECONDS] [--model <alias-or-model>] [--prompt-file PATH] [prompt...]
346
+ ```
347
+
348
+ - `call --read-only` passes a Delegate-generated `--agent-config` deny-list for
349
+ edit, write, exec, and `mcp__*`, plus `--permission-mode auto`. Work and
350
+ default call use `--permission-mode dangerous` because non-interactive Devin
351
+ rejects unapproved edit/exec tools.
352
+ - Prompt text is materialized in a private temporary file and passed with
353
+ Devin `--prompt-file` plus `-p`; dry-run argv and tracked manifests do not
354
+ contain the prompt.
355
+ - Model selection uses `--model` (an alias from `devin.models` or a raw model
356
+ ID), the run-input JSON `model`, or `devin.defaultModel`. Unknown names are
357
+ left to Devin validation. `--reasoning-effort` is unsupported.
358
+ - Setup, capability refresh, and `models devin --live` use the prompt-free
359
+ `devin models list --format json` catalog. Catalog failures degrade to
360
+ version-only metadata without prompting Devin.
361
+
362
+ Examples:
363
+
364
+ ```bash
365
+ delegate devin work "Implement the scoped task; report changed files and tests."
366
+ delegate devin call --read-only "Score this answer against the rubric."
367
+ delegate --isolation worktree devin work "Implement the feature in a persistent worktree."
368
+ ```
369
+
337
370
  ### `delegate opencode`
338
371
 
339
372
  Wraps OpenCode's non-interactive `run` command.
@@ -500,7 +533,9 @@ delegate [--json] workflow save <script.py> --name NAME
500
533
  and UTF-8 `promptBytes`; Cursor/Kimi/OMP prompts over 102400 bytes add a warning
501
534
  before their argv transport limit can fail a real run.
502
535
  - `--resume` replays the journal, adopts matching child runs by workflow agent
503
- key, and continues from missing work.
536
+ key, and continues from missing work. Resuming a completed `--dry-run` starts
537
+ its planned agents live under the same workflow ID; simulated journal events
538
+ remain visible for audit but are excluded from replay and live budget.
504
539
  - `wait` and `result` accept an explicit workflow ID or, when omitted, resolve
505
540
  the latest eligible workflow. JSON output for implicit selection includes the
506
541
  selected `wfId` and `resolutionKind: "latest"`.
@@ -671,7 +706,11 @@ Typical dry-run JSON fields:
671
706
 
672
707
  `isolation` is a human-readable summary combining `effectiveIsolation` and `isolationLifecycle` (e.g. `"worktree temporary"`, `"worktree persistent"`, `"none"`). Depend on the structured fields rather than parsing it. A push dry-run also includes `mailPushAdapter` with the audit status and the internal hook command; unverified harnesses include the pull-degradation warning.
673
708
 
674
- When a profile is active, dry-run and completion payloads add `authProfile` (the resolved profile name) and, when a Codex fallback profile is configured, `fallbackProfile`. Dry-run also adds `profileEnv` (the injected env map, with values redacted). These keys are omitted when no profile is active.
709
+ When a profile is active, dry-run and completion payloads add `authProfile`
710
+ (the resolved profile name). Codex dry-runs also always add `fallbackProfile`
711
+ (the configured profile name or `null`); completion payloads add it only when
712
+ a fallback is configured. Dry-run also adds `profileEnv` (the injected env map,
713
+ with values redacted). Profile metadata is omitted when no profile is active.
675
714
 
676
715
  For Cursor, Claude, Grok, OpenCode, Pi, Oh My Pi, Droid, and Kimi safe mode, an explicit `--isolation none`
677
716
  is normalized to `auto` with a warning because those safe contracts depend on
@@ -849,7 +888,7 @@ Automatic setup and refresh use these evidence sources:
849
888
  | Kimi | Models in the active Kimi configuration | Provider metadata may advertise efforts, but Delegate has no Kimi effort transport and still rejects `--reasoning-effort`. |
850
889
  | Claude | No model enumeration | The native effort enum is harness-wide evidence. |
851
890
  | Grok | Models visible to the active account | Exact config, discovery, or bundled declarations win; otherwise the native effort enum is harness-wide compatibility evidence and model-specific support remains unknown. |
852
- | Devin | No prompt-free model enumeration | Automatic discovery records only installation/version; Delegate has no Devin effort transport. |
891
+ | Devin | Family slugs, aliases, and concrete variants visible to the active account | The prompt-free JSON catalog carries display names; Delegate has no Devin effort transport. |
853
892
  | OpenCode | Harness catalog | Listed variants are `exact` for that model; models without exact variant evidence retain the documented unvalidated pass-through path. |
854
893
  | Pi | Harness catalog | Thinking support is model-specific, but available labels come from a harness-wide enum and are reported as partial model evidence. |
855
894
  | Oh My Pi | Harness catalog | A model's explicit `thinking` array is exact; missing arrays use harness-partial compatibility rather than fabricated model evidence. |
@@ -884,6 +923,8 @@ stale and ordinary launches ignore only that harness's record until refresh.
884
923
  Cached reads never run `--version` merely to test staleness, and neither does an
885
924
  ordinary launch: a cached record can only be short of what the harness now
886
925
  supports, never claim more, so one that satisfies the run is used as-is.
926
+ Existing Devin version-only cache records therefore remain valid but contain no
927
+ live catalog until `delegate capabilities refresh devin` is run.
887
928
 
888
929
  A launch re-probes `--version` for its own harness only when the cached record
889
930
  has already cost the run something: it refused an explicit `--reasoning-effort`,
@@ -909,11 +950,9 @@ policy to another. Dry runs never probe at all.
909
950
 
910
951
  All automatic probes run with `shell=False`, stdin closed, a neutral temporary
911
952
  working directory, bounded output, and a timeout. They pass the active profile
912
- environment but do not carry a task prompt. Devin is the explicit exception on
913
- the opt-in one-off surface: `models devin --live` uses a bounded invalid-model,
914
- prompt-like invocation to make Devin print its available-model error. Setup and
915
- `capabilities refresh` never use that Devin invocation; they run `--version`
916
- only.
953
+ environment but do not carry a task prompt. Devin uses the same prompt-free
954
+ `models list --format json` metadata command for setup, capability refresh, and
955
+ `models devin --live`; failures degrade to a version-only partial record.
917
956
 
918
957
  Discovery output applies best-effort credential scrubbing, so secret-shaped
919
958
  model IDs or diagnostic values may appear as `***`. Exact values should come
@@ -1008,7 +1047,7 @@ repo copy or persistent worktree itself.
1008
1047
  Tracked runs return bounded parent-facing output and store local metadata under `.delegate/` in the source workspace.
1009
1048
 
1010
1049
  ```bash
1011
- delegate runs [--active|--running|--stale|--recent] [--harness HARNESS] [--group NAME] [--limit N]
1050
+ delegate runs [--active|--running|--stale|--recent] [--harness HARNESS] [--group NAME] [--limit N] [--structural]
1012
1051
  delegate runs prune [--older-than DAYS] [--dry-run]
1013
1052
  delegate ps [--harness HARNESS] [--group NAME] [--limit N]
1014
1053
  delegate snapshot [--latest HARNESS] [--no-redact] <handle>
@@ -1055,8 +1094,18 @@ creating a Run or writing a prompt record.
1055
1094
  | Include dirty | `includeDirty` | `--include-dirty` | Source and explicit values are creation-only and are dropped for ordinary resume with a note. | Retained only as a drop decision; on a persistent/attached source, explicit `--include-dirty` is rejected because attachment does not create or sync a worktree. |
1056
1095
 
1057
1096
  `delegate runs` defaults to recent runs. `--active` preserves the legacy active view and includes both live `running` runs and `stale` runs. Use `--running` for only live tracked processes and `--stale` for runs recorded as running whose PID is missing or dead. `--active`, `--running`, `--stale`, and `--recent` are mutually exclusive. `--group NAME` filters by launch group and the runs table shows a `group` column when any visible run has one.
1097
+ `--structural` omits content-bearing run fields and emits only identity, lifecycle, model,
1098
+ timestamp, group/mode, and `initiatorRoot` metadata. It is intended for local status collectors.
1099
+ JSON output (`delegate.runs.v1`) includes `total` (post-filter match count before `--limit`)
1100
+ and `truncated` (`true` when `total` exceeds the returned `runs` length). Text mode appends
1101
+ `showing N of M runs (raise --limit to see more)` when truncated. A zero-row result with
1102
+ `--group` or `--harness` adds a `warnings` entry (and a matching text `warning:` line): when
1103
+ the scope filters match Runs that `--active`/`--running`/`--stale` then excluded, it names
1104
+ the status flag to drop; otherwise it notes the Registry is workspace-scoped and `--cwd PATH`
1105
+ targets another workspace's Registry — it does not claim the filter matches elsewhere.
1058
1106
  `delegate ps` is the shorter first-class form of `delegate runs --active` and
1059
- accepts the same harness, group, and limit selectors.
1107
+ accepts the same harness, group, limit, and structural selectors (including `total`,
1108
+ `truncated`, and the empty-filter workspace-scope warning).
1060
1109
 
1061
1110
  `delegate runs prune` removes old terminal Run records from the workspace Registry so they stop accumulating forever. Only runs whose effective status is terminal (`succeeded`, `failed`, `cancelled`, or `stale` from a dead child) and whose last Registry activity is older than the threshold (default 30 days; override with `--older-than DAYS`) are eligible. Effectively running runs are always skipped, and persistent-worktree runs are skipped unless their worktree is recorded as removed or missing — pruning the record of a live worktree would orphan it from `worktree list`/`show`/`remove`. Pruning deletes the per-Run directory (Snapshot, Manifest, logs, events, Completion Report) and the retained raw-log archive; worktree paths on disk are never touched. `--dry-run` reports what would be removed without changing anything. JSON output uses schema `delegate.runs-prune.v1` with `planned`, `removed`, `skipped` (each entry carries a `reason`), and `errors` sections.
1062
1111
 
@@ -1111,10 +1160,17 @@ Common JSON fields for tracked run completion:
1111
1160
 
1112
1161
  Persistent worktree completions also include `branch`, `worktree`, a
1113
1162
  `workSummary`, and (when requested) `commitPolicy`. `workSummary` reports dirty
1114
- state, changed file count, diff stat, and commits created by the child. When a
1115
- Codex usage-limit fallback fires, the completion payload also includes
1116
- `codexAuthFallback` metadata (reason, the primary and fallback profile names,
1117
- both exit codes, and a redacted primary stderr tail).
1163
+ state, changed file count, diff stat, and commits created by the child. Tracked
1164
+ Cursor completions include `usage` when the Cursor CLI reports it, using
1165
+ `basis: "reported"` and camel-case token fields such as `inputTokens` and
1166
+ `outputTokens`. When a Codex usage-limit fallback fires, the completion payload
1167
+ also includes `codexAuthFallback` metadata (reason, the primary and fallback
1168
+ profile names, both exit codes, and a redacted primary stderr tail). The
1169
+ fallback is Codex-only and is enabled only by `codex.fallbackProfile`; Delegate
1170
+ remembers temporary blocks by hashed credential namespace (`CODEX_HOME/auth.json` plus
1171
+ `codex.profile`) as canonical state. Default work/personal credential homes
1172
+ also mirror compatible legacy alias keys so existing launchers share blocks;
1173
+ remapped aliases remain isolated.
1118
1174
 
1119
1175
  Snapshot JSON uses schema `delegate.snapshot.v1` and includes fields such as `alias`, `runId`, `harness`, `status`, `rawStatus`, `effectiveStatus`, `staleReason`, `nextActions`, `cwd`, `executionCwd`, `workspaceRoot`, `assistantText`, `recentEvents`, `warnings`, `exitCode`, reasoning metadata, terminal metadata, and isolation/worktree metadata when applicable. `workspaceRoot` is also exported to the child as `WORKSPACE_ROOT`, so commands can anchor workspace-relative paths after changing directories. Inspection commands do not rewrite a stale run's recorded state; they expose the raw recorded status plus the effective status computed from the current PID check. Run-output and worktree show output include `requestedHandle`, `resolvedHandle`, and `resolutionKind` (`literal`, `latest`, or `latest_model`) when a handle resolves indirectly. For bare harness handles, snapshot, run-output, and wait also report `resolvedRunId`, `resolvedAlias`, `resolvedWorkspace`, `resolvedAge`, and `resolvedAgeSeconds`. Resolutions older than 24 hours add a `bare_handle_stale` warning suggesting `--cwd` or an explicit handle.
1120
1176
 
@@ -1136,6 +1192,28 @@ Work-mode attempts are never replayed after tool activity or a workspace change.
1136
1192
 
1137
1193
  Run-output JSON uses schema `delegate.run-output.v1` and returns selected completion report, stdout, and/or stderr content. By default, secret-like strings are redacted unless `--no-redact` is supplied. Tracked runs finish in one of the terminal statuses `succeeded`, `failed`, or `cancelled`; explicit harness cancellation/error terminal events override an exit-zero child status.
1138
1194
 
1195
+ Tracked stdout and stderr logs are capped independently at 16 MiB. Exceeding a
1196
+ cap terminates the child and records `output_limit_exceeded` plus an
1197
+ `outputLimit` object naming the stream and byte limit. After an explicit
1198
+ terminal-success event, Delegate gives the harness one second to exit and then
1199
+ stops a lingering process; successful envelopes disclose this as
1200
+ `stoppedAfterCompletion: true`. Harnesses must emit that terminal event only
1201
+ after flushing their final payload.
1202
+
1203
+ Each tracked Run also keeps `events.jsonl`, an append-only raw diagnostic mirror
1204
+ of child stdout lines as `{"kind":"stream.line","stream":"stdout","text":...}`
1205
+ records (including a final unterminated line when the child exits mid-line).
1206
+ The mirror retains at most 500 stdout-line records, followed by one
1207
+ `stream.lines_truncated` marker when additional lines are omitted. Normalized
1208
+ progress events also appear in Snapshot `recentEvents`; it retains the first
1209
+ 100 and latest 400 events while reporting the full `eventsTotal`. Both surfaces
1210
+ bound child-controlled event strings to 500 characters, including the `…`
1211
+ sentinel when clipped. Truncated `message`/raw-line text adds `textChars`; other
1212
+ normalized fields add `<field>Chars` (for example `targetChars`). Short fields
1213
+ omit truncation metadata.
1214
+ Retained event text is not redacted — treat `events.jsonl` and `recentEvents`
1215
+ as sensitive diagnostic artifacts.
1216
+
1139
1217
  Safe runs and read-only call runs that exit successfully with `resultQuality=empty`
1140
1218
  retry once with the original prompt plus a plain-text final-answer instruction.
1141
1219
  Pure and slash pass-through prompts, and write-capable calls, do not retry. Retried
@@ -265,6 +265,11 @@ Controls local run recording.
265
265
  - `retention.enabled`: whether raw logs are eligible for archive-only retention.
266
266
  - `retention.rawLogDays`: non-negative number of days before bulky raw logs may be archived.
267
267
 
268
+ Ambient retention is best-effort. Archive I/O is serialized separately from
269
+ Registry mutations, so a slow archive cannot block run progress, inspection,
270
+ or cancellation; if another retention pass is already active, a concurrent
271
+ ambient pass returns immediately.
272
+
268
273
  ### `cursor`
269
274
 
270
275
  ```json
@@ -336,7 +341,7 @@ Controls local run recording.
336
341
  - `models`: optional map of local aliases to Codex model IDs for `--model` / JSON `model`. Alias keys must not collide with mode names, equal the engine's own name, or start with `-`.
337
342
  - `defaultReasoningEffort`: optional non-empty effort string. When a Codex model resolves (run input or `codex.defaultModel`) and supports the level, Delegate emits a Codex config override; otherwise the run proceeds without reasoning effort and records a warning. An explicit `--reasoning-effort` flag fails closed for unsupported levels, but can target the Codex harness default model when no model is configured.
338
343
  - `profile`: optional Codex CLI config overlay name. It is config-only; JSON run input cannot set it.
339
- - `fallbackProfile`: optional top-level `profiles.definitions` name for one quota-limit retry on tracked Codex runs. The fallback profile must define `env.CODEX_HOME`.
344
+ - `fallbackProfile`: optional top-level `profiles.definitions` name for Codex-only quota fallback. The fallback profile must define `env.CODEX_HOME`. Tracked Codex runs persist temporary usage-limit blocks under `~/.ai-profiles/runtime/failover/`; hashed credential namespace (`CODEX_HOME/auth.json` plus `codex.profile`) is canonical, while default work/personal credential homes also mirror compatible legacy alias keys so existing launchers share blocks. Remapped aliases remain isolated. If both the primary and fallback credential namespaces are blocked, Delegate keeps the primary attempt and does not launch the known-blocked fallback.
340
345
  - `workSandbox`: `read-only`, `workspace-write`, or `danger-full-access` for Codex work mode when full bypass is not enabled.
341
346
  - `ephemeral`: include Codex `--ephemeral` in JSON-streaming runs.
342
347
  - `ignoreUserConfig`: include Codex `--ignore-user-config`.
@@ -110,6 +110,16 @@ resume against the first and fails with `workflow_locked`. Pick one.
110
110
  This preserves in-flight sibling results for replay while preventing unrelated
111
111
  siblings from starting after a human checkpoint has requested control.
112
112
 
113
+ A completed dry-run can also become a live run without creating a second
114
+ workflow record:
115
+
116
+ ```bash
117
+ python3 bin/delegate.py workflow run --resume wf_0123abcdef45
118
+ ```
119
+
120
+ Its simulated events remain in `journal.jsonl` for audit, but resume ignores
121
+ them as cached results and resets simulated budget before launching live agents.
122
+
113
123
  ## Limits
114
124
 
115
125
  Workflow scripts are intentionally capped:
@@ -59,8 +59,12 @@ Run focused tests first, then the broader checks before handoff:
59
59
  ```bash
60
60
  python3 -m compileall -q src tests bin
61
61
  git diff --check
62
- python3 -m unittest discover -s tests
62
+ python3 -m unittest discover -s tests -t .
63
63
  ```
64
64
 
65
+ `-t .` makes discovery import `tests/__init__.py`, which shims `src` onto
66
+ `sys.path` and strips ambient env. Unittest prints its `Ran N tests / OK`
67
+ summary to stderr — pipe with `2>&1` when capturing output.
68
+
65
69
  Required CI does not need real Cursor, Droid, Codex, Claude, Grok, Devin,
66
70
  OpenCode, Pi, Oh My Pi, or Kimi binaries.
@@ -28,7 +28,8 @@ When `AI_PROFILE=work|personal` is set and the matching
28
28
  `~/.delegate/config.<profile>.json` overlay is missing, Delegate blocks launch
29
29
  and mutation commands but allows read-only diagnostics (`profiles`, `runs`,
30
30
  `run-output`, `snapshot`, cached `capabilities`, `worktree show`,
31
- `worktree list`, `describe`, `models`) with a warning. This check runs inside
31
+ `worktree list`, `workflow check|status|watch|events|result|wait|list`,
32
+ `describe`, `models`) with a warning. This check runs inside
32
33
  `delegate_agent.cli:main` (`src/delegate_agent/profile_guard.py`), so it applies
33
34
  regardless of entrypoint: the installed pip console script, `python -m
34
35
  delegate_agent.cli`, or `bin/delegate.py`. Some local installs additionally put
@@ -38,8 +39,11 @@ check even earlier, before Python starts. `AI_PROFILE` values other than
38
39
  `work`/`personal` are not recognized profiles; Delegate warns and runs on the
39
40
  base account rather than failing closed, since there is no config filename
40
41
  convention to check against. Fix a half-configured install with
41
- `env -u AI_PROFILE delegate config sync-profiles`, or bypass once with
42
- `env -u AI_PROFILE delegate ...` or an explicit `DELEGATE_CONFIG=...`.
42
+ `env -u AI_PROFILE delegate config sync-profiles`, or bypass profile selection
43
+ once with `env -u AI_PROFILE delegate ...`.
44
+ In profile-aware shell installs, profile selection loads credentials; an
45
+ incoming explicit `DELEGATE_CONFIG` remains the runtime-policy config only
46
+ after the selected profile overlay passes validation.
43
47
 
44
48
  ## Do not promote implicitly
45
49