searchSpecSections.ts and consumer - mention vector search

This commit is contained in:
2026-04-09 09:54:28 +05:30
parent 26509680ea
commit 3c4893c320
2 changed files with 2 additions and 2 deletions
@@ -10,7 +10,7 @@ import { createSearchSpecSectionsTool } from "../../src/agent-tools";
export default tool({ export default tool({
description: description:
"Searches the ECMAScript specification for sections relevant to a query. " + "Vector search the ECMAScript specification for sections relevant to a query. " +
"Returns JSON array with sectionId, sectionTitle, score, partIndex, totalParts, and content. " + "Returns JSON array with sectionId, sectionTitle, score, partIndex, totalParts, and content. " +
"Use this when you need to find spec sections related to a JavaScript topic or question.", "Use this when you need to find spec sections related to a JavaScript topic or question.",
args: { args: {
+1 -1
View File
@@ -27,7 +27,7 @@ export function createSearchSpecSectionsTool(
return new DynamicStructuredTool({ return new DynamicStructuredTool({
name: "ask262_search_spec_sections", name: "ask262_search_spec_sections",
description: description:
"Searches the ECMAScript specification for sections relevant to a query. Returns JSON array with sectionId, sectionTitle, score, partIndex, totalParts, and content. partIndex and totalParts indicate which chunk of a multi-part section this is (0-indexed, partIndex+1/totalParts), null if single-part.", "Vector search the ECMAScript specification for sections relevant to a query. Returns JSON array with sectionId, sectionTitle, score, partIndex, totalParts, and content. partIndex and totalParts indicate which chunk of a multi-part section this is (0-indexed, partIndex+1/totalParts), null if single-part.",
schema: searchSpecSchema, schema: searchSpecSchema,
func: async ({ query }) => { func: async ({ query }) => {
// Generate embedding for the query // Generate embedding for the query