tencentcloud-sdk-nodejs-es 4.1.47 → 4.1.52
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.
|
@@ -27,9 +27,6 @@ export class Client extends TencentCloudCommon.AbstractClient {
|
|
|
27
27
|
async ChunkDocument(req, cb) {
|
|
28
28
|
return this.request("ChunkDocument", req, cb);
|
|
29
29
|
}
|
|
30
|
-
async WebSearch(req, cb) {
|
|
31
|
-
return this.request("WebSearch", req, cb);
|
|
32
|
-
}
|
|
33
30
|
async RunRerank(req, cb) {
|
|
34
31
|
return this.request("RunRerank", req, cb);
|
|
35
32
|
}
|
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as TencentCloudCommon from "tencentcloud-sdk-nodejs-common";
|
|
2
|
-
import { ChatCompletionsRequest, ChunkDocumentAsyncRequest, ChunkDocumentRequest, GetDocumentChunkResultRequest, GetDocumentParseResultRequest, ParseDocumentResponse, GetTextEmbeddingRequest, ParseDocumentAsyncResponse, ChunkDocumentResponse, GetDocumentParseResultResponse, RunRerankRequest,
|
|
2
|
+
import { ChatCompletionsRequest, ChunkDocumentAsyncRequest, ChunkDocumentRequest, GetDocumentChunkResultRequest, GetDocumentParseResultRequest, ParseDocumentResponse, GetTextEmbeddingRequest, ParseDocumentAsyncResponse, ChunkDocumentResponse, GetDocumentParseResultResponse, RunRerankRequest, GetDocumentChunkResultResponse, ChunkDocumentAsyncResponse, ParseDocumentRequest, GetTextEmbeddingResponse, RunRerankResponse, ParseDocumentAsyncRequest, ChatCompletionsResponse } from "./es_models";
|
|
3
3
|
/**
|
|
4
4
|
* es client
|
|
5
5
|
* @class
|
|
@@ -44,10 +44,6 @@ export declare class Client extends TencentCloudCommon.AbstractClient {
|
|
|
44
44
|
本接口为分隔符规则切片接口,有单账号调用上限控制,如您有提高并发限制的需求请 [联系我们](https://cloud.tencent.com/act/event/Online_service) 。
|
|
45
45
|
*/
|
|
46
46
|
ChunkDocument(req: ChunkDocumentRequest, cb?: (error: string, rep: ChunkDocumentResponse) => void): Promise<ChunkDocumentResponse>;
|
|
47
|
-
/**
|
|
48
|
-
* WebSearch API 是一个网页搜索服务,支持多种搜索引擎,可以获取网页的标题、URL、摘要和正文内容。
|
|
49
|
-
*/
|
|
50
|
-
WebSearch(req: WebSearchRequest, cb?: (error: string, rep: WebSearchResponse) => void): Promise<WebSearchResponse>;
|
|
51
47
|
/**
|
|
52
48
|
* 重排是指在 RAG 过程中,通过评估文档与查询之间的相关性,将最相关的文档放在前面,确保语言模型在生成回答时优先考虑排名靠前的上下文,提高生成结果的准确性和可信度,也可以通过这种方式进行过滤,减少大模型成本。
|
|
53
49
|
本接口有单账号调用上限控制,如您有提高并发限制的需求请[联系我们](https://cloud.tencent.com/act/event/Online_service) 。
|
|
@@ -82,12 +82,6 @@ class Client extends TencentCloudCommon.AbstractClient {
|
|
|
82
82
|
async ChunkDocument(req, cb) {
|
|
83
83
|
return this.request("ChunkDocument", req, cb);
|
|
84
84
|
}
|
|
85
|
-
/**
|
|
86
|
-
* WebSearch API 是一个网页搜索服务,支持多种搜索引擎,可以获取网页的标题、URL、摘要和正文内容。
|
|
87
|
-
*/
|
|
88
|
-
async WebSearch(req, cb) {
|
|
89
|
-
return this.request("WebSearch", req, cb);
|
|
90
|
-
}
|
|
91
85
|
/**
|
|
92
86
|
* 重排是指在 RAG 过程中,通过评估文档与查询之间的相关性,将最相关的文档放在前面,确保语言模型在生成回答时优先考虑排名靠前的上下文,提高生成结果的准确性和可信度,也可以通过这种方式进行过滤,减少大模型成本。
|
|
93
87
|
本接口有单账号调用上限控制,如您有提高并发限制的需求请[联系我们](https://cloud.tencent.com/act/event/Online_service) 。
|
|
@@ -348,75 +348,6 @@ export interface ChunkConfig {
|
|
|
348
348
|
*/
|
|
349
349
|
Delimiters?: Array<string>;
|
|
350
350
|
}
|
|
351
|
-
/**
|
|
352
|
-
* WebSearch请求参数结构体
|
|
353
|
-
*/
|
|
354
|
-
export interface WebSearchRequest {
|
|
355
|
-
/**
|
|
356
|
-
* 查询
|
|
357
|
-
*/
|
|
358
|
-
Query: string;
|
|
359
|
-
/**
|
|
360
|
-
* 搜索的网页数量,默认20
|
|
361
|
-
*/
|
|
362
|
-
Count?: number;
|
|
363
|
-
/**
|
|
364
|
-
* 指定域名,gov.cn 可匹配 *.gov.cn的域名。
|
|
365
|
-
*/
|
|
366
|
-
Site?: string;
|
|
367
|
-
/**
|
|
368
|
-
* 是否获取返回网页全文,默认 false。
|
|
369
|
-
*/
|
|
370
|
-
FetchContent?: boolean;
|
|
371
|
-
/**
|
|
372
|
-
* 域名白名单,在不指定 Site 时,只保存匹配白名单域名的网页。
|
|
373
|
-
*/
|
|
374
|
-
WhiteSites?: Array<string>;
|
|
375
|
-
/**
|
|
376
|
-
* 域名黑名单,在不指定 Site 和白名单时,过滤黑名单中的域名。
|
|
377
|
-
*/
|
|
378
|
-
BlackSites?: Array<string>;
|
|
379
|
-
/**
|
|
380
|
-
* 秒级时间戳,搜索网页的开始时间,默认不限制开始时间。
|
|
381
|
-
*/
|
|
382
|
-
StartTime?: number;
|
|
383
|
-
/**
|
|
384
|
-
* 秒级时间戳,搜索网页的结束时间,默认为现在。
|
|
385
|
-
*/
|
|
386
|
-
EndTime?: number;
|
|
387
|
-
/**
|
|
388
|
-
* 指定搜索引擎,可选混合搜索 mixed,或 bing, baidu, sogou, 默认为 sogou
|
|
389
|
-
*/
|
|
390
|
-
SearchEngine?: string;
|
|
391
|
-
}
|
|
392
|
-
/**
|
|
393
|
-
* 网页搜索结果
|
|
394
|
-
*/
|
|
395
|
-
export interface WebPage {
|
|
396
|
-
/**
|
|
397
|
-
* 标题
|
|
398
|
-
*/
|
|
399
|
-
Title?: string;
|
|
400
|
-
/**
|
|
401
|
-
* url
|
|
402
|
-
*/
|
|
403
|
-
Url?: string;
|
|
404
|
-
/**
|
|
405
|
-
* 网页摘要
|
|
406
|
-
注意:此字段可能返回 null,表示取不到有效值。
|
|
407
|
-
*/
|
|
408
|
-
Summary?: string;
|
|
409
|
-
/**
|
|
410
|
-
* 网页收录时间。可能为空。
|
|
411
|
-
注意:此字段可能返回 null,表示取不到有效值。
|
|
412
|
-
*/
|
|
413
|
-
Time?: string;
|
|
414
|
-
/**
|
|
415
|
-
* Markdown 格式的网页正文
|
|
416
|
-
注意:此字段可能返回 null,表示取不到有效值。
|
|
417
|
-
*/
|
|
418
|
-
Content?: string;
|
|
419
|
-
}
|
|
420
351
|
/**
|
|
421
352
|
* 会话内容,按对话时间从旧到新在数组中排列,长度受模型窗口大小限制。
|
|
422
353
|
*/
|
|
@@ -492,31 +423,6 @@ export interface ChunkDocumentAsyncResponse {
|
|
|
492
423
|
*/
|
|
493
424
|
RequestId?: string;
|
|
494
425
|
}
|
|
495
|
-
/**
|
|
496
|
-
* WebSearch返回参数结构体
|
|
497
|
-
*/
|
|
498
|
-
export interface WebSearchResponse {
|
|
499
|
-
/**
|
|
500
|
-
* 查询
|
|
501
|
-
*/
|
|
502
|
-
Query?: string;
|
|
503
|
-
/**
|
|
504
|
-
* 响应状态
|
|
505
|
-
*/
|
|
506
|
-
Status?: string;
|
|
507
|
-
/**
|
|
508
|
-
* 执行搜索的引擎
|
|
509
|
-
*/
|
|
510
|
-
SearchEngine?: string;
|
|
511
|
-
/**
|
|
512
|
-
* 搜索结果
|
|
513
|
-
*/
|
|
514
|
-
Results?: Array<WebPage>;
|
|
515
|
-
/**
|
|
516
|
-
* 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
|
517
|
-
*/
|
|
518
|
-
RequestId?: string;
|
|
519
|
-
}
|
|
520
426
|
/**
|
|
521
427
|
* 联网搜索选项。
|
|
522
428
|
*/
|