@or-sdk/agents 1.12.0-beta.2532.0 → 1.12.0-beta.2540.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.
package/dist/cjs/types.js CHANGED
@@ -1,3 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ActivityKind = void 0;
4
+ var ActivityKind;
5
+ (function (ActivityKind) {
6
+ ActivityKind["Observation"] = "Observation";
7
+ ActivityKind["Thought"] = "Thought";
8
+ ActivityKind["Action"] = "Action";
9
+ })(ActivityKind = exports.ActivityKind || (exports.ActivityKind = {}));
3
10
  //# sourceMappingURL=types.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/types.ts"],"names":[],"mappings":""}
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/types.ts"],"names":[],"mappings":";;;AAMA,IAAY,YAOX;AAPD,WAAY,YAAY;IAEtB,2CAA2B,CAAA;IAE3B,mCAAmB,CAAA;IAEnB,iCAAiB,CAAA;AACnB,CAAC,EAPW,YAAY,GAAZ,oBAAY,KAAZ,oBAAY,QAOvB"}
package/dist/esm/types.js CHANGED
@@ -1,2 +1,7 @@
1
- export {};
1
+ export var ActivityKind;
2
+ (function (ActivityKind) {
3
+ ActivityKind["Observation"] = "Observation";
4
+ ActivityKind["Thought"] = "Thought";
5
+ ActivityKind["Action"] = "Action";
6
+ })(ActivityKind || (ActivityKind = {}));
2
7
  //# sourceMappingURL=types.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/types.ts"],"names":[],"mappings":""}
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/types.ts"],"names":[],"mappings":"AAMA,MAAM,CAAN,IAAY,YAOX;AAPD,WAAY,YAAY;IAEtB,2CAA2B,CAAA;IAE3B,mCAAmB,CAAA;IAEnB,iCAAiB,CAAA;AACnB,CAAC,EAPW,YAAY,KAAZ,YAAY,QAOvB"}
@@ -1,5 +1,10 @@
1
1
  import { OrderDirection, Token } from '@or-sdk/base';
2
2
  import type { SearchMode } from '@or-sdk/lookup';
3
+ export declare enum ActivityKind {
4
+ Observation = "Observation",
5
+ Thought = "Thought",
6
+ Action = "Action"
7
+ }
3
8
  export type CallOptions = {
4
9
  signal?: AbortSignal;
5
10
  };
@@ -17,33 +22,25 @@ export type AgentModelOptions = {
17
22
  presencePenalty?: number;
18
23
  modelName?: string;
19
24
  };
