@morphllm/morphsdk 0.2.126 → 0.2.127

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (158) hide show
  1. package/dist/{chunk-GISRJI5P.js → chunk-3ZA7Y66U.js} +2 -2
  2. package/dist/{chunk-AXYGFPEJ.js → chunk-6DRIR7AI.js} +5 -4
  3. package/dist/chunk-6DRIR7AI.js.map +1 -0
  4. package/dist/{chunk-ULZOJQ2W.js → chunk-ADHGSV2D.js} +2 -2
  5. package/dist/{chunk-37ZZ24IX.js → chunk-DS7YL4V3.js} +8 -4
  6. package/dist/{chunk-37ZZ24IX.js.map → chunk-DS7YL4V3.js.map} +1 -1
  7. package/dist/{chunk-IYZX6EYC.js → chunk-EGOCFCAH.js} +2 -2
  8. package/dist/{chunk-C26M3TWM.js → chunk-EL6CCK7C.js} +2 -2
  9. package/dist/{chunk-EB656RG6.js → chunk-GDCVK6SP.js} +2 -2
  10. package/dist/{chunk-5CIUBER5.js → chunk-GVF4Q75N.js} +2 -2
  11. package/dist/{chunk-CPZKCBED.js → chunk-GWKCMFD6.js} +2 -2
  12. package/dist/{chunk-VYJUGQUR.js → chunk-HZK5TEUK.js} +1 -1
  13. package/dist/{chunk-6Y2LHEJJ.js → chunk-K6YSD3DR.js} +2 -2
  14. package/dist/{chunk-R74NP2D4.js → chunk-LX34ZO3N.js} +2 -2
  15. package/dist/{chunk-W7WUZMKZ.js → chunk-LXBIP5FI.js} +2 -2
  16. package/dist/{chunk-K6GLBQBV.js → chunk-MJHAVXFK.js} +2 -2
  17. package/dist/{chunk-FAH4YGRN.js → chunk-NQQS5BZZ.js} +3 -3
  18. package/dist/{chunk-KJVFYRXY.js → chunk-QOE522DB.js} +15 -15
  19. package/dist/{chunk-QK5RNORE.js → chunk-QUULFOWB.js} +10 -5
  20. package/dist/{chunk-QK5RNORE.js.map → chunk-QUULFOWB.js.map} +1 -1
  21. package/dist/{chunk-CYVV5X5K.js → chunk-R5IFI552.js} +2 -2
  22. package/dist/{chunk-CYVV5X5K.js.map → chunk-R5IFI552.js.map} +1 -1
  23. package/dist/{chunk-76PPJZWV.js → chunk-REJNS3OW.js} +8 -4
  24. package/dist/{chunk-76PPJZWV.js.map → chunk-REJNS3OW.js.map} +1 -1
  25. package/dist/{chunk-6722FXFI.js → chunk-U73OIAJC.js} +2 -2
  26. package/dist/{chunk-3NLCSADX.js → chunk-UAQ7UWZB.js} +2 -2
  27. package/dist/{chunk-KUABSLVR.js → chunk-YTUQEDWH.js} +2 -2
  28. package/dist/{chunk-TREVNTLA.js → chunk-ZVAXTR2V.js} +2 -2
  29. package/dist/{chunk-YHZRHPJI.js → chunk-ZYD2SEQK.js} +2 -2
  30. package/dist/{client-s3_iDem0.d.ts → client-CNYzlN_6.d.ts} +6 -3
  31. package/dist/client.cjs +22 -8
  32. package/dist/client.cjs.map +1 -1
  33. package/dist/client.d.ts +1 -1
  34. package/dist/client.js +21 -21
  35. package/dist/edge.cjs +1 -1
  36. package/dist/edge.cjs.map +1 -1
  37. package/dist/edge.js +4 -4
  38. package/dist/index.cjs +22 -8
  39. package/dist/index.cjs.map +1 -1
  40. package/dist/index.d.ts +1 -1
  41. package/dist/index.js +21 -21
  42. package/dist/modelrouter/core.cjs +1 -1
  43. package/dist/modelrouter/core.cjs.map +1 -1
  44. package/dist/modelrouter/core.js +3 -3
  45. package/dist/modelrouter/index.cjs +1 -1
  46. package/dist/modelrouter/index.cjs.map +1 -1
  47. package/dist/modelrouter/index.js +3 -3
  48. package/dist/tools/browser/anthropic.cjs +1 -1
  49. package/dist/tools/browser/anthropic.cjs.map +1 -1
  50. package/dist/tools/browser/anthropic.js +5 -5
  51. package/dist/tools/browser/core.cjs +1 -1
  52. package/dist/tools/browser/core.cjs.map +1 -1
  53. package/dist/tools/browser/core.js +4 -4
  54. package/dist/tools/browser/index.cjs +1 -1
  55. package/dist/tools/browser/index.cjs.map +1 -1
  56. package/dist/tools/browser/index.js +7 -7
  57. package/dist/tools/browser/openai.cjs +1 -1
  58. package/dist/tools/browser/openai.cjs.map +1 -1
  59. package/dist/tools/browser/openai.js +5 -5
  60. package/dist/tools/browser/profiles/core.cjs +1 -1
  61. package/dist/tools/browser/profiles/core.cjs.map +1 -1
  62. package/dist/tools/browser/profiles/core.js +3 -3
  63. package/dist/tools/browser/profiles/index.cjs +1 -1
  64. package/dist/tools/browser/profiles/index.cjs.map +1 -1
  65. package/dist/tools/browser/profiles/index.js +3 -3
  66. package/dist/tools/browser/vercel.cjs +1 -1
  67. package/dist/tools/browser/vercel.cjs.map +1 -1
  68. package/dist/tools/browser/vercel.js +5 -5
  69. package/dist/tools/codebase_search/anthropic.cjs +1 -1
  70. package/dist/tools/codebase_search/anthropic.cjs.map +1 -1
  71. package/dist/tools/codebase_search/anthropic.js +4 -4
  72. package/dist/tools/codebase_search/core.cjs +1 -1
  73. package/dist/tools/codebase_search/core.cjs.map +1 -1
  74. package/dist/tools/codebase_search/core.js +3 -3
  75. package/dist/tools/codebase_search/index.cjs +1 -1
  76. package/dist/tools/codebase_search/index.cjs.map +1 -1
  77. package/dist/tools/codebase_search/index.js +6 -6
  78. package/dist/tools/codebase_search/openai.cjs +1 -1
  79. package/dist/tools/codebase_search/openai.cjs.map +1 -1
  80. package/dist/tools/codebase_search/openai.js +4 -4
  81. package/dist/tools/codebase_search/vercel.cjs +1 -1
  82. package/dist/tools/codebase_search/vercel.cjs.map +1 -1
  83. package/dist/tools/codebase_search/vercel.js +4 -4
  84. package/dist/tools/fastapply/anthropic.cjs +1 -1
  85. package/dist/tools/fastapply/anthropic.cjs.map +1 -1
  86. package/dist/tools/fastapply/anthropic.js +4 -4
  87. package/dist/tools/fastapply/apply.cjs +1 -1
  88. package/dist/tools/fastapply/apply.cjs.map +1 -1
  89. package/dist/tools/fastapply/apply.js +2 -2
  90. package/dist/tools/fastapply/core.cjs +1 -1
  91. package/dist/tools/fastapply/core.cjs.map +1 -1
  92. package/dist/tools/fastapply/core.js +3 -3
  93. package/dist/tools/fastapply/index.cjs +1 -1
  94. package/dist/tools/fastapply/index.cjs.map +1 -1
  95. package/dist/tools/fastapply/index.js +6 -6
  96. package/dist/tools/fastapply/openai.cjs +1 -1
  97. package/dist/tools/fastapply/openai.cjs.map +1 -1
  98. package/dist/tools/fastapply/openai.js +4 -4
  99. package/dist/tools/fastapply/vercel.cjs +1 -1
  100. package/dist/tools/fastapply/vercel.cjs.map +1 -1
  101. package/dist/tools/fastapply/vercel.js +4 -4
  102. package/dist/tools/index.cjs +1 -1
  103. package/dist/tools/index.cjs.map +1 -1
  104. package/dist/tools/index.js +6 -6
  105. package/dist/tools/utils/resilience.cjs +1 -1
  106. package/dist/tools/utils/resilience.cjs.map +1 -1
  107. package/dist/tools/utils/resilience.js +2 -2
  108. package/dist/tools/warp_grep/agent/runner.cjs +1 -1
  109. package/dist/tools/warp_grep/agent/runner.cjs.map +1 -1
  110. package/dist/tools/warp_grep/agent/runner.js +2 -2
  111. package/dist/tools/warp_grep/anthropic.cjs +10 -5
  112. package/dist/tools/warp_grep/anthropic.cjs.map +1 -1
  113. package/dist/tools/warp_grep/anthropic.d.ts +2 -1
  114. package/dist/tools/warp_grep/anthropic.js +5 -5
  115. package/dist/tools/warp_grep/client.cjs +1 -1
  116. package/dist/tools/warp_grep/client.cjs.map +1 -1
  117. package/dist/tools/warp_grep/client.js +3 -3
  118. package/dist/tools/warp_grep/gemini.cjs +10 -5
  119. package/dist/tools/warp_grep/gemini.cjs.map +1 -1
  120. package/dist/tools/warp_grep/gemini.d.ts +2 -1
  121. package/dist/tools/warp_grep/gemini.js +12 -7
  122. package/dist/tools/warp_grep/gemini.js.map +1 -1
  123. package/dist/tools/warp_grep/index.cjs +5 -4
  124. package/dist/tools/warp_grep/index.cjs.map +1 -1
  125. package/dist/tools/warp_grep/index.d.ts +6 -2
  126. package/dist/tools/warp_grep/index.js +4 -4
  127. package/dist/tools/warp_grep/openai.cjs +10 -5
  128. package/dist/tools/warp_grep/openai.cjs.map +1 -1
  129. package/dist/tools/warp_grep/openai.d.ts +2 -1
  130. package/dist/tools/warp_grep/openai.js +5 -5
  131. package/dist/tools/warp_grep/vercel.cjs +9 -4
  132. package/dist/tools/warp_grep/vercel.cjs.map +1 -1
  133. package/dist/tools/warp_grep/vercel.d.ts +2 -1
  134. package/dist/tools/warp_grep/vercel.js +5 -5
  135. package/dist/version.cjs +1 -1
  136. package/dist/version.cjs.map +1 -1
  137. package/dist/version.js +1 -1
  138. package/package.json +1 -1
  139. package/dist/chunk-AXYGFPEJ.js.map +0 -1
  140. /package/dist/{chunk-GISRJI5P.js.map → chunk-3ZA7Y66U.js.map} +0 -0
  141. /package/dist/{chunk-ULZOJQ2W.js.map → chunk-ADHGSV2D.js.map} +0 -0
  142. /package/dist/{chunk-IYZX6EYC.js.map → chunk-EGOCFCAH.js.map} +0 -0
  143. /package/dist/{chunk-C26M3TWM.js.map → chunk-EL6CCK7C.js.map} +0 -0
  144. /package/dist/{chunk-EB656RG6.js.map → chunk-GDCVK6SP.js.map} +0 -0
  145. /package/dist/{chunk-5CIUBER5.js.map → chunk-GVF4Q75N.js.map} +0 -0
  146. /package/dist/{chunk-CPZKCBED.js.map → chunk-GWKCMFD6.js.map} +0 -0
  147. /package/dist/{chunk-VYJUGQUR.js.map → chunk-HZK5TEUK.js.map} +0 -0
  148. /package/dist/{chunk-6Y2LHEJJ.js.map → chunk-K6YSD3DR.js.map} +0 -0
  149. /package/dist/{chunk-R74NP2D4.js.map → chunk-LX34ZO3N.js.map} +0 -0
  150. /package/dist/{chunk-W7WUZMKZ.js.map → chunk-LXBIP5FI.js.map} +0 -0
  151. /package/dist/{chunk-K6GLBQBV.js.map → chunk-MJHAVXFK.js.map} +0 -0
  152. /package/dist/{chunk-FAH4YGRN.js.map → chunk-NQQS5BZZ.js.map} +0 -0
  153. /package/dist/{chunk-KJVFYRXY.js.map → chunk-QOE522DB.js.map} +0 -0
  154. /package/dist/{chunk-6722FXFI.js.map → chunk-U73OIAJC.js.map} +0 -0
  155. /package/dist/{chunk-3NLCSADX.js.map → chunk-UAQ7UWZB.js.map} +0 -0
  156. /package/dist/{chunk-KUABSLVR.js.map → chunk-YTUQEDWH.js.map} +0 -0
  157. /package/dist/{chunk-TREVNTLA.js.map → chunk-ZVAXTR2V.js.map} +0 -0
  158. /package/dist/{chunk-YHZRHPJI.js.map → chunk-ZYD2SEQK.js.map} +0 -0
@@ -135,7 +135,8 @@ declare const createMorphWarpGrepTool: typeof createWarpGrepTool;
135
135
  declare function createGitHubSearchTool(config: GitHubSearchToolConfig): FunctionDeclaration & {
136
136
  execute: (input: {
137
137
  query: string;
138
- github: string;
138
+ github_url?: string;
139
+ owner_repo?: string;
139
140
  branch?: string;
140
141
  }) => Promise<WarpGrepResult>;
141
142
  formatResult: (result: WarpGrepResult) => string;
@@ -5,23 +5,23 @@ import {
5
5
  GITHUB_SEARCH_TOOL_NAME,
6
6
  WARP_GREP_DESCRIPTION,
7
7
  WARP_GREP_TOOL_NAME
8
- } from "../../chunk-AXYGFPEJ.js";
8
+ } from "../../chunk-6DRIR7AI.js";
9
9
  import {
10
10
  WarpGrepClient,
11
11
  executeGitHubReadFile,
12
12
  executeToolCall,
13
13
  formatGitHubReadFileResult,
14
14
  formatResult
15
- } from "../../chunk-C26M3TWM.js";
15
+ } from "../../chunk-EL6CCK7C.js";
16
16
  import "../../chunk-NF2QWJDY.js";
17
17
  import "../../chunk-63VHBANJ.js";
18
- import "../../chunk-W7WUZMKZ.js";
18
+ import "../../chunk-LXBIP5FI.js";
19
19
  import "../../chunk-GVGJIXV2.js";
20
20
  import "../../chunk-K2FXHDX2.js";
21
21
  import "../../chunk-DKODF3YG.js";
22
22
  import "../../chunk-QRXG5CAZ.js";
23
23
  import "../../chunk-VCKJ22DX.js";
24
- import "../../chunk-CYVV5X5K.js";
24
+ import "../../chunk-R5IFI552.js";
25
25
  import "../../chunk-PZ5AY32C.js";
26
26
 
27
27
  // tools/warp_grep/gemini.ts
@@ -63,10 +63,11 @@ var GITHUB_SEARCH_PARAMETERS = {
63
63
  type: "OBJECT",
64
64
  properties: {
65
65
  query: { type: "STRING", description: "Natural language search query" },
66
- github: { type: "STRING", description: 'GitHub URL or "owner/repo" shorthand' },
66
+ github_url: { type: "STRING", description: 'GitHub repository URL to search (e.g. "https://github.com/vercel/next.js"). You must provide either github_url or owner_repo.' },
67
+ owner_repo: { type: "STRING", description: 'Repository owner/repo shorthand (e.g. "vercel/next.js"). You must provide either github_url or owner_repo.' },
67
68
  branch: { type: "STRING", description: "Branch to search (defaults to repo default branch)" }
68
69
  },
69
- required: ["query", "github"]
70
+ required: ["query"]
70
71
  };
71
72
  function createGitHubSearchTool(config) {
72
73
  const client = new WarpGrepClient(config);
@@ -77,7 +78,11 @@ function createGitHubSearchTool(config) {
77
78
  };
78
79
  return Object.assign(declaration, {
79
80
  execute: async (input) => {
80
- return client.searchGitHub(input);
81
+ const github = input.github_url || input.owner_repo;
82
+ if (!github) {
83
+ throw new Error("Please provide github search url or owner/repo id");
84
+ }
85
+ return client.searchGitHub({ query: input.query, github, branch: input.branch });
81
86
  },
82
87
  formatResult: (result) => {
83
88
  return formatResult(result);
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../tools/warp_grep/gemini.ts"],"sourcesContent":["/**\n * Google Gemini SDK adapter for morph-warp-grep tool\n * \n * Requires @google/generative-ai as a peer dependency.\n * Install with: npm install @google/generative-ai\n */\n\nimport type { FunctionDeclaration, FunctionDeclarationSchema } from '@google/generative-ai';\nimport { executeToolCall, formatResult, WarpGrepClient, executeGitHubReadFile, formatGitHubReadFileResult } from './client.js';\nimport { WARP_GREP_DESCRIPTION, WARP_GREP_TOOL_NAME, GITHUB_SEARCH_TOOL_NAME, GITHUB_SEARCH_DESCRIPTION, GITHUB_READ_FILE_TOOL_NAME, GITHUB_READ_FILE_DESCRIPTION, GITHUB_READ_FILE_INPUT_SCHEMA } from './prompts.js';\nimport type { WarpGrepToolConfig, WarpGrepResult, GitHubSearchToolConfig, GitHubReadFileInput, GitHubReadFileResult, GitHubReadFileToolConfig } from './types.js';\n\n// Use plain object to avoid runtime import of SchemaType enum\nconst TOOL_PARAMETERS = {\n type: 'OBJECT',\n properties: {\n query: { \n type: 'STRING', \n description: 'Free-form repository question' \n },\n },\n required: ['query'],\n} as unknown as FunctionDeclarationSchema;\n\n/**\n * Gemini-native warp grep function declaration\n * \n * @example\n * ```typescript\n * import { GoogleGenerativeAI } from '@google/generative-ai';\n * import { warpGrepFunctionDeclaration, execute } from '@morphllm/morphsdk/tools/warp-grep/gemini';\n * \n * const genAI = new GoogleGenerativeAI(process.env.GOOGLE_API_KEY);\n * const model = genAI.getGenerativeModel({\n * model: 'gemini-2.0-flash',\n * tools: [{ functionDeclarations: [warpGrepFunctionDeclaration] }]\n * });\n * \n * const chat = model.startChat();\n * const result = await chat.sendMessage('Find authentication middleware');\n * \n * // Handle function call\n * const call = result.response.functionCalls()?.[0];\n * if (call) {\n * const searchResult = await execute(call.args, { repoRoot: '.' });\n * console.log(searchResult);\n * }\n * ```\n */\nexport const warpGrepFunctionDeclaration: FunctionDeclaration = {\n name: WARP_GREP_TOOL_NAME,\n description: WARP_GREP_DESCRIPTION,\n parameters: TOOL_PARAMETERS,\n};\n\n/**\n * Execute warp grep search\n * \n * @param input - Tool input with query\n * @param config - Configuration with repoRoot and optional provider\n * @returns Search results\n */\nexport async function execute(\n input: { query: string } | string,\n config: WarpGrepToolConfig\n): Promise<WarpGrepResult> {\n return executeToolCall(input, config);\n}\n\nexport { formatResult };\n\n/**\n * Gemini tool with execute method attached\n */\nexport interface GeminiWarpGrepTool extends FunctionDeclaration {\n execute: (input: unknown) => Promise<WarpGrepResult>;\n formatResult: (result: WarpGrepResult) => string;\n}\n\n/**\n * Create a custom warp grep tool with configuration and methods\n * \n * @param config - Configuration options\n * @returns Function declaration with execute and formatResult methods\n * \n * @example Local usage\n * ```typescript\n * import { GoogleGenerativeAI } from '@google/generative-ai';\n * import { createMorphWarpGrepTool } from '@morphllm/morphsdk/tools/warp-grep/gemini';\n * \n * const tool = createMorphWarpGrepTool({ repoRoot: '.' });\n * \n * const genAI = new GoogleGenerativeAI(process.env.GOOGLE_API_KEY);\n * const model = genAI.getGenerativeModel({\n * model: 'gemini-2.0-flash',\n * tools: [{ functionDeclarations: [tool] }]\n * });\n * \n * const chat = model.startChat();\n * const result = await chat.sendMessage('Find authentication middleware');\n * \n * // Handle function call\n * const call = result.response.functionCalls()?.[0];\n * if (call && call.name === tool.name) {\n * const searchResult = await tool.execute(call.args);\n * console.log(tool.formatResult(searchResult));\n * \n * // Send result back to model\n * await chat.sendMessage([{\n * functionResponse: {\n * name: call.name,\n * response: { result: tool.formatResult(searchResult) }\n * }\n * }]);\n * }\n * ```\n * \n * @example Remote sandbox (E2B, Modal, etc.)\n * ```typescript\n * const tool = createMorphWarpGrepTool({\n * repoRoot: '/home/repo',\n * remoteCommands: {\n * grep: async (pattern, path) => (await sandbox.run(`rg '${pattern}' '${path}'`)).stdout,\n * read: async (path, start, end) => (await sandbox.run(`sed -n '${start},${end}p' '${path}'`)).stdout,\n * listDir: async (path, maxDepth) => (await sandbox.run(`find '${path}' -maxdepth ${maxDepth}`)).stdout,\n * },\n * });\n * ```\n */\nexport function createWarpGrepTool(config: WarpGrepToolConfig): GeminiWarpGrepTool {\n const declaration: FunctionDeclaration = {\n name: config.name ?? WARP_GREP_TOOL_NAME,\n description: config.description ?? WARP_GREP_DESCRIPTION,\n parameters: TOOL_PARAMETERS,\n };\n\n return Object.assign(declaration, {\n execute: async (input: unknown): Promise<WarpGrepResult> => {\n return executeToolCall(input as { query: string } | string, config);\n },\n formatResult: (result: WarpGrepResult): string => {\n return formatResult(result);\n },\n });\n}\n\n// Legacy alias for backwards compatibility\nexport const createMorphWarpGrepTool = createWarpGrepTool;\n\nconst GITHUB_SEARCH_PARAMETERS = {\n type: 'OBJECT',\n properties: {\n query: { type: 'STRING', description: 'Natural language search query' },\n github: { type: 'STRING', description: 'GitHub URL or \"owner/repo\" shorthand' },\n branch: { type: 'STRING', description: 'Branch to search (defaults to repo default branch)' },\n },\n required: ['query', 'github'],\n} as unknown as FunctionDeclarationSchema;\n\n/**\n * Create a GitHub search tool for Google Gemini SDK\n *\n * @param config - Configuration options (morphApiKey, morphApiUrl, codeSearchUrl, timeout)\n * @returns Gemini FunctionDeclaration with execute and formatResult methods\n *\n * @example\n * ```typescript\n * import { GoogleGenerativeAI } from '@google/generative-ai';\n * import { createGitHubSearchTool } from '@morphllm/morphsdk/tools/warp-grep/gemini';\n *\n * const tool = createGitHubSearchTool({ morphApiKey: process.env.MORPH_API_KEY });\n *\n * const genAI = new GoogleGenerativeAI(process.env.GOOGLE_API_KEY);\n * const model = genAI.getGenerativeModel({\n * model: 'gemini-2.0-flash',\n * tools: [{ functionDeclarations: [tool] }]\n * });\n *\n * // Execute\n * const result = await tool.execute({ query: 'auth middleware', github: 'vercel/next.js' });\n * console.log(tool.formatResult(result));\n * ```\n */\nexport function createGitHubSearchTool(config: GitHubSearchToolConfig) {\n const client = new WarpGrepClient(config);\n\n const declaration: FunctionDeclaration = {\n name: GITHUB_SEARCH_TOOL_NAME,\n description: GITHUB_SEARCH_DESCRIPTION,\n parameters: GITHUB_SEARCH_PARAMETERS,\n };\n\n return Object.assign(declaration, {\n execute: async (input: { query: string; github: string; branch?: string }): Promise<WarpGrepResult> => {\n return client.searchGitHub(input);\n },\n formatResult: (result: WarpGrepResult): string => {\n return formatResult(result);\n },\n });\n}\n\nconst GITHUB_READ_FILE_PARAMETERS = {\n type: 'OBJECT',\n properties: {\n github: { type: 'STRING', description: 'owner/repo shorthand (e.g., \"vercel/next.js\")' },\n path: { type: 'STRING', description: 'File path within the repository' },\n startLine: { type: 'NUMBER', description: 'Start line number (1-based)' },\n endLine: { type: 'NUMBER', description: 'End line number (1-based, inclusive)' },\n branch: { type: 'STRING', description: 'Branch to read from (defaults to repo default branch)' },\n },\n required: ['github', 'path'],\n} as unknown as FunctionDeclarationSchema;\n\n/**\n * Create a GitHub read file tool for Google Gemini SDK\n *\n * @param config - Optional configuration (timeout)\n * @returns Gemini FunctionDeclaration with execute and formatResult methods\n *\n * @example\n * ```typescript\n * import { GoogleGenerativeAI } from '@google/generative-ai';\n * import { createGitHubReadFileTool } from '@morphllm/morphsdk/tools/warp-grep/gemini';\n *\n * const tool = createGitHubReadFileTool();\n *\n * const genAI = new GoogleGenerativeAI(process.env.GOOGLE_API_KEY);\n * const model = genAI.getGenerativeModel({\n * model: 'gemini-2.0-flash',\n * tools: [{ functionDeclarations: [tool] }]\n * });\n *\n * const result = await tool.execute({ github: 'vercel/next.js', path: 'package.json' });\n * console.log(tool.formatResult(result));\n * ```\n */\nexport function createGitHubReadFileTool(config?: GitHubReadFileToolConfig) {\n const declaration: FunctionDeclaration = {\n name: GITHUB_READ_FILE_TOOL_NAME,\n description: GITHUB_READ_FILE_DESCRIPTION,\n parameters: GITHUB_READ_FILE_PARAMETERS,\n };\n\n return Object.assign(declaration, {\n execute: async (input: GitHubReadFileInput): Promise<GitHubReadFileResult> => {\n return executeGitHubReadFile(input, config);\n },\n formatResult: (result: GitHubReadFileResult): string => {\n return formatGitHubReadFileResult(result);\n },\n });\n}\n\nexport default warpGrepFunctionDeclaration;\n\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAaA,IAAM,kBAAkB;AAAA,EACtB,MAAM;AAAA,EACN,YAAY;AAAA,IACV,OAAO;AAAA,MACL,MAAM;AAAA,MACN,aAAa;AAAA,IACf;AAAA,EACF;AAAA,EACA,UAAU,CAAC,OAAO;AACpB;AA2BO,IAAM,8BAAmD;AAAA,EAC9D,MAAM;AAAA,EACN,aAAa;AAAA,EACb,YAAY;AACd;AASA,eAAsB,QACpB,OACA,QACyB;AACzB,SAAO,gBAAgB,OAAO,MAAM;AACtC;AA8DO,SAAS,mBAAmB,QAAgD;AACjF,QAAM,cAAmC;AAAA,IACvC,MAAM,OAAO,QAAQ;AAAA,IACrB,aAAa,OAAO,eAAe;AAAA,IACnC,YAAY;AAAA,EACd;AAEA,SAAO,OAAO,OAAO,aAAa;AAAA,IAChC,SAAS,OAAO,UAA4C;AAC1D,aAAO,gBAAgB,OAAqC,MAAM;AAAA,IACpE;AAAA,IACA,cAAc,CAAC,WAAmC;AAChD,aAAO,aAAa,MAAM;AAAA,IAC5B;AAAA,EACF,CAAC;AACH;AAGO,IAAM,0BAA0B;AAEvC,IAAM,2BAA2B;AAAA,EAC/B,MAAM;AAAA,EACN,YAAY;AAAA,IACV,OAAO,EAAE,MAAM,UAAU,aAAa,gCAAgC;AAAA,IACtE,QAAQ,EAAE,MAAM,UAAU,aAAa,uCAAuC;AAAA,IAC9E,QAAQ,EAAE,MAAM,UAAU,aAAa,qDAAqD;AAAA,EAC9F;AAAA,EACA,UAAU,CAAC,SAAS,QAAQ;AAC9B;AA0BO,SAAS,uBAAuB,QAAgC;AACrE,QAAM,SAAS,IAAI,eAAe,MAAM;AAExC,QAAM,cAAmC;AAAA,IACvC,MAAM;AAAA,IACN,aAAa;AAAA,IACb,YAAY;AAAA,EACd;AAEA,SAAO,OAAO,OAAO,aAAa;AAAA,IAChC,SAAS,OAAO,UAAuF;AACrG,aAAO,OAAO,aAAa,KAAK;AAAA,IAClC;AAAA,IACA,cAAc,CAAC,WAAmC;AAChD,aAAO,aAAa,MAAM;AAAA,IAC5B;AAAA,EACF,CAAC;AACH;AAEA,IAAM,8BAA8B;AAAA,EAClC,MAAM;AAAA,EACN,YAAY;AAAA,IACV,QAAQ,EAAE,MAAM,UAAU,aAAa,gDAAgD;AAAA,IACvF,MAAM,EAAE,MAAM,UAAU,aAAa,kCAAkC;AAAA,IACvE,WAAW,EAAE,MAAM,UAAU,aAAa,8BAA8B;AAAA,IACxE,SAAS,EAAE,MAAM,UAAU,aAAa,uCAAuC;AAAA,IAC/E,QAAQ,EAAE,MAAM,UAAU,aAAa,wDAAwD;AAAA,EACjG;AAAA,EACA,UAAU,CAAC,UAAU,MAAM;AAC7B;AAyBO,SAAS,yBAAyB,QAAmC;AAC1E,QAAM,cAAmC;AAAA,IACvC,MAAM;AAAA,IACN,aAAa;AAAA,IACb,YAAY;AAAA,EACd;AAEA,SAAO,OAAO,OAAO,aAAa;AAAA,IAChC,SAAS,OAAO,UAA8D;AAC5E,aAAO,sBAAsB,OAAO,MAAM;AAAA,IAC5C;AAAA,IACA,cAAc,CAAC,WAAyC;AACtD,aAAO,2BAA2B,MAAM;AAAA,IAC1C;AAAA,EACF,CAAC;AACH;AAEA,IAAO,iBAAQ;","names":[]}
1
+ {"version":3,"sources":["../../../tools/warp_grep/gemini.ts"],"sourcesContent":["/**\n * Google Gemini SDK adapter for morph-warp-grep tool\n * \n * Requires @google/generative-ai as a peer dependency.\n * Install with: npm install @google/generative-ai\n */\n\nimport type { FunctionDeclaration, FunctionDeclarationSchema } from '@google/generative-ai';\nimport { executeToolCall, formatResult, WarpGrepClient, executeGitHubReadFile, formatGitHubReadFileResult } from './client.js';\nimport { WARP_GREP_DESCRIPTION, WARP_GREP_TOOL_NAME, GITHUB_SEARCH_TOOL_NAME, GITHUB_SEARCH_DESCRIPTION, GITHUB_READ_FILE_TOOL_NAME, GITHUB_READ_FILE_DESCRIPTION, GITHUB_READ_FILE_INPUT_SCHEMA } from './prompts.js';\nimport type { WarpGrepToolConfig, WarpGrepResult, GitHubSearchToolConfig, GitHubReadFileInput, GitHubReadFileResult, GitHubReadFileToolConfig } from './types.js';\n\n// Use plain object to avoid runtime import of SchemaType enum\nconst TOOL_PARAMETERS = {\n type: 'OBJECT',\n properties: {\n query: { \n type: 'STRING', \n description: 'Free-form repository question' \n },\n },\n required: ['query'],\n} as unknown as FunctionDeclarationSchema;\n\n/**\n * Gemini-native warp grep function declaration\n * \n * @example\n * ```typescript\n * import { GoogleGenerativeAI } from '@google/generative-ai';\n * import { warpGrepFunctionDeclaration, execute } from '@morphllm/morphsdk/tools/warp-grep/gemini';\n * \n * const genAI = new GoogleGenerativeAI(process.env.GOOGLE_API_KEY);\n * const model = genAI.getGenerativeModel({\n * model: 'gemini-2.0-flash',\n * tools: [{ functionDeclarations: [warpGrepFunctionDeclaration] }]\n * });\n * \n * const chat = model.startChat();\n * const result = await chat.sendMessage('Find authentication middleware');\n * \n * // Handle function call\n * const call = result.response.functionCalls()?.[0];\n * if (call) {\n * const searchResult = await execute(call.args, { repoRoot: '.' });\n * console.log(searchResult);\n * }\n * ```\n */\nexport const warpGrepFunctionDeclaration: FunctionDeclaration = {\n name: WARP_GREP_TOOL_NAME,\n description: WARP_GREP_DESCRIPTION,\n parameters: TOOL_PARAMETERS,\n};\n\n/**\n * Execute warp grep search\n * \n * @param input - Tool input with query\n * @param config - Configuration with repoRoot and optional provider\n * @returns Search results\n */\nexport async function execute(\n input: { query: string } | string,\n config: WarpGrepToolConfig\n): Promise<WarpGrepResult> {\n return executeToolCall(input, config);\n}\n\nexport { formatResult };\n\n/**\n * Gemini tool with execute method attached\n */\nexport interface GeminiWarpGrepTool extends FunctionDeclaration {\n execute: (input: unknown) => Promise<WarpGrepResult>;\n formatResult: (result: WarpGrepResult) => string;\n}\n\n/**\n * Create a custom warp grep tool with configuration and methods\n * \n * @param config - Configuration options\n * @returns Function declaration with execute and formatResult methods\n * \n * @example Local usage\n * ```typescript\n * import { GoogleGenerativeAI } from '@google/generative-ai';\n * import { createMorphWarpGrepTool } from '@morphllm/morphsdk/tools/warp-grep/gemini';\n * \n * const tool = createMorphWarpGrepTool({ repoRoot: '.' });\n * \n * const genAI = new GoogleGenerativeAI(process.env.GOOGLE_API_KEY);\n * const model = genAI.getGenerativeModel({\n * model: 'gemini-2.0-flash',\n * tools: [{ functionDeclarations: [tool] }]\n * });\n * \n * const chat = model.startChat();\n * const result = await chat.sendMessage('Find authentication middleware');\n * \n * // Handle function call\n * const call = result.response.functionCalls()?.[0];\n * if (call && call.name === tool.name) {\n * const searchResult = await tool.execute(call.args);\n * console.log(tool.formatResult(searchResult));\n * \n * // Send result back to model\n * await chat.sendMessage([{\n * functionResponse: {\n * name: call.name,\n * response: { result: tool.formatResult(searchResult) }\n * }\n * }]);\n * }\n * ```\n * \n * @example Remote sandbox (E2B, Modal, etc.)\n * ```typescript\n * const tool = createMorphWarpGrepTool({\n * repoRoot: '/home/repo',\n * remoteCommands: {\n * grep: async (pattern, path) => (await sandbox.run(`rg '${pattern}' '${path}'`)).stdout,\n * read: async (path, start, end) => (await sandbox.run(`sed -n '${start},${end}p' '${path}'`)).stdout,\n * listDir: async (path, maxDepth) => (await sandbox.run(`find '${path}' -maxdepth ${maxDepth}`)).stdout,\n * },\n * });\n * ```\n */\nexport function createWarpGrepTool(config: WarpGrepToolConfig): GeminiWarpGrepTool {\n const declaration: FunctionDeclaration = {\n name: config.name ?? WARP_GREP_TOOL_NAME,\n description: config.description ?? WARP_GREP_DESCRIPTION,\n parameters: TOOL_PARAMETERS,\n };\n\n return Object.assign(declaration, {\n execute: async (input: unknown): Promise<WarpGrepResult> => {\n return executeToolCall(input as { query: string } | string, config);\n },\n formatResult: (result: WarpGrepResult): string => {\n return formatResult(result);\n },\n });\n}\n\n// Legacy alias for backwards compatibility\nexport const createMorphWarpGrepTool = createWarpGrepTool;\n\nconst GITHUB_SEARCH_PARAMETERS = {\n type: 'OBJECT',\n properties: {\n query: { type: 'STRING', description: 'Natural language search query' },\n github_url: { type: 'STRING', description: 'GitHub repository URL to search (e.g. \"https://github.com/vercel/next.js\"). You must provide either github_url or owner_repo.' },\n owner_repo: { type: 'STRING', description: 'Repository owner/repo shorthand (e.g. \"vercel/next.js\"). You must provide either github_url or owner_repo.' },\n branch: { type: 'STRING', description: 'Branch to search (defaults to repo default branch)' },\n },\n required: ['query'],\n} as unknown as FunctionDeclarationSchema;\n\n/**\n * Create a GitHub search tool for Google Gemini SDK\n *\n * @param config - Configuration options (morphApiKey, morphApiUrl, codeSearchUrl, timeout)\n * @returns Gemini FunctionDeclaration with execute and formatResult methods\n *\n * @example\n * ```typescript\n * import { GoogleGenerativeAI } from '@google/generative-ai';\n * import { createGitHubSearchTool } from '@morphllm/morphsdk/tools/warp-grep/gemini';\n *\n * const tool = createGitHubSearchTool({ morphApiKey: process.env.MORPH_API_KEY });\n *\n * const genAI = new GoogleGenerativeAI(process.env.GOOGLE_API_KEY);\n * const model = genAI.getGenerativeModel({\n * model: 'gemini-2.0-flash',\n * tools: [{ functionDeclarations: [tool] }]\n * });\n *\n * // Execute\n * const result = await tool.execute({ query: 'auth middleware', github: 'vercel/next.js' });\n * console.log(tool.formatResult(result));\n * ```\n */\nexport function createGitHubSearchTool(config: GitHubSearchToolConfig) {\n const client = new WarpGrepClient(config);\n\n const declaration: FunctionDeclaration = {\n name: GITHUB_SEARCH_TOOL_NAME,\n description: GITHUB_SEARCH_DESCRIPTION,\n parameters: GITHUB_SEARCH_PARAMETERS,\n };\n\n return Object.assign(declaration, {\n execute: async (input: { query: string; github_url?: string; owner_repo?: string; branch?: string }): Promise<WarpGrepResult> => {\n const github = input.github_url || input.owner_repo;\n if (!github) {\n throw new Error('Please provide github search url or owner/repo id');\n }\n return client.searchGitHub({ query: input.query, github, branch: input.branch });\n },\n formatResult: (result: WarpGrepResult): string => {\n return formatResult(result);\n },\n });\n}\n\nconst GITHUB_READ_FILE_PARAMETERS = {\n type: 'OBJECT',\n properties: {\n github: { type: 'STRING', description: 'owner/repo shorthand (e.g., \"vercel/next.js\")' },\n path: { type: 'STRING', description: 'File path within the repository' },\n startLine: { type: 'NUMBER', description: 'Start line number (1-based)' },\n endLine: { type: 'NUMBER', description: 'End line number (1-based, inclusive)' },\n branch: { type: 'STRING', description: 'Branch to read from (defaults to repo default branch)' },\n },\n required: ['github', 'path'],\n} as unknown as FunctionDeclarationSchema;\n\n/**\n * Create a GitHub read file tool for Google Gemini SDK\n *\n * @param config - Optional configuration (timeout)\n * @returns Gemini FunctionDeclaration with execute and formatResult methods\n *\n * @example\n * ```typescript\n * import { GoogleGenerativeAI } from '@google/generative-ai';\n * import { createGitHubReadFileTool } from '@morphllm/morphsdk/tools/warp-grep/gemini';\n *\n * const tool = createGitHubReadFileTool();\n *\n * const genAI = new GoogleGenerativeAI(process.env.GOOGLE_API_KEY);\n * const model = genAI.getGenerativeModel({\n * model: 'gemini-2.0-flash',\n * tools: [{ functionDeclarations: [tool] }]\n * });\n *\n * const result = await tool.execute({ github: 'vercel/next.js', path: 'package.json' });\n * console.log(tool.formatResult(result));\n * ```\n */\nexport function createGitHubReadFileTool(config?: GitHubReadFileToolConfig) {\n const declaration: FunctionDeclaration = {\n name: GITHUB_READ_FILE_TOOL_NAME,\n description: GITHUB_READ_FILE_DESCRIPTION,\n parameters: GITHUB_READ_FILE_PARAMETERS,\n };\n\n return Object.assign(declaration, {\n execute: async (input: GitHubReadFileInput): Promise<GitHubReadFileResult> => {\n return executeGitHubReadFile(input, config);\n },\n formatResult: (result: GitHubReadFileResult): string => {\n return formatGitHubReadFileResult(result);\n },\n });\n}\n\nexport default warpGrepFunctionDeclaration;\n\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAaA,IAAM,kBAAkB;AAAA,EACtB,MAAM;AAAA,EACN,YAAY;AAAA,IACV,OAAO;AAAA,MACL,MAAM;AAAA,MACN,aAAa;AAAA,IACf;AAAA,EACF;AAAA,EACA,UAAU,CAAC,OAAO;AACpB;AA2BO,IAAM,8BAAmD;AAAA,EAC9D,MAAM;AAAA,EACN,aAAa;AAAA,EACb,YAAY;AACd;AASA,eAAsB,QACpB,OACA,QACyB;AACzB,SAAO,gBAAgB,OAAO,MAAM;AACtC;AA8DO,SAAS,mBAAmB,QAAgD;AACjF,QAAM,cAAmC;AAAA,IACvC,MAAM,OAAO,QAAQ;AAAA,IACrB,aAAa,OAAO,eAAe;AAAA,IACnC,YAAY;AAAA,EACd;AAEA,SAAO,OAAO,OAAO,aAAa;AAAA,IAChC,SAAS,OAAO,UAA4C;AAC1D,aAAO,gBAAgB,OAAqC,MAAM;AAAA,IACpE;AAAA,IACA,cAAc,CAAC,WAAmC;AAChD,aAAO,aAAa,MAAM;AAAA,IAC5B;AAAA,EACF,CAAC;AACH;AAGO,IAAM,0BAA0B;AAEvC,IAAM,2BAA2B;AAAA,EAC/B,MAAM;AAAA,EACN,YAAY;AAAA,IACV,OAAO,EAAE,MAAM,UAAU,aAAa,gCAAgC;AAAA,IACtE,YAAY,EAAE,MAAM,UAAU,aAAa,gIAAgI;AAAA,IAC3K,YAAY,EAAE,MAAM,UAAU,aAAa,6GAA6G;AAAA,IACxJ,QAAQ,EAAE,MAAM,UAAU,aAAa,qDAAqD;AAAA,EAC9F;AAAA,EACA,UAAU,CAAC,OAAO;AACpB;AA0BO,SAAS,uBAAuB,QAAgC;AACrE,QAAM,SAAS,IAAI,eAAe,MAAM;AAExC,QAAM,cAAmC;AAAA,IACvC,MAAM;AAAA,IACN,aAAa;AAAA,IACb,YAAY;AAAA,EACd;AAEA,SAAO,OAAO,OAAO,aAAa;AAAA,IAChC,SAAS,OAAO,UAAiH;AAC/H,YAAM,SAAS,MAAM,cAAc,MAAM;AACzC,UAAI,CAAC,QAAQ;AACX,cAAM,IAAI,MAAM,mDAAmD;AAAA,MACrE;AACA,aAAO,OAAO,aAAa,EAAE,OAAO,MAAM,OAAO,QAAQ,QAAQ,MAAM,OAAO,CAAC;AAAA,IACjF;AAAA,IACA,cAAc,CAAC,WAAmC;AAChD,aAAO,aAAa,MAAM;AAAA,IAC5B;AAAA,EACF,CAAC;AACH;AAEA,IAAM,8BAA8B;AAAA,EAClC,MAAM;AAAA,EACN,YAAY;AAAA,IACV,QAAQ,EAAE,MAAM,UAAU,aAAa,gDAAgD;AAAA,IACvF,MAAM,EAAE,MAAM,UAAU,aAAa,kCAAkC;AAAA,IACvE,WAAW,EAAE,MAAM,UAAU,aAAa,8BAA8B;AAAA,IACxE,SAAS,EAAE,MAAM,UAAU,aAAa,uCAAuC;AAAA,IAC/E,QAAQ,EAAE,MAAM,UAAU,aAAa,wDAAwD;AAAA,EACjG;AAAA,EACA,UAAU,CAAC,UAAU,MAAM;AAC7B;AAyBO,SAAS,yBAAyB,QAAmC;AAC1E,QAAM,cAAmC;AAAA,IACvC,MAAM;AAAA,IACN,aAAa;AAAA,IACb,YAAY;AAAA,EACd;AAEA,SAAO,OAAO,OAAO,aAAa;AAAA,IAChC,SAAS,OAAO,UAA8D;AAC5E,aAAO,sBAAsB,OAAO,MAAM;AAAA,IAC5C;AAAA,IACA,cAAc,CAAC,WAAyC;AACtD,aAAO,2BAA2B,MAAM;AAAA,IAC1C;AAAA,EACF,CAAC;AACH;AAEA,IAAO,iBAAQ;","names":[]}
@@ -995,7 +995,7 @@ var import_openai = __toESM(require("openai"), 1);
995
995
  // package.json
996
996
  var package_default = {
997
997
  name: "@morphllm/morphsdk",
998
- version: "0.2.126",
998
+ version: "0.2.127",
999
999
  description: "TypeScript SDK and CLI for Morph Fast Apply integration",
1000
1000
  type: "module",
1001
1001
  main: "./dist/index.cjs",
@@ -2087,15 +2087,16 @@ function formatResult(result) {
2087
2087
  var WARP_GREP_TOOL_NAME = "warpgrep_codebase_search";
2088
2088
  var WARP_GREP_DESCRIPTION = 'IMPORTANT: If you need to explore the codebase to gather context, and the task does not involve a single file or function which is provided by name, you should ALWAYS use the warpgrep codebase search tool first instead of running search commands. When the task requires exploration beyond a single known file, invoke warpgrep first with a natural-language query describing the target functionality, bug, or architectural concern. Warp Grep is a fast and accurate tool that can search for all relevant context in a codebase. Keep queries action-oriented (e.g., "Find where billing invoices are generated and emailed"), and after reviewing the summarized results, you may verify important findings with other search tools or direct file reads to ensure completeness. Warp Grep can be used for query types like: find function responsible for <small feature>; find code that does <description>; find code path for <big feature>; Where does <minimal error message> come from?; or any query of that type. When a task requires exploration beyond a single known file, ALWAYS default to warpgrep codebase search before other search mechanisms.';
2089
2089
  var GITHUB_WARP_GREP_SEARCH_TOOL_NAME = "warpgrep_github_search";
2090
- var GITHUB_WARP_GREP_SEARCH_DESCRIPTION = 'IMPORTANT: If you need to explore the codebase of a public GitHub repository (not your local workspace), use warpgrep_github_search instead of warpgrep_codebase_search. ONLY use this tool when the task requires understanding code in an external repo, and invoke warpgrep_github_search with a GitHub URL or owner/repo shorthand (e.g., vercel/next.js) and a natural-language query describing the target functionality, bug, or architectural concern. DO NOT use this tool when the task requires understanding code in your local workspace. Use warpgrep_codebase_search instead.Useful when you suspect a library or framework is being used in a way that is not documented, or if you suspect an update or a bug in the library or framework.WarpGrep searches GitHub repos the same way it searches local codebases: fast and accurate. Keep queries action-oriented (e.g., "Find where how the new use workflow directive works"), and after reviewing the results, you may verify important findings with other tools or direct file reads. WarpGrep can be used for query types like: find function responsible for <small feature>; find code that does <description>; find code path for <big feature>; Where does <minimal error message> come from?; or any query of that type. When a task involves exploring code in an external public repo, ALWAYS use warpgrep_github_search.';
2090
+ var GITHUB_WARP_GREP_SEARCH_DESCRIPTION = 'IMPORTANT: If you need to explore the codebase of a public GitHub repository (not your local workspace), use warpgrep_github_search instead of warpgrep_codebase_search. ONLY use this tool when the task requires understanding code in an external repo, and invoke warpgrep_github_search with a natural-language query describing the target functionality, bug, or architectural concern. DO NOT use this tool when the task requires understanding code in your local workspace. Use warpgrep_codebase_search instead.Useful when you suspect a library or framework is being used in a way that is not documented, or if you suspect an update or a bug in the library or framework.WarpGrep searches GitHub repos the same way it searches local codebases: fast and accurate. Keep queries action-oriented (e.g., "Find where how the new use workflow directive works"), and after reviewing the results, you may verify important findings with other tools or direct file reads. WarpGrep can be used for query types like: find function responsible for <small feature>; find code that does <description>; find code path for <big feature>; Where does <minimal error message> come from?; or any query of that type. When a task involves exploring code in an external public repo, ALWAYS use warpgrep_github_search. You must provide either a github_url or owner_repo parameter (at least one is required).';
2091
2091
  var GITHUB_WARP_GREP_SEARCH_INPUT_SCHEMA = {
2092
2092
  type: "object",
2093
2093
  properties: {
2094
2094
  query: { type: "string", description: "Natural language search query describing what to find in the repository" },
2095
- github: { type: "string", description: 'owner/repo shorthand (ex: "vercel/next.js" for "https://github.com/vercel/next.js")' },
2095
+ github_url: { type: "string", description: 'GitHub repository URL to search (e.g. "https://github.com/vercel/next.js"). You must provide either github_url or owner_repo.' },
2096
+ owner_repo: { type: "string", description: 'Repository owner/repo shorthand (e.g. "vercel/next.js"). You must provide either github_url or owner_repo.' },
2096
2097
  branch: { type: "string", description: "Branch to search (defaults to the repository default branch)" }
2097
2098
  },
2098
- required: ["query", "github"]
2099
+ required: ["query"]
2099
2100
  };
2100
2101
  var GITHUB_SEARCH_TOOL_NAME = GITHUB_WARP_GREP_SEARCH_TOOL_NAME;
2101
2102
  var GITHUB_SEARCH_DESCRIPTION = GITHUB_WARP_GREP_SEARCH_DESCRIPTION;