Repository navigation
Commit 614c3f9
feat: signal superseded drafts and verification outcome to WebSocket clients (#305)
* feat(serve): signal superseded drafts and verification outcome to clients
When the loop re-asks the model after a final-looking answer (completion
nudge or hint-mode verification retry), WebSocket clients received both
answers as ordinary text, and a strict-mode verification failure never
reached the live stream.
- loop: synchronous AnswerEventHandler (draft superseded, verification
started/completed) so frames stay in order with token_delta and land
before done; Engine/Agent.VerifyOutcome; superseded drafts persist
superseded + superseded_reason.
- serve: answer_superseded frame (turn-tagged, only for drafts streamed
live), verification runtime_event frames (no verifier prose),
done.verified; the bulk send skips drafts.
- REST runs reset the accumulated result on answer_superseded, the memory
buffer keeps the turn's final answer, and markdown export labels drafts.
- docs: protocol entries and a "Superseded drafts and verification"
section in docs/WEBUI.md.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* feat(ui): fold superseded drafts and flag unverified answers
- answer_superseded folds the streamed draft into a collapsed
"draft revised" row; the revised reply renders as the answer.
- done.verified == "fail" adds a "✗ unverified" chip to the current
turn's answer (never a draft or an earlier turn); a bulk token carrying
the verification-failed marker has it stripped in favor of the chip.
- History replay folds superseded records and renders persisted markers
as the chip.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>1 parent 59a357e commit 614c3f9
19 files changed
Lines changed: 1254 additions & 55 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
| 27 | + | |
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
981 | 981 | | |
982 | 982 | | |
983 | 983 | | |
| 984 | + | |
| 985 | + | |
| 986 | + | |
984 | 987 | | |
985 | 988 | | |
986 | 989 | | |
| |||
1032 | 1035 | | |
1033 | 1036 | | |
1034 | 1037 | | |
| 1038 | + | |
| 1039 | + | |
| 1040 | + | |
| 1041 | + | |
| 1042 | + | |
| 1043 | + | |
| 1044 | + | |
| 1045 | + | |
| 1046 | + | |
1035 | 1047 | | |
1036 | 1048 | | |
1037 | 1049 | | |
| |||
1084 | 1096 | | |
1085 | 1097 | | |
1086 | 1098 | | |
| 1099 | + | |
1087 | 1100 | | |
1088 | 1101 | | |
1089 | 1102 | | |
| |||
1105 | 1118 | | |
1106 | 1119 | | |
1107 | 1120 | | |
| 1121 | + | |
| 1122 | + | |
| 1123 | + | |
| 1124 | + | |
| 1125 | + | |
| 1126 | + | |
| 1127 | + | |
| 1128 | + | |
| 1129 | + | |
| 1130 | + | |
| 1131 | + | |
| 1132 | + | |
| 1133 | + | |
| 1134 | + | |
| 1135 | + | |
| 1136 | + | |
| 1137 | + | |
| 1138 | + | |
| 1139 | + | |
| 1140 | + | |
| 1141 | + | |
| 1142 | + | |
| 1143 | + | |
| 1144 | + | |
| 1145 | + | |
| 1146 | + | |
| 1147 | + | |
| 1148 | + | |
| 1149 | + | |
| 1150 | + | |
| 1151 | + | |
| 1152 | + | |
| 1153 | + | |
| 1154 | + | |
| 1155 | + | |
1108 | 1156 | | |
1109 | 1157 | | |
1110 | 1158 | | |
| |||
1278 | 1326 | | |
1279 | 1327 | | |
1280 | 1328 | | |
1281 | | - | |
1282 | | - | |
1283 | | - | |
1284 | | - | |
1285 | | - | |
1286 | | - | |
1287 | | - | |
1288 | | - | |
| 1329 | + | |
| 1330 | + | |
| 1331 | + | |
| 1332 | + | |
| 1333 | + | |
| 1334 | + | |
| 1335 | + | |
| 1336 | + | |
| 1337 | + | |
1289 | 1338 | | |
1290 | 1339 | | |
1291 | 1340 | | |
| |||
2477 | 2526 | | |
2478 | 2527 | | |
2479 | 2528 | | |
| 2529 | + | |
| 2530 | + | |
| 2531 | + | |
| 2532 | + | |
| 2533 | + | |
| 2534 | + | |
| 2535 | + | |
2480 | 2536 | | |
2481 | 2537 | | |
2482 | 2538 | | |
| |||
2497 | 2553 | | |
2498 | 2554 | | |
2499 | 2555 | | |
2500 | | - | |
| 2556 | + | |
| 2557 | + | |
2501 | 2558 | | |
2502 | | - | |
2503 | | - | |
2504 | | - | |
2505 | | - | |
2506 | | - | |
| 2559 | + | |
| 2560 | + | |
2507 | 2561 | | |
2508 | 2562 | | |
2509 | 2563 | | |
| |||
2556 | 2610 | | |
2557 | 2611 | | |
2558 | 2612 | | |
| 2613 | + | |
| 2614 | + | |
| 2615 | + | |
2559 | 2616 | | |
2560 | 2617 | | |
2561 | 2618 | | |
| |||
2566 | 2623 | | |
2567 | 2624 | | |
2568 | 2625 | | |
| 2626 | + | |
| 2627 | + | |
| 2628 | + | |
| 2629 | + | |
| 2630 | + | |
| 2631 | + | |
| 2632 | + | |
| 2633 | + | |
| 2634 | + | |
| 2635 | + | |
| 2636 | + | |
| 2637 | + | |
2569 | 2638 | | |
2570 | 2639 | | |
2571 | 2640 | | |
| |||
0 commit comments