@happyvertical/smrt-personas 0.38.18
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/AGENTS.md +85 -0
- package/CLAUDE.md +1 -0
- package/LICENSE +7 -0
- package/dist/index.d.ts +294 -0
- package/dist/index.js +290 -0
- package/dist/index.js.map +1 -0
- package/dist/manifest.json +397 -0
- package/dist/smrt-knowledge.json +311 -0
- package/package.json +61 -0
|
@@ -0,0 +1,397 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": "1.0.0",
|
|
3
|
+
"timestamp": 1783560123595,
|
|
4
|
+
"packageName": "@happyvertical/smrt-personas",
|
|
5
|
+
"packageVersion": "0.38.18",
|
|
6
|
+
"objects": {
|
|
7
|
+
"@happyvertical/smrt-personas:AgentPersona": {
|
|
8
|
+
"name": "agentpersona",
|
|
9
|
+
"className": "AgentPersona",
|
|
10
|
+
"qualifiedName": "@happyvertical/smrt-personas:AgentPersona",
|
|
11
|
+
"collection": "agentpersonas",
|
|
12
|
+
"filePath": "/home/runner/_work/smrt/smrt/packages/personas/src/agent-persona.ts",
|
|
13
|
+
"packageName": "@happyvertical/smrt-personas",
|
|
14
|
+
"fields": {
|
|
15
|
+
"tenantId": {
|
|
16
|
+
"type": "text",
|
|
17
|
+
"required": true,
|
|
18
|
+
"_meta": {
|
|
19
|
+
"sqlType": "UUID",
|
|
20
|
+
"__tenancy": {
|
|
21
|
+
"isTenantIdField": true,
|
|
22
|
+
"autoFilter": true,
|
|
23
|
+
"required": true,
|
|
24
|
+
"autoPopulate": true,
|
|
25
|
+
"nullable": false,
|
|
26
|
+
"mode": "required",
|
|
27
|
+
"field": "tenantId",
|
|
28
|
+
"allowSuperAdminBypass": false
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
},
|
|
32
|
+
"agentClass": {
|
|
33
|
+
"type": "text",
|
|
34
|
+
"required": false,
|
|
35
|
+
"_meta": {}
|
|
36
|
+
},
|
|
37
|
+
"name": {
|
|
38
|
+
"type": "text",
|
|
39
|
+
"required": false,
|
|
40
|
+
"default": ""
|
|
41
|
+
},
|
|
42
|
+
"contextType": {
|
|
43
|
+
"type": "text",
|
|
44
|
+
"required": false,
|
|
45
|
+
"_meta": {
|
|
46
|
+
"nullable": true
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
"contextId": {
|
|
50
|
+
"type": "text",
|
|
51
|
+
"required": false,
|
|
52
|
+
"_meta": {
|
|
53
|
+
"nullable": true
|
|
54
|
+
}
|
|
55
|
+
},
|
|
56
|
+
"instructions": {
|
|
57
|
+
"type": "text",
|
|
58
|
+
"required": false,
|
|
59
|
+
"_meta": {}
|
|
60
|
+
},
|
|
61
|
+
"allowedTools": {
|
|
62
|
+
"type": "text",
|
|
63
|
+
"required": false,
|
|
64
|
+
"_meta": {}
|
|
65
|
+
},
|
|
66
|
+
"runAsUserId": {
|
|
67
|
+
"type": "crossPackageRef",
|
|
68
|
+
"required": true,
|
|
69
|
+
"related": "@happyvertical/smrt-users:User"
|
|
70
|
+
},
|
|
71
|
+
"actsAsProfileId": {
|
|
72
|
+
"type": "crossPackageRef",
|
|
73
|
+
"required": false,
|
|
74
|
+
"related": "@happyvertical/smrt-profiles:Profile",
|
|
75
|
+
"_meta": {
|
|
76
|
+
"nullable": true
|
|
77
|
+
}
|
|
78
|
+
},
|
|
79
|
+
"memoryScope": {
|
|
80
|
+
"type": "text",
|
|
81
|
+
"required": false,
|
|
82
|
+
"_meta": {}
|
|
83
|
+
},
|
|
84
|
+
"priority": {
|
|
85
|
+
"type": "integer",
|
|
86
|
+
"required": false,
|
|
87
|
+
"default": 0
|
|
88
|
+
},
|
|
89
|
+
"enabled": {
|
|
90
|
+
"type": "boolean",
|
|
91
|
+
"required": false,
|
|
92
|
+
"_meta": {}
|
|
93
|
+
}
|
|
94
|
+
},
|
|
95
|
+
"methods": {
|
|
96
|
+
"getAllowedTools": {
|
|
97
|
+
"name": "getAllowedTools",
|
|
98
|
+
"async": false,
|
|
99
|
+
"parameters": [],
|
|
100
|
+
"returnType": "string[]",
|
|
101
|
+
"isStatic": false,
|
|
102
|
+
"isPublic": true
|
|
103
|
+
},
|
|
104
|
+
"setAllowedTools": {
|
|
105
|
+
"name": "setAllowedTools",
|
|
106
|
+
"async": false,
|
|
107
|
+
"parameters": [
|
|
108
|
+
{
|
|
109
|
+
"name": "tools",
|
|
110
|
+
"type": "string[]",
|
|
111
|
+
"optional": false
|
|
112
|
+
}
|
|
113
|
+
],
|
|
114
|
+
"returnType": "void",
|
|
115
|
+
"isStatic": false,
|
|
116
|
+
"isPublic": true
|
|
117
|
+
}
|
|
118
|
+
},
|
|
119
|
+
"decoratorConfig": {
|
|
120
|
+
"tableName": "agent_personas",
|
|
121
|
+
"api": {
|
|
122
|
+
"include": [
|
|
123
|
+
"list",
|
|
124
|
+
"get",
|
|
125
|
+
"create",
|
|
126
|
+
"update",
|
|
127
|
+
"delete"
|
|
128
|
+
]
|
|
129
|
+
},
|
|
130
|
+
"cli": {
|
|
131
|
+
"include": [
|
|
132
|
+
"list",
|
|
133
|
+
"get"
|
|
134
|
+
]
|
|
135
|
+
},
|
|
136
|
+
"mcp": {
|
|
137
|
+
"include": [
|
|
138
|
+
"list",
|
|
139
|
+
"get"
|
|
140
|
+
]
|
|
141
|
+
},
|
|
142
|
+
"conflictColumns": [
|
|
143
|
+
"tenant_id",
|
|
144
|
+
"agent_class",
|
|
145
|
+
"name"
|
|
146
|
+
],
|
|
147
|
+
"tenantScoped": {
|
|
148
|
+
"mode": "required"
|
|
149
|
+
}
|
|
150
|
+
},
|
|
151
|
+
"extends": "SmrtObject",
|
|
152
|
+
"exportName": "AgentPersona",
|
|
153
|
+
"collectionExportName": "AgentPersonaCollection",
|
|
154
|
+
"validationRules": [
|
|
155
|
+
{
|
|
156
|
+
"field": "tenantId",
|
|
157
|
+
"rule": "required",
|
|
158
|
+
"fieldType": "text"
|
|
159
|
+
},
|
|
160
|
+
{
|
|
161
|
+
"field": "runAsUserId",
|
|
162
|
+
"rule": "required",
|
|
163
|
+
"fieldType": "crossPackageRef"
|
|
164
|
+
}
|
|
165
|
+
],
|
|
166
|
+
"schema": {
|
|
167
|
+
"tableName": "agent_personas",
|
|
168
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"agent_personas\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"tenant_id\" UUID NOT NULL,\n \"agent_class\" TEXT,\n \"name\" TEXT DEFAULT '',\n \"context_type\" TEXT,\n \"context_id\" TEXT,\n \"instructions\" TEXT,\n \"allowed_tools\" TEXT,\n \"run_as_user_id\" UUID NOT NULL,\n \"acts_as_profile_id\" UUID,\n \"memory_scope\" TEXT,\n \"priority\" INTEGER DEFAULT 0,\n \"enabled\" BOOLEAN\n);",
|
|
169
|
+
"columns": {
|
|
170
|
+
"id": {
|
|
171
|
+
"type": "UUID",
|
|
172
|
+
"primaryKey": true,
|
|
173
|
+
"referenceKind": "id",
|
|
174
|
+
"notNull": true
|
|
175
|
+
},
|
|
176
|
+
"slug": {
|
|
177
|
+
"type": "TEXT",
|
|
178
|
+
"notNull": true
|
|
179
|
+
},
|
|
180
|
+
"context": {
|
|
181
|
+
"type": "TEXT",
|
|
182
|
+
"notNull": true,
|
|
183
|
+
"default": ""
|
|
184
|
+
},
|
|
185
|
+
"created_at": {
|
|
186
|
+
"type": "TIMESTAMP",
|
|
187
|
+
"notNull": true,
|
|
188
|
+
"default": "current_timestamp"
|
|
189
|
+
},
|
|
190
|
+
"updated_at": {
|
|
191
|
+
"type": "TIMESTAMP",
|
|
192
|
+
"notNull": true,
|
|
193
|
+
"default": "current_timestamp"
|
|
194
|
+
},
|
|
195
|
+
"tenant_id": {
|
|
196
|
+
"type": "UUID",
|
|
197
|
+
"referenceKind": "tenantId",
|
|
198
|
+
"notNull": true,
|
|
199
|
+
"unique": false
|
|
200
|
+
},
|
|
201
|
+
"agent_class": {
|
|
202
|
+
"type": "TEXT",
|
|
203
|
+
"notNull": false,
|
|
204
|
+
"unique": false
|
|
205
|
+
},
|
|
206
|
+
"name": {
|
|
207
|
+
"type": "TEXT",
|
|
208
|
+
"notNull": false,
|
|
209
|
+
"unique": false,
|
|
210
|
+
"default": ""
|
|
211
|
+
},
|
|
212
|
+
"context_type": {
|
|
213
|
+
"type": "TEXT",
|
|
214
|
+
"notNull": false,
|
|
215
|
+
"unique": false
|
|
216
|
+
},
|
|
217
|
+
"context_id": {
|
|
218
|
+
"type": "TEXT",
|
|
219
|
+
"notNull": false,
|
|
220
|
+
"unique": false
|
|
221
|
+
},
|
|
222
|
+
"instructions": {
|
|
223
|
+
"type": "TEXT",
|
|
224
|
+
"notNull": false,
|
|
225
|
+
"unique": false
|
|
226
|
+
},
|
|
227
|
+
"allowed_tools": {
|
|
228
|
+
"type": "TEXT",
|
|
229
|
+
"notNull": false,
|
|
230
|
+
"unique": false
|
|
231
|
+
},
|
|
232
|
+
"run_as_user_id": {
|
|
233
|
+
"type": "UUID",
|
|
234
|
+
"referenceKind": "crossPackageRef",
|
|
235
|
+
"notNull": true,
|
|
236
|
+
"unique": false
|
|
237
|
+
},
|
|
238
|
+
"acts_as_profile_id": {
|
|
239
|
+
"type": "UUID",
|
|
240
|
+
"referenceKind": "crossPackageRef",
|
|
241
|
+
"notNull": false,
|
|
242
|
+
"unique": false
|
|
243
|
+
},
|
|
244
|
+
"memory_scope": {
|
|
245
|
+
"type": "TEXT",
|
|
246
|
+
"notNull": false,
|
|
247
|
+
"unique": false
|
|
248
|
+
},
|
|
249
|
+
"priority": {
|
|
250
|
+
"type": "INTEGER",
|
|
251
|
+
"notNull": false,
|
|
252
|
+
"unique": false,
|
|
253
|
+
"default": 0
|
|
254
|
+
},
|
|
255
|
+
"enabled": {
|
|
256
|
+
"type": "BOOLEAN",
|
|
257
|
+
"notNull": false,
|
|
258
|
+
"unique": false
|
|
259
|
+
}
|
|
260
|
+
},
|
|
261
|
+
"indexes": [
|
|
262
|
+
{
|
|
263
|
+
"name": "agent_personas_id_idx",
|
|
264
|
+
"columns": [
|
|
265
|
+
"id"
|
|
266
|
+
]
|
|
267
|
+
},
|
|
268
|
+
{
|
|
269
|
+
"name": "agent_personas_tenant_id_agent_class_idx",
|
|
270
|
+
"columns": [
|
|
271
|
+
"tenant_id",
|
|
272
|
+
"agent_class",
|
|
273
|
+
"name"
|
|
274
|
+
],
|
|
275
|
+
"unique": true
|
|
276
|
+
}
|
|
277
|
+
],
|
|
278
|
+
"version": "71e955ef"
|
|
279
|
+
}
|
|
280
|
+
},
|
|
281
|
+
"@happyvertical/smrt-personas:AgentPersonaCollection": {
|
|
282
|
+
"name": "agentpersonacollection",
|
|
283
|
+
"className": "AgentPersonaCollection",
|
|
284
|
+
"qualifiedName": "@happyvertical/smrt-personas:AgentPersonaCollection",
|
|
285
|
+
"collection": "agentpersonas",
|
|
286
|
+
"filePath": "/home/runner/_work/smrt/smrt/packages/personas/src/agent-persona.ts",
|
|
287
|
+
"packageName": "@happyvertical/smrt-personas",
|
|
288
|
+
"fields": {},
|
|
289
|
+
"methods": {
|
|
290
|
+
"byTenantAndClass": {
|
|
291
|
+
"name": "byTenantAndClass",
|
|
292
|
+
"async": true,
|
|
293
|
+
"parameters": [
|
|
294
|
+
{
|
|
295
|
+
"name": "tenantId",
|
|
296
|
+
"type": "string",
|
|
297
|
+
"optional": false
|
|
298
|
+
},
|
|
299
|
+
{
|
|
300
|
+
"name": "agentClass",
|
|
301
|
+
"type": "string",
|
|
302
|
+
"optional": false
|
|
303
|
+
}
|
|
304
|
+
],
|
|
305
|
+
"returnType": "Promise<AgentPersona[]>",
|
|
306
|
+
"isStatic": false,
|
|
307
|
+
"isPublic": true
|
|
308
|
+
},
|
|
309
|
+
"findActive": {
|
|
310
|
+
"name": "findActive",
|
|
311
|
+
"async": true,
|
|
312
|
+
"parameters": [
|
|
313
|
+
{
|
|
314
|
+
"name": "tenantId",
|
|
315
|
+
"type": "string",
|
|
316
|
+
"optional": false
|
|
317
|
+
},
|
|
318
|
+
{
|
|
319
|
+
"name": "agentClass",
|
|
320
|
+
"type": "string",
|
|
321
|
+
"optional": false
|
|
322
|
+
},
|
|
323
|
+
{
|
|
324
|
+
"name": "context",
|
|
325
|
+
"type": "object",
|
|
326
|
+
"optional": true
|
|
327
|
+
}
|
|
328
|
+
],
|
|
329
|
+
"returnType": "Promise<AgentPersona[]>",
|
|
330
|
+
"isStatic": false,
|
|
331
|
+
"isPublic": true
|
|
332
|
+
}
|
|
333
|
+
},
|
|
334
|
+
"decoratorConfig": {
|
|
335
|
+
"tableName": "agent_personas"
|
|
336
|
+
},
|
|
337
|
+
"extends": "SmrtCollection",
|
|
338
|
+
"extendsTypeArg": "AgentPersona",
|
|
339
|
+
"exportName": "AgentPersonaCollection",
|
|
340
|
+
"collectionExportName": "AgentPersonaCollectionCollection",
|
|
341
|
+
"schema": {
|
|
342
|
+
"tableName": "agent_personas",
|
|
343
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"agent_personas\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp\n);",
|
|
344
|
+
"columns": {
|
|
345
|
+
"id": {
|
|
346
|
+
"type": "UUID",
|
|
347
|
+
"primaryKey": true,
|
|
348
|
+
"referenceKind": "id",
|
|
349
|
+
"notNull": true
|
|
350
|
+
},
|
|
351
|
+
"slug": {
|
|
352
|
+
"type": "TEXT",
|
|
353
|
+
"notNull": true
|
|
354
|
+
},
|
|
355
|
+
"context": {
|
|
356
|
+
"type": "TEXT",
|
|
357
|
+
"notNull": true,
|
|
358
|
+
"default": ""
|
|
359
|
+
},
|
|
360
|
+
"created_at": {
|
|
361
|
+
"type": "TIMESTAMP",
|
|
362
|
+
"notNull": true,
|
|
363
|
+
"default": "current_timestamp"
|
|
364
|
+
},
|
|
365
|
+
"updated_at": {
|
|
366
|
+
"type": "TIMESTAMP",
|
|
367
|
+
"notNull": true,
|
|
368
|
+
"default": "current_timestamp"
|
|
369
|
+
}
|
|
370
|
+
},
|
|
371
|
+
"indexes": [
|
|
372
|
+
{
|
|
373
|
+
"name": "agent_personas_id_idx",
|
|
374
|
+
"columns": [
|
|
375
|
+
"id"
|
|
376
|
+
]
|
|
377
|
+
},
|
|
378
|
+
{
|
|
379
|
+
"name": "agent_personas_slug_context_idx",
|
|
380
|
+
"columns": [
|
|
381
|
+
"slug",
|
|
382
|
+
"context"
|
|
383
|
+
],
|
|
384
|
+
"unique": true
|
|
385
|
+
}
|
|
386
|
+
],
|
|
387
|
+
"version": "48e54c2f"
|
|
388
|
+
}
|
|
389
|
+
}
|
|
390
|
+
},
|
|
391
|
+
"moduleType": "smrt",
|
|
392
|
+
"smrtDependencies": [
|
|
393
|
+
"@happyvertical/smrt-agents",
|
|
394
|
+
"@happyvertical/smrt-core",
|
|
395
|
+
"@happyvertical/smrt-tenancy"
|
|
396
|
+
]
|
|
397
|
+
}
|