feat(cron): add per-job reasoning effort overrides - #69911
Conversation
Duplicate of #7382: the current diff implements the same per-job |
teknium1
left a comment
There was a problem hiding this comment.
Thanks for consolidating the per-job reasoning work. Current main still lacks this capability: cron/jobs.py:1246 has no per-job reasoning_effort input and cron/scheduler.py:3364 resolves only model/global reasoning.
Problems
web/src/lib/cron-job.ts:100converts a malformed legacy value tonull;buildCronJobPayloadthen always emits thatnullat line 71. An unrelated dashboard edit therefore clears the stored value. This conflicts with the stated read/preserve compatibility contract, and the added test currently codifies the destructive result.
Suggested changes
- Preserve an invalid legacy value as a distinct editor state and omit
reasoning_effortfrom an update unless the selector was changed. Add a name-only edit test that proves the field is omitted.
This is an automated hermes-sweeper review.
| @@ -88,6 +100,7 @@ export function cronJobFormFromJob(job: CronJob): CronJobFormState { | |||
| base_url: asString(job.base_url), | |||
There was a problem hiding this comment.
This collapses an invalid legacy value to null; since buildCronJobPayload always emits reasoning_effort (line 71), a name-only dashboard save clears the stored value. Preserve a distinct invalid/preserve state and omit the field until the user changes this selector.
SummaryNine PRs address or reference #23524. #7382, #26214, #30929, #62623, #63327, #64565, #65679, and #69911 implement the same per-job cron reasoning override at varying surface breadth, while #14617 combines that mechanism with broader Related pull requests
Duplicates#7382, #26214, #30929, #62623, #63327, #64565, #65679, and #69911 implement substantially the same per-job cron Suggested consolidationKeep #7382 open with a salvage path as the canonical focused implementation: retain its validated storage boundary, current CLI parser wiring, canonical effort vocabulary, and shared resolver fallback. Author action: rebase #14617 and split out its distinct Complex graphflowchart TD
classDef open fill:#dbeafe,stroke:#1d4ed8,color:#1e3a8a
classDef merged fill:#dcfce7,stroke:#15803d,color:#14532d
classDef closed fill:#e5e7eb,stroke:#6b7280,color:#1f2937
classDef unverified fill:#f3f4f6,stroke:#9ca3af,color:#374151
classDef best stroke-width:3px,stroke:#b45309
classDef target stroke-width:3px,stroke:#4338ca
I23524(["issue #23524 (open)"])
subgraph Dup7382 ["PRs duplicating each other"]
P7382["PR #7382 (open)"]
P26214["PR #26214 (open)"]
P30929["PR #30929 (open)"]
P62623["PR #62623 (closed)"]
P63327["PR #63327 (open)"]
P64565["PR #64565 (closed)"]
P65679["PR #65679 (closed)"]
P69911["PR #69911 (open)"]
end
P69911 -->|fixes| I23524
class I23524 open
class P7382 open
class P26214 open
class P30929 open
class P62623 closed
class P63327 open
class P64565 closed
class P65679 closed
class P69911 open
class P7382 best
class P65679 best
class P69911 target
click I23524 "https://github.com/NousResearch/hermes-agent/issues/23524"
click P7382 "https://github.com/NousResearch/hermes-agent/pull/7382"
click P26214 "https://github.com/NousResearch/hermes-agent/pull/26214"
click P30929 "https://github.com/NousResearch/hermes-agent/pull/30929"
click P62623 "https://github.com/NousResearch/hermes-agent/pull/62623"
click P63327 "https://github.com/NousResearch/hermes-agent/pull/63327"
click P64565 "https://github.com/NousResearch/hermes-agent/pull/64565"
click P65679 "https://github.com/NousResearch/hermes-agent/pull/65679"
click P69911 "https://github.com/NousResearch/hermes-agent/pull/69911"
Graph: solid arrow = fixes / best fix, dashed arrow = partial or unverified (see edge label); boxed group = PRs duplicating each other; amber border = best fix; indigo border = target; gray node = closed (state tag in the node label). Cross-PR triage: Reviewed 9 pull requests and 1 issue in this complex. Each diff was read against this issue; Assessment working set: 423 kB of PR diffs, 27 kB of issue/PR text, 20 kB of discussion (29 comments), 17 verify verdicts. verdicts reflect diff content, not PR titles. Part of an automated triage batch. |
|
Heads-up: the core cron half of this (store validation, scheduler precedence, CLI flags, docs) landed on main via #91244 (43c6dac, salvaged from #91038; first-submitter credit to @PavelTajdus in #30929). What #91244 did NOT land is your desktop/dashboard/web surfacing — that half is still open ground. Two notes for a rebase: (1) the merged store uses |
Related to merged #91244: the core cron implementation landed there, while the desktop/dashboard/web user surface remains a valid follow-up if rebased onto that implementation and kept out of the model-facing cronjob tool schema. |
Closes #23524.
Summary
Add a first-class optional
reasoning_effortoverride to each cron job and carry it through storage, runtime resolution, the unifiedcronjobtool, CLI, authenticated APIs, web/desktop editors, automation blueprints, tests, and docs.This is a current-
mainconsolidation of the overlapping work and design discussion in #7382, #14617, #26214, #30929, #62623, #63327, #64565, and #65679. In particular:maxandultra;agent.reasoning_overridesresolver rather than replacing or bypassing it.Thanks to @MikelCalvo, @Alex-giao, @evaclawdbot, @PavelTajdus, @dschnurbusch, @the3asic, and the authors/reviewers of the related attempts for establishing the behavior and edge cases this consolidation covers.
Semantics
Canonical stored values are:
Resolution happens only after provider authentication/fallback has selected the model actually used:
Behavior at write boundaries:
null: inherit; store no key;null, or CLI--reasoning-effort inherit: remove the key and restore inheritance;none: explicitly disable reasoning for this job;false: canonicalize tonone;true, empty/unknown values, containers, and numbers: reject;Script-only
no_agentjobs retain the configured value for editing/audit and for switching back to agent mode, but never apply it at runtime.Surface coverage
cronjobcreate/update/listhermes cron create,edit, andlistVerification
Rebased onto current
main(de5ece994) before submission.git diff --check: passedA broader local project run discovered 42,046 tests and reported 25 failures in 14 unrelated platform/environment tests on macOS (for example missing Linux
systemctlutilities and/tmpvs/private/tmpassumptions). The complete cron suite remained green.Compatibility
Existing
jobs.jsonrecords require no migration and are not rewritten merely by being read or listed. Jobs without the field continue to inherit the existing per-model/global reasoning policy.