The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.
Rust agent-orchestrationai-agentsai-assistantdesktopllmlocal-firstmcppersonal-aiprivacyrustsecond-braintauri
fix(tinyagents): cap retry backoff override at production initial wait
Steven Enamakel52ac7b92b01b
diff --git a/.github/workflows/ci-lanes.yml b/.github/workflows/ci-lanes.ymlindex f518c6e873..3c8a0e0419 100644--- a/.github/workflows/ci-lanes.yml+++ b/.github/workflows/ci-lanes.yml@@ -59,11 +59,6 @@ jobs:# Sequential diagnostic validation plus cache save already took 118 min# before seven coverage suites could execute; reserve a complete-run budget.timeout-minutes: 180- env:- # One line per compile (outcome, crate, time, why not stored): ranks the- # misses and the not-cacheable compiles. Copied to ci-out/tinymold.log by- # "Record cache statistics" below and uploaded with the lane logs.- TINYMOLD_LOG: ${{ runner.temp }}/tinymold.logsteps:- name: Checkout PR merge commituses: tinyhumansai/.github/actions/checkout@35fa65b76c80d48779592b111837e55d9d0860d4@@ -81,6 +76,10 @@ jobs:- name: Verify private runner contractrun: bash scripts/ci/self-hosted/verify-runner.sh+ - name: Set Tinymold diagnostic log path+ # RUNNER_TEMP is available to steps, but not to the job-level env block.+ run: echo "TINYMOLD_LOG=$RUNNER_TEMP/tinymold.log" >> "$GITHUB_ENV"+- name: Setup Tinymoldid: tinymolduses: tinyhumansai/tinymold@c4a7ea77ce4a95bf0a65fb403de310bd624197d4diff --git a/crates/openhuman-core/src/agent/tinyagents/turn_policy.rs b/crates/openhuman-core/src/agent/tinyagents/turn_policy.rsindex 8598936b4b..ec1dcffa4c 100644--- a/crates/openhuman-core/src/agent/tinyagents/turn_policy.rs+++ b/crates/openhuman-core/src/agent/tinyagents/turn_policy.rs@@ -168,12 +168,13 @@ pub(crate) fn run_policy_for_provider_with_backoff(/// Scale the model-call retry schedule down to `initial` milliseconds/// (`OPENHUMAN_MODEL_RETRY_BACKOFF_MS`). The attempt count and the doubling/// shape are kept; only the waits shrink, so suites that drive a failing-/// upstream do not sit through the 3/6/12/24 s production schedule. Unset,-/// empty, `0` or unparsable leaves the production schedule untouched.+/// upstream do not sit through the 3/6/12/24 s production schedule. Values+/// above the production initial wait, as well as unset, empty, `0` or+/// unparsable values, leave the production schedule untouched.pub(crate) fn apply_retry_backoff_override(policy: &mut RunPolicy, raw: Option<&str>) {let Some(ms) = raw.and_then(|v| v.trim().parse::<u64>().ok())- .filter(|ms| *ms > 0)+ .filter(|ms| *ms > 0 && *ms <= policy.retry.initial_backoff_ms)else {return;};diff --git a/crates/openhuman-core/src/agent/tinyagents/turn_policy_budget_tests.rs b/crates/openhuman-core/src/agent/tinyagents/turn_policy_budget_tests.rsindex 3f4b0ebb21..52270bd360 100644--- a/crates/openhuman-core/src/agent/tinyagents/turn_policy_budget_tests.rs+++ b/crates/openhuman-core/src/agent/tinyagents/turn_policy_budget_tests.rs@@ -109,7 +109,14 @@ fn hosted_openai_keeps_the_hosted_ceilings_in_the_policy() {#[test]fn retry_backoff_override_shrinks_the_schedule_and_ignores_junk() {let production = run_policy_for_provider_with_backoff(8, false, false, None, None).retry;- for raw in [None, Some(""), Some("0"), Some("abc"), Some("-5")] {+ for raw in [+ None,+ Some(""),+ Some("0"),+ Some("abc"),+ Some("-5"),+ Some("60000"),+ ] {let mut policy = run_policy_for_provider_with_backoff(8, false, false, None, None);apply_retry_backoff_override(&mut policy, raw);assert_eq!(