@blueking/chat-helper 0.0.1-beta.9 → 0.0.3

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 (42) hide show
  1. package/README.md +631 -141
  2. package/dist/agent/type.d.ts +27 -2
  3. package/dist/agent/type.ts.js +1 -1
  4. package/dist/agent/use-agent.d.ts +464 -484
  5. package/dist/agent/use-agent.ts.js +191 -42
  6. package/dist/event/ag-ui.d.ts +37 -7
  7. package/dist/event/ag-ui.ts.js +225 -173
  8. package/dist/event/type.d.ts +99 -107
  9. package/dist/event/type.ts.js +34 -11
  10. package/dist/http/fetch/fetch.d.ts +5 -1
  11. package/dist/http/fetch/fetch.ts.js +40 -51
  12. package/dist/http/fetch/index.d.ts +1 -0
  13. package/dist/http/fetch/index.ts.js +133 -3
  14. package/dist/http/index.d.ts +14 -5
  15. package/dist/http/index.ts.js +59 -3
  16. package/dist/http/module/index.d.ts +13 -5
  17. package/dist/http/module/index.ts.js +2 -1
  18. package/dist/http/module/message.d.ts +22 -5
  19. package/dist/http/module/message.ts.js +51 -4
  20. package/dist/http/module/session.d.ts +4 -1
  21. package/dist/http/module/session.ts.js +66 -4
  22. package/dist/http/transform/agent.ts.js +11 -8
  23. package/dist/http/transform/message.d.ts +6 -6
  24. package/dist/http/transform/message.ts.js +566 -118
  25. package/dist/http/transform/session.ts.js +9 -1
  26. package/dist/index.d.ts +2983 -3314
  27. package/dist/index.ts.js +27 -5
  28. package/dist/mediator/index.d.ts +2 -0
  29. package/dist/mediator/index.ts.js +26 -0
  30. package/dist/mediator/type.d.ts +50 -0
  31. package/dist/mediator/type.ts.js +28 -0
  32. package/dist/mediator/use-mediator.d.ts +7 -0
  33. package/dist/mediator/use-mediator.ts.js +47 -0
  34. package/dist/message/type.d.ts +280 -146
  35. package/dist/message/type.ts.js +16 -15
  36. package/dist/message/use-message.d.ts +847 -963
  37. package/dist/message/use-message.ts.js +230 -37
  38. package/dist/session/type.d.ts +10 -0
  39. package/dist/session/use-session.d.ts +2006 -2214
  40. package/dist/session/use-session.ts.js +198 -33
  41. package/dist/type.d.ts +2 -0
  42. package/package.json +11 -6
@@ -1,15 +1,21 @@
1
- import type { IMessage, IMessageApi } from '../message/type';
1
+ import type { IMessage } from '../message/type';
2
+ export interface ISupportUpload {
3
+ vision: boolean;
4
+ }
2
5
  export interface IAgentCommand {
3
6
  agentId: number;
7
+ alias?: string;
4
8
  components: IAgentCommandComponent[];
5
9
  content: null | string;
6
10
  icon?: string;
7
11
  id: string;
8
12
  name: string;
9
13
  status: string;
14
+ supportUpload?: ISupportUpload;
10
15
  }
11
16
  export interface IAgentCommandApi {
12
17
  agent_id: number;
18
+ alias?: string;
13
19
  components: IAgentCommandComponentApi[];
14
20
  content: null | string;
15
21
  icon: string;
@@ -17,6 +23,7 @@ export interface IAgentCommandApi {
17
23
  name: string;
18
24
  selectedText?: null | string;
19
25
  status: string;
26
+ support_upload?: ISupportUpload;
20
27
  }
21
28
  export interface IAgentCommandComponent {
22
29
  default?: null | string;
@@ -51,6 +58,7 @@ export interface IAgentCommandComponentApi {
51
58
  }
52
59
  export interface IAgentInfo {
53
60
  agentName?: string;
61
+ resources?: IAgentResourceItem[];
54
62
  saasUrl?: string;
55
63
  chatGroup?: {
56
64
  enabled: boolean;
@@ -65,10 +73,12 @@ export interface IAgentInfo {
65
73
  };
66
74
  promptSetting?: {
67
75
  content?: IMessage[];
76
+ supportUpload?: ISupportUpload;
68
77
  };
69
78
  }
70
79
  export interface IAgentInfoApi {
71
80
  agent_name: string;
81
+ resources?: IAgentResourceItem[];
72
82
  saas_url?: string;
73
83
  chat_group?: {
74
84
  enabled: boolean;
@@ -82,6 +92,21 @@ export interface IAgentInfoApi {
82
92
  predefined_questions?: string[];
83
93
  };
84
94
  prompt_setting?: {
85
- content?: IMessageApi[];
95
+ content?: IMessage[];
96
+ support_upload?: ISupportUpload;
86
97
  };
87
98
  }
99
+ export interface IAgentResourceItem {
100
+ code: string;
101
+ icon: null | string;
102
+ id: null | number;
103
+ name: string;
104
+ type: string;
105
+ }
106
+ /** @deprecated 后端已改为扁平列表 IAgentResourceItem[],不再使用分组结构 */
107
+ export interface IAgentResources {
108
+ command?: IAgentResourceItem[];
109
+ knowledgebase?: IAgentResourceItem[];
110
+ mcp?: IAgentResourceItem[];
111
+ tool?: IAgentResourceItem[];
112
+ }
@@ -22,4 +22,4 @@
22
22
  * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
23
23
  * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
24
24
  * IN THE SOFTWARE.
25
- */ export { };
25
+ */ /** @deprecated 后端已改为扁平列表 IAgentResourceItem[],不再使用分组结构 */ export { };