20
- export type CreateAgent = {
21
- name: string;
22
- description?: string;
23
- typeDefs?: string;
24
- objective?: string;
25
- image?: string;
26
- model?: AgentModelOptions;
27
- };
28
- export type UpdateAgent = {
29
- description?: string;
30
- image?: string;
31
- typeDefs?: string;
32
- objective?: string;
33
- model?: AgentModelOptions;
25
+ export type AgentActivity = {
26
+ kind: ActivityKind;
27
+ input: string;
34
28
  };
35
29
  export type Agent = {
36
30
  id: string;
37
31
  accountId: string;
38
32
  name: string;
39
33
  description?: string;
40
- image?: string;
41
- typeDefs?: string;
42
- objective?: string;
43
- model?: AgentModelOptions;
34
+ image: string;
35
+ typeDefs: string;
36
+ objective: string;
37
+ model: AgentModelOptions;
44
38
  createdAt: string | Date;
45
39
  updatedAt: string | Date;
40
+ primer: AgentActivity[];
46
41
  };
42
+ export type UpdateAgent = Partial<Omit<Agent, 'id' | 'createdAt' | 'updatedAt' | 'name' | 'accountId'>>;
43
+ export type CreateAgent = Omit<Agent, 'id' | 'createdAt' | 'updatedAt' | 'accountId'>;
47
44
  export type FindAgentsOptions = {
48
45
  from?: number;
49
46
  size?: number;
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AACrD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAEjD,MAAM,MAAM,WAAW,GAAG;IACxB,M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AAC;AAEF,MAAM,MAAM,aAAa,GAAG;IAE1B,IAAI,EAAE,YAAY,CAAC;IAEnB,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,MAAM,MAAM,KAAK,GAAG;IAIlB,EAAE,EAAE,MAAM,CAAC;IAKX,SAAS,EAAE,MAAM,CAAC;IAMlB,IAAI,EAAE,MAAM,CAAC;IAKb,WAAW,CAAC,EAAE,MAAM,CAAC;IAKrB,KAAK,EAAE,MAAM,CAAC;IAKd,QAAQ,EAAE,MAAM,CAAC;IAKjB,SAAS,EAAE,MAAM,CAAC;IAKlB,KAAK,EAAE,iBAAiB,CAAC;IAKzB,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IAKzB,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IAKzB,MAAM,EAAE,aAAa,EAAE,CAAC;CACzB,CAAC;AAEF,MAAM,MAAM,WAAW,GAAG,OAAO,CAAC,IAAI,CAAC,KAAK,EAAE,IAAI,GAAG,WAAW,GAAG,WAAW,GAAG,MAAM,GAAG,WAAW,CAAC,CAAC,CAAC;AACxG,MAAM,MAAM,WAAW,GAAG,IAAI,CAAC,KAAK,EAAE,IAAI,GAAG,WAAW,GAAG,WAAW,GAAG,WAAW,CAAC,CAAC;AAEtF,MAAM,MAAM,iBAAiB,GAAG;IAI9B,IAAI,CAAC,EAAE,MAAM,CAAC;IAKd,IAAI,CAAC,EAAE,MAAM,CAAC;IAKd,KAAK,CAAC,EAAE,MAAM,CAAC;IAKf,IAAI,CAAC,EAAE,UAAU,CAAC;IAKlB,aAAa,CAAC,EAAE,MAAM,CAAC;IAKvB,cAAc,CAAC,EAAE,cAAc,CAAC;CACjC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@or-sdk/agents",
3
- "version": "1.12.0-beta.2532.0",
3
+ "version": "1.12.0-beta.2540.0",
4
4
  "main": "dist/cjs/index.js",
5
5
  "module": "dist/esm/index.js",
6
6
  "types": "dist/types/index.d.ts",
package/src/types.ts CHANGED
@@ -1,6 +1,18 @@
1
1
  import { OrderDirection, Token } from '@or-sdk/base';
2
2
  import type { SearchMode } from '@or-sdk/lookup';
3
3
 
4
+ /**
5
+ * Enum representing the kinds of activities that an agent can perform.
6
+ */
7
+ export enum ActivityKind {
8
+ /** An observation made by the agent. */
9
+ Observation = 'Observation',
10
+ /** A thought process of the agent. */
11
+ Thought = 'Thought',
12
+ /** An action taken by the agent. */
13
+ Action = 'Action',
14
+ }
15
+
4
16
  export type CallOptions = {
5
17
  signal?: AbortSignal;
6
18
  };
@@ -59,64 +71,11 @@ export type AgentModelOptions = {
59
71
  modelName?: string;
60
72
  };
61
73
 
62
- export type CreateAgent = {
63
- /**
64
- * Agent name
65
- * Can start only with a capital letter.
66
- */
67
- name: string;
68
-
69
- /**
70
- * Agent description
71
- */
72
- description?: string;
73
-
74
- /**
75
- * A GraphQL type definitions document.
76
- */
77
- typeDefs?: string;
78
-
79
- /**
80
- * The objective or goal the agent is trying to achieve.
81
- */
82
- objective?: string;
83
-
84
- /**
85
- * A agent thumbnail image URL.
86
- */
87
- image?: string;
88
-
89
- /**
90
- * Model options for the agent.
91
- */
92
- model?: AgentModelOptions;
93
- };
94
-
95
- export type UpdateAgent = {
96
- /**
97
- * Agent description
98
- */
99
- description?: string;
100
-
101
- /**
102
- * A agent thumbnail image URL.
103
- */
104
- image?: string;
105
-
106
- /**
107
- * A GraphQL type definitions document.
108
- */
109
- typeDefs?: string;
110
-
111
- /**
112
- * The objective or goal the agent is trying to achieve.
113
- */
114
- objective?: string;
115
-
116
- /**
117
- * Model options for the agent.
118
- */
119
- model?: AgentModelOptions;
74
+ export type AgentActivity = {
75
+ /** The kind of activity. */
76
+ kind: ActivityKind;
77
+ /** The input or content of the activity. */
78
+ input: string;
120
79
  };
121
80
 
122
81
  export type Agent = {
@@ -144,22 +103,22 @@ export type Agent = {
144
103
  /**
145
104
  * Agent image URL.
146
105
  */
147
- image?: string;
106
+ image: string;
148
107
 
149
108
  /**
150
109
  * A GraphQL type definitions document.
151
110
  */
152
- typeDefs?: string;
111
+ typeDefs: string;
153
112
 
154
113
  /**
155
114
  * The objective or goal the agent is trying to achieve.
156
115
  */
157
- objective?: string;
116
+ objective: string;
158
117
 
159
118
  /**
160
119
  * Model options for the agent.
161
120
  */
162
- model?: AgentModelOptions;
121
+ model: AgentModelOptions;
163
122
 
164
123
  /**
165
124
  * Creation Date
@@ -170,8 +129,16 @@ export type Agent = {
170
129
  * Updating Date
171
130
  */
172
131
  updatedAt: string | Date;
132
+
133
+ /**
134
+ * History primer.
135
+ */
136
+ primer: AgentActivity[];
173
137
  };
174
138
 
139
+ export type UpdateAgent = Partial<Omit<Agent, 'id' | 'createdAt' | 'updatedAt' | 'name' | 'accountId'>>;
140
+ export type CreateAgent = Omit<Agent, 'id' | 'createdAt' | 'updatedAt' | 'accountId'>;
141
+
175
142
  export type FindAgentsOptions = {
176
143
  /**
177
144
  * Start pagination from