createVectorRetrievalTool
function createVectorRetrievalTool(options): Tool<{ query: string; topK?: number;}, VectorRetrievalToolOutput>;Creates a retrieval tool that can be added to any Kuralle agent.
The tool wraps any Retriever implementation, allowing the LLM to
decide when to search for relevant knowledge. Uses the Vercel AI SDK
tool() directly.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
|
|
Returns
Section titled “Returns”Tool<{
query: string;
topK?: number;
}, VectorRetrievalToolOutput>