triangle-utils 1.4.64 → 1.4.65

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.
@@ -5,10 +5,12 @@ export declare class UtilsAnthropic {
5
5
  max_tokens?: number;
6
6
  print_usage?: boolean;
7
7
  json_format?: Record<string, any>;
8
+ web?: boolean;
8
9
  }): Promise<string | undefined>;
9
10
  claude_query(model_id: string, prompt: string, attachment_pdf?: string, options?: {
10
11
  max_tokens?: number;
11
12
  print_usage?: boolean;
12
13
  json_format?: Record<string, any>;
14
+ web?: boolean;
13
15
  }): Promise<string | undefined>;
14
16
  }
@@ -17,6 +17,7 @@ export class UtilsAnthropic {
17
17
  }
18
18
  ]
19
19
  })),
20
+ tools: options.web === true ? [{ name: "web_search", type: "web_search_20260209" }] : [],
20
21
  max_tokens: options.max_tokens || 1000,
21
22
  output_config: options.json_format !== undefined ? {
22
23
  format: {
@@ -68,6 +69,7 @@ export class UtilsAnthropic {
68
69
  role: "user",
69
70
  content: message_contents
70
71
  }],
72
+ tools: options.web === true ? [{ name: "web_search", type: "web_search_20260209" }] : [],
71
73
  max_tokens: options.max_tokens || 1000,
72
74
  output_config: options.json_format !== undefined ? {
73
75
  format: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "triangle-utils",
3
- "version": "1.4.64",
3
+ "version": "1.4.65",
4
4
  "main": "dist/src/index.js",
5
5
  "types": "dist/src/index.d.ts",
6
6
  "directories": {
@@ -14,7 +14,8 @@ export class UtilsAnthropic {
14
14
  options : {
15
15
  max_tokens? : number,
16
16
  print_usage? : boolean,
17
- json_format? : Record<string, any>
17
+ json_format? : Record<string, any>,
18
+ web? : boolean
18
19
  } = {}
19
20
  ) : Promise<string | undefined> {
20
21
  try {
@@ -30,6 +31,7 @@ export class UtilsAnthropic {
30
31
  }
31
32
  ]
32
33
  })),
34
+ tools : options.web === true ? [{ name : "web_search", type : "web_search_20260209" }] : [],
33
35
  max_tokens : options.max_tokens || 1000,
34
36
  output_config : options.json_format !== undefined ? {
35
37
  format : {
@@ -61,7 +63,8 @@ export class UtilsAnthropic {
61
63
  options : {
62
64
  max_tokens? : number,
63
65
  print_usage? : boolean,
64
- json_format? : Record<string, any>
66
+ json_format? : Record<string, any>,
67
+ web? : boolean
65
68
  } = {}
66
69
  ) : Promise<string | undefined> {
67
70
  try {
@@ -93,6 +96,7 @@ export class UtilsAnthropic {
93
96
  role : "user",
94
97
  content : message_contents
95
98
  }],
99
+ tools : options.web === true ? [{ name : "web_search", type : "web_search_20260209" }] : [],
96
100
  max_tokens : options.max_tokens || 1000,
97
101
  output_config : options.json_format !== undefined ? {
98
102
  format : {