valyu-js 2.7.7 → 2.7.8
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.
- package/dist/index.d.mts +17 -2
- package/dist/index.d.ts +17 -2
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -13,6 +13,7 @@ interface SearchResult {
|
|
|
13
13
|
data_type?: DataType;
|
|
14
14
|
date?: string;
|
|
15
15
|
length: number;
|
|
16
|
+
price: number;
|
|
16
17
|
relevance_score?: number;
|
|
17
18
|
publication_date?: string;
|
|
18
19
|
id?: string;
|
|
@@ -169,12 +170,26 @@ interface ExtractionMetadata {
|
|
|
169
170
|
response_length: string;
|
|
170
171
|
extract_effort: string;
|
|
171
172
|
}
|
|
173
|
+
interface AnswerSearchResult {
|
|
174
|
+
title: string;
|
|
175
|
+
url: string;
|
|
176
|
+
content: string | object | any[];
|
|
177
|
+
description?: string;
|
|
178
|
+
source: string;
|
|
179
|
+
source_type?: string;
|
|
180
|
+
data_type?: DataType;
|
|
181
|
+
date?: string;
|
|
182
|
+
length: number;
|
|
183
|
+
relevance_score?: number;
|
|
184
|
+
image_url?: Record<string, string>;
|
|
185
|
+
abstract?: string;
|
|
186
|
+
}
|
|
172
187
|
interface AnswerSuccessResponse {
|
|
173
188
|
success: true;
|
|
174
189
|
tx_id: string;
|
|
175
190
|
original_query: string;
|
|
176
191
|
contents: string | Record<string, any>;
|
|
177
|
-
search_results:
|
|
192
|
+
search_results: AnswerSearchResult[];
|
|
178
193
|
search_metadata: SearchMetadata;
|
|
179
194
|
ai_usage: AIUsage;
|
|
180
195
|
cost: Cost;
|
|
@@ -188,7 +203,7 @@ type AnswerResponse = AnswerSuccessResponse | AnswerErrorResponse;
|
|
|
188
203
|
type AnswerStreamChunkType = "search_results" | "content" | "metadata" | "done" | "error";
|
|
189
204
|
interface AnswerStreamChunk {
|
|
190
205
|
type: AnswerStreamChunkType;
|
|
191
|
-
search_results?:
|
|
206
|
+
search_results?: AnswerSearchResult[];
|
|
192
207
|
content?: string;
|
|
193
208
|
finish_reason?: string;
|
|
194
209
|
tx_id?: string;
|
package/dist/index.d.ts
CHANGED
|
@@ -13,6 +13,7 @@ interface SearchResult {
|
|
|
13
13
|
data_type?: DataType;
|
|
14
14
|
date?: string;
|
|
15
15
|
length: number;
|
|
16
|
+
price: number;
|
|
16
17
|
relevance_score?: number;
|
|
17
18
|
publication_date?: string;
|
|
18
19
|
id?: string;
|
|
@@ -169,12 +170,26 @@ interface ExtractionMetadata {
|
|
|
169
170
|
response_length: string;
|
|
170
171
|
extract_effort: string;
|
|
171
172
|
}
|
|
173
|
+
interface AnswerSearchResult {
|
|
174
|
+
title: string;
|
|
175
|
+
url: string;
|
|
176
|
+
content: string | object | any[];
|
|
177
|
+
description?: string;
|
|
178
|
+
source: string;
|
|
179
|
+
source_type?: string;
|
|
180
|
+
data_type?: DataType;
|
|
181
|
+
date?: string;
|
|
182
|
+
length: number;
|
|
183
|
+
relevance_score?: number;
|
|
184
|
+
image_url?: Record<string, string>;
|
|
185
|
+
abstract?: string;
|
|
186
|
+
}
|
|
172
187
|
interface AnswerSuccessResponse {
|
|
173
188
|
success: true;
|
|
174
189
|
tx_id: string;
|
|
175
190
|
original_query: string;
|
|
176
191
|
contents: string | Record<string, any>;
|
|
177
|
-
search_results:
|
|
192
|
+
search_results: AnswerSearchResult[];
|
|
178
193
|
search_metadata: SearchMetadata;
|
|
179
194
|
ai_usage: AIUsage;
|
|
180
195
|
cost: Cost;
|
|
@@ -188,7 +203,7 @@ type AnswerResponse = AnswerSuccessResponse | AnswerErrorResponse;
|
|
|
188
203
|
type AnswerStreamChunkType = "search_results" | "content" | "metadata" | "done" | "error";
|
|
189
204
|
interface AnswerStreamChunk {
|
|
190
205
|
type: AnswerStreamChunkType;
|
|
191
|
-
search_results?:
|
|
206
|
+
search_results?: AnswerSearchResult[];
|
|
192
207
|
content?: string;
|
|
193
208
|
finish_reason?: string;
|
|
194
209
|
tx_id?: string;
|