react-agent-harness 0.12.1__tar.gz → 0.14.0__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.
- {react_agent_harness-0.12.1/react_agent_harness.egg-info → react_agent_harness-0.14.0}/PKG-INFO +1 -1
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/README.md +53 -9
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/agents/base.py +631 -573
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/console.py +14 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/events.py +29 -0
- react_agent_harness-0.14.0/harness/runstate.py +416 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/runtime.py +77 -75
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/orchestrator/planner.py +222 -32
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/pyproject.toml +2 -1
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0/react_agent_harness.egg-info}/PKG-INFO +1 -1
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/react_agent_harness.egg-info/SOURCES.txt +8 -0
- react_agent_harness-0.14.0/tests/test_budget_restore.py +129 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_checkpoint_resume.py +311 -84
- react_agent_harness-0.14.0/tests/test_concurrent_same_agent.py +400 -0
- react_agent_harness-0.14.0/tests/test_hitl_gate.py +192 -0
- react_agent_harness-0.14.0/tests/test_orchestrator_task_state.py +330 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_per_call_site_llm.py +8 -8
- react_agent_harness-0.14.0/tests/test_resumable_delegation.py +342 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_resume_hint_banner.py +1 -1
- react_agent_harness-0.14.0/tests/test_run_state_machine.py +338 -0
- react_agent_harness-0.14.0/tests/test_runstate.py +357 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_subagent_tool.py +24 -9
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tools/builtin/subagent.py +97 -2
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/LICENSE +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/agents/__init__.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/__init__.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/agent_tree.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/annotation.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/background_tasks.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/cancellation.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/checkpoint.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/cli.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/executor_bridge.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/hitl.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/llm/__init__.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/llm/_streaming.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/llm/anthropic.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/llm/auth.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/llm/claude_code.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/llm/fallback.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/llm/openai.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/llm/openai_codex.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/llm/reasoning.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/llm/routing.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/model_switching.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/oauth_browser.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/otel.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/persistent.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/persistent_completion.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/persistent_controls.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/persistent_prompt.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/plan_mode.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/session_memory.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/skills.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/steering.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/streaming.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/tool_policy.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/trace.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/trace_viewer.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/harness/utils.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/memory/__init__.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/memory/episodic_lance.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/memory/manager.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/memory/redis_store.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/memory/stores.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/memory/working.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/orchestrator/__init__.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/react_agent_harness.egg-info/dependency_links.txt +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/react_agent_harness.egg-info/entry_points.txt +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/react_agent_harness.egg-info/requires.txt +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/react_agent_harness.egg-info/top_level.txt +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/setup.cfg +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_agents_base.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_annotation.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_anthropic_llm.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_background_tasks.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_budget_guard.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_cancellation.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_claude_code_llm.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_cli.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_console_renderer.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_event_payloads.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_executor_bridge.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_fallback_llm.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_fan_in.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_hitl_banner.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_http_fetch.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_llm_auth.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_mcp_adapter.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_mcp_auth.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_mcp_streamable_http.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_memory.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_memory_reconciler.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_memory_touchpoints.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_model_switching.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_oauth_browser.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_openai_codex_llm.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_openai_llm.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_orchestrator.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_otel.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_parse_action_json.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_persistent_agent.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_persistent_completion.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_persistent_controls.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_persistent_prompt.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_plan_approval.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_plan_mode.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_plan_mode_controller.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_redis_store.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_routing_llm.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_session_memory.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_skills.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_steering.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_streaming.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_system_prompt_routing.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_tool_policy.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_trace.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_trailing_assistant_state.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_utils.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_vision.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tests/test_working_memory.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tools/__init__.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tools/builtin/__init__.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tools/builtin/background.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tools/builtin/fetch_image.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tools/builtin/http_fetch.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tools/mcp/__init__.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tools/mcp/adapter.py +0 -0
- {react_agent_harness-0.12.1 → react_agent_harness-0.14.0}/tools/mcp/auth.py +0 -0
{react_agent_harness-0.12.1/react_agent_harness.egg-info → react_agent_harness-0.14.0}/PKG-INFO
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: react-agent-harness
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.14.0
|
|
4
4
|
Summary: Multi-agent LLM orchestration: hybrid DAG planning, two-tier memory, streaming, cost/token budgets with per-call-site breakdown
|
|
5
5
|
Requires-Python: >=3.10
|
|
6
6
|
License-File: LICENSE
|
|
@@ -52,6 +52,7 @@ harness/tool_policy.py Persistent tool policy — user-scoped allow rules,
|
|
|
52
52
|
harness/console.py ConsoleRenderer — centralised BusEvent formatting + render_budget helper
|
|
53
53
|
harness/steering.py Async steering — agent.steer(text), StdinRouter pub/sub, FileSteer, factory helpers
|
|
54
54
|
harness/checkpoint.py CheckpointStore + _ResumeHint + maybe_resume_key — pluggable run-state persistence (file + Redis); auto-resume built into dispatch_stream / run_stream
|
|
55
|
+
harness/runstate.py RunState / OrchestratorState — the explicit, serializable position of a run: step + phase, per-action and per-task status, budget, failure reason
|
|
55
56
|
harness/otel.py OTELHook — OpenTelemetry span exporter (opt-in)
|
|
56
57
|
harness/executor_bridge.py ExecutorBridge + ExecutorTool — controlled subprocess launcher with optional Docker sandboxing
|
|
57
58
|
harness/oauth_browser.py Localhost OAuth callback server + open_or_print_url — shared by MCP browser-OAuth and LLM login flows
|
|
@@ -671,6 +672,15 @@ continuity flows through long-term memory (`MemoryManager.build_context(
|
|
|
671
672
|
agent_id=…)`), not through WM carry-over — same model as the
|
|
672
673
|
orchestrator's per-task agents.
|
|
673
674
|
|
|
675
|
+
**Crash-resume.** A delegation mints its own `run_id`, which reaches the
|
|
676
|
+
parent on the `subagent_start` event and is recorded on the action. If the
|
|
677
|
+
process dies mid-delegation, resuming the parent continues the sub-agent from
|
|
678
|
+
its own checkpoint instead of re-running it. Resuming is best-effort: with no
|
|
679
|
+
checkpoint store, no stored state, or a pre-0.13 checkpoint, the delegation
|
|
680
|
+
simply runs again. Execution is at-least-once either way — the step in flight
|
|
681
|
+
when the checkpoint was written is replayed, which `ActionState.attempts`
|
|
682
|
+
records.
|
|
683
|
+
|
|
674
684
|
Parallel delegation works via the existing `actions: [...]` shape:
|
|
675
685
|
|
|
676
686
|
```json
|
|
@@ -827,9 +837,13 @@ The demo uses that utility for:
|
|
|
827
837
|
|
|
828
838
|
Background sub-agent tasks are process-local. They keep running while the
|
|
829
839
|
REPL/server process is alive; completed results become durable only when
|
|
830
|
-
collected into the session transcript with `/tasks collect <id|all>`.
|
|
831
|
-
|
|
832
|
-
|
|
840
|
+
collected into the session transcript with `/tasks collect <id|all>`.
|
|
841
|
+
|
|
842
|
+
Overlapping delegations to one sub-agent are safe as of 0.13: each invocation
|
|
843
|
+
runs on its own copy of the tool and its nested agent, so concurrent runs no
|
|
844
|
+
longer share working memory. What remains your responsibility is whether that
|
|
845
|
+
agent's **tools and LLM adapter** tolerate concurrent use — a tool holding a
|
|
846
|
+
single connection or a non-reentrant client still needs its own guarding.
|
|
833
847
|
|
|
834
848
|
When a `PersistentAgent` coordinator is wired with `SubAgentTool`s, it also
|
|
835
849
|
gets LLM-visible background tools automatically:
|
|
@@ -1632,6 +1646,10 @@ agent-harness policy clear
|
|
|
1632
1646
|
**Wall-time budget** is suspended while waiting for input — human think-time
|
|
1633
1647
|
does not count against `max_wall_time_seconds`.
|
|
1634
1648
|
|
|
1649
|
+
**Gating does not depend on durability.** A tool listed in `hitl_tools` is
|
|
1650
|
+
always gated; with no checkpoint store configured you still get the prompt,
|
|
1651
|
+
you just don't get crash-resume.
|
|
1652
|
+
|
|
1635
1653
|
### Step-level checkpointing
|
|
1636
1654
|
|
|
1637
1655
|
Enable periodic crash-resume independent of HITL:
|
|
@@ -1654,16 +1672,42 @@ Each agent writes to its own key so orchestrated runs never overwrite each other
|
|
|
1654
1672
|
| Path | Checkpoint key | Stored at |
|
|
1655
1673
|
|---|---|---|
|
|
1656
1674
|
| Single-agent (`run_agent`, `run_routed`) | `<run_id>:<agent_id>` | `~/.agent-harness/checkpoints/<run_id>:<agent_id>.json` |
|
|
1657
|
-
| Orchestrated (`run`, `run_stream`) | `<run_id>` (orchestrator) + `<run_id>:<agent_id>` (each
|
|
1675
|
+
| Orchestrated (`run`, `run_stream`) | `<run_id>` (orchestrator) + `<run_id>:<task_id>:<agent_id>` (each task) | one file per task, one file for the orchestrator |
|
|
1676
|
+
|
|
1677
|
+
Orchestrated agent keys carry the **task id** because a plan may name the same
|
|
1678
|
+
agent for two tasks; keyed only by agent id, both would write to one file and
|
|
1679
|
+
overwrite each other.
|
|
1658
1680
|
|
|
1659
|
-
The orchestrator checkpoint stores the goal, the
|
|
1660
|
-
|
|
1661
|
-
|
|
1681
|
+
The orchestrator checkpoint stores the goal, the *current* plan (replanning
|
|
1682
|
+
replaces it), a `TaskState` per planned task, and the replan count. Per-task
|
|
1683
|
+
status — `pending / running / done / failed / skipped` plus a durable attempt
|
|
1684
|
+
counter — is what lets a task interrupted mid-flight resume from its agent's
|
|
1685
|
+
own position rather than restarting. It is written at each task transition and
|
|
1686
|
+
deleted on clean `DONE`.
|
|
1662
1687
|
|
|
1663
1688
|
### Crash / Ctrl-C resume
|
|
1664
1689
|
|
|
1665
|
-
|
|
1666
|
-
|
|
1690
|
+
A checkpoint is a `RunState` (`harness/runstate.py`): where the run is (`step`
|
|
1691
|
+
plus a `think / approve / act / observe` phase), the actions of the current
|
|
1692
|
+
step with per-action status, the full `WorkingMemory`, the budget so far, and —
|
|
1693
|
+
if it failed — why. It is written before every HITL prompt and (if
|
|
1694
|
+
`checkpoint_every > 0`) at each periodic step.
|
|
1695
|
+
|
|
1696
|
+
Resuming is not a separate code path: the loop loads the state and keeps
|
|
1697
|
+
advancing it, so a run that died partway through a batch of approvals comes
|
|
1698
|
+
back knowing which calls were already approved and which tools already ran.
|
|
1699
|
+
|
|
1700
|
+
Recorded spending is restored, so a resumed run cannot start its budget over.
|
|
1701
|
+
The exception is a run that failed *because* of the budget — restoring the
|
|
1702
|
+
guard that just tripped would fail again at the same point, so the raised
|
|
1703
|
+
`GuardrailConfig` is allowed to take effect instead.
|
|
1704
|
+
|
|
1705
|
+
> **Checkpoints from before 0.13 cannot be resumed.** They predate per-action
|
|
1706
|
+
> and per-task status, so there is no honest way to reconstruct where such a
|
|
1707
|
+
> run actually was; `runtime.resume()` raises `LegacyCheckpointError` rather
|
|
1708
|
+
> than guessing. Checkpoints are short-lived by design —
|
|
1709
|
+
> `FileCheckpointStore.purge_old` defaults to 7 days, `RedisCheckpointStore`
|
|
1710
|
+
> expires after 24h.
|
|
1667
1711
|
|
|
1668
1712
|
**What the banner prints:**
|
|
1669
1713
|
|