mirror of
https://github.com/run-llama/semtools.git
synced 2026-07-21 19:25:23 -04:00
Feature (optional): store context hydration helper #8
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @lwyBZss8924d on GitHub (Sep 18, 2025).
Summary
Provide a helper API to hydrate context lines for ranked results, simplifying CLI/orchestrator code that needs to render snippets.
Motivation
n_linescontext around a matched line.Proposed API (Rust)
Notes
searchCLI could reuse it when--output jsonto include thelinesfield consistently for workspace-backed results.Acceptance criteria
@lwyBZss8924d commented on GitHub (Sep 18, 2025):
Intent: standardize snippet packaging for citations and verification in agentic flows.
Why a context hydration helper matters:
Scope
Outcome
@lwyBZss8924d commented on GitHub (Sep 18, 2025):
Reference: OpenAI Model Selection Guide — Long-Context Agentic RAG
Why a context hydration helper aligns with the Cookbook approach:
Agent example (excerpt) that consumes such snippets:
A small helper in Store makes the evidence step straightforward and consistent across the ecosystem.
@logan-markewich commented on GitHub (Sep 18, 2025):
I'm not sure I totally understand the proposal here
The
--n-linesparam already provides the lines around the match hit. Is there something more that can be done here? Any example of usage/output would help!