@crowdedkingdoms/crowdyjs 11.0.0 → 12.0.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/MIGRATION.md +118 -0
- package/README.md +208 -0
- package/dist/crowdy-agent/browser-dispatcher.d.ts +41 -0
- package/dist/crowdy-agent/browser-dispatcher.d.ts.map +1 -0
- package/dist/crowdy-agent/browser-dispatcher.js +264 -0
- package/dist/crowdy-agent/controller.d.ts +144 -0
- package/dist/crowdy-agent/controller.d.ts.map +1 -0
- package/dist/crowdy-agent/controller.js +1239 -0
- package/dist/crowdy-agent/errors.d.ts +37 -0
- package/dist/crowdy-agent/errors.d.ts.map +1 -0
- package/dist/crowdy-agent/errors.js +107 -0
- package/dist/crowdy-agent/graphql-transport.d.ts +154 -0
- package/dist/crowdy-agent/graphql-transport.d.ts.map +1 -0
- package/dist/crowdy-agent/graphql-transport.js +854 -0
- package/dist/crowdy-agent/index.d.ts +16 -0
- package/dist/crowdy-agent/index.d.ts.map +1 -0
- package/dist/crowdy-agent/index.js +15 -0
- package/dist/crowdy-agent/registry.d.ts +29 -0
- package/dist/crowdy-agent/registry.d.ts.map +1 -0
- package/dist/crowdy-agent/registry.js +281 -0
- package/dist/crowdy-agent/schema.d.ts +72 -0
- package/dist/crowdy-agent/schema.d.ts.map +1 -0
- package/dist/crowdy-agent/schema.js +467 -0
- package/dist/crowdy-agent/studio-tools.d.ts +15 -0
- package/dist/crowdy-agent/studio-tools.d.ts.map +1 -0
- package/dist/crowdy-agent/studio-tools.js +280 -0
- package/dist/crowdy-agent/tool-descriptors.d.ts +4 -0
- package/dist/crowdy-agent/tool-descriptors.d.ts.map +1 -0
- package/dist/crowdy-agent/tool-descriptors.js +1049 -0
- package/dist/crowdy-agent/transport.d.ts +152 -0
- package/dist/crowdy-agent/transport.d.ts.map +1 -0
- package/dist/crowdy-agent/transport.js +27 -0
- package/dist/crowdy-agent/types.d.ts +328 -0
- package/dist/crowdy-agent/types.d.ts.map +1 -0
- package/dist/crowdy-agent/types.js +37 -0
- package/dist/crowdy-client.d.ts +3 -0
- package/dist/crowdy-client.d.ts.map +1 -1
- package/dist/crowdy-client.js +6 -0
- package/dist/crowdy-studio/agent-dom-shell.d.ts +40 -0
- package/dist/crowdy-studio/agent-dom-shell.d.ts.map +1 -0
- package/dist/crowdy-studio/agent-dom-shell.js +354 -0
- package/dist/crowdy-studio/controller.d.ts +74 -4
- package/dist/crowdy-studio/controller.d.ts.map +1 -1
- package/dist/crowdy-studio/controller.js +450 -17
- package/dist/crowdy-studio/dom-shell.d.ts +4 -1
- package/dist/crowdy-studio/dom-shell.d.ts.map +1 -1
- package/dist/crowdy-studio/dom-shell.js +6 -1
- package/dist/crowdy-studio/index.d.ts +6 -3
- package/dist/crowdy-studio/index.d.ts.map +1 -1
- package/dist/crowdy-studio/index.js +3 -0
- package/dist/crowdy-studio/models.d.ts +67 -0
- package/dist/crowdy-studio/models.d.ts.map +1 -1
- package/dist/crowdy-studio/mount.d.ts +22 -1
- package/dist/crowdy-studio/mount.d.ts.map +1 -1
- package/dist/crowdy-studio/mount.js +163 -2
- package/dist/crowdy-studio/styles.d.ts +1 -1
- package/dist/crowdy-studio/styles.d.ts.map +1 -1
- package/dist/crowdy-studio/styles.js +5 -3
- package/dist/generated/graphql.d.ts +3753 -1
- package/dist/generated/graphql.d.ts.map +1 -1
- package/dist/generated/graphql.js +296 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/kit/npcs.d.ts.map +1 -1
- package/dist/kit/social.d.ts.map +1 -1
- package/dist/player-host/index.d.ts +5 -0
- package/dist/player-host/index.d.ts.map +1 -0
- package/dist/player-host/index.js +3 -0
- package/dist/player-host/lease-manager.d.ts +66 -0
- package/dist/player-host/lease-manager.d.ts.map +1 -0
- package/dist/player-host/lease-manager.js +428 -0
- package/dist/player-host/schemas.d.ts +9 -0
- package/dist/player-host/schemas.d.ts.map +1 -0
- package/dist/player-host/schemas.js +347 -0
- package/dist/player-host/tools.d.ts +13 -0
- package/dist/player-host/tools.d.ts.map +1 -0
- package/dist/player-host/tools.js +79 -0
- package/dist/player-host/types.d.ts +203 -0
- package/dist/player-host/types.d.ts.map +1 -0
- package/dist/player-host/types.js +1 -0
- package/package.json +12 -2
|
@@ -0,0 +1,347 @@
|
|
|
1
|
+
import { assertBoundedJsonSchema, deepFreeze, } from '../crowdy-agent/schema.js';
|
|
2
|
+
import { CROWDY_AGENT_ERROR_CODES } from '../crowdy-agent/errors.js';
|
|
3
|
+
const decimal = () => ({
|
|
4
|
+
type: 'string',
|
|
5
|
+
minLength: 1,
|
|
6
|
+
maxLength: 48,
|
|
7
|
+
pattern: '^-?(0|[1-9][0-9]*)(\\.[0-9]{1,9})?$',
|
|
8
|
+
});
|
|
9
|
+
const text = (maxLength, minLength = 0) => ({
|
|
10
|
+
type: 'string',
|
|
11
|
+
minLength,
|
|
12
|
+
maxLength,
|
|
13
|
+
});
|
|
14
|
+
const enumText = (values) => ({
|
|
15
|
+
type: 'string',
|
|
16
|
+
minLength: 1,
|
|
17
|
+
maxLength: Math.max(...values.map((value) => value.length)),
|
|
18
|
+
enum: values,
|
|
19
|
+
});
|
|
20
|
+
const integer = (minimum, maximum) => ({
|
|
21
|
+
type: 'integer',
|
|
22
|
+
minimum,
|
|
23
|
+
maximum,
|
|
24
|
+
});
|
|
25
|
+
const number = (minimum, maximum) => ({
|
|
26
|
+
type: 'number',
|
|
27
|
+
minimum,
|
|
28
|
+
maximum,
|
|
29
|
+
});
|
|
30
|
+
const boolean = () => ({ type: 'boolean' });
|
|
31
|
+
const dateTime = () => ({
|
|
32
|
+
type: 'string',
|
|
33
|
+
minLength: 20,
|
|
34
|
+
maxLength: 40,
|
|
35
|
+
format: 'date-time',
|
|
36
|
+
});
|
|
37
|
+
const array = (items, maxItems, minItems = 0, uniqueItems = false) => ({
|
|
38
|
+
type: 'array',
|
|
39
|
+
minItems,
|
|
40
|
+
maxItems,
|
|
41
|
+
uniqueItems,
|
|
42
|
+
items,
|
|
43
|
+
});
|
|
44
|
+
const object = (properties, required = Object.keys(properties)) => ({
|
|
45
|
+
type: 'object',
|
|
46
|
+
additionalProperties: false,
|
|
47
|
+
required,
|
|
48
|
+
maxProperties: Object.keys(properties).length,
|
|
49
|
+
properties,
|
|
50
|
+
});
|
|
51
|
+
const vector = object({
|
|
52
|
+
x: decimal(),
|
|
53
|
+
y: decimal(),
|
|
54
|
+
z: decimal(),
|
|
55
|
+
});
|
|
56
|
+
const look = object({
|
|
57
|
+
yaw: decimal(),
|
|
58
|
+
pitch: decimal(),
|
|
59
|
+
});
|
|
60
|
+
const scope = enumText([
|
|
61
|
+
'observe',
|
|
62
|
+
'locomotion',
|
|
63
|
+
'interact',
|
|
64
|
+
'craft',
|
|
65
|
+
'combat',
|
|
66
|
+
'communicate',
|
|
67
|
+
'travel',
|
|
68
|
+
'grid',
|
|
69
|
+
'trust_consent',
|
|
70
|
+
'commerce',
|
|
71
|
+
]);
|
|
72
|
+
const commandKind = enumText([
|
|
73
|
+
'MOVE',
|
|
74
|
+
'LOOK',
|
|
75
|
+
'STOP',
|
|
76
|
+
'INVENTORY_SELECT',
|
|
77
|
+
'INVENTORY_CONSUME',
|
|
78
|
+
'INVENTORY_TRANSFER',
|
|
79
|
+
'INTERACT',
|
|
80
|
+
'CRAFT',
|
|
81
|
+
'MOUNT',
|
|
82
|
+
'COMBAT_ATTACK',
|
|
83
|
+
'CHAT_SEND',
|
|
84
|
+
'TRAVEL_TELEPORT',
|
|
85
|
+
]);
|
|
86
|
+
const planned = {
|
|
87
|
+
observationId: text(128, 1),
|
|
88
|
+
capabilityRevision: text(128, 1),
|
|
89
|
+
controlledEntityId: text(128, 1),
|
|
90
|
+
};
|
|
91
|
+
export const PLAYER_HOST_CAPABILITIES_SCHEMA_V1 = deepFreeze(object({
|
|
92
|
+
contractVersion: {
|
|
93
|
+
...text(20, 20),
|
|
94
|
+
const: 'crowdy.player-host/1',
|
|
95
|
+
},
|
|
96
|
+
gameId: text(128, 1),
|
|
97
|
+
revision: text(128, 1),
|
|
98
|
+
controlledEntityId: text(128, 1),
|
|
99
|
+
commands: array(object({
|
|
100
|
+
kind: commandKind,
|
|
101
|
+
toolName: text(128, 3),
|
|
102
|
+
requiredScope: scope,
|
|
103
|
+
risk: enumText([
|
|
104
|
+
'READ_ONLY',
|
|
105
|
+
'ROUTINE_WRITE',
|
|
106
|
+
'WORLD_CONTROL',
|
|
107
|
+
'DESTRUCTIVE',
|
|
108
|
+
'TRUST_CONSENT',
|
|
109
|
+
'ECONOMIC',
|
|
110
|
+
'IRREVERSIBLE',
|
|
111
|
+
]),
|
|
112
|
+
approval: enumText(['NONE', 'REQUIRED', 'CONDITIONAL']),
|
|
113
|
+
rateLimitPerSecond: integer(1, 100),
|
|
114
|
+
}, ['kind', 'toolName', 'risk', 'approval', 'rateLimitPerSecond']), 64),
|
|
115
|
+
observation: object({
|
|
116
|
+
maxAgeMs: integer(100, 10000),
|
|
117
|
+
maxNearbyActors: integer(0, 128),
|
|
118
|
+
maxNearbyVoxels: integer(0, 256),
|
|
119
|
+
}),
|
|
120
|
+
advertisedAt: dateTime(),
|
|
121
|
+
}));
|
|
122
|
+
export const OBSERVE_REQUEST_SCHEMA_V1 = deepFreeze(object({
|
|
123
|
+
detail: enumText(['MINIMAL', 'STANDARD', 'TACTICAL']),
|
|
124
|
+
maxNearbyActors: integer(0, 64),
|
|
125
|
+
maxNearbyVoxels: integer(0, 128),
|
|
126
|
+
}));
|
|
127
|
+
const inventory = object({
|
|
128
|
+
selectedSlot: integer(0, 255),
|
|
129
|
+
slots: array(object({
|
|
130
|
+
slot: integer(0, 255),
|
|
131
|
+
itemId: text(128, 1),
|
|
132
|
+
quantity: integer(0, 1000000),
|
|
133
|
+
usable: boolean(),
|
|
134
|
+
}), 256),
|
|
135
|
+
craftableRecipeIds: array(text(128, 1), 128, 0, true),
|
|
136
|
+
});
|
|
137
|
+
export const GAME_OBSERVATION_SCHEMA_V1 = deepFreeze(object({
|
|
138
|
+
contractVersion: {
|
|
139
|
+
...text(25, 25),
|
|
140
|
+
const: 'crowdy.game-observation/1',
|
|
141
|
+
},
|
|
142
|
+
observationId: text(128, 1),
|
|
143
|
+
capabilityRevision: text(128, 1),
|
|
144
|
+
controlledEntityId: text(128, 1),
|
|
145
|
+
observedAt: dateTime(),
|
|
146
|
+
expiresAt: dateTime(),
|
|
147
|
+
player: object({
|
|
148
|
+
position: vector,
|
|
149
|
+
velocity: vector,
|
|
150
|
+
look,
|
|
151
|
+
health: decimal(),
|
|
152
|
+
alive: boolean(),
|
|
153
|
+
}),
|
|
154
|
+
controlledEntity: object({
|
|
155
|
+
kind: enumText(['PLAYER', 'MOUNT', 'VEHICLE']),
|
|
156
|
+
position: vector,
|
|
157
|
+
velocity: vector,
|
|
158
|
+
}),
|
|
159
|
+
target: object({
|
|
160
|
+
targetId: text(128, 1),
|
|
161
|
+
kind: enumText(['ACTOR', 'VOXEL', 'OBJECT', 'NONE']),
|
|
162
|
+
distance: decimal(),
|
|
163
|
+
}, ['targetId', 'kind', 'distance']),
|
|
164
|
+
inventory,
|
|
165
|
+
grid: object({
|
|
166
|
+
gridRef: text(128, 1),
|
|
167
|
+
low: vector,
|
|
168
|
+
high: vector,
|
|
169
|
+
effectiveScopes: array(scope, 10, 0, true),
|
|
170
|
+
}),
|
|
171
|
+
nearbyActors: array(object({
|
|
172
|
+
actorId: text(128, 1),
|
|
173
|
+
kind: enumText(['PLAYER', 'NPC', 'MOB', 'OBJECT', 'VEHICLE']),
|
|
174
|
+
position: vector,
|
|
175
|
+
distance: decimal(),
|
|
176
|
+
disposition: enumText([
|
|
177
|
+
'SELF',
|
|
178
|
+
'FRIENDLY',
|
|
179
|
+
'NEUTRAL',
|
|
180
|
+
'HOSTILE',
|
|
181
|
+
'UNKNOWN',
|
|
182
|
+
]),
|
|
183
|
+
label: text(128),
|
|
184
|
+
health: decimal(),
|
|
185
|
+
}, ['actorId', 'kind', 'position', 'distance', 'disposition']), 64),
|
|
186
|
+
nearbyVoxels: array(object({
|
|
187
|
+
position: vector,
|
|
188
|
+
material: text(128, 1),
|
|
189
|
+
interaction: enumText(['NONE', 'MINE', 'PLACE', 'USE']),
|
|
190
|
+
}), 128),
|
|
191
|
+
inputState: object({
|
|
192
|
+
modalOpen: boolean(),
|
|
193
|
+
textInputFocused: boolean(),
|
|
194
|
+
humanInputActive: boolean(),
|
|
195
|
+
}),
|
|
196
|
+
}, [
|
|
197
|
+
'contractVersion',
|
|
198
|
+
'observationId',
|
|
199
|
+
'capabilityRevision',
|
|
200
|
+
'controlledEntityId',
|
|
201
|
+
'observedAt',
|
|
202
|
+
'expiresAt',
|
|
203
|
+
'player',
|
|
204
|
+
'controlledEntity',
|
|
205
|
+
'nearbyActors',
|
|
206
|
+
'nearbyVoxels',
|
|
207
|
+
'inputState',
|
|
208
|
+
]));
|
|
209
|
+
const move = object({
|
|
210
|
+
kind: { ...enumText(['MOVE']), const: 'MOVE' },
|
|
211
|
+
...planned,
|
|
212
|
+
direction: enumText(['FORWARD', 'BACKWARD', 'LEFT', 'RIGHT', 'UP', 'DOWN']),
|
|
213
|
+
intensity: number(0, 1),
|
|
214
|
+
durationMs: integer(16, 2000),
|
|
215
|
+
});
|
|
216
|
+
const lookCommand = object({
|
|
217
|
+
kind: { ...enumText(['LOOK']), const: 'LOOK' },
|
|
218
|
+
...planned,
|
|
219
|
+
deltaYaw: number(-180, 180),
|
|
220
|
+
deltaPitch: number(-90, 90),
|
|
221
|
+
});
|
|
222
|
+
const stop = object({
|
|
223
|
+
kind: { ...enumText(['STOP']), const: 'STOP' },
|
|
224
|
+
});
|
|
225
|
+
const inventorySelect = object({
|
|
226
|
+
kind: { ...enumText(['INVENTORY_SELECT']), const: 'INVENTORY_SELECT' },
|
|
227
|
+
...planned,
|
|
228
|
+
slot: integer(0, 255),
|
|
229
|
+
});
|
|
230
|
+
const inventoryConsume = object({
|
|
231
|
+
kind: { ...enumText(['INVENTORY_CONSUME']), const: 'INVENTORY_CONSUME' },
|
|
232
|
+
...planned,
|
|
233
|
+
slot: integer(0, 255),
|
|
234
|
+
quantity: integer(1, 64),
|
|
235
|
+
});
|
|
236
|
+
const inventoryTransfer = object({
|
|
237
|
+
kind: { ...enumText(['INVENTORY_TRANSFER']), const: 'INVENTORY_TRANSFER' },
|
|
238
|
+
...planned,
|
|
239
|
+
direction: enumText(['TO_CONTAINER', 'FROM_CONTAINER']),
|
|
240
|
+
slot: integer(0, 255),
|
|
241
|
+
quantity: integer(1, 64),
|
|
242
|
+
containerRef: text(128, 1),
|
|
243
|
+
});
|
|
244
|
+
const interact = object({
|
|
245
|
+
kind: { ...enumText(['INTERACT']), const: 'INTERACT' },
|
|
246
|
+
...planned,
|
|
247
|
+
action: enumText(['MINE', 'PLACE', 'USE', 'FISH', 'NPC_TALK']),
|
|
248
|
+
targetRef: text(128, 1),
|
|
249
|
+
inventorySlot: integer(0, 255),
|
|
250
|
+
}, [
|
|
251
|
+
'kind',
|
|
252
|
+
'observationId',
|
|
253
|
+
'capabilityRevision',
|
|
254
|
+
'controlledEntityId',
|
|
255
|
+
'action',
|
|
256
|
+
'targetRef',
|
|
257
|
+
]);
|
|
258
|
+
const craft = object({
|
|
259
|
+
kind: { ...enumText(['CRAFT']), const: 'CRAFT' },
|
|
260
|
+
...planned,
|
|
261
|
+
recipeId: text(128, 1),
|
|
262
|
+
quantity: integer(1, 64),
|
|
263
|
+
});
|
|
264
|
+
const mount = object({
|
|
265
|
+
kind: { ...enumText(['MOUNT']), const: 'MOUNT' },
|
|
266
|
+
...planned,
|
|
267
|
+
action: enumText(['MOUNT', 'DISMOUNT']),
|
|
268
|
+
mountRef: text(128, 1),
|
|
269
|
+
}, [
|
|
270
|
+
'kind',
|
|
271
|
+
'observationId',
|
|
272
|
+
'capabilityRevision',
|
|
273
|
+
'controlledEntityId',
|
|
274
|
+
'action',
|
|
275
|
+
]);
|
|
276
|
+
const attack = object({
|
|
277
|
+
kind: { ...enumText(['COMBAT_ATTACK']), const: 'COMBAT_ATTACK' },
|
|
278
|
+
...planned,
|
|
279
|
+
targetRef: text(128, 1),
|
|
280
|
+
attack: enumText(['PRIMARY', 'SECONDARY']),
|
|
281
|
+
});
|
|
282
|
+
const chat = object({
|
|
283
|
+
kind: { ...enumText(['CHAT_SEND']), const: 'CHAT_SEND' },
|
|
284
|
+
...planned,
|
|
285
|
+
channel: enumText(['LOCAL', 'GROUP']),
|
|
286
|
+
text: text(280, 1),
|
|
287
|
+
});
|
|
288
|
+
const teleport = object({
|
|
289
|
+
kind: { ...enumText(['TRAVEL_TELEPORT']), const: 'TRAVEL_TELEPORT' },
|
|
290
|
+
...planned,
|
|
291
|
+
destinationRef: text(128, 1),
|
|
292
|
+
});
|
|
293
|
+
export const GAME_COMMAND_SCHEMAS_V1 = deepFreeze({
|
|
294
|
+
MOVE: move,
|
|
295
|
+
LOOK: lookCommand,
|
|
296
|
+
STOP: stop,
|
|
297
|
+
INVENTORY_SELECT: inventorySelect,
|
|
298
|
+
INVENTORY_CONSUME: inventoryConsume,
|
|
299
|
+
INVENTORY_TRANSFER: inventoryTransfer,
|
|
300
|
+
INTERACT: interact,
|
|
301
|
+
CRAFT: craft,
|
|
302
|
+
MOUNT: mount,
|
|
303
|
+
COMBAT_ATTACK: attack,
|
|
304
|
+
CHAT_SEND: chat,
|
|
305
|
+
TRAVEL_TELEPORT: teleport,
|
|
306
|
+
});
|
|
307
|
+
export const GAME_COMMAND_SCHEMA_V1 = deepFreeze({
|
|
308
|
+
oneOf: Object.values(GAME_COMMAND_SCHEMAS_V1),
|
|
309
|
+
});
|
|
310
|
+
const error = object({
|
|
311
|
+
code: {
|
|
312
|
+
...text(64, 1),
|
|
313
|
+
enum: CROWDY_AGENT_ERROR_CODES,
|
|
314
|
+
},
|
|
315
|
+
message: text(512, 1),
|
|
316
|
+
retryable: boolean(),
|
|
317
|
+
remediation: text(512, 1),
|
|
318
|
+
field: text(256, 1),
|
|
319
|
+
requiredScope: text(80, 1),
|
|
320
|
+
}, ['code', 'message', 'retryable']);
|
|
321
|
+
export const GAME_COMMAND_RESULT_SCHEMA_V1 = deepFreeze(object({
|
|
322
|
+
contractVersion: {
|
|
323
|
+
...text(28, 28),
|
|
324
|
+
const: 'crowdy.game-command-result/1',
|
|
325
|
+
},
|
|
326
|
+
status: enumText(['SUCCEEDED', 'FAILED', 'DENIED', 'OUTCOME_UNKNOWN']),
|
|
327
|
+
commandKind,
|
|
328
|
+
observationId: text(128, 1),
|
|
329
|
+
details: array(object({
|
|
330
|
+
name: text(64, 1),
|
|
331
|
+
value: text(512),
|
|
332
|
+
}), 32),
|
|
333
|
+
error,
|
|
334
|
+
}, ['contractVersion', 'status', 'commandKind']));
|
|
335
|
+
for (const schema of [
|
|
336
|
+
OBSERVE_REQUEST_SCHEMA_V1,
|
|
337
|
+
...Object.values(GAME_COMMAND_SCHEMAS_V1),
|
|
338
|
+
]) {
|
|
339
|
+
assertBoundedJsonSchema(schema);
|
|
340
|
+
}
|
|
341
|
+
for (const schema of [
|
|
342
|
+
PLAYER_HOST_CAPABILITIES_SCHEMA_V1,
|
|
343
|
+
GAME_OBSERVATION_SCHEMA_V1,
|
|
344
|
+
GAME_COMMAND_RESULT_SCHEMA_V1,
|
|
345
|
+
]) {
|
|
346
|
+
assertBoundedJsonSchema(schema, { rejectAuthorityFields: false });
|
|
347
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { CrowdyAgentBrowserToolHandlersV1 } from '../crowdy-agent/browser-dispatcher.js';
|
|
2
|
+
import type { PlayerHostAdapterV1 } from './types.js';
|
|
3
|
+
import { AgentControlLeaseManager, type AgentControlLeaseManagerOptionsV1 } from './lease-manager.js';
|
|
4
|
+
export interface PlayerHostAgentToolsV1 {
|
|
5
|
+
readonly leaseManager: AgentControlLeaseManager;
|
|
6
|
+
readonly handlers: CrowdyAgentBrowserToolHandlersV1;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* Build the exact generic game-tool router used by a game integration such as
|
|
10
|
+
* Blocks with Friends. Game-specific extensions remain separate descriptors.
|
|
11
|
+
*/
|
|
12
|
+
export declare function createPlayerHostAgentTools(adapter: PlayerHostAdapterV1, options?: AgentControlLeaseManagerOptionsV1): PlayerHostAgentToolsV1;
|
|
13
|
+
//# sourceMappingURL=tools.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tools.d.ts","sourceRoot":"","sources":["../../src/player-host/tools.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,gCAAgC,EACjC,MAAM,uCAAuC,CAAC;AAK/C,OAAO,KAAK,EAIV,mBAAmB,EACpB,MAAM,YAAY,CAAC;AACpB,OAAO,EACL,wBAAwB,EACxB,KAAK,iCAAiC,EACvC,MAAM,oBAAoB,CAAC;AAE5B,MAAM,WAAW,sBAAsB;IACrC,QAAQ,CAAC,YAAY,EAAE,wBAAwB,CAAC;IAChD,QAAQ,CAAC,QAAQ,EAAE,gCAAgC,CAAC;CACrD;AAED;;;GAGG;AACH,wBAAgB,0BAA0B,CACxC,OAAO,EAAE,mBAAmB,EAC5B,OAAO,GAAE,iCAAsC,GAC9C,sBAAsB,CA4DxB"}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import { CrowdyAgentError, CrowdyAgentOutcomeUnknownError, } from '../crowdy-agent/errors.js';
|
|
2
|
+
import { AgentControlLeaseManager, } from './lease-manager.js';
|
|
3
|
+
/**
|
|
4
|
+
* Build the exact generic game-tool router used by a game integration such as
|
|
5
|
+
* Blocks with Friends. Game-specific extensions remain separate descriptors.
|
|
6
|
+
*/
|
|
7
|
+
export function createPlayerHostAgentTools(adapter, options = {}) {
|
|
8
|
+
const leaseManager = new AgentControlLeaseManager(adapter, options);
|
|
9
|
+
const control = (kind) => async (argumentsValue, context) => mapGameResult(await runHostOperation(leaseManager, context.signal, () => leaseManager.dispatch({
|
|
10
|
+
toolCallId: context.invocation.toolCallId,
|
|
11
|
+
clientEpoch: context.invocation.clientEpoch ?? '',
|
|
12
|
+
leaseId: context.invocation.leaseId,
|
|
13
|
+
approvalGrant: context.invocation.approvalGrant,
|
|
14
|
+
command: {
|
|
15
|
+
kind,
|
|
16
|
+
...argumentsValue,
|
|
17
|
+
},
|
|
18
|
+
})));
|
|
19
|
+
return {
|
|
20
|
+
leaseManager,
|
|
21
|
+
handlers: Object.freeze({
|
|
22
|
+
'game.capabilities.get': (_arguments, context) => runHostOperation(leaseManager, context.signal, () => leaseManager.refreshCapabilities()),
|
|
23
|
+
'game.observe': (argumentsValue, context) => runHostOperation(leaseManager, context.signal, () => leaseManager.observe(argumentsValue, {
|
|
24
|
+
clientEpoch: context.invocation.clientEpoch ?? '',
|
|
25
|
+
leaseId: context.invocation.leaseId,
|
|
26
|
+
})),
|
|
27
|
+
'game.control.move': control('MOVE'),
|
|
28
|
+
'game.control.look': control('LOOK'),
|
|
29
|
+
'game.control.stop': control('STOP'),
|
|
30
|
+
'game.inventory.select': control('INVENTORY_SELECT'),
|
|
31
|
+
'game.inventory.consume': control('INVENTORY_CONSUME'),
|
|
32
|
+
'game.inventory.transfer': control('INVENTORY_TRANSFER'),
|
|
33
|
+
'game.interact': control('INTERACT'),
|
|
34
|
+
'game.craft': control('CRAFT'),
|
|
35
|
+
'game.mount': control('MOUNT'),
|
|
36
|
+
'game.combat.attack': control('COMBAT_ATTACK'),
|
|
37
|
+
'game.chat.send': control('CHAT_SEND'),
|
|
38
|
+
'game.travel.teleport': control('TRAVEL_TELEPORT'),
|
|
39
|
+
}),
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
function mapGameResult(result) {
|
|
43
|
+
if (result.status === 'SUCCEEDED')
|
|
44
|
+
return result;
|
|
45
|
+
if (result.status === 'OUTCOME_UNKNOWN') {
|
|
46
|
+
throw new CrowdyAgentOutcomeUnknownError(result.error?.message ??
|
|
47
|
+
'The game command outcome could not be confirmed');
|
|
48
|
+
}
|
|
49
|
+
throw new CrowdyAgentError(result.error?.code ??
|
|
50
|
+
(result.status === 'DENIED'
|
|
51
|
+
? 'AGENT_SCOPE_DENIED'
|
|
52
|
+
: 'AGENT_TOOL_FAILED'), result.error?.message ??
|
|
53
|
+
(result.status === 'DENIED'
|
|
54
|
+
? 'The game command was denied'
|
|
55
|
+
: 'The game command failed'), {
|
|
56
|
+
retryable: result.error?.retryable ?? false,
|
|
57
|
+
...(result.error?.requiredScope
|
|
58
|
+
? { requiredScope: result.error.requiredScope }
|
|
59
|
+
: {}),
|
|
60
|
+
});
|
|
61
|
+
}
|
|
62
|
+
async function runHostOperation(leaseManager, signal, operation) {
|
|
63
|
+
const abort = () => leaseManager.preempt('HUMAN_STOP');
|
|
64
|
+
if (signal.aborted) {
|
|
65
|
+
abort();
|
|
66
|
+
throw new CrowdyAgentError('AGENT_CANCELLED', 'Player host operation was cancelled');
|
|
67
|
+
}
|
|
68
|
+
signal.addEventListener('abort', abort, { once: true });
|
|
69
|
+
try {
|
|
70
|
+
const result = await operation();
|
|
71
|
+
if (signal.aborted) {
|
|
72
|
+
throw new CrowdyAgentError('AGENT_CANCELLED', 'Player host operation was cancelled');
|
|
73
|
+
}
|
|
74
|
+
return result;
|
|
75
|
+
}
|
|
76
|
+
finally {
|
|
77
|
+
signal.removeEventListener('abort', abort);
|
|
78
|
+
}
|
|
79
|
+
}
|
|
@@ -0,0 +1,203 @@
|
|
|
1
|
+
import type { CrowdyAgentApprovalPolicy, CrowdyAgentPreemptionReason, CrowdyAgentToolRisk } from '../crowdy-agent/types.js';
|
|
2
|
+
import type { AgentErrorV1 } from '../crowdy-agent/errors.js';
|
|
3
|
+
/** Decimal strings avoid coordinate precision loss across GraphQL and JSON. */
|
|
4
|
+
export interface PlayerHostVector3V1 {
|
|
5
|
+
readonly x: string;
|
|
6
|
+
readonly y: string;
|
|
7
|
+
readonly z: string;
|
|
8
|
+
}
|
|
9
|
+
export interface PlayerHostLookV1 {
|
|
10
|
+
readonly yaw: string;
|
|
11
|
+
readonly pitch: string;
|
|
12
|
+
}
|
|
13
|
+
export type PlayerHostLeaseScope = 'observe' | 'locomotion' | 'interact' | 'craft' | 'combat' | 'communicate' | 'travel' | 'grid' | 'trust_consent' | 'commerce';
|
|
14
|
+
export type PlayerHostCommandKind = 'MOVE' | 'LOOK' | 'STOP' | 'INVENTORY_SELECT' | 'INVENTORY_CONSUME' | 'INVENTORY_TRANSFER' | 'INTERACT' | 'CRAFT' | 'MOUNT' | 'COMBAT_ATTACK' | 'CHAT_SEND' | 'TRAVEL_TELEPORT';
|
|
15
|
+
export interface PlayerHostCommandCapabilityV1 {
|
|
16
|
+
readonly kind: PlayerHostCommandKind;
|
|
17
|
+
readonly toolName: string;
|
|
18
|
+
readonly requiredScope?: PlayerHostLeaseScope;
|
|
19
|
+
readonly risk: CrowdyAgentToolRisk;
|
|
20
|
+
readonly approval: CrowdyAgentApprovalPolicy;
|
|
21
|
+
readonly rateLimitPerSecond: number;
|
|
22
|
+
}
|
|
23
|
+
export interface PlayerHostCapabilitiesV1 {
|
|
24
|
+
readonly contractVersion: 'crowdy.player-host/1';
|
|
25
|
+
readonly gameId: string;
|
|
26
|
+
readonly revision: string;
|
|
27
|
+
readonly controlledEntityId: string;
|
|
28
|
+
readonly commands: readonly PlayerHostCommandCapabilityV1[];
|
|
29
|
+
readonly observation: {
|
|
30
|
+
readonly maxAgeMs: number;
|
|
31
|
+
readonly maxNearbyActors: number;
|
|
32
|
+
readonly maxNearbyVoxels: number;
|
|
33
|
+
};
|
|
34
|
+
readonly advertisedAt: string;
|
|
35
|
+
}
|
|
36
|
+
export interface ObserveRequestV1 {
|
|
37
|
+
readonly detail: 'MINIMAL' | 'STANDARD' | 'TACTICAL';
|
|
38
|
+
readonly maxNearbyActors: number;
|
|
39
|
+
readonly maxNearbyVoxels: number;
|
|
40
|
+
}
|
|
41
|
+
export interface GameObservationActorV1 {
|
|
42
|
+
readonly actorId: string;
|
|
43
|
+
readonly kind: 'PLAYER' | 'NPC' | 'MOB' | 'OBJECT' | 'VEHICLE';
|
|
44
|
+
readonly position: PlayerHostVector3V1;
|
|
45
|
+
readonly distance: string;
|
|
46
|
+
readonly disposition: 'SELF' | 'FRIENDLY' | 'NEUTRAL' | 'HOSTILE' | 'UNKNOWN';
|
|
47
|
+
readonly label?: string;
|
|
48
|
+
readonly health?: string;
|
|
49
|
+
}
|
|
50
|
+
export interface GameObservationInventoryV1 {
|
|
51
|
+
readonly selectedSlot: number;
|
|
52
|
+
readonly slots: readonly {
|
|
53
|
+
readonly slot: number;
|
|
54
|
+
readonly itemId: string;
|
|
55
|
+
readonly quantity: number;
|
|
56
|
+
readonly usable: boolean;
|
|
57
|
+
}[];
|
|
58
|
+
readonly craftableRecipeIds: readonly string[];
|
|
59
|
+
}
|
|
60
|
+
export interface GameObservationV1 {
|
|
61
|
+
readonly contractVersion: 'crowdy.game-observation/1';
|
|
62
|
+
readonly observationId: string;
|
|
63
|
+
readonly capabilityRevision: string;
|
|
64
|
+
readonly controlledEntityId: string;
|
|
65
|
+
readonly observedAt: string;
|
|
66
|
+
readonly expiresAt: string;
|
|
67
|
+
readonly player: {
|
|
68
|
+
readonly position: PlayerHostVector3V1;
|
|
69
|
+
readonly velocity: PlayerHostVector3V1;
|
|
70
|
+
readonly look: PlayerHostLookV1;
|
|
71
|
+
readonly health: string;
|
|
72
|
+
readonly alive: boolean;
|
|
73
|
+
};
|
|
74
|
+
readonly controlledEntity: {
|
|
75
|
+
readonly kind: 'PLAYER' | 'MOUNT' | 'VEHICLE';
|
|
76
|
+
readonly position: PlayerHostVector3V1;
|
|
77
|
+
readonly velocity: PlayerHostVector3V1;
|
|
78
|
+
};
|
|
79
|
+
readonly target?: {
|
|
80
|
+
readonly targetId: string;
|
|
81
|
+
readonly kind: 'ACTOR' | 'VOXEL' | 'OBJECT' | 'NONE';
|
|
82
|
+
readonly distance: string;
|
|
83
|
+
};
|
|
84
|
+
readonly inventory?: GameObservationInventoryV1;
|
|
85
|
+
readonly grid?: {
|
|
86
|
+
readonly gridRef: string;
|
|
87
|
+
readonly low: PlayerHostVector3V1;
|
|
88
|
+
readonly high: PlayerHostVector3V1;
|
|
89
|
+
readonly effectiveScopes: readonly PlayerHostLeaseScope[];
|
|
90
|
+
};
|
|
91
|
+
readonly nearbyActors: readonly GameObservationActorV1[];
|
|
92
|
+
readonly nearbyVoxels: readonly {
|
|
93
|
+
readonly position: PlayerHostVector3V1;
|
|
94
|
+
readonly material: string;
|
|
95
|
+
readonly interaction: 'NONE' | 'MINE' | 'PLACE' | 'USE';
|
|
96
|
+
}[];
|
|
97
|
+
readonly inputState: {
|
|
98
|
+
readonly modalOpen: boolean;
|
|
99
|
+
readonly textInputFocused: boolean;
|
|
100
|
+
readonly humanInputActive: boolean;
|
|
101
|
+
};
|
|
102
|
+
}
|
|
103
|
+
interface PlannedCommandV1 {
|
|
104
|
+
readonly observationId: string;
|
|
105
|
+
readonly capabilityRevision: string;
|
|
106
|
+
readonly controlledEntityId: string;
|
|
107
|
+
}
|
|
108
|
+
export interface GameMoveCommandV1 extends PlannedCommandV1 {
|
|
109
|
+
readonly kind: 'MOVE';
|
|
110
|
+
readonly direction: 'FORWARD' | 'BACKWARD' | 'LEFT' | 'RIGHT' | 'UP' | 'DOWN';
|
|
111
|
+
readonly intensity: number;
|
|
112
|
+
readonly durationMs: number;
|
|
113
|
+
}
|
|
114
|
+
export interface GameLookCommandV1 extends PlannedCommandV1 {
|
|
115
|
+
readonly kind: 'LOOK';
|
|
116
|
+
readonly deltaYaw: number;
|
|
117
|
+
readonly deltaPitch: number;
|
|
118
|
+
}
|
|
119
|
+
export interface GameStopCommandV1 {
|
|
120
|
+
readonly kind: 'STOP';
|
|
121
|
+
}
|
|
122
|
+
export interface GameInventorySelectCommandV1 extends PlannedCommandV1 {
|
|
123
|
+
readonly kind: 'INVENTORY_SELECT';
|
|
124
|
+
readonly slot: number;
|
|
125
|
+
}
|
|
126
|
+
export interface GameInventoryConsumeCommandV1 extends PlannedCommandV1 {
|
|
127
|
+
readonly kind: 'INVENTORY_CONSUME';
|
|
128
|
+
readonly slot: number;
|
|
129
|
+
readonly quantity: number;
|
|
130
|
+
}
|
|
131
|
+
export interface GameInventoryTransferCommandV1 extends PlannedCommandV1 {
|
|
132
|
+
readonly kind: 'INVENTORY_TRANSFER';
|
|
133
|
+
readonly direction: 'TO_CONTAINER' | 'FROM_CONTAINER';
|
|
134
|
+
readonly slot: number;
|
|
135
|
+
readonly quantity: number;
|
|
136
|
+
readonly containerRef: string;
|
|
137
|
+
}
|
|
138
|
+
export interface GameInteractCommandV1 extends PlannedCommandV1 {
|
|
139
|
+
readonly kind: 'INTERACT';
|
|
140
|
+
readonly action: 'MINE' | 'PLACE' | 'USE' | 'FISH' | 'NPC_TALK';
|
|
141
|
+
readonly targetRef: string;
|
|
142
|
+
readonly inventorySlot?: number;
|
|
143
|
+
}
|
|
144
|
+
export interface GameCraftCommandV1 extends PlannedCommandV1 {
|
|
145
|
+
readonly kind: 'CRAFT';
|
|
146
|
+
readonly recipeId: string;
|
|
147
|
+
readonly quantity: number;
|
|
148
|
+
}
|
|
149
|
+
export interface GameMountCommandV1 extends PlannedCommandV1 {
|
|
150
|
+
readonly kind: 'MOUNT';
|
|
151
|
+
readonly action: 'MOUNT' | 'DISMOUNT';
|
|
152
|
+
readonly mountRef?: string;
|
|
153
|
+
}
|
|
154
|
+
export interface GameCombatAttackCommandV1 extends PlannedCommandV1 {
|
|
155
|
+
readonly kind: 'COMBAT_ATTACK';
|
|
156
|
+
readonly targetRef: string;
|
|
157
|
+
readonly attack: 'PRIMARY' | 'SECONDARY';
|
|
158
|
+
}
|
|
159
|
+
export interface GameChatSendCommandV1 extends PlannedCommandV1 {
|
|
160
|
+
readonly kind: 'CHAT_SEND';
|
|
161
|
+
readonly channel: 'LOCAL' | 'GROUP';
|
|
162
|
+
readonly text: string;
|
|
163
|
+
}
|
|
164
|
+
export interface GameTravelTeleportCommandV1 extends PlannedCommandV1 {
|
|
165
|
+
readonly kind: 'TRAVEL_TELEPORT';
|
|
166
|
+
readonly destinationRef: string;
|
|
167
|
+
}
|
|
168
|
+
export type GameCommandV1 = GameMoveCommandV1 | GameLookCommandV1 | GameStopCommandV1 | GameInventorySelectCommandV1 | GameInventoryConsumeCommandV1 | GameInventoryTransferCommandV1 | GameInteractCommandV1 | GameCraftCommandV1 | GameMountCommandV1 | GameCombatAttackCommandV1 | GameChatSendCommandV1 | GameTravelTeleportCommandV1;
|
|
169
|
+
export interface GameCommandResultV1 {
|
|
170
|
+
readonly contractVersion: 'crowdy.game-command-result/1';
|
|
171
|
+
readonly status: 'SUCCEEDED' | 'FAILED' | 'DENIED' | 'OUTCOME_UNKNOWN';
|
|
172
|
+
readonly commandKind: PlayerHostCommandKind;
|
|
173
|
+
readonly observationId?: string;
|
|
174
|
+
readonly details?: readonly {
|
|
175
|
+
readonly name: string;
|
|
176
|
+
readonly value: string;
|
|
177
|
+
}[];
|
|
178
|
+
readonly error?: AgentErrorV1;
|
|
179
|
+
}
|
|
180
|
+
/** Created only by AgentControlLeaseManager after all local checks pass. */
|
|
181
|
+
export interface ValidatedGateV1 {
|
|
182
|
+
readonly contractVersion: 'crowdy.validated-gate/1';
|
|
183
|
+
readonly clientEpoch: string;
|
|
184
|
+
readonly leaseId?: string;
|
|
185
|
+
readonly scopes: readonly PlayerHostLeaseScope[];
|
|
186
|
+
readonly contextVersion: string;
|
|
187
|
+
readonly observationId?: string;
|
|
188
|
+
readonly validatedAt: string;
|
|
189
|
+
}
|
|
190
|
+
/**
|
|
191
|
+
* Game integration boundary. Implementations call the same typed intent
|
|
192
|
+
* services used by human input; they never expose SDK, DOM, transport, or host
|
|
193
|
+
* call escape hatches.
|
|
194
|
+
*/
|
|
195
|
+
export interface PlayerHostAdapterV1 {
|
|
196
|
+
readonly contractVersion: 'crowdy.player-host/1';
|
|
197
|
+
capabilities(): Promise<PlayerHostCapabilitiesV1>;
|
|
198
|
+
observe(request: ObserveRequestV1): Promise<GameObservationV1>;
|
|
199
|
+
dispatch(command: GameCommandV1, gate: ValidatedGateV1): Promise<GameCommandResultV1>;
|
|
200
|
+
clearAgentIntent(reason: CrowdyAgentPreemptionReason): void;
|
|
201
|
+
}
|
|
202
|
+
export {};
|
|
203
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/player-host/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,yBAAyB,EACzB,2BAA2B,EAC3B,mBAAmB,EACpB,MAAM,0BAA0B,CAAC;AAClC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAE9D,+EAA+E;AAC/E,MAAM,WAAW,mBAAmB;IAClC,QAAQ,CAAC,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;CACxB;AAED,MAAM,MAAM,oBAAoB,GAC5B,SAAS,GACT,YAAY,GACZ,UAAU,GACV,OAAO,GACP,QAAQ,GACR,aAAa,GACb,QAAQ,GACR,MAAM,GACN,eAAe,GACf,UAAU,CAAC;AAEf,MAAM,MAAM,qBAAqB,GAC7B,MAAM,GACN,MAAM,GACN,MAAM,GACN,kBAAkB,GAClB,mBAAmB,GACnB,oBAAoB,GACpB,UAAU,GACV,OAAO,GACP,OAAO,GACP,eAAe,GACf,WAAW,GACX,iBAAiB,CAAC;AAEtB,MAAM,WAAW,6BAA6B;IAC5C,QAAQ,CAAC,IAAI,EAAE,qBAAqB,CAAC;IACrC,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,aAAa,CAAC,EAAE,oBAAoB,CAAC;IAC9C,QAAQ,CAAC,IAAI,EAAE,mBAAmB,CAAC;IACnC,QAAQ,CAAC,QAAQ,EAAE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