Skip to content

[pull] main from danny-avila:main - #164

Merged
pull[bot] merged 7 commits into
innFactory:mainfrom
danny-avila:main
Aug 7, 2026
Merged

[pull] main from danny-avila:main#164
pull[bot] merged 7 commits into
innFactory:mainfrom
danny-avila:main

Conversation

@pull

@pull pull Bot commented Aug 7, 2026

Copy link
Copy Markdown

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.4)

Can you help keep this open source service alive? 💖 Please sponsor : )

* feat: support resumable HITL in subagents

* fix: prioritize stream breaker failures

* fix: preserve subagent resume state

* fix: scope rebuilt run resumes

* fix: preserve resumable child state

* fix: persist subagent replay lifecycle

* test: align HITL checkpointer expectation

* fix: restore cached subagent replay metadata

* fix: harden subagent replay lifecycle

* fix: preserve approval policy branches

* fix: fail closed on malformed approvals

* fix: preserve child checkpoint ownership

* fix: preserve one-shot approval replay

* fix: isolate reconstructed subagent branches

* fix: snapshot resumable subagent state

* fix: make subagent replay restoration atomic

* fix: isolate repeated resume attempts

* fix: preserve live approval hook evaluation

* fix: isolate subagent approval resume branches

* test: cover subagent resume isolation

* fix: isolate subagent resume lifecycle

* fix: scope Send subagent replay batches

* fix: preserve custom interrupt payloads

* fix: restore rebuilt resume output
* feat(search): add RagApiReranker for public rag_api /v1/rerank

Implements the fast-v1 reranker profile against public danny-avila/rag_api
(Track 5 of the search-stack plan), matching the existing Jina/Cohere
reranker conventions in src/tools/search/rerankers.ts:

- RagApiReranker extends BaseReranker, calling POST {baseUrl}/v1/rerank
  with { profile, query, candidates: [{id, text, base_score}], top_n } and
  parsing { profile, model, results: [{id, index, score}] }.
- Auth via an async token supplier (short-lived JWTs minted per call by the
  host app) instead of a static API key.
- Configurable timeout; on timeout, non-2xx, malformed response, or a
  rejected token supplier, falls back to the candidates' original order
  (BaseReranker.getDefaultRanking) rather than throwing into the search
  flow. Successful responses are sorted deterministically (score desc,
  index asc tiebreak) rather than trusting response order.
- Client-side enforcement of the contract limits (<=50 candidates, top_n
  <=25) via truncation + a debug log, never an error.
- Wired into RerankerType ('rag-api'), createReranker, and
  SearchToolConfig/createSearchTool alongside the existing jina/cohere
  fields (ragApiUrl, ragApiTokenSupplier, ragApiProfile).

Tests mock the axios HTTP boundary per project convention and cover
success, timeout fallback, error fallback, malformed-response fallback,
tie ordering, and candidate/top_n truncation.

* fix(search): harden RagApiReranker bounds, validation, and URL handling

- Bound the whole rerank operation (token acquisition + request) with the
  configured timeout; a stalled token supplier previously ran before axios
  started, so the search could hang indefinitely. The deadline aborts any
  in-flight request and falls back to the original candidate order.
- Validate every result row against the candidates actually submitted rather
  than the full document list, and reject the entire batch when any row is
  invalid, instead of silently accepting partially malformed responses.
- Strip trailing slashes from the base URL before appending `/v1/rerank`,
  matching the other base-URL-based search clients.
- Cap documents before building candidates so each call only allocates the
  bounded work it can submit.

* fix(search): cancel rag_api token acquisition and reject duplicate indices

- Hand the rerank deadline's `AbortSignal` to the token supplier so a supplier
  that mints its token over the network can cancel that request when the
  deadline fires, instead of leaving auth requests and sockets running past
  their caller. The signal is an optional argument, so existing zero-argument
  suppliers keep working unchanged.
- Reject the whole batch when a result index repeats: duplicates previously
  passed validation and mapped one document into several `top_n` slots,
  silently omitting distinct results. Seen indices are tracked in the same
  pass that validates each row.
* feat: resolve selected subagent inputs lazily

* fix: harden lazy subagent resume errors

* fix: harden lazy subagent execution

* fix: harden lazy subagent replay and concurrency

* fix: harden lazy subagent lifecycle

* fix: close lazy subagent replay races

* fix: bind subagent replay to effective type

* refactor: centralize durable subagent executions

* fix: harden durable subagent execution lifecycle
@pull pull Bot locked and limited conversation to collaborators Aug 7, 2026
@pull pull Bot added the ⤵️ pull label Aug 7, 2026
@pull
pull Bot merged commit 5289285 into innFactory:main Aug 7, 2026
1 check passed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant