fix: Refine flow — optimistic UI update + instruction passthrough

- Add getActiveRefineAgent to spawn mutation optimistic updates and
  live event invalidation rules so the refine panel reflects agent
  state immediately without manual refresh
- Accept optional instruction param in buildRefinePrompt() and inject
  it as <user_instruction> block so the agent knows what to focus on
- Pass input.instruction through in architect router spawn call
This commit is contained in:
Lukas May
2026-03-05 16:58:12 +01:00
parent 3d1818d567
commit 763871a2a5
4 changed files with 17 additions and 7 deletions

View File

@@ -265,7 +265,7 @@ export function architectProcedures(publicProcedure: ProcedureBuilder) {
status: 'in_progress',
});
const prompt = buildRefinePrompt();
const prompt = buildRefinePrompt(input.instruction);
return agentManager.spawn({
name: input.name,