Commit 6797c81
committed
feat(honcho): add observed_peer/observer_peer params to conclusion writes
Closes the write-side symmetry gap. The read tools shipped in 1e70994 already
accept literal peer names via query_peer_conclusions; create_conclusion(s)
now match.
New optional params on create_conclusion and create_conclusions:
- observed_peer: literal peer name being observed (overrides 'observed' alias)
- observer_peer: literal peer name doing the observing (defaults to AI peer)
Enables cell-B writes (user evaluating an AI peer) and arbitrary multi-agent
edges (Claude observing Codex, etc.) without breaking the existing
'observed: user|self' alias contract for the common cases.
Resolution lives in a single helper, resolveConclusionPeers, used by both
create handlers. Literal names take precedence over aliases when provided;
alias-only callers see identical behavior. Response payload now reports the
resolved (observer, observed) edge for traceability.
The bulk handler also reuses cached peer objects (userPeer / aiPeer from the
session block) when resolved names match — only fetches fresh peer objects
for genuinely arbitrary edges.1 parent 792b3cc commit 6797c81
2 files changed
Lines changed: 135 additions & 30 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29216 | 29216 | | |
29217 | 29217 | | |
29218 | 29218 | | |
| 29219 | + | |
| 29220 | + | |
| 29221 | + | |
| 29222 | + | |
| 29223 | + | |
| 29224 | + | |
| 29225 | + | |
| 29226 | + | |
| 29227 | + | |
| 29228 | + | |
| 29229 | + | |
| 29230 | + | |
| 29231 | + | |
| 29232 | + | |
| 29233 | + | |
| 29234 | + | |
| 29235 | + | |
29219 | 29236 | | |
29220 | 29237 | | |
29221 | 29238 | | |
| |||
29678 | 29695 | | |
29679 | 29696 | | |
29680 | 29697 | | |
| 29698 | + | |
| 29699 | + | |
| 29700 | + | |
| 29701 | + | |
| 29702 | + | |
| 29703 | + | |
| 29704 | + | |
| 29705 | + | |
29681 | 29706 | | |
29682 | 29707 | | |
29683 | 29708 | | |
| |||
29967 | 29992 | | |
29968 | 29993 | | |
29969 | 29994 | | |
| 29995 | + | |
| 29996 | + | |
| 29997 | + | |
| 29998 | + | |
| 29999 | + | |
| 30000 | + | |
| 30001 | + | |
| 30002 | + | |
29970 | 30003 | | |
29971 | 30004 | | |
29972 | 30005 | | |
| |||
30156 | 30189 | | |
30157 | 30190 | | |
30158 | 30191 | | |
30159 | | - | |
30160 | | - | |
30161 | | - | |
30162 | | - | |
30163 | | - | |
30164 | | - | |
30165 | | - | |
| 30192 | + | |
| 30193 | + | |
| 30194 | + | |
30166 | 30195 | | |
30167 | | - | |
| 30196 | + | |
| 30197 | + | |
| 30198 | + | |
| 30199 | + | |
| 30200 | + | |
| 30201 | + | |
| 30202 | + | |
| 30203 | + | |
| 30204 | + | |
30168 | 30205 | | |
30169 | 30206 | | |
30170 | 30207 | | |
| |||
30325 | 30362 | | |
30326 | 30363 | | |
30327 | 30364 | | |
30328 | | - | |
30329 | | - | |
| 30365 | + | |
| 30366 | + | |
| 30367 | + | |
30330 | 30368 | | |
30331 | 30369 | | |
30332 | 30370 | | |
| 30371 | + | |
| 30372 | + | |
30333 | 30373 | | |
30334 | 30374 | | |
30335 | 30375 | | |
30336 | 30376 | | |
30337 | | - | |
| 30377 | + | |
30338 | 30378 | | |
30339 | 30379 | | |
30340 | 30380 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
58 | 89 | | |
59 | 90 | | |
60 | 91 | | |
| |||
600 | 631 | | |
601 | 632 | | |
602 | 633 | | |
| 634 | + | |
| 635 | + | |
| 636 | + | |
| 637 | + | |
| 638 | + | |
| 639 | + | |
| 640 | + | |
| 641 | + | |
603 | 642 | | |
604 | 643 | | |
605 | 644 | | |
| |||
889 | 928 | | |
890 | 929 | | |
891 | 930 | | |
| 931 | + | |
| 932 | + | |
| 933 | + | |
| 934 | + | |
| 935 | + | |
| 936 | + | |
| 937 | + | |
| 938 | + | |
892 | 939 | | |
893 | 940 | | |
894 | 941 | | |
| |||
1099 | 1146 | | |
1100 | 1147 | | |
1101 | 1148 | | |
1102 | | - | |
1103 | | - | |
1104 | | - | |
1105 | | - | |
1106 | | - | |
1107 | | - | |
1108 | | - | |
1109 | | - | |
1110 | | - | |
1111 | | - | |
1112 | | - | |
| 1149 | + | |
| 1150 | + | |
| 1151 | + | |
| 1152 | + | |
| 1153 | + | |
| 1154 | + | |
| 1155 | + | |
| 1156 | + | |
1113 | 1157 | | |
1114 | 1158 | | |
1115 | 1159 | | |
1116 | | - | |
| 1160 | + | |
| 1161 | + | |
| 1162 | + | |
| 1163 | + | |
| 1164 | + | |
| 1165 | + | |
| 1166 | + | |
| 1167 | + | |
| 1168 | + | |
1117 | 1169 | | |
1118 | 1170 | | |
1119 | 1171 | | |
| |||
1305 | 1357 | | |
1306 | 1358 | | |
1307 | 1359 | | |
| 1360 | + | |
| 1361 | + | |
| 1362 | + | |
| 1363 | + | |
| 1364 | + | |
| 1365 | + | |
1308 | 1366 | | |
1309 | | - | |
1310 | | - | |
1311 | | - | |
1312 | | - | |
1313 | | - | |
| 1367 | + | |
| 1368 | + | |
| 1369 | + | |
| 1370 | + | |
| 1371 | + | |
| 1372 | + | |
| 1373 | + | |
| 1374 | + | |
1314 | 1375 | | |
1315 | | - | |
| 1376 | + | |
1316 | 1377 | | |
1317 | 1378 | | |
1318 | 1379 | | |
1319 | 1380 | | |
| 1381 | + | |
| 1382 | + | |
| 1383 | + | |
| 1384 | + | |
1320 | 1385 | | |
1321 | 1386 | | |
1322 | 1387 | | |
1323 | 1388 | | |
1324 | | - | |
| 1389 | + | |
1325 | 1390 | | |
1326 | 1391 | | |
1327 | 1392 | | |
| |||
0 commit comments