Show the model a stage will use and word the enrich row correctly

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
WolfandClaude Fable 5.1 committed 2026-09-30 15:44:32 +02:00
1 parent 800c0c428e
commit 2d9806bdbf
2 files changed
+17 -7

No files matched your search

+6 -3
View File
@@ -11,11 +11,14 @@ finders ask it (`extract.extract_task`, `summarise.summarise_task`).
`enrich` (reading the best roles on their own pages, `app/jobs/enrich.py`) `enrich` (reading the best roles on their own pages, `app/jobs/enrich.py`)
asks no model and is on by default (`enrich.enabled`); its switch is asks no model and is on by default (`enrich.enabled`); its switch is
`stage:enrich`, set the same way through `PUT /api/stages/enrich`. `stage:enrich`, set the same way as the others: by the Runs page
(`PUT /api/stages/enrich`) and by `app stages enrich on|off`.
`describe` is what `GET /api/stages` and `app stages` show: for each stage `describe` is what `GET /api/stages` and `app stages` show: for each stage
with a switch, the model stages and `enrich`, whether it is on, where that comes from, the model it uses, and who with a switch, the model stages and `enrich`, whether it is on, where that comes from, the model it uses, and who
would answer. would answer. The model is the one a call is made with: `agent.model` when
set, since it overrides the per-task model everywhere (`desk/modeltask.py`),
else the stage's own.
""" """
from __future__ import annotations from __future__ import annotations
@@ -98,7 +101,7 @@ def describe_one(config: Config, store: Store, name: str) -> Stage:
backend, said = answer(config) backend, said = answer(config)
return Stage(name=name, on=stage_on(config, store, name), return Stage(name=name, on=stage_on(config, store, name),
source="config" if stored(store, name) is None else "stored", source="config" if stored(store, name) is None else "stored",
model=getattr(getattr(config, name), "model", ""), backend=backend, model=config.agent.model or getattr(config, name).model, backend=backend,
answer=said) answer=said)
+11 -4
View File
@@ -109,10 +109,17 @@
...(stage.model ? [el("span", "badge", stage.model)] : [])); ...(stage.model ? [el("span", "badge", stage.model)] : []));
row.append(name, stageSwitch(stage, () => renderStages(stages))); row.append(name, stageSwitch(stage, () => renderStages(stages)));
const sub = el("span", "sub"); const sub = el("span", "sub");
sub.append(`${DOES[stage.name]}. How deep it reads is set per search agent, under `); if (stage.name === "enrich") {
const agents = el("a", "", "Search agents"); /* Global, unlike the model stages: `enrich.top` and `enrich.min_score`. */
agents.href = "/settings/agents"; sub.append(`${DOES[stage.name]}. How many it reads is set for every agent alike by `
sub.append(agents, stage.source === "config" + "enrich.top and enrich.min_score in config.yaml");
} else {
sub.append(`${DOES[stage.name]}. How deep it reads is set per search agent, under `);
const agents = el("a", "", "Search agents");
agents.href = "/settings/agents";
sub.append(agents);
}
sub.append(stage.source === "config"
? ". Following config.yaml until this switch is used." ? ". Following config.yaml until this switch is used."
: "."); : ".");
row.appendChild(sub); row.appendChild(sub);