@langchain/xai 1.4.17 → 1.5.0

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 (50) hide show
  1. package/CHANGELOG.md +21 -0
  2. package/dist/chat_models/completions.cjs +1 -1
  3. package/dist/chat_models/completions.cjs.map +1 -1
  4. package/dist/chat_models/completions.d.cts +9 -10
  5. package/dist/chat_models/completions.d.cts.map +1 -1
  6. package/dist/chat_models/completions.d.ts +9 -10
  7. package/dist/chat_models/completions.d.ts.map +1 -1
  8. package/dist/chat_models/completions.js +1 -1
  9. package/dist/chat_models/completions.js.map +1 -1
  10. package/dist/chat_models/responses-types.d.cts +94 -95
  11. package/dist/chat_models/responses-types.d.cts.map +1 -1
  12. package/dist/chat_models/responses-types.d.ts +94 -95
  13. package/dist/chat_models/responses-types.d.ts.map +1 -1
  14. package/dist/chat_models/responses.cjs +1 -1
  15. package/dist/chat_models/responses.cjs.map +1 -1
  16. package/dist/chat_models/responses.d.cts +2 -2
  17. package/dist/chat_models/responses.d.cts.map +1 -1
  18. package/dist/chat_models/responses.d.ts +2 -2
  19. package/dist/chat_models/responses.d.ts.map +1 -1
  20. package/dist/chat_models/responses.js +1 -1
  21. package/dist/chat_models/responses.js.map +1 -1
  22. package/dist/live_search.d.cts +7 -8
  23. package/dist/live_search.d.cts.map +1 -1
  24. package/dist/live_search.d.ts +7 -8
  25. package/dist/live_search.d.ts.map +1 -1
  26. package/dist/tools/code_execution.d.cts +3 -4
  27. package/dist/tools/code_execution.d.cts.map +1 -1
  28. package/dist/tools/code_execution.d.ts +3 -4
  29. package/dist/tools/code_execution.d.ts.map +1 -1
  30. package/dist/tools/collections_search.d.cts +4 -5
  31. package/dist/tools/collections_search.d.cts.map +1 -1
  32. package/dist/tools/collections_search.d.ts +4 -5
  33. package/dist/tools/collections_search.d.ts.map +1 -1
  34. package/dist/tools/index.d.cts +1 -2
  35. package/dist/tools/index.d.cts.map +1 -1
  36. package/dist/tools/index.d.ts +1 -2
  37. package/dist/tools/index.d.ts.map +1 -1
  38. package/dist/tools/live_search.d.cts +10 -11
  39. package/dist/tools/live_search.d.cts.map +1 -1
  40. package/dist/tools/live_search.d.ts +10 -11
  41. package/dist/tools/live_search.d.ts.map +1 -1
  42. package/dist/tools/web_search.d.cts +4 -5
  43. package/dist/tools/web_search.d.cts.map +1 -1
  44. package/dist/tools/web_search.d.ts +4 -5
  45. package/dist/tools/web_search.d.ts.map +1 -1
  46. package/dist/tools/x_search.d.cts +4 -5
  47. package/dist/tools/x_search.d.cts.map +1 -1
  48. package/dist/tools/x_search.d.ts +4 -5
  49. package/dist/tools/x_search.d.ts.map +1 -1
  50. package/package.json +7 -7
@@ -3,13 +3,13 @@ import { XAISearchParameters } from "../live_search.cjs";
3
3
  /**
4
4
  * xAI's deprecated live_search tool type.
5
5
  */
6
- declare const XAI_LIVE_SEARCH_TOOL_TYPE = "live_search_deprecated_20251215";
7
- declare const XAI_LIVE_SEARCH_TOOL_NAME = "live_search";
6
+ export declare const XAI_LIVE_SEARCH_TOOL_TYPE = "live_search_deprecated_20251215";
7
+ export declare const XAI_LIVE_SEARCH_TOOL_NAME = "live_search";
8
8
  /**
9
9
  * xAI's built-in live_search tool type.
10
10
  * Enables the model to search the web for real-time information.
11
11
  */
12
- interface XAILiveSearchTool extends XAISearchParameters {
12
+ export interface XAILiveSearchTool extends XAISearchParameters {
13
13
  /**
14
14
  * The name of the tool. Must be "live_search" for xAI's built-in search.
15
15
  */
@@ -26,7 +26,7 @@ interface XAILiveSearchTool extends XAISearchParameters {
26
26
  * Web search source configuration for the xAI live search tool (camelCase).
27
27
  * This is converted to the snake_case `XAIWebSource` internally.
28
28
  */
29
- interface XAIWebSearchToolSource {
29
+ export interface XAIWebSearchToolSource {
30
30
  type: "web";
31
31
  country?: string;
32
32
  excludedWebsites?: string[];
@@ -37,7 +37,7 @@ interface XAIWebSearchToolSource {
37
37
  * News search source configuration for the xAI live search tool (camelCase).
38
38
  * This is converted to the snake_case `XAINewsSource` internally.
39
39
  */
40
- interface XAINewsSearchToolSource {
40
+ export interface XAINewsSearchToolSource {
41
41
  type: "news";
42
42
  country?: string;
43
43
  excludedWebsites?: string[];
@@ -47,7 +47,7 @@ interface XAINewsSearchToolSource {
47
47
  * X (formerly Twitter) search source configuration for the xAI live search tool (camelCase).
48
48
  * This is converted to the snake_case `XAIXSource` internally.
49
49
  */
50
- interface XAIXSearchToolSource {
50
+ export interface XAIXSearchToolSource {
51
51
  type: "x";
52
52
  includedXHandles?: string[];
53
53
  excludedXHandles?: string[];
@@ -58,18 +58,18 @@ interface XAIXSearchToolSource {
58
58
  * RSS feed search source configuration for the xAI live search tool.
59
59
  * The structure matches `XAIRssSource` (only `links`).
60
60
  */
61
- interface XAIRssSearchToolSource {
61
+ export interface XAIRssSearchToolSource {
62
62
  type: "rss";
63
63
  links: string[];
64
64
  }
65
- type XAISearchToolSource = XAIWebSearchToolSource | XAINewsSearchToolSource | XAIXSearchToolSource | XAIRssSearchToolSource;
65
+ export type XAISearchToolSource = XAIWebSearchToolSource | XAINewsSearchToolSource | XAIXSearchToolSource | XAIRssSearchToolSource;
66
66
  /**
67
67
  * Options for the xAI live search tool (camelCase).
68
68
  * All fields are camel-cased for the TypeScript API and are mapped to the
69
69
  * corresponding snake_case fields in the underlying `XAISearchParameters`
70
70
  * object that is sent to xAI's deprecated Live Search API.
71
71
  */
72
- interface XAILiveSearchToolOptions {
72
+ export interface XAILiveSearchToolOptions {
73
73
  /**
74
74
  * Controls when the model should perform a search.
75
75
  * - "auto": Let the model decide when to search (default)
@@ -141,7 +141,6 @@ interface XAILiveSearchToolOptions {
141
141
  * const result = await llmWithSearch.invoke("What happened in tech today?");
142
142
  * ```
143
143
  */
144
- declare function xaiLiveSearch(options?: XAILiveSearchToolOptions): XAILiveSearchTool;
144
+ export declare function xaiLiveSearch(options?: XAILiveSearchToolOptions): XAILiveSearchTool;
145
145
  //#endregion
146
- export { XAILiveSearchTool, XAILiveSearchToolOptions, XAINewsSearchToolSource, XAIRssSearchToolSource, XAISearchToolSource, XAIWebSearchToolSource, XAIXSearchToolSource, XAI_LIVE_SEARCH_TOOL_NAME, XAI_LIVE_SEARCH_TOOL_TYPE, xaiLiveSearch };
147
146
  //# sourceMappingURL=live_search.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"live_search.d.cts","names":[],"sources":["../../src/tools/live_search.ts"],"mappings":";;;;;cAKa;cACA;;;;;UAMI,0BAA0B;;;;EAIzC,aAAa;;;;;;;EAOb,aAAa;;;;;;UAOE;EACf;EACA;EACA;EACA;EACA;;;;;;UAOe;EACf;EACA;EACA;EACA;;;;;;UAOe;EACf;EACA;EACA;EACA;EACA;;;;;;UAOe;EACf;EACA;;KAGU,sBACR,yBACA,0BACA,uBACA;;;;;;;UAQa;;;;;;;EAOf;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;;EAMA,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAiGI,cACd,UAAS,2BACR"}
1
+ {"version":3,"file":"live_search.d.cts","names":[],"sources":["../../src/tools/live_search.ts"],"mappings":";;;;;qBAKa;qBACA;;;;;iBAMI,0BAA0B;;;;EAIzC,aAAa;;;;;;;EAOb,aAAa;;;;;;iBAOE;EACf;EACA;EACA;EACA;EACA;;;;;;iBAOe;EACf;EACA;EACA;EACA;;;;;;iBAOe;EACf;EACA;EACA;EACA;EACA;;;;;;iBAOe;EACf;EACA;;YAGU,sBACR,yBACA,0BACA,uBACA;;;;;;;iBAQa;;;;;;;EAOf;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;;EAMA,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wBAiGI,cACd,UAAS,2BACR"}
@@ -3,13 +3,13 @@ import { XAISearchParameters } from "../live_search.js";
3
3
  /**
4
4
  * xAI's deprecated live_search tool type.
5
5
  */
6
- declare const XAI_LIVE_SEARCH_TOOL_TYPE = "live_search_deprecated_20251215";
7
- declare const XAI_LIVE_SEARCH_TOOL_NAME = "live_search";
6
+ export declare const XAI_LIVE_SEARCH_TOOL_TYPE = "live_search_deprecated_20251215";
7
+ export declare const XAI_LIVE_SEARCH_TOOL_NAME = "live_search";
8
8
  /**
9
9
  * xAI's built-in live_search tool type.
10
10
  * Enables the model to search the web for real-time information.
11
11
  */
12
- interface XAILiveSearchTool extends XAISearchParameters {
12
+ export interface XAILiveSearchTool extends XAISearchParameters {
13
13
  /**
14
14
  * The name of the tool. Must be "live_search" for xAI's built-in search.
15
15
  */
@@ -26,7 +26,7 @@ interface XAILiveSearchTool extends XAISearchParameters {
26
26
  * Web search source configuration for the xAI live search tool (camelCase).
27
27
  * This is converted to the snake_case `XAIWebSource` internally.
28
28
  */
29
- interface XAIWebSearchToolSource {
29
+ export interface XAIWebSearchToolSource {
30
30
  type: "web";
31
31
  country?: string;
32
32
  excludedWebsites?: string[];
@@ -37,7 +37,7 @@ interface XAIWebSearchToolSource {
37
37
  * News search source configuration for the xAI live search tool (camelCase).
38
38
  * This is converted to the snake_case `XAINewsSource` internally.
39
39
  */
40
- interface XAINewsSearchToolSource {
40
+ export interface XAINewsSearchToolSource {
41
41
  type: "news";
42
42
  country?: string;
43
43
  excludedWebsites?: string[];
@@ -47,7 +47,7 @@ interface XAINewsSearchToolSource {
47
47
  * X (formerly Twitter) search source configuration for the xAI live search tool (camelCase).
48
48
  * This is converted to the snake_case `XAIXSource` internally.
49
49
  */
50
- interface XAIXSearchToolSource {
50
+ export interface XAIXSearchToolSource {
51
51
  type: "x";
52
52
  includedXHandles?: string[];
53
53
  excludedXHandles?: string[];
@@ -58,18 +58,18 @@ interface XAIXSearchToolSource {
58
58
  * RSS feed search source configuration for the xAI live search tool.
59
59
  * The structure matches `XAIRssSource` (only `links`).
60
60
  */
61
- interface XAIRssSearchToolSource {
61
+ export interface XAIRssSearchToolSource {
62
62
  type: "rss";
63
63
  links: string[];
64
64
  }
65
- type XAISearchToolSource = XAIWebSearchToolSource | XAINewsSearchToolSource | XAIXSearchToolSource | XAIRssSearchToolSource;
65
+ export type XAISearchToolSource = XAIWebSearchToolSource | XAINewsSearchToolSource | XAIXSearchToolSource | XAIRssSearchToolSource;
66
66
  /**
67
67
  * Options for the xAI live search tool (camelCase).
68
68
  * All fields are camel-cased for the TypeScript API and are mapped to the
69
69
  * corresponding snake_case fields in the underlying `XAISearchParameters`
70
70
  * object that is sent to xAI's deprecated Live Search API.
71
71
  */
72
- interface XAILiveSearchToolOptions {
72
+ export interface XAILiveSearchToolOptions {
73
73
  /**
74
74
  * Controls when the model should perform a search.
75
75
  * - "auto": Let the model decide when to search (default)
@@ -141,7 +141,6 @@ interface XAILiveSearchToolOptions {
141
141
  * const result = await llmWithSearch.invoke("What happened in tech today?");
142
142
  * ```
143
143
  */
144
- declare function xaiLiveSearch(options?: XAILiveSearchToolOptions): XAILiveSearchTool;
144
+ export declare function xaiLiveSearch(options?: XAILiveSearchToolOptions): XAILiveSearchTool;
145
145
  //#endregion
146
- export { XAILiveSearchTool, XAILiveSearchToolOptions, XAINewsSearchToolSource, XAIRssSearchToolSource, XAISearchToolSource, XAIWebSearchToolSource, XAIXSearchToolSource, XAI_LIVE_SEARCH_TOOL_NAME, XAI_LIVE_SEARCH_TOOL_TYPE, xaiLiveSearch };
147
146
  //# sourceMappingURL=live_search.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"live_search.d.ts","names":[],"sources":["../../src/tools/live_search.ts"],"mappings":";;;;;cAKa;cACA;;;;;UAMI,0BAA0B;;;;EAIzC,aAAa;;;;;;;EAOb,aAAa;;;;;;UAOE;EACf;EACA;EACA;EACA;EACA;;;;;;UAOe;EACf;EACA;EACA;EACA;;;;;;UAOe;EACf;EACA;EACA;EACA;EACA;;;;;;UAOe;EACf;EACA;;KAGU,sBACR,yBACA,0BACA,uBACA;;;;;;;UAQa;;;;;;;EAOf;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;;EAMA,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAiGI,cACd,UAAS,2BACR"}
1
+ {"version":3,"file":"live_search.d.ts","names":[],"sources":["../../src/tools/live_search.ts"],"mappings":";;;;;qBAKa;qBACA;;;;;iBAMI,0BAA0B;;;;EAIzC,aAAa;;;;;;;EAOb,aAAa;;;;;;iBAOE;EACf;EACA;EACA;EACA;EACA;;;;;;iBAOe;EACf;EACA;EACA;EACA;;;;;;iBAOe;EACf;EACA;EACA;EACA;EACA;;;;;;iBAOe;EACf;EACA;;YAGU,sBACR,yBACA,0BACA,uBACA;;;;;;;iBAQa;;;;;;;EAOf;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;;EAMA,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wBAiGI,cACd,UAAS,2BACR"}
@@ -2,14 +2,14 @@
2
2
  /**
3
3
  * xAI Web Search tool type constant.
4
4
  */
5
- declare const XAI_WEB_SEARCH_TOOL_TYPE = "web_search";
5
+ export declare const XAI_WEB_SEARCH_TOOL_TYPE = "web_search";
6
6
  /**
7
7
  * xAI's built-in web search tool interface.
8
8
  * Enables the model to search the web and browse pages for real-time information.
9
9
  *
10
10
  * This tool is part of xAI's agentic tool calling API.
11
11
  */
12
- interface XAIWebSearchTool {
12
+ export interface XAIWebSearchTool {
13
13
  /**
14
14
  * The type of the tool. Must be "web_search".
15
15
  */
@@ -35,7 +35,7 @@ interface XAIWebSearchTool {
35
35
  * All fields are camel-cased for the TypeScript API and are mapped to the
36
36
  * corresponding snake_case fields in the API request.
37
37
  */
38
- interface XAIWebSearchToolOptions {
38
+ export interface XAIWebSearchToolOptions {
39
39
  /**
40
40
  * Domains to exclusively include in the search (max 5).
41
41
  * Cannot be used together with `excludedDomains`.
@@ -98,7 +98,6 @@ interface XAIWebSearchToolOptions {
98
98
  * });
99
99
  * ```
100
100
  */
101
- declare function xaiWebSearch(options?: XAIWebSearchToolOptions): XAIWebSearchTool;
101
+ export declare function xaiWebSearch(options?: XAIWebSearchToolOptions): XAIWebSearchTool;
102
102
  //#endregion
103
- export { XAIWebSearchTool, XAIWebSearchToolOptions, XAI_WEB_SEARCH_TOOL_TYPE, xaiWebSearch };
104
103
  //# sourceMappingURL=web_search.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"web_search.d.cts","names":[],"sources":["../../src/tools/web_search.ts"],"mappings":";;;;cAGa;;;;;;;UAQI;;;;EAIf,aAAa;;;;;EAKb;;;;;EAKA;;;;;EAKA;;;;;;;UAQe;;;;;;;EAOf;;;;;;;EAOA;;;;;;;;EAQA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA0Cc,aACd,UAAS,0BACR"}
1
+ {"version":3,"file":"web_search.d.cts","names":[],"sources":["../../src/tools/web_search.ts"],"mappings":";;;;qBAGa;;;;;;;iBAQI;;;;EAIf,aAAa;;;;;EAKb;;;;;EAKA;;;;;EAKA;;;;;;;iBAQe;;;;;;;EAOf;;;;;;;EAOA;;;;;;;;EAQA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wBA0Cc,aACd,UAAS,0BACR"}
@@ -2,14 +2,14 @@
2
2
  /**
3
3
  * xAI Web Search tool type constant.
4
4
  */
5
- declare const XAI_WEB_SEARCH_TOOL_TYPE = "web_search";
5
+ export declare const XAI_WEB_SEARCH_TOOL_TYPE = "web_search";
6
6
  /**
7
7
  * xAI's built-in web search tool interface.
8
8
  * Enables the model to search the web and browse pages for real-time information.
9
9
  *
10
10
  * This tool is part of xAI's agentic tool calling API.
11
11
  */
12
- interface XAIWebSearchTool {
12
+ export interface XAIWebSearchTool {
13
13
  /**
14
14
  * The type of the tool. Must be "web_search".
15
15
  */
@@ -35,7 +35,7 @@ interface XAIWebSearchTool {
35
35
  * All fields are camel-cased for the TypeScript API and are mapped to the
36
36
  * corresponding snake_case fields in the API request.
37
37
  */
38
- interface XAIWebSearchToolOptions {
38
+ export interface XAIWebSearchToolOptions {
39
39
  /**
40
40
  * Domains to exclusively include in the search (max 5).
41
41
  * Cannot be used together with `excludedDomains`.
@@ -98,7 +98,6 @@ interface XAIWebSearchToolOptions {
98
98
  * });
99
99
  * ```
100
100
  */
101
- declare function xaiWebSearch(options?: XAIWebSearchToolOptions): XAIWebSearchTool;
101
+ export declare function xaiWebSearch(options?: XAIWebSearchToolOptions): XAIWebSearchTool;
102
102
  //#endregion
103
- export { XAIWebSearchTool, XAIWebSearchToolOptions, XAI_WEB_SEARCH_TOOL_TYPE, xaiWebSearch };
104
103
  //# sourceMappingURL=web_search.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"web_search.d.ts","names":[],"sources":["../../src/tools/web_search.ts"],"mappings":";;;;cAGa;;;;;;;UAQI;;;;EAIf,aAAa;;;;;EAKb;;;;;EAKA;;;;;EAKA;;;;;;;UAQe;;;;;;;EAOf;;;;;;;EAOA;;;;;;;;EAQA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA0Cc,aACd,UAAS,0BACR"}
1
+ {"version":3,"file":"web_search.d.ts","names":[],"sources":["../../src/tools/web_search.ts"],"mappings":";;;;qBAGa;;;;;;;iBAQI;;;;EAIf,aAAa;;;;;EAKb;;;;;EAKA;;;;;EAKA;;;;;;;iBAQe;;;;;;;EAOf;;;;;;;EAOA;;;;;;;;EAQA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wBA0Cc,aACd,UAAS,0BACR"}
@@ -2,7 +2,7 @@
2
2
  /**
3
3
  * xAI X Search tool type constant.
4
4
  */
5
- declare const XAI_X_SEARCH_TOOL_TYPE = "x_search";
5
+ export declare const XAI_X_SEARCH_TOOL_TYPE = "x_search";
6
6
  /**
7
7
  * xAI's built-in X (formerly Twitter) search tool interface.
8
8
  * Enables the model to perform keyword search, semantic search, user search,
@@ -10,7 +10,7 @@ declare const XAI_X_SEARCH_TOOL_TYPE = "x_search";
10
10
  *
11
11
  * This tool is part of xAI's agentic tool calling API.
12
12
  */
13
- interface XAIXSearchTool {
13
+ export interface XAIXSearchTool {
14
14
  /**
15
15
  * The type of the tool. Must be "x_search".
16
16
  */
@@ -51,7 +51,7 @@ interface XAIXSearchTool {
51
51
  * All fields are camel-cased for the TypeScript API and are mapped to the
52
52
  * corresponding snake_case fields in the API request.
53
53
  */
54
- interface XAIXSearchToolOptions {
54
+ export interface XAIXSearchToolOptions {
55
55
  /**
56
56
  * X handles to exclusively include in the search (max 10).
57
57
  * Cannot be used together with `excludedXHandles`.
@@ -139,7 +139,6 @@ interface XAIXSearchToolOptions {
139
139
  * });
140
140
  * ```
141
141
  */
142
- declare function xaiXSearch(options?: XAIXSearchToolOptions): XAIXSearchTool;
142
+ export declare function xaiXSearch(options?: XAIXSearchToolOptions): XAIXSearchTool;
143
143
  //#endregion
144
- export { XAIXSearchTool, XAIXSearchToolOptions, XAI_X_SEARCH_TOOL_TYPE, xaiXSearch };
145
144
  //# sourceMappingURL=x_search.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"x_search.d.cts","names":[],"sources":["../../src/tools/x_search.ts"],"mappings":";;;;cAGa;;;;;;;;UASI;;;;EAIf,aAAa;;;;;EAKb;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;;;UAQe;;;;;;;EAOf;;;;;;;EAOA;;;;;;;EAOA;;;;;;;EAOA;;;;;;;;EAQA;;;;;;;;EAQA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA6Cc,WACd,UAAS,wBACR"}
1
+ {"version":3,"file":"x_search.d.cts","names":[],"sources":["../../src/tools/x_search.ts"],"mappings":";;;;qBAGa;;;;;;;;iBASI;;;;EAIf,aAAa;;;;;EAKb;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;;;iBAQe;;;;;;;EAOf;;;;;;;EAOA;;;;;;;EAOA;;;;;;;EAOA;;;;;;;;EAQA;;;;;;;;EAQA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wBA6Cc,WACd,UAAS,wBACR"}
@@ -2,7 +2,7 @@
2
2
  /**
3
3
  * xAI X Search tool type constant.
4
4
  */
5
- declare const XAI_X_SEARCH_TOOL_TYPE = "x_search";
5
+ export declare const XAI_X_SEARCH_TOOL_TYPE = "x_search";
6
6
  /**
7
7
  * xAI's built-in X (formerly Twitter) search tool interface.
8
8
  * Enables the model to perform keyword search, semantic search, user search,
@@ -10,7 +10,7 @@ declare const XAI_X_SEARCH_TOOL_TYPE = "x_search";
10
10
  *
11
11
  * This tool is part of xAI's agentic tool calling API.
12
12
  */
13
- interface XAIXSearchTool {
13
+ export interface XAIXSearchTool {
14
14
  /**
15
15
  * The type of the tool. Must be "x_search".
16
16
  */
@@ -51,7 +51,7 @@ interface XAIXSearchTool {
51
51
  * All fields are camel-cased for the TypeScript API and are mapped to the
52
52
  * corresponding snake_case fields in the API request.
53
53
  */
54
- interface XAIXSearchToolOptions {
54
+ export interface XAIXSearchToolOptions {
55
55
  /**
56
56
  * X handles to exclusively include in the search (max 10).
57
57
  * Cannot be used together with `excludedXHandles`.
@@ -139,7 +139,6 @@ interface XAIXSearchToolOptions {
139
139
  * });
140
140
  * ```
141
141
  */
142
- declare function xaiXSearch(options?: XAIXSearchToolOptions): XAIXSearchTool;
142
+ export declare function xaiXSearch(options?: XAIXSearchToolOptions): XAIXSearchTool;
143
143
  //#endregion
144
- export { XAIXSearchTool, XAIXSearchToolOptions, XAI_X_SEARCH_TOOL_TYPE, xaiXSearch };
145
144
  //# sourceMappingURL=x_search.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"x_search.d.ts","names":[],"sources":["../../src/tools/x_search.ts"],"mappings":";;;;cAGa;;;;;;;;UASI;;;;EAIf,aAAa;;;;;EAKb;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;;;UAQe;;;;;;;EAOf;;;;;;;EAOA;;;;;;;EAOA;;;;;;;EAOA;;;;;;;;EAQA;;;;;;;;EAQA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA6Cc,WACd,UAAS,wBACR"}
1
+ {"version":3,"file":"x_search.d.ts","names":[],"sources":["../../src/tools/x_search.ts"],"mappings":";;;;qBAGa;;;;;;;;iBASI;;;;EAIf,aAAa;;;;;EAKb;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;EAKA;;;;;;;iBAQe;;;;;;;EAOf;;;;;;;EAOA;;;;;;;EAOA;;;;;;;EAOA;;;;;;;;EAQA;;;;;;;;EAQA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wBA6Cc,WACd,UAAS,wBACR"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@langchain/xai",
3
- "version": "1.4.17",
3
+ "version": "1.5.0",
4
4
  "description": "xAI integration for LangChain.js",
5
5
  "author": "LangChain",
6
6
  "license": "MIT",
@@ -14,21 +14,21 @@
14
14
  },
15
15
  "homepage": "https://github.com/langchain-ai/langchainjs/tree/main/libs/providers/langchain-xai/",
16
16
  "dependencies": {
17
- "@langchain/openai": "1.6.2"
17
+ "@langchain/openai": "1.7.0"
18
18
  },
19
19
  "peerDependencies": {
20
- "@langchain/core": "^1.0.0"
20
+ "@langchain/core": "^1.3.0"
21
21
  },
22
22
  "devDependencies": {
23
23
  "@tsconfig/recommended": "^1.0.3",
24
- "@vitest/coverage-v8": "^4.1.11",
24
+ "@vitest/coverage-v8": "^5.0.2",
25
25
  "dotenv": "^17.4.2",
26
26
  "dpdm": "^4.3.0",
27
27
  "typescript": "~7.0.2",
28
- "vitest": "^4.1.11",
28
+ "vitest": "^5.0.2",
29
29
  "zod": "^3.25.76",
30
- "@langchain/core": "^1.2.14",
31
- "@langchain/openai": "^1.6.2",
30
+ "@langchain/core": "^1.3.0",
31
+ "@langchain/openai": "^1.7.0",
32
32
  "@langchain/standard-tests": "0.0.23",
33
33
  "@langchain/tsconfig": "0.0.1"
34
34
  },