2 Commits

Author SHA1 Message Date
hataa
bea75f3b23
fix(subagents): verify the returned row position in read_batch_item (#8191)
read_batch_item trusted list_items(offset=position) to land on position.
That only holds while item rows are dense: OFFSET-based paging skips
surviving rows over any gap (e.g. a future retention delete), so the
reader would serve the next item's report attributed to the requested
item key, and the tool layer would project next_position from the wrong
base. The browser projection (read_browser_batch_item) already verifies
items[0].position; align the model-facing reader with it and add the
same negative-position guard. Reading past a gap now returns not_found
instead of a shifted row, matching the browser path's semantics.
2026-11-12 22:12:07 +08:00
Guo-Yixin
8011677d70
feat(subagents): add bounded same-thread batch result inspection (#6416)
* feat(subagents): add bounded same-thread batch result reader

* test(subagents): validate batch result reader on PostgreSQL

* docs(subagents): explain batch reader budget and position contracts

* fix(tests): adapt batch reader PostgreSQL CI connection options

---------

Co-authored-by: Willem Jiang <willem.jiang@gmail.com>
2026-10-07 18:43:31 +08:00