@next-api-sdk/llm-sdk 1.3.0 → 1.4.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 (28) hide show
  1. package/README.md +0 -1
  2. package/contracts.json +155 -0
  3. package/dist/cjs/api/llm/agent_flow/createTaskForAgentFlow.js.map +1 -1
  4. package/dist/cjs/api/llm/agent_flow/index.js +22 -0
  5. package/dist/cjs/api/llm/agent_flow/index.js.map +1 -1
  6. package/dist/cjs/api/llm/agent_flow/searchTaskForAgentFlow.js +14 -0
  7. package/dist/cjs/api/llm/agent_flow/searchTaskForAgentFlow.js.map +1 -0
  8. package/dist/cjs/api/llm/agent_flow/updateStateForAgentFlow.js +14 -0
  9. package/dist/cjs/api/llm/agent_flow/updateStateForAgentFlow.js.map +1 -0
  10. package/dist/cjs/api/llm/aiops_tools/templateLlmChatV2.js +1 -1
  11. package/dist/cjs/api/llm/aiops_tools/templateLlmChatV2.js.map +1 -1
  12. package/dist/cjs/model/aiops_service/ModelLlmChatAgentTaskRequest.js.map +1 -1
  13. package/dist/esm/api/llm/agent_flow/createTaskForAgentFlow.js.map +1 -1
  14. package/dist/esm/api/llm/agent_flow/index.js +2 -0
  15. package/dist/esm/api/llm/agent_flow/index.js.map +1 -1
  16. package/dist/esm/api/llm/agent_flow/searchTaskForAgentFlow.js +7 -0
  17. package/dist/esm/api/llm/agent_flow/searchTaskForAgentFlow.js.map +1 -0
  18. package/dist/esm/api/llm/agent_flow/updateStateForAgentFlow.js +7 -0
  19. package/dist/esm/api/llm/agent_flow/updateStateForAgentFlow.js.map +1 -0
  20. package/dist/esm/api/llm/aiops_tools/templateLlmChatV2.js +1 -1
  21. package/dist/esm/api/llm/aiops_tools/templateLlmChatV2.js.map +1 -1
  22. package/dist/esm/model/aiops_service/ModelLlmChatAgentTaskRequest.js.map +1 -1
  23. package/dist/types/api/llm/agent_flow/createTaskForAgentFlow.d.ts +2 -0
  24. package/dist/types/api/llm/agent_flow/index.d.ts +2 -0
  25. package/dist/types/api/llm/agent_flow/searchTaskForAgentFlow.d.ts +34 -0
  26. package/dist/types/api/llm/agent_flow/updateStateForAgentFlow.d.ts +10 -0
  27. package/dist/types/model/aiops_service/ModelLlmChatAgentTaskRequest.d.ts +2 -0
  28. package/package.json +2 -2
package/README.md CHANGED
@@ -16,4 +16,3 @@ import * as LlmSdk from "@next-api-sdk/llm-sdk";
16
16
  ```
17
17
 
18
18
  [@next-core/create-api-sdk]: https://github.com/easyops-cn/next-core/tree/master/packages/create-api-sdk
19
-
package/contracts.json CHANGED
@@ -209,6 +209,11 @@
209
209
  "name": "agentId",
210
210
  "type": "string",
211
211
  "description": "指定处理任务的agent"
212
+ },
213
+ {
214
+ "name": "engineVersion",
215
+ "type": "string",
216
+ "description": "执行任务引擎的版本号"
212
217
  }
213
218
  ]
214
219
  },
@@ -308,6 +313,155 @@
308
313
  }
309
314
  ]
310
315
  },
316
+ {
317
+ "contract": "llm.agent_flow.SearchTaskForAgentFlow",
318
+ "name": "SearchTaskForAgentFlow",
319
+ "version": "1.0.0",
320
+ "description": "分页查询agent flow, 默认只查询最近三个页的数据",
321
+ "endpoint": {
322
+ "method": "POST",
323
+ "uri": "/api/v1/llm/agent/flow/search"
324
+ },
325
+ "request": {
326
+ "type": "object",
327
+ "fields": [
328
+ {
329
+ "name": "query",
330
+ "type": "string",
331
+ "description": "对标题进行关键字搜索"
332
+ },
333
+ {
334
+ "name": "limit",
335
+ "type": "int",
336
+ "description": "数据数量大小限制, 默认30"
337
+ },
338
+ {
339
+ "name": "next_token",
340
+ "type": "string",
341
+ "description": "分页token,字符串;向上翻页或向下翻页的token都在这个参数传入。"
342
+ }
343
+ ]
344
+ },
345
+ "response": {
346
+ "type": "object",
347
+ "fields": [
348
+ {
349
+ "name": "next_token",
350
+ "type": "string",
351
+ "description": "下一页,查询的token,为空时,没有下一页"
352
+ },
353
+ {
354
+ "name": "previous_token",
355
+ "type": "string",
356
+ "description": "上一页,查询的token,为空时,没有上一页"
357
+ },
358
+ {
359
+ "name": "data",
360
+ "type": "object[]",
361
+ "description": "任务列表",
362
+ "fields": [
363
+ {
364
+ "name": "id",
365
+ "type": "string",
366
+ "description": "任务id"
367
+ },
368
+ {
369
+ "name": "startTime",
370
+ "type": "int",
371
+ "description": "创建时间戳,单位秒"
372
+ },
373
+ {
374
+ "name": "endTime",
375
+ "type": "int",
376
+ "description": "结束时间戳,单位秒"
377
+ },
378
+ {
379
+ "name": "state",
380
+ "type": "string",
381
+ "description": "任务状态,\"submitted\", \"working\", \"input-required\",\"completed\",\"canceled\",\"failed\", \"unknown\""
382
+ },
383
+ {
384
+ "name": "title",
385
+ "type": "string",
386
+ "description": "标题"
387
+ }
388
+ ]
389
+ }
390
+ ]
391
+ },
392
+ "examples": [
393
+ {
394
+ "description": {
395
+ "en": "search task of flow agent",
396
+ "zh": "分页查询agent flow任务数据"
397
+ },
398
+ "request": {
399
+ "method": "POST",
400
+ "uri": "/api/v1/llm/agent/flow/search",
401
+ "headers": {
402
+ "Content-Type": "application/json"
403
+ },
404
+ "body": "{\n\t\"query\": \"测试标题\",\n \"limit\": 1\n}"
405
+ },
406
+ "response": {
407
+ "headers": {
408
+ "Content-Type": "application/json; charset=utf-8"
409
+ },
410
+ "body": "{\n \"code\": 0,\n \"codeExplain\": \"\",\n \"error\": \"\",\n \"data\": {\n \"next_token\": \"xxxxxxx\",\n \"previous_token\": \"\",\n \"data\": [\n {\n \"title\": \"录入应用系统\",\n \"startTime\": 1747106187.0,\n \"_row_id\": \"00000196c7a4c973af2e063afadd7f7b\",\n \"status\": \"completed\",\n \"endTime\": 1747106535.0\n }\n ]\n }\n}"
411
+ }
412
+ }
413
+ ]
414
+ },
415
+ {
416
+ "contract": "llm.agent_flow.UpdateStateForAgentFlow",
417
+ "name": "UpdateStateForAgentFlow",
418
+ "version": "1.0.0",
419
+ "description": "flow agent更新任务状态,支持暂停、停止和重启任务",
420
+ "endpoint": {
421
+ "method": "POST",
422
+ "uri": "/api/v1/llm/agent/flow/:taskId/updateState"
423
+ },
424
+ "request": {
425
+ "type": "object",
426
+ "fields": [
427
+ {
428
+ "name": "taskId",
429
+ "type": "string",
430
+ "description": "总任务id"
431
+ },
432
+ {
433
+ "name": "state",
434
+ "type": "string",
435
+ "description": "调整任务状态,可以设置为 stopped, paused, working(paused的任务状态时,可以继续)"
436
+ }
437
+ ]
438
+ },
439
+ "response": null,
440
+ "examples": [
441
+ {
442
+ "description": {
443
+ "zh": "flow agent更新任务状态,支持暂停、停止和重启任务"
444
+ },
445
+ "request": {
446
+ "method": "POST",
447
+ "uri": "http://ip:port/api/v1/llm/agent/8239375684858666781/updateState",
448
+ "headers": {
449
+ "Content-Type": "application/json",
450
+ "user": "linus",
451
+ "org": 1234
452
+ },
453
+ "body": "{\n \"state\": \"stopped\"\n}"
454
+ },
455
+ "response": {
456
+ "headers": {
457
+ "Content-Type": "application/json; charset=utf-8"
458
+ },
459
+ "status_code": 200,
460
+ "body": "{\n \"code\": 0,\n \"codeExplain\": \"\",\n \"error\": \"\"\n}"
461
+ }
462
+ }
463
+ ]
464
+ },
311
465
  {
312
466
  "contract": "llm.aiops_base.DeleteEmbedding",
313
467
  "name": "DeleteEmbedding",
@@ -3521,6 +3675,7 @@
3521
3675
  },
3522
3676
  "response": {
3523
3677
  "default": {},
3678
+ "wrapper": false,
3524
3679
  "fields": [
3525
3680
  {
3526
3681
  "ref": "LlmChatAgentTaskResponse.*"
@@ -1 +1 @@
1
- {"version":3,"file":"createTaskForAgentFlow.js","names":["_http","require","AgentFlowApi_createTaskForAgentFlow","data","options","http","post","exports"],"sources":["../../../../../src/api/llm/agent_flow/createTaskForAgentFlow.ts"],"sourcesContent":["import { http, HttpOptions } from \"@next-core/http\";\nimport { ResponseBodyWrapper } from \"../../../wrapper.js\";\n\nexport interface AgentFlowApi_CreateTaskForAgentFlowRequestBody {\n /** 用户输入 */\n input?: string;\n\n /** 指定处理任务的agent */\n agentId?: string;\n}\n\nexport interface AgentFlowApi_CreateTaskForAgentFlowResponseBody {\n /** 任务id */\n taskId?: string;\n}\n\n/**\n * @description 创建agent flow的任务\n * @endpoint POST /api/v1/llm/agent/flow/create\n */\nexport const AgentFlowApi_createTaskForAgentFlow = async (\n data: AgentFlowApi_CreateTaskForAgentFlowRequestBody,\n options?: HttpOptions\n): Promise<AgentFlowApi_CreateTaskForAgentFlowResponseBody> =>\n /**! @contract easyops.api.llm.agent_flow.CreateTaskForAgentFlow@1.0.0 */ (\n await http.post<\n ResponseBodyWrapper<AgentFlowApi_CreateTaskForAgentFlowResponseBody>\n >(\n \"api/gateway/logic.llm.aiops_service/api/v1/llm/agent/flow/create\",\n data,\n options\n )\n ).data;\n"],"mappings":";;;;;;AAAA,IAAAA,KAAA,GAAAC,OAAA;AAgBA;AACA;AACA;AACA;AACO,MAAMC,mCAAmC,GAAG,MAAAA,CACjDC,IAAoD,EACpDC,OAAqB,KAErB,yEAA0E,CACxE,MAAMC,UAAI,CAACC,IAAI,CAGb,kEAAkE,EAClEH,IAAI,EACJC,OACF,CAAC,EACDD,IAAI;AAACI,OAAA,CAAAL,mCAAA,GAAAA,mCAAA","ignoreList":[]}
1
+ {"version":3,"file":"createTaskForAgentFlow.js","names":["_http","require","AgentFlowApi_createTaskForAgentFlow","data","options","http","post","exports"],"sources":["../../../../../src/api/llm/agent_flow/createTaskForAgentFlow.ts"],"sourcesContent":["import { http, HttpOptions } from \"@next-core/http\";\nimport { ResponseBodyWrapper } from \"../../../wrapper.js\";\n\nexport interface AgentFlowApi_CreateTaskForAgentFlowRequestBody {\n /** 用户输入 */\n input?: string;\n\n /** 指定处理任务的agent */\n agentId?: string;\n\n /** 执行任务引擎的版本号 */\n engineVersion?: string;\n}\n\nexport interface AgentFlowApi_CreateTaskForAgentFlowResponseBody {\n /** 任务id */\n taskId?: string;\n}\n\n/**\n * @description 创建agent flow的任务\n * @endpoint POST /api/v1/llm/agent/flow/create\n */\nexport const AgentFlowApi_createTaskForAgentFlow = async (\n data: AgentFlowApi_CreateTaskForAgentFlowRequestBody,\n options?: HttpOptions\n): Promise<AgentFlowApi_CreateTaskForAgentFlowResponseBody> =>\n /**! @contract easyops.api.llm.agent_flow.CreateTaskForAgentFlow@1.0.0 */ (\n await http.post<\n ResponseBodyWrapper<AgentFlowApi_CreateTaskForAgentFlowResponseBody>\n >(\n \"api/gateway/logic.llm.aiops_service/api/v1/llm/agent/flow/create\",\n data,\n options\n )\n ).data;\n"],"mappings":";;;;;;AAAA,IAAAA,KAAA,GAAAC,OAAA;AAmBA;AACA;AACA;AACA;AACO,MAAMC,mCAAmC,GAAG,MAAAA,CACjDC,IAAoD,EACpDC,OAAqB,KAErB,yEAA0E,CACxE,MAAMC,UAAI,CAACC,IAAI,CAGb,kEAAkE,EAClEH,IAAI,EACJC,OACF,CAAC,EACDD,IAAI;AAACI,OAAA,CAAAL,mCAAA,GAAAA,mCAAA","ignoreList":[]}
@@ -36,4 +36,26 @@ Object.keys(_getTaskDetailForAgentFlow).forEach(function (key) {
36
36
  }
37
37
  });
38
38
  });
39
+ var _searchTaskForAgentFlow = require("./searchTaskForAgentFlow.js");
40
+ Object.keys(_searchTaskForAgentFlow).forEach(function (key) {
41
+ if (key === "default" || key === "__esModule") return;
42
+ if (key in exports && exports[key] === _searchTaskForAgentFlow[key]) return;
43
+ Object.defineProperty(exports, key, {
44
+ enumerable: true,
45
+ get: function () {
46
+ return _searchTaskForAgentFlow[key];
47
+ }
48
+ });
49
+ });
50
+ var _updateStateForAgentFlow = require("./updateStateForAgentFlow.js");
51
+ Object.keys(_updateStateForAgentFlow).forEach(function (key) {
52
+ if (key === "default" || key === "__esModule") return;
53
+ if (key in exports && exports[key] === _updateStateForAgentFlow[key]) return;
54
+ Object.defineProperty(exports, key, {
55
+ enumerable: true,
56
+ get: function () {
57
+ return _updateStateForAgentFlow[key];
58
+ }
59
+ });
60
+ });
39
61
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["_addJobMessageForAgentFlow","require","Object","keys","forEach","key","exports","defineProperty","enumerable","get","_createTaskForAgentFlow","_getTaskDetailForAgentFlow"],"sources":["../../../../../src/api/llm/agent_flow/index.ts"],"sourcesContent":["export * from \"./addJobMessageForAgentFlow.js\";\nexport * from \"./createTaskForAgentFlow.js\";\nexport * from \"./getTaskDetailForAgentFlow.js\";\n"],"mappings":";;;;;AAAA,IAAAA,0BAAA,GAAAC,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAH,0BAAA,EAAAI,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAL,0BAAA,CAAAK,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAT,0BAAA,CAAAK,GAAA;IAAA;EAAA;AAAA;AACA,IAAAK,uBAAA,GAAAT,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAO,uBAAA,EAAAN,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAK,uBAAA,CAAAL,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAC,uBAAA,CAAAL,GAAA;IAAA;EAAA;AAAA;AACA,IAAAM,0BAAA,GAAAV,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAQ,0BAAA,EAAAP,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAM,0BAAA,CAAAN,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAE,0BAAA,CAAAN,GAAA;IAAA;EAAA;AAAA","ignoreList":[]}
1
+ {"version":3,"file":"index.js","names":["_addJobMessageForAgentFlow","require","Object","keys","forEach","key","exports","defineProperty","enumerable","get","_createTaskForAgentFlow","_getTaskDetailForAgentFlow","_searchTaskForAgentFlow","_updateStateForAgentFlow"],"sources":["../../../../../src/api/llm/agent_flow/index.ts"],"sourcesContent":["export * from \"./addJobMessageForAgentFlow.js\";\nexport * from \"./createTaskForAgentFlow.js\";\nexport * from \"./getTaskDetailForAgentFlow.js\";\nexport * from \"./searchTaskForAgentFlow.js\";\nexport * from \"./updateStateForAgentFlow.js\";\n"],"mappings":";;;;;AAAA,IAAAA,0BAAA,GAAAC,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAH,0BAAA,EAAAI,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAL,0BAAA,CAAAK,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAT,0BAAA,CAAAK,GAAA;IAAA;EAAA;AAAA;AACA,IAAAK,uBAAA,GAAAT,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAO,uBAAA,EAAAN,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAK,uBAAA,CAAAL,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAC,uBAAA,CAAAL,GAAA;IAAA;EAAA;AAAA;AACA,IAAAM,0BAAA,GAAAV,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAQ,0BAAA,EAAAP,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAM,0BAAA,CAAAN,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAE,0BAAA,CAAAN,GAAA;IAAA;EAAA;AAAA;AACA,IAAAO,uBAAA,GAAAX,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAS,uBAAA,EAAAR,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAO,uBAAA,CAAAP,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAG,uBAAA,CAAAP,GAAA;IAAA;EAAA;AAAA;AACA,IAAAQ,wBAAA,GAAAZ,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAU,wBAAA,EAAAT,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAQ,wBAAA,CAAAR,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAI,wBAAA,CAAAR,GAAA;IAAA;EAAA;AAAA","ignoreList":[]}
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.AgentFlowApi_searchTaskForAgentFlow = void 0;
7
+ var _http = require("@next-core/http");
8
+ /**
9
+ * @description 分页查询agent flow, 默认只查询最近三个页的数据
10
+ * @endpoint POST /api/v1/llm/agent/flow/search
11
+ */
12
+ const AgentFlowApi_searchTaskForAgentFlow = async (data, options) => /**! @contract easyops.api.llm.agent_flow.SearchTaskForAgentFlow@1.0.0 */(await _http.http.post("api/gateway/logic.llm.aiops_service/api/v1/llm/agent/flow/search", data, options)).data;
13
+ exports.AgentFlowApi_searchTaskForAgentFlow = AgentFlowApi_searchTaskForAgentFlow;
14
+ //# sourceMappingURL=searchTaskForAgentFlow.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"searchTaskForAgentFlow.js","names":["_http","require","AgentFlowApi_searchTaskForAgentFlow","data","options","http","post","exports"],"sources":["../../../../../src/api/llm/agent_flow/searchTaskForAgentFlow.ts"],"sourcesContent":["import { http, HttpOptions } from \"@next-core/http\";\nimport { ResponseBodyWrapper } from \"../../../wrapper.js\";\n\nexport interface AgentFlowApi_SearchTaskForAgentFlowRequestBody {\n /** 对标题进行关键字搜索 */\n query?: string;\n\n /** 数据数量大小限制, 默认30 */\n limit?: number;\n\n /** 分页token,字符串;向上翻页或向下翻页的token都在这个参数传入。 */\n next_token?: string;\n}\n\nexport interface AgentFlowApi_SearchTaskForAgentFlowResponseBody {\n /** 下一页,查询的token,为空时,没有下一页 */\n next_token?: string;\n\n /** 上一页,查询的token,为空时,没有上一页 */\n previous_token?: string;\n\n /** 任务列表 */\n data?: AgentFlowApi_SearchTaskForAgentFlowResponseBody_data_item[];\n}\n\n/**\n * @description 分页查询agent flow, 默认只查询最近三个页的数据\n * @endpoint POST /api/v1/llm/agent/flow/search\n */\nexport const AgentFlowApi_searchTaskForAgentFlow = async (\n data: AgentFlowApi_SearchTaskForAgentFlowRequestBody,\n options?: HttpOptions\n): Promise<AgentFlowApi_SearchTaskForAgentFlowResponseBody> =>\n /**! @contract easyops.api.llm.agent_flow.SearchTaskForAgentFlow@1.0.0 */ (\n await http.post<\n ResponseBodyWrapper<AgentFlowApi_SearchTaskForAgentFlowResponseBody>\n >(\n \"api/gateway/logic.llm.aiops_service/api/v1/llm/agent/flow/search\",\n data,\n options\n )\n ).data;\n\nexport interface AgentFlowApi_SearchTaskForAgentFlowResponseBody_data_item {\n /** 任务id */\n id?: string;\n\n /** 创建时间戳,单位秒 */\n startTime?: number;\n\n /** 结束时间戳,单位秒 */\n endTime?: number;\n\n /** 任务状态,\"submitted\", \"working\", \"input-required\",\"completed\",\"canceled\",\"failed\", \"unknown\" */\n state?: string;\n\n /** 标题 */\n title?: string;\n}\n"],"mappings":";;;;;;AAAA,IAAAA,KAAA,GAAAC,OAAA;AAyBA;AACA;AACA;AACA;AACO,MAAMC,mCAAmC,GAAG,MAAAA,CACjDC,IAAoD,EACpDC,OAAqB,KAErB,yEAA0E,CACxE,MAAMC,UAAI,CAACC,IAAI,CAGb,kEAAkE,EAClEH,IAAI,EACJC,OACF,CAAC,EACDD,IAAI;AAACI,OAAA,CAAAL,mCAAA,GAAAA,mCAAA","ignoreList":[]}
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.AgentFlowApi_updateStateForAgentFlow = void 0;
7
+ var _http = require("@next-core/http");
8
+ /**
9
+ * @description flow agent更新任务状态,支持暂停、停止和重启任务
10
+ * @endpoint POST /api/v1/llm/agent/flow/:taskId/updateState
11
+ */
12
+ const AgentFlowApi_updateStateForAgentFlow = (taskId, data, options) => /**! @contract easyops.api.llm.agent_flow.UpdateStateForAgentFlow@1.0.0 */_http.http.post(`api/gateway/logic.llm.aiops_service/api/v1/llm/agent/flow/${taskId}/updateState`, data, options);
13
+ exports.AgentFlowApi_updateStateForAgentFlow = AgentFlowApi_updateStateForAgentFlow;
14
+ //# sourceMappingURL=updateStateForAgentFlow.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"updateStateForAgentFlow.js","names":["_http","require","AgentFlowApi_updateStateForAgentFlow","taskId","data","options","http","post","exports"],"sources":["../../../../../src/api/llm/agent_flow/updateStateForAgentFlow.ts"],"sourcesContent":["import { http, HttpOptions } from \"@next-core/http\";\n\nexport interface AgentFlowApi_UpdateStateForAgentFlowRequestBody {\n /** 调整任务状态,可以设置为 stopped, paused, working(paused的任务状态时,可以继续) */\n state?: string;\n}\n\n/**\n * @description flow agent更新任务状态,支持暂停、停止和重启任务\n * @endpoint POST /api/v1/llm/agent/flow/:taskId/updateState\n */\nexport const AgentFlowApi_updateStateForAgentFlow = (\n taskId: string | number,\n data: AgentFlowApi_UpdateStateForAgentFlowRequestBody,\n options?: HttpOptions\n): Promise<void> =>\n /**! @contract easyops.api.llm.agent_flow.UpdateStateForAgentFlow@1.0.0 */ http.post<void>(\n `api/gateway/logic.llm.aiops_service/api/v1/llm/agent/flow/${taskId}/updateState`,\n data,\n options\n );\n"],"mappings":";;;;;;AAAA,IAAAA,KAAA,GAAAC,OAAA;AAOA;AACA;AACA;AACA;AACO,MAAMC,oCAAoC,GAAGA,CAClDC,MAAuB,EACvBC,IAAqD,EACrDC,OAAqB,KAErB,0EAA2EC,UAAI,CAACC,IAAI,CAClF,6DAA6DJ,MAAM,cAAc,EACjFC,IAAI,EACJC,OACF,CAAC;AAACG,OAAA,CAAAN,oCAAA,GAAAA,oCAAA","ignoreList":[]}
@@ -9,6 +9,6 @@ var _http = require("@next-core/http");
9
9
  * @description 根据模板与大模型对话,返回json
10
10
  * @endpoint POST /api/v1/llm/tools/template_llm_chat_v2
11
11
  */
12
- const AiopsToolsApi_templateLlmChatV2 = async (data, options) => /**! @contract easyops.api.llm.aiops_tools.TemplateLlmChatV2@1.0.0 */(await _http.http.post("api/gateway/logic.llm.aiops_service/api/v1/llm/tools/template_llm_chat_v2", data, options)).data;
12
+ const AiopsToolsApi_templateLlmChatV2 = (data, options) => /**! @contract easyops.api.llm.aiops_tools.TemplateLlmChatV2@1.0.0 */_http.http.post("api/gateway/logic.llm.aiops_service/api/v1/llm/tools/template_llm_chat_v2", data, options);
13
13
  exports.AiopsToolsApi_templateLlmChatV2 = AiopsToolsApi_templateLlmChatV2;
14
14
  //# sourceMappingURL=templateLlmChatV2.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"templateLlmChatV2.js","names":["_http","require","AiopsToolsApi_templateLlmChatV2","data","options","http","post","exports"],"sources":["../../../../../src/api/llm/aiops_tools/templateLlmChatV2.ts"],"sourcesContent":["import { http, HttpOptions } from \"@next-core/http\";\nimport {\n ModelLlmChatAgentTaskResponse,\n ModelLlmChatMessage,\n} from \"../../../model/aiops_service/index.js\";\nimport { ResponseBodyWrapper } from \"../../../wrapper.js\";\n\nexport interface AiopsToolsApi_TemplateLlmChatV2RequestBody {\n /** 模板,为空时,不使用默认引擎 */\n template?: string;\n\n /** 模板引擎的数据 */\n variables?: Record<string, any>;\n\n /** 大模型id */\n model?: string;\n\n /** 历史对话消息 */\n historyMessages?: Partial<ModelLlmChatMessage>[];\n\n /** 输入对话,模板为空时才生效 */\n input?: string;\n\n /** 输出格式,默认json */\n outputType?: string;\n\n /** 取值范围是:(0.0, 1.0],不能等于 0,默认值为 0.1,值越大,会使输出更随机,更具创造性;值越小,输出会更加稳定或确定 */\n temperature?: number;\n\n /** 是否是调试模式,为true时,返回debug_resp */\n debug?: boolean;\n\n /** 是否是流式 */\n stream?: boolean;\n\n /** system角色的提示词模板 */\n systemTemplate?: string;\n\n /** system模板所需要的数据 */\n systemVariables?: Record<string, any>;\n\n /** 任务id */\n taskId?: string;\n\n /** 输入的图片url */\n images?: string[];\n}\n\nexport type AiopsToolsApi_TemplateLlmChatV2ResponseBody =\n Partial<ModelLlmChatAgentTaskResponse> &\n AiopsToolsApi_TemplateLlmChatV2ResponseBody_2;\n\n/**\n * @description 根据模板与大模型对话,返回json\n * @endpoint POST /api/v1/llm/tools/template_llm_chat_v2\n */\nexport const AiopsToolsApi_templateLlmChatV2 = async (\n data: AiopsToolsApi_TemplateLlmChatV2RequestBody,\n options?: HttpOptions\n): Promise<AiopsToolsApi_TemplateLlmChatV2ResponseBody> =>\n /**! @contract easyops.api.llm.aiops_tools.TemplateLlmChatV2@1.0.0 */ (\n await http.post<\n ResponseBodyWrapper<AiopsToolsApi_TemplateLlmChatV2ResponseBody>\n >(\n \"api/gateway/logic.llm.aiops_service/api/v1/llm/tools/template_llm_chat_v2\",\n data,\n options\n )\n ).data;\n\nexport interface AiopsToolsApi_TemplateLlmChatV2ResponseBody_2 {\n /** 提取返回的数据 */\n data?: any;\n\n /** 调试时大模型返回值 */\n debug_resp?: string;\n\n /** 如果解析不到正确的数据格式,则将大模型返回的数据塞到这里 */\n errorOutput?: string;\n}\n"],"mappings":";;;;;;AAAA,IAAAA,KAAA,GAAAC,OAAA;AAoDA;AACA;AACA;AACA;AACO,MAAMC,+BAA+B,GAAG,MAAAA,CAC7CC,IAAgD,EAChDC,OAAqB,KAErB,qEAAsE,CACpE,MAAMC,UAAI,CAACC,IAAI,CAGb,2EAA2E,EAC3EH,IAAI,EACJC,OACF,CAAC,EACDD,IAAI;AAACI,OAAA,CAAAL,+BAAA,GAAAA,+BAAA","ignoreList":[]}
1
+ {"version":3,"file":"templateLlmChatV2.js","names":["_http","require","AiopsToolsApi_templateLlmChatV2","data","options","http","post","exports"],"sources":["../../../../../src/api/llm/aiops_tools/templateLlmChatV2.ts"],"sourcesContent":["import { http, HttpOptions } from \"@next-core/http\";\nimport {\n ModelLlmChatAgentTaskResponse,\n ModelLlmChatMessage,\n} from \"../../../model/aiops_service/index.js\";\n\nexport interface AiopsToolsApi_TemplateLlmChatV2RequestBody {\n /** 模板,为空时,不使用默认引擎 */\n template?: string;\n\n /** 模板引擎的数据 */\n variables?: Record<string, any>;\n\n /** 大模型id */\n model?: string;\n\n /** 历史对话消息 */\n historyMessages?: Partial<ModelLlmChatMessage>[];\n\n /** 输入对话,模板为空时才生效 */\n input?: string;\n\n /** 输出格式,默认json */\n outputType?: string;\n\n /** 取值范围是:(0.0, 1.0],不能等于 0,默认值为 0.1,值越大,会使输出更随机,更具创造性;值越小,输出会更加稳定或确定 */\n temperature?: number;\n\n /** 是否是调试模式,为true时,返回debug_resp */\n debug?: boolean;\n\n /** 是否是流式 */\n stream?: boolean;\n\n /** system角色的提示词模板 */\n systemTemplate?: string;\n\n /** system模板所需要的数据 */\n systemVariables?: Record<string, any>;\n\n /** 任务id */\n taskId?: string;\n\n /** 输入的图片url */\n images?: string[];\n}\n\nexport type AiopsToolsApi_TemplateLlmChatV2ResponseBody =\n Partial<ModelLlmChatAgentTaskResponse> &\n AiopsToolsApi_TemplateLlmChatV2ResponseBody_2;\n\n/**\n * @description 根据模板与大模型对话,返回json\n * @endpoint POST /api/v1/llm/tools/template_llm_chat_v2\n */\nexport const AiopsToolsApi_templateLlmChatV2 = (\n data: AiopsToolsApi_TemplateLlmChatV2RequestBody,\n options?: HttpOptions\n): Promise<AiopsToolsApi_TemplateLlmChatV2ResponseBody> =>\n /**! @contract easyops.api.llm.aiops_tools.TemplateLlmChatV2@1.0.0 */ http.post<AiopsToolsApi_TemplateLlmChatV2ResponseBody>(\n \"api/gateway/logic.llm.aiops_service/api/v1/llm/tools/template_llm_chat_v2\",\n data,\n options\n );\n\nexport interface AiopsToolsApi_TemplateLlmChatV2ResponseBody_2 {\n /** 提取返回的数据 */\n data?: any;\n\n /** 调试时大模型返回值 */\n debug_resp?: string;\n\n /** 如果解析不到正确的数据格式,则将大模型返回的数据塞到这里 */\n errorOutput?: string;\n}\n"],"mappings":";;;;;;AAAA,IAAAA,KAAA,GAAAC,OAAA;AAmDA;AACA;AACA;AACA;AACO,MAAMC,+BAA+B,GAAGA,CAC7CC,IAAgD,EAChDC,OAAqB,KAErB,qEAAsEC,UAAI,CAACC,IAAI,CAC7E,2EAA2E,EAC3EH,IAAI,EACJC,OACF,CAAC;AAACG,OAAA,CAAAL,+BAAA,GAAAA,+BAAA","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"ModelLlmChatAgentTaskRequest.js","names":[],"sources":["../../../../src/model/aiops_service/ModelLlmChatAgentTaskRequest.ts"],"sourcesContent":["import { ModelLlmChatMessage } from \"./index.js\";\n\n/** 聊天机器人,处理agent任务的请求 */\nexport interface ModelLlmChatAgentTaskRequest {\n /** 任务需求 */\n input: string;\n\n /** 图片的url,支持多个图片 */\n images: string[];\n\n /** 任务配置 */\n config: Record<string, any>;\n\n /** 当前任务上下文的id */\n conversationId: string;\n\n /** 在多agent场景,指定使用哪个agent */\n agentId: string;\n\n /** 当前任务Id */\n taskId: string;\n\n /** 已经提取的表单数据 */\n formData: any;\n\n /** 助手id */\n robotId: string;\n\n /** 是否流式返回 */\n stream: boolean;\n\n /** 历史会话消息,适用支持多轮会话的agent */\n historyMessages: Partial<ModelLlmChatMessage>[];\n\n /** 流式数据列表(占位符,防止flow builder自动清理流式返回的数据) */\n sseDataList: any[];\n}\n"],"mappings":"","ignoreList":[]}
1
+ {"version":3,"file":"ModelLlmChatAgentTaskRequest.js","names":[],"sources":["../../../../src/model/aiops_service/ModelLlmChatAgentTaskRequest.ts"],"sourcesContent":["import { ModelLlmChatMessage } from \"./index.js\";\n\n/** 聊天机器人,处理agent任务的请求 */\nexport interface ModelLlmChatAgentTaskRequest {\n /** 任务需求 */\n input: string;\n\n /** 大模型的Temperature, 值范围0.0~1.0 */\n temperature: number;\n\n /** 图片的url,支持多个图片 */\n images: string[];\n\n /** 任务配置 */\n config: Record<string, any>;\n\n /** 当前任务上下文的id */\n conversationId: string;\n\n /** 在多agent场景,指定使用哪个agent */\n agentId: string;\n\n /** 当前任务Id */\n taskId: string;\n\n /** 已经提取的表单数据 */\n formData: any;\n\n /** 助手id */\n robotId: string;\n\n /** 是否流式返回 */\n stream: boolean;\n\n /** 历史会话消息,适用支持多轮会话的agent */\n historyMessages: Partial<ModelLlmChatMessage>[];\n\n /** 流式数据列表(占位符,防止flow builder自动清理流式返回的数据) */\n sseDataList: any[];\n}\n"],"mappings":"","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"createTaskForAgentFlow.js","names":["http","AgentFlowApi_createTaskForAgentFlow","data","options","post"],"sources":["../../../../../src/api/llm/agent_flow/createTaskForAgentFlow.ts"],"sourcesContent":["import { http, HttpOptions } from \"@next-core/http\";\nimport { ResponseBodyWrapper } from \"../../../wrapper.js\";\n\nexport interface AgentFlowApi_CreateTaskForAgentFlowRequestBody {\n /** 用户输入 */\n input?: string;\n\n /** 指定处理任务的agent */\n agentId?: string;\n}\n\nexport interface AgentFlowApi_CreateTaskForAgentFlowResponseBody {\n /** 任务id */\n taskId?: string;\n}\n\n/**\n * @description 创建agent flow的任务\n * @endpoint POST /api/v1/llm/agent/flow/create\n */\nexport const AgentFlowApi_createTaskForAgentFlow = async (\n data: AgentFlowApi_CreateTaskForAgentFlowRequestBody,\n options?: HttpOptions\n): Promise<AgentFlowApi_CreateTaskForAgentFlowResponseBody> =>\n /**! @contract easyops.api.llm.agent_flow.CreateTaskForAgentFlow@1.0.0 */ (\n await http.post<\n ResponseBodyWrapper<AgentFlowApi_CreateTaskForAgentFlowResponseBody>\n >(\n \"api/gateway/logic.llm.aiops_service/api/v1/llm/agent/flow/create\",\n data,\n options\n )\n ).data;\n"],"mappings":"AAAA,SAASA,IAAI,QAAqB,iBAAiB;AAgBnD;AACA;AACA;AACA;AACA,OAAO,MAAMC,mCAAmC,GAAG,MAAAA,CACjDC,IAAoD,EACpDC,OAAqB,KAErB,yEAA0E,CACxE,MAAMH,IAAI,CAACI,IAAI,CAGb,kEAAkE,EAClEF,IAAI,EACJC,OACF,CAAC,EACDD,IAAI","ignoreList":[]}
1
+ {"version":3,"file":"createTaskForAgentFlow.js","names":["http","AgentFlowApi_createTaskForAgentFlow","data","options","post"],"sources":["../../../../../src/api/llm/agent_flow/createTaskForAgentFlow.ts"],"sourcesContent":["import { http, HttpOptions } from \"@next-core/http\";\nimport { ResponseBodyWrapper } from \"../../../wrapper.js\";\n\nexport interface AgentFlowApi_CreateTaskForAgentFlowRequestBody {\n /** 用户输入 */\n input?: string;\n\n /** 指定处理任务的agent */\n agentId?: string;\n\n /** 执行任务引擎的版本号 */\n engineVersion?: string;\n}\n\nexport interface AgentFlowApi_CreateTaskForAgentFlowResponseBody {\n /** 任务id */\n taskId?: string;\n}\n\n/**\n * @description 创建agent flow的任务\n * @endpoint POST /api/v1/llm/agent/flow/create\n */\nexport const AgentFlowApi_createTaskForAgentFlow = async (\n data: AgentFlowApi_CreateTaskForAgentFlowRequestBody,\n options?: HttpOptions\n): Promise<AgentFlowApi_CreateTaskForAgentFlowResponseBody> =>\n /**! @contract easyops.api.llm.agent_flow.CreateTaskForAgentFlow@1.0.0 */ (\n await http.post<\n ResponseBodyWrapper<AgentFlowApi_CreateTaskForAgentFlowResponseBody>\n >(\n \"api/gateway/logic.llm.aiops_service/api/v1/llm/agent/flow/create\",\n data,\n options\n )\n ).data;\n"],"mappings":"AAAA,SAASA,IAAI,QAAqB,iBAAiB;AAmBnD;AACA;AACA;AACA;AACA,OAAO,MAAMC,mCAAmC,GAAG,MAAAA,CACjDC,IAAoD,EACpDC,OAAqB,KAErB,yEAA0E,CACxE,MAAMH,IAAI,CAACI,IAAI,CAGb,kEAAkE,EAClEF,IAAI,EACJC,OACF,CAAC,EACDD,IAAI","ignoreList":[]}
@@ -1,4 +1,6 @@
1
1
  export * from "./addJobMessageForAgentFlow.js";
2
2
  export * from "./createTaskForAgentFlow.js";
3
3
  export * from "./getTaskDetailForAgentFlow.js";
4
+ export * from "./searchTaskForAgentFlow.js";
5
+ export * from "./updateStateForAgentFlow.js";
4
6
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["../../../../../src/api/llm/agent_flow/index.ts"],"sourcesContent":["export * from \"./addJobMessageForAgentFlow.js\";\nexport * from \"./createTaskForAgentFlow.js\";\nexport * from \"./getTaskDetailForAgentFlow.js\";\n"],"mappings":"AAAA,cAAc,gCAAgC;AAC9C,cAAc,6BAA6B;AAC3C,cAAc,gCAAgC","ignoreList":[]}
1
+ {"version":3,"file":"index.js","names":[],"sources":["../../../../../src/api/llm/agent_flow/index.ts"],"sourcesContent":["export * from \"./addJobMessageForAgentFlow.js\";\nexport * from \"./createTaskForAgentFlow.js\";\nexport * from \"./getTaskDetailForAgentFlow.js\";\nexport * from \"./searchTaskForAgentFlow.js\";\nexport * from \"./updateStateForAgentFlow.js\";\n"],"mappings":"AAAA,cAAc,gCAAgC;AAC9C,cAAc,6BAA6B;AAC3C,cAAc,gCAAgC;AAC9C,cAAc,6BAA6B;AAC3C,cAAc,8BAA8B","ignoreList":[]}
@@ -0,0 +1,7 @@
1
+ import { http } from "@next-core/http";
2
+ /**
3
+ * @description 分页查询agent flow, 默认只查询最近三个页的数据
4
+ * @endpoint POST /api/v1/llm/agent/flow/search
5
+ */
6
+ export const AgentFlowApi_searchTaskForAgentFlow = async (data, options) => /**! @contract easyops.api.llm.agent_flow.SearchTaskForAgentFlow@1.0.0 */(await http.post("api/gateway/logic.llm.aiops_service/api/v1/llm/agent/flow/search", data, options)).data;
7
+ //# sourceMappingURL=searchTaskForAgentFlow.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"searchTaskForAgentFlow.js","names":["http","AgentFlowApi_searchTaskForAgentFlow","data","options","post"],"sources":["../../../../../src/api/llm/agent_flow/searchTaskForAgentFlow.ts"],"sourcesContent":["import { http, HttpOptions } from \"@next-core/http\";\nimport { ResponseBodyWrapper } from \"../../../wrapper.js\";\n\nexport interface AgentFlowApi_SearchTaskForAgentFlowRequestBody {\n /** 对标题进行关键字搜索 */\n query?: string;\n\n /** 数据数量大小限制, 默认30 */\n limit?: number;\n\n /** 分页token,字符串;向上翻页或向下翻页的token都在这个参数传入。 */\n next_token?: string;\n}\n\nexport interface AgentFlowApi_SearchTaskForAgentFlowResponseBody {\n /** 下一页,查询的token,为空时,没有下一页 */\n next_token?: string;\n\n /** 上一页,查询的token,为空时,没有上一页 */\n previous_token?: string;\n\n /** 任务列表 */\n data?: AgentFlowApi_SearchTaskForAgentFlowResponseBody_data_item[];\n}\n\n/**\n * @description 分页查询agent flow, 默认只查询最近三个页的数据\n * @endpoint POST /api/v1/llm/agent/flow/search\n */\nexport const AgentFlowApi_searchTaskForAgentFlow = async (\n data: AgentFlowApi_SearchTaskForAgentFlowRequestBody,\n options?: HttpOptions\n): Promise<AgentFlowApi_SearchTaskForAgentFlowResponseBody> =>\n /**! @contract easyops.api.llm.agent_flow.SearchTaskForAgentFlow@1.0.0 */ (\n await http.post<\n ResponseBodyWrapper<AgentFlowApi_SearchTaskForAgentFlowResponseBody>\n >(\n \"api/gateway/logic.llm.aiops_service/api/v1/llm/agent/flow/search\",\n data,\n options\n )\n ).data;\n\nexport interface AgentFlowApi_SearchTaskForAgentFlowResponseBody_data_item {\n /** 任务id */\n id?: string;\n\n /** 创建时间戳,单位秒 */\n startTime?: number;\n\n /** 结束时间戳,单位秒 */\n endTime?: number;\n\n /** 任务状态,\"submitted\", \"working\", \"input-required\",\"completed\",\"canceled\",\"failed\", \"unknown\" */\n state?: string;\n\n /** 标题 */\n title?: string;\n}\n"],"mappings":"AAAA,SAASA,IAAI,QAAqB,iBAAiB;AAyBnD;AACA;AACA;AACA;AACA,OAAO,MAAMC,mCAAmC,GAAG,MAAAA,CACjDC,IAAoD,EACpDC,OAAqB,KAErB,yEAA0E,CACxE,MAAMH,IAAI,CAACI,IAAI,CAGb,kEAAkE,EAClEF,IAAI,EACJC,OACF,CAAC,EACDD,IAAI","ignoreList":[]}
@@ -0,0 +1,7 @@
1
+ import { http } from "@next-core/http";
2
+ /**
3
+ * @description flow agent更新任务状态,支持暂停、停止和重启任务
4
+ * @endpoint POST /api/v1/llm/agent/flow/:taskId/updateState
5
+ */
6
+ export const AgentFlowApi_updateStateForAgentFlow = (taskId, data, options) => /**! @contract easyops.api.llm.agent_flow.UpdateStateForAgentFlow@1.0.0 */http.post(`api/gateway/logic.llm.aiops_service/api/v1/llm/agent/flow/${taskId}/updateState`, data, options);
7
+ //# sourceMappingURL=updateStateForAgentFlow.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"updateStateForAgentFlow.js","names":["http","AgentFlowApi_updateStateForAgentFlow","taskId","data","options","post"],"sources":["../../../../../src/api/llm/agent_flow/updateStateForAgentFlow.ts"],"sourcesContent":["import { http, HttpOptions } from \"@next-core/http\";\n\nexport interface AgentFlowApi_UpdateStateForAgentFlowRequestBody {\n /** 调整任务状态,可以设置为 stopped, paused, working(paused的任务状态时,可以继续) */\n state?: string;\n}\n\n/**\n * @description flow agent更新任务状态,支持暂停、停止和重启任务\n * @endpoint POST /api/v1/llm/agent/flow/:taskId/updateState\n */\nexport const AgentFlowApi_updateStateForAgentFlow = (\n taskId: string | number,\n data: AgentFlowApi_UpdateStateForAgentFlowRequestBody,\n options?: HttpOptions\n): Promise<void> =>\n /**! @contract easyops.api.llm.agent_flow.UpdateStateForAgentFlow@1.0.0 */ http.post<void>(\n `api/gateway/logic.llm.aiops_service/api/v1/llm/agent/flow/${taskId}/updateState`,\n data,\n options\n );\n"],"mappings":"AAAA,SAASA,IAAI,QAAqB,iBAAiB;AAOnD;AACA;AACA;AACA;AACA,OAAO,MAAMC,oCAAoC,GAAGA,CAClDC,MAAuB,EACvBC,IAAqD,EACrDC,OAAqB,KAErB,0EAA2EJ,IAAI,CAACK,IAAI,CAClF,6DAA6DH,MAAM,cAAc,EACjFC,IAAI,EACJC,OACF,CAAC","ignoreList":[]}
@@ -3,5 +3,5 @@ import { http } from "@next-core/http";
3
3
  * @description 根据模板与大模型对话,返回json
4
4
  * @endpoint POST /api/v1/llm/tools/template_llm_chat_v2
5
5
  */
6
- export const AiopsToolsApi_templateLlmChatV2 = async (data, options) => /**! @contract easyops.api.llm.aiops_tools.TemplateLlmChatV2@1.0.0 */(await http.post("api/gateway/logic.llm.aiops_service/api/v1/llm/tools/template_llm_chat_v2", data, options)).data;
6
+ export const AiopsToolsApi_templateLlmChatV2 = (data, options) => /**! @contract easyops.api.llm.aiops_tools.TemplateLlmChatV2@1.0.0 */http.post("api/gateway/logic.llm.aiops_service/api/v1/llm/tools/template_llm_chat_v2", data, options);
7
7
  //# sourceMappingURL=templateLlmChatV2.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"templateLlmChatV2.js","names":["http","AiopsToolsApi_templateLlmChatV2","data","options","post"],"sources":["../../../../../src/api/llm/aiops_tools/templateLlmChatV2.ts"],"sourcesContent":["import { http, HttpOptions } from \"@next-core/http\";\nimport {\n ModelLlmChatAgentTaskResponse,\n ModelLlmChatMessage,\n} from \"../../../model/aiops_service/index.js\";\nimport { ResponseBodyWrapper } from \"../../../wrapper.js\";\n\nexport interface AiopsToolsApi_TemplateLlmChatV2RequestBody {\n /** 模板,为空时,不使用默认引擎 */\n template?: string;\n\n /** 模板引擎的数据 */\n variables?: Record<string, any>;\n\n /** 大模型id */\n model?: string;\n\n /** 历史对话消息 */\n historyMessages?: Partial<ModelLlmChatMessage>[];\n\n /** 输入对话,模板为空时才生效 */\n input?: string;\n\n /** 输出格式,默认json */\n outputType?: string;\n\n /** 取值范围是:(0.0, 1.0],不能等于 0,默认值为 0.1,值越大,会使输出更随机,更具创造性;值越小,输出会更加稳定或确定 */\n temperature?: number;\n\n /** 是否是调试模式,为true时,返回debug_resp */\n debug?: boolean;\n\n /** 是否是流式 */\n stream?: boolean;\n\n /** system角色的提示词模板 */\n systemTemplate?: string;\n\n /** system模板所需要的数据 */\n systemVariables?: Record<string, any>;\n\n /** 任务id */\n taskId?: string;\n\n /** 输入的图片url */\n images?: string[];\n}\n\nexport type AiopsToolsApi_TemplateLlmChatV2ResponseBody =\n Partial<ModelLlmChatAgentTaskResponse> &\n AiopsToolsApi_TemplateLlmChatV2ResponseBody_2;\n\n/**\n * @description 根据模板与大模型对话,返回json\n * @endpoint POST /api/v1/llm/tools/template_llm_chat_v2\n */\nexport const AiopsToolsApi_templateLlmChatV2 = async (\n data: AiopsToolsApi_TemplateLlmChatV2RequestBody,\n options?: HttpOptions\n): Promise<AiopsToolsApi_TemplateLlmChatV2ResponseBody> =>\n /**! @contract easyops.api.llm.aiops_tools.TemplateLlmChatV2@1.0.0 */ (\n await http.post<\n ResponseBodyWrapper<AiopsToolsApi_TemplateLlmChatV2ResponseBody>\n >(\n \"api/gateway/logic.llm.aiops_service/api/v1/llm/tools/template_llm_chat_v2\",\n data,\n options\n )\n ).data;\n\nexport interface AiopsToolsApi_TemplateLlmChatV2ResponseBody_2 {\n /** 提取返回的数据 */\n data?: any;\n\n /** 调试时大模型返回值 */\n debug_resp?: string;\n\n /** 如果解析不到正确的数据格式,则将大模型返回的数据塞到这里 */\n errorOutput?: string;\n}\n"],"mappings":"AAAA,SAASA,IAAI,QAAqB,iBAAiB;AAoDnD;AACA;AACA;AACA;AACA,OAAO,MAAMC,+BAA+B,GAAG,MAAAA,CAC7CC,IAAgD,EAChDC,OAAqB,KAErB,qEAAsE,CACpE,MAAMH,IAAI,CAACI,IAAI,CAGb,2EAA2E,EAC3EF,IAAI,EACJC,OACF,CAAC,EACDD,IAAI","ignoreList":[]}
1
+ {"version":3,"file":"templateLlmChatV2.js","names":["http","AiopsToolsApi_templateLlmChatV2","data","options","post"],"sources":["../../../../../src/api/llm/aiops_tools/templateLlmChatV2.ts"],"sourcesContent":["import { http, HttpOptions } from \"@next-core/http\";\nimport {\n ModelLlmChatAgentTaskResponse,\n ModelLlmChatMessage,\n} from \"../../../model/aiops_service/index.js\";\n\nexport interface AiopsToolsApi_TemplateLlmChatV2RequestBody {\n /** 模板,为空时,不使用默认引擎 */\n template?: string;\n\n /** 模板引擎的数据 */\n variables?: Record<string, any>;\n\n /** 大模型id */\n model?: string;\n\n /** 历史对话消息 */\n historyMessages?: Partial<ModelLlmChatMessage>[];\n\n /** 输入对话,模板为空时才生效 */\n input?: string;\n\n /** 输出格式,默认json */\n outputType?: string;\n\n /** 取值范围是:(0.0, 1.0],不能等于 0,默认值为 0.1,值越大,会使输出更随机,更具创造性;值越小,输出会更加稳定或确定 */\n temperature?: number;\n\n /** 是否是调试模式,为true时,返回debug_resp */\n debug?: boolean;\n\n /** 是否是流式 */\n stream?: boolean;\n\n /** system角色的提示词模板 */\n systemTemplate?: string;\n\n /** system模板所需要的数据 */\n systemVariables?: Record<string, any>;\n\n /** 任务id */\n taskId?: string;\n\n /** 输入的图片url */\n images?: string[];\n}\n\nexport type AiopsToolsApi_TemplateLlmChatV2ResponseBody =\n Partial<ModelLlmChatAgentTaskResponse> &\n AiopsToolsApi_TemplateLlmChatV2ResponseBody_2;\n\n/**\n * @description 根据模板与大模型对话,返回json\n * @endpoint POST /api/v1/llm/tools/template_llm_chat_v2\n */\nexport const AiopsToolsApi_templateLlmChatV2 = (\n data: AiopsToolsApi_TemplateLlmChatV2RequestBody,\n options?: HttpOptions\n): Promise<AiopsToolsApi_TemplateLlmChatV2ResponseBody> =>\n /**! @contract easyops.api.llm.aiops_tools.TemplateLlmChatV2@1.0.0 */ http.post<AiopsToolsApi_TemplateLlmChatV2ResponseBody>(\n \"api/gateway/logic.llm.aiops_service/api/v1/llm/tools/template_llm_chat_v2\",\n data,\n options\n );\n\nexport interface AiopsToolsApi_TemplateLlmChatV2ResponseBody_2 {\n /** 提取返回的数据 */\n data?: any;\n\n /** 调试时大模型返回值 */\n debug_resp?: string;\n\n /** 如果解析不到正确的数据格式,则将大模型返回的数据塞到这里 */\n errorOutput?: string;\n}\n"],"mappings":"AAAA,SAASA,IAAI,QAAqB,iBAAiB;AAmDnD;AACA;AACA;AACA;AACA,OAAO,MAAMC,+BAA+B,GAAGA,CAC7CC,IAAgD,EAChDC,OAAqB,KAErB,qEAAsEH,IAAI,CAACI,IAAI,CAC7E,2EAA2E,EAC3EF,IAAI,EACJC,OACF,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"ModelLlmChatAgentTaskRequest.js","names":[],"sources":["../../../../src/model/aiops_service/ModelLlmChatAgentTaskRequest.ts"],"sourcesContent":["import { ModelLlmChatMessage } from \"./index.js\";\n\n/** 聊天机器人,处理agent任务的请求 */\nexport interface ModelLlmChatAgentTaskRequest {\n /** 任务需求 */\n input: string;\n\n /** 图片的url,支持多个图片 */\n images: string[];\n\n /** 任务配置 */\n config: Record<string, any>;\n\n /** 当前任务上下文的id */\n conversationId: string;\n\n /** 在多agent场景,指定使用哪个agent */\n agentId: string;\n\n /** 当前任务Id */\n taskId: string;\n\n /** 已经提取的表单数据 */\n formData: any;\n\n /** 助手id */\n robotId: string;\n\n /** 是否流式返回 */\n stream: boolean;\n\n /** 历史会话消息,适用支持多轮会话的agent */\n historyMessages: Partial<ModelLlmChatMessage>[];\n\n /** 流式数据列表(占位符,防止flow builder自动清理流式返回的数据) */\n sseDataList: any[];\n}\n"],"mappings":"","ignoreList":[]}
1
+ {"version":3,"file":"ModelLlmChatAgentTaskRequest.js","names":[],"sources":["../../../../src/model/aiops_service/ModelLlmChatAgentTaskRequest.ts"],"sourcesContent":["import { ModelLlmChatMessage } from \"./index.js\";\n\n/** 聊天机器人,处理agent任务的请求 */\nexport interface ModelLlmChatAgentTaskRequest {\n /** 任务需求 */\n input: string;\n\n /** 大模型的Temperature, 值范围0.0~1.0 */\n temperature: number;\n\n /** 图片的url,支持多个图片 */\n images: string[];\n\n /** 任务配置 */\n config: Record<string, any>;\n\n /** 当前任务上下文的id */\n conversationId: string;\n\n /** 在多agent场景,指定使用哪个agent */\n agentId: string;\n\n /** 当前任务Id */\n taskId: string;\n\n /** 已经提取的表单数据 */\n formData: any;\n\n /** 助手id */\n robotId: string;\n\n /** 是否流式返回 */\n stream: boolean;\n\n /** 历史会话消息,适用支持多轮会话的agent */\n historyMessages: Partial<ModelLlmChatMessage>[];\n\n /** 流式数据列表(占位符,防止flow builder自动清理流式返回的数据) */\n sseDataList: any[];\n}\n"],"mappings":"","ignoreList":[]}
@@ -4,6 +4,8 @@ export interface AgentFlowApi_CreateTaskForAgentFlowRequestBody {
4
4
  input?: string;
5
5
  /** 指定处理任务的agent */
6
6
  agentId?: string;
7
+ /** 执行任务引擎的版本号 */
8
+ engineVersion?: string;
7
9
  }
8
10
  export interface AgentFlowApi_CreateTaskForAgentFlowResponseBody {
9
11
  /** 任务id */
@@ -1,3 +1,5 @@
1
1
  export * from "./addJobMessageForAgentFlow.js";
2
2
  export * from "./createTaskForAgentFlow.js";
3
3
  export * from "./getTaskDetailForAgentFlow.js";
4
+ export * from "./searchTaskForAgentFlow.js";
5
+ export * from "./updateStateForAgentFlow.js";
@@ -0,0 +1,34 @@
1
+ import { HttpOptions } from "@next-core/http";
2
+ export interface AgentFlowApi_SearchTaskForAgentFlowRequestBody {
3
+ /** 对标题进行关键字搜索 */
4
+ query?: string;
5
+ /** 数据数量大小限制, 默认30 */
6
+ limit?: number;
7
+ /** 分页token,字符串;向上翻页或向下翻页的token都在这个参数传入。 */
8
+ next_token?: string;
9
+ }
10
+ export interface AgentFlowApi_SearchTaskForAgentFlowResponseBody {
11
+ /** 下一页,查询的token,为空时,没有下一页 */
12
+ next_token?: string;
13
+ /** 上一页,查询的token,为空时,没有上一页 */
14
+ previous_token?: string;
15
+ /** 任务列表 */
16
+ data?: AgentFlowApi_SearchTaskForAgentFlowResponseBody_data_item[];
17
+ }
18
+ /**
19
+ * @description 分页查询agent flow, 默认只查询最近三个页的数据
20
+ * @endpoint POST /api/v1/llm/agent/flow/search
21
+ */
22
+ export declare const AgentFlowApi_searchTaskForAgentFlow: (data: AgentFlowApi_SearchTaskForAgentFlowRequestBody, options?: HttpOptions) => Promise<AgentFlowApi_SearchTaskForAgentFlowResponseBody>;
23
+ export interface AgentFlowApi_SearchTaskForAgentFlowResponseBody_data_item {
24
+ /** 任务id */
25
+ id?: string;
26
+ /** 创建时间戳,单位秒 */
27
+ startTime?: number;
28
+ /** 结束时间戳,单位秒 */
29
+ endTime?: number;
30
+ /** 任务状态,"submitted", "working", "input-required","completed","canceled","failed", "unknown" */
31
+ state?: string;
32
+ /** 标题 */
33
+ title?: string;
34
+ }
@@ -0,0 +1,10 @@
1
+ import { HttpOptions } from "@next-core/http";
2
+ export interface AgentFlowApi_UpdateStateForAgentFlowRequestBody {
3
+ /** 调整任务状态,可以设置为 stopped, paused, working(paused的任务状态时,可以继续) */
4
+ state?: string;
5
+ }
6
+ /**
7
+ * @description flow agent更新任务状态,支持暂停、停止和重启任务
8
+ * @endpoint POST /api/v1/llm/agent/flow/:taskId/updateState
9
+ */
10
+ export declare const AgentFlowApi_updateStateForAgentFlow: (taskId: string | number, data: AgentFlowApi_UpdateStateForAgentFlowRequestBody, options?: HttpOptions) => Promise<void>;
@@ -3,6 +3,8 @@ import { ModelLlmChatMessage } from "./index.js";
3
3
  export interface ModelLlmChatAgentTaskRequest {
4
4
  /** 任务需求 */
5
5
  input: string;
6
+ /** 大模型的Temperature, 值范围0.0~1.0 */
7
+ temperature: number;
6
8
  /** 图片的url,支持多个图片 */
7
9
  images: string[];
8
10
  /** 任务配置 */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@next-api-sdk/llm-sdk",
3
- "version": "1.3.0",
3
+ "version": "1.4.0",
4
4
  "description": "API SDK for Llm",
5
5
  "homepage": "https://github.com/easyops-cn/next-api-sdk/tree/master/sdk/llm-sdk",
6
6
  "repository": {
@@ -43,5 +43,5 @@
43
43
  "devDependencies": {
44
44
  "@next-core/build-next-libs": "^1.0.0"
45
45
  },
46
- "gitHead": "e1bd40327515f49ba143480a71d4f55e4e54334d"
46
+ "gitHead": "7f7382c25c910778ccb206b4d7249dbb5778b123"
47
47
  }