@sudobility/screenwriter_types 0.1.3 → 0.1.4

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.
@@ -0,0 +1,691 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * Synchronous AI actions: `POST /ai/{action}` in screenwriter_api, which authenticates the caller and turns around
4
+ * to one ShapeShyft endpoint of the same name. Unlike the document jobs in `./index.ts` (coverage, polish) these take
5
+ * their whole input in the request body, read no document, and answer in the same HTTP response.
6
+ *
7
+ * The output schemas follow the same convention as `AI_ENDPOINT_OUTPUT_SCHEMAS`: written for structured output, so
8
+ * every field is required (nullable, never optional) and objects are closed — `z.toJSONSchema` gives the exact schema
9
+ * to store on the ShapeShyft endpoint (`bun run ai:schemas` in screenwriter_api prints them). What the API returns to
10
+ * the client is the normalised `*Result` shape (nulls dropped), not the raw model shape.
11
+ */
12
+ export declare const AI_ACTIONS: readonly ["generate-character-skeleton", "generate-script", "polish-character-dialogue", "polish-scene"];
13
+ export type AiAction = (typeof AI_ACTIONS)[number];
14
+ export declare const aiActionSchema: z.ZodEnum<{
15
+ "generate-character-skeleton": "generate-character-skeleton";
16
+ "generate-script": "generate-script";
17
+ "polish-character-dialogue": "polish-character-dialogue";
18
+ "polish-scene": "polish-scene";
19
+ }>;
20
+ /** Counted limits for the action requests, declared once: request schemas, output schemas and prompts read these. */
21
+ export declare const AI_ACTION_LIMITS: {
22
+ /** Free-form text a writer pastes in: a character description, or the story to turn into a script. */
23
+ readonly descriptionMax: 8000;
24
+ readonly storyMax: 30000;
25
+ readonly skeletonFieldMax: 1000;
26
+ readonly characterNameMax: 80;
27
+ readonly languageMax: 35;
28
+ /** Dialogue polish: one character's lines. */
29
+ readonly dialoguesMax: 100;
30
+ readonly dialogueTextMax: 2000;
31
+ /** Scene polish. */
32
+ readonly sceneElementsMax: 300;
33
+ readonly sceneElementTextMax: 2000;
34
+ readonly sceneCharactersMax: 20;
35
+ /** Script generation output. */
36
+ readonly scenesMax: 40;
37
+ readonly elementsPerSceneMax: 200;
38
+ readonly elementTextMax: 2000;
39
+ readonly titleMax: 120;
40
+ readonly locationMax: 120;
41
+ readonly timeMax: 40;
42
+ readonly idMax: 64;
43
+ };
44
+ /** Physical, Social, Psychological — the bone structure. Only `age` is required; every other field is optional. */
45
+ export declare const CHARACTER_SKELETON_FIELDS: {
46
+ readonly physical: readonly ["age", "race", "height", "weight", "appearance", "sexOrientationExperience", "posture", "unusualCharacteristics", "health"];
47
+ readonly social: readonly ["occupationAndAttitude", "education", "money", "class", "relationships", "homeLife", "religion", "placeInCommunity", "politics", "interests"];
48
+ readonly psychological: readonly ["attitudeTowardLife", "moralStandard", "intelligence", "ambitions", "frustrations", "fearsAndObsessions", "extrovertOrIntrovert", "specialQualities", "proudestAchievement", "greatestSorrow", "greatestShame", "noticedFirst", "secret", "noticedLast", "coreContradictions", "deepestDesire"];
49
+ };
50
+ export declare const CHARACTER_SKELETON_KEYS: readonly ["age", "race", "height", "weight", "appearance", "sexOrientationExperience", "posture", "unusualCharacteristics", "health", "occupationAndAttitude", "education", "money", "class", "relationships", "homeLife", "religion", "placeInCommunity", "politics", "interests", "attitudeTowardLife", "moralStandard", "intelligence", "ambitions", "frustrations", "fearsAndObsessions", "extrovertOrIntrovert", "specialQualities", "proudestAchievement", "greatestSorrow", "greatestShame", "noticedFirst", "secret", "noticedLast", "coreContradictions", "deepestDesire"];
51
+ export type CharacterSkeletonKey = (typeof CHARACTER_SKELETON_KEYS)[number];
52
+ /** A skeleton as it is stored and sent between client and API: `age` plus whichever other fields have a value. */
53
+ export declare const characterSkeletonSchema: z.ZodObject<{
54
+ age: z.ZodString;
55
+ health: z.ZodOptional<z.ZodString>;
56
+ appearance: z.ZodOptional<z.ZodString>;
57
+ race: z.ZodOptional<z.ZodString>;
58
+ height: z.ZodOptional<z.ZodString>;
59
+ weight: z.ZodOptional<z.ZodString>;
60
+ sexOrientationExperience: z.ZodOptional<z.ZodString>;
61
+ posture: z.ZodOptional<z.ZodString>;
62
+ unusualCharacteristics: z.ZodOptional<z.ZodString>;
63
+ occupationAndAttitude: z.ZodOptional<z.ZodString>;
64
+ education: z.ZodOptional<z.ZodString>;
65
+ money: z.ZodOptional<z.ZodString>;
66
+ class: z.ZodOptional<z.ZodString>;
67
+ relationships: z.ZodOptional<z.ZodString>;
68
+ homeLife: z.ZodOptional<z.ZodString>;
69
+ religion: z.ZodOptional<z.ZodString>;
70
+ placeInCommunity: z.ZodOptional<z.ZodString>;
71
+ politics: z.ZodOptional<z.ZodString>;
72
+ interests: z.ZodOptional<z.ZodString>;
73
+ attitudeTowardLife: z.ZodOptional<z.ZodString>;
74
+ moralStandard: z.ZodOptional<z.ZodString>;
75
+ intelligence: z.ZodOptional<z.ZodString>;
76
+ ambitions: z.ZodOptional<z.ZodString>;
77
+ frustrations: z.ZodOptional<z.ZodString>;
78
+ fearsAndObsessions: z.ZodOptional<z.ZodString>;
79
+ extrovertOrIntrovert: z.ZodOptional<z.ZodString>;
80
+ specialQualities: z.ZodOptional<z.ZodString>;
81
+ proudestAchievement: z.ZodOptional<z.ZodString>;
82
+ greatestSorrow: z.ZodOptional<z.ZodString>;
83
+ greatestShame: z.ZodOptional<z.ZodString>;
84
+ noticedFirst: z.ZodOptional<z.ZodString>;
85
+ secret: z.ZodOptional<z.ZodString>;
86
+ noticedLast: z.ZodOptional<z.ZodString>;
87
+ coreContradictions: z.ZodOptional<z.ZodString>;
88
+ deepestDesire: z.ZodOptional<z.ZodString>;
89
+ }, z.core.$strip>;
90
+ export type CharacterSkeleton = z.infer<typeof characterSkeletonSchema>;
91
+ export declare const SCRIPT_ELEMENT_TYPES: readonly ["action", "character", "parenthetical", "dialogue", "transition"];
92
+ export type ScriptElementType = (typeof SCRIPT_ELEMENT_TYPES)[number];
93
+ export declare const scriptElementSchema: z.ZodObject<{
94
+ type: z.ZodEnum<{
95
+ action: "action";
96
+ character: "character";
97
+ dialogue: "dialogue";
98
+ parenthetical: "parenthetical";
99
+ transition: "transition";
100
+ }>;
101
+ text: z.ZodString;
102
+ }, z.core.$strict>;
103
+ export type ScriptElement = z.infer<typeof scriptElementSchema>;
104
+ export declare const SCENE_SETTINGS: readonly ["int", "ext", "intExt"];
105
+ export declare const sceneHeadingSchema: z.ZodObject<{
106
+ setting: z.ZodEnum<{
107
+ int: "int";
108
+ ext: "ext";
109
+ intExt: "intExt";
110
+ }>;
111
+ location: z.ZodString;
112
+ time: z.ZodString;
113
+ }, z.core.$strict>;
114
+ export type SceneHeading = z.infer<typeof sceneHeadingSchema>;
115
+ export declare const generatedSceneSchema: z.ZodObject<{
116
+ heading: z.ZodObject<{
117
+ setting: z.ZodEnum<{
118
+ int: "int";
119
+ ext: "ext";
120
+ intExt: "intExt";
121
+ }>;
122
+ location: z.ZodString;
123
+ time: z.ZodString;
124
+ }, z.core.$strict>;
125
+ elements: z.ZodArray<z.ZodObject<{
126
+ type: z.ZodEnum<{
127
+ action: "action";
128
+ character: "character";
129
+ dialogue: "dialogue";
130
+ parenthetical: "parenthetical";
131
+ transition: "transition";
132
+ }>;
133
+ text: z.ZodString;
134
+ }, z.core.$strict>>;
135
+ }, z.core.$strict>;
136
+ export type GeneratedScene = z.infer<typeof generatedSceneSchema>;
137
+ export declare const generateCharacterSkeletonRequestSchema: z.ZodObject<{
138
+ text: z.ZodString;
139
+ language: z.ZodOptional<z.ZodString>;
140
+ }, z.core.$strict>;
141
+ export type GenerateCharacterSkeletonRequest = z.infer<typeof generateCharacterSkeletonRequestSchema>;
142
+ export declare const generateCharacterSkeletonModelSchema: z.ZodObject<{
143
+ skeleton: z.ZodObject<{
144
+ age: z.ZodString;
145
+ health: z.ZodNullable<z.ZodString>;
146
+ appearance: z.ZodNullable<z.ZodString>;
147
+ race: z.ZodNullable<z.ZodString>;
148
+ height: z.ZodNullable<z.ZodString>;
149
+ weight: z.ZodNullable<z.ZodString>;
150
+ sexOrientationExperience: z.ZodNullable<z.ZodString>;
151
+ posture: z.ZodNullable<z.ZodString>;
152
+ unusualCharacteristics: z.ZodNullable<z.ZodString>;
153
+ occupationAndAttitude: z.ZodNullable<z.ZodString>;
154
+ education: z.ZodNullable<z.ZodString>;
155
+ money: z.ZodNullable<z.ZodString>;
156
+ class: z.ZodNullable<z.ZodString>;
157
+ relationships: z.ZodNullable<z.ZodString>;
158
+ homeLife: z.ZodNullable<z.ZodString>;
159
+ religion: z.ZodNullable<z.ZodString>;
160
+ placeInCommunity: z.ZodNullable<z.ZodString>;
161
+ politics: z.ZodNullable<z.ZodString>;
162
+ interests: z.ZodNullable<z.ZodString>;
163
+ attitudeTowardLife: z.ZodNullable<z.ZodString>;
164
+ moralStandard: z.ZodNullable<z.ZodString>;
165
+ intelligence: z.ZodNullable<z.ZodString>;
166
+ ambitions: z.ZodNullable<z.ZodString>;
167
+ frustrations: z.ZodNullable<z.ZodString>;
168
+ fearsAndObsessions: z.ZodNullable<z.ZodString>;
169
+ extrovertOrIntrovert: z.ZodNullable<z.ZodString>;
170
+ specialQualities: z.ZodNullable<z.ZodString>;
171
+ proudestAchievement: z.ZodNullable<z.ZodString>;
172
+ greatestSorrow: z.ZodNullable<z.ZodString>;
173
+ greatestShame: z.ZodNullable<z.ZodString>;
174
+ noticedFirst: z.ZodNullable<z.ZodString>;
175
+ secret: z.ZodNullable<z.ZodString>;
176
+ noticedLast: z.ZodNullable<z.ZodString>;
177
+ coreContradictions: z.ZodNullable<z.ZodString>;
178
+ deepestDesire: z.ZodNullable<z.ZodString>;
179
+ }, z.core.$strict>;
180
+ }, z.core.$strict>;
181
+ export declare const generateCharacterSkeletonResultSchema: z.ZodObject<{
182
+ skeleton: z.ZodObject<{
183
+ age: z.ZodString;
184
+ health: z.ZodOptional<z.ZodString>;
185
+ appearance: z.ZodOptional<z.ZodString>;
186
+ race: z.ZodOptional<z.ZodString>;
187
+ height: z.ZodOptional<z.ZodString>;
188
+ weight: z.ZodOptional<z.ZodString>;
189
+ sexOrientationExperience: z.ZodOptional<z.ZodString>;
190
+ posture: z.ZodOptional<z.ZodString>;
191
+ unusualCharacteristics: z.ZodOptional<z.ZodString>;
192
+ occupationAndAttitude: z.ZodOptional<z.ZodString>;
193
+ education: z.ZodOptional<z.ZodString>;
194
+ money: z.ZodOptional<z.ZodString>;
195
+ class: z.ZodOptional<z.ZodString>;
196
+ relationships: z.ZodOptional<z.ZodString>;
197
+ homeLife: z.ZodOptional<z.ZodString>;
198
+ religion: z.ZodOptional<z.ZodString>;
199
+ placeInCommunity: z.ZodOptional<z.ZodString>;
200
+ politics: z.ZodOptional<z.ZodString>;
201
+ interests: z.ZodOptional<z.ZodString>;
202
+ attitudeTowardLife: z.ZodOptional<z.ZodString>;
203
+ moralStandard: z.ZodOptional<z.ZodString>;
204
+ intelligence: z.ZodOptional<z.ZodString>;
205
+ ambitions: z.ZodOptional<z.ZodString>;
206
+ frustrations: z.ZodOptional<z.ZodString>;
207
+ fearsAndObsessions: z.ZodOptional<z.ZodString>;
208
+ extrovertOrIntrovert: z.ZodOptional<z.ZodString>;
209
+ specialQualities: z.ZodOptional<z.ZodString>;
210
+ proudestAchievement: z.ZodOptional<z.ZodString>;
211
+ greatestSorrow: z.ZodOptional<z.ZodString>;
212
+ greatestShame: z.ZodOptional<z.ZodString>;
213
+ noticedFirst: z.ZodOptional<z.ZodString>;
214
+ secret: z.ZodOptional<z.ZodString>;
215
+ noticedLast: z.ZodOptional<z.ZodString>;
216
+ coreContradictions: z.ZodOptional<z.ZodString>;
217
+ deepestDesire: z.ZodOptional<z.ZodString>;
218
+ }, z.core.$strip>;
219
+ }, z.core.$strict>;
220
+ export type GenerateCharacterSkeletonResult = z.infer<typeof generateCharacterSkeletonResultSchema>;
221
+ export declare const generateScriptRequestSchema: z.ZodObject<{
222
+ story: z.ZodString;
223
+ title: z.ZodOptional<z.ZodString>;
224
+ language: z.ZodOptional<z.ZodString>;
225
+ }, z.core.$strict>;
226
+ export type GenerateScriptRequest = z.infer<typeof generateScriptRequestSchema>;
227
+ export declare const generateScriptModelSchema: z.ZodObject<{
228
+ title: z.ZodNullable<z.ZodString>;
229
+ scenes: z.ZodArray<z.ZodObject<{
230
+ heading: z.ZodObject<{
231
+ setting: z.ZodEnum<{
232
+ int: "int";
233
+ ext: "ext";
234
+ intExt: "intExt";
235
+ }>;
236
+ location: z.ZodString;
237
+ time: z.ZodString;
238
+ }, z.core.$strict>;
239
+ elements: z.ZodArray<z.ZodObject<{
240
+ type: z.ZodEnum<{
241
+ action: "action";
242
+ character: "character";
243
+ dialogue: "dialogue";
244
+ parenthetical: "parenthetical";
245
+ transition: "transition";
246
+ }>;
247
+ text: z.ZodString;
248
+ }, z.core.$strict>>;
249
+ }, z.core.$strict>>;
250
+ }, z.core.$strict>;
251
+ export declare const generateScriptResultSchema: z.ZodObject<{
252
+ title: z.ZodNullable<z.ZodString>;
253
+ scenes: z.ZodArray<z.ZodObject<{
254
+ heading: z.ZodObject<{
255
+ setting: z.ZodEnum<{
256
+ int: "int";
257
+ ext: "ext";
258
+ intExt: "intExt";
259
+ }>;
260
+ location: z.ZodString;
261
+ time: z.ZodString;
262
+ }, z.core.$strict>;
263
+ elements: z.ZodArray<z.ZodObject<{
264
+ type: z.ZodEnum<{
265
+ action: "action";
266
+ character: "character";
267
+ dialogue: "dialogue";
268
+ parenthetical: "parenthetical";
269
+ transition: "transition";
270
+ }>;
271
+ text: z.ZodString;
272
+ }, z.core.$strict>>;
273
+ }, z.core.$strict>>;
274
+ }, z.core.$strict>;
275
+ export type GenerateScriptResult = z.infer<typeof generateScriptResultSchema>;
276
+ export declare const dialogueLineSchema: z.ZodObject<{
277
+ id: z.ZodString;
278
+ text: z.ZodString;
279
+ }, z.core.$strict>;
280
+ export type DialogueLine = z.infer<typeof dialogueLineSchema>;
281
+ export declare const polishCharacterDialogueRequestSchema: z.ZodObject<{
282
+ character: z.ZodString;
283
+ skeleton: z.ZodObject<{
284
+ age: z.ZodString;
285
+ health: z.ZodOptional<z.ZodString>;
286
+ appearance: z.ZodOptional<z.ZodString>;
287
+ race: z.ZodOptional<z.ZodString>;
288
+ height: z.ZodOptional<z.ZodString>;
289
+ weight: z.ZodOptional<z.ZodString>;
290
+ sexOrientationExperience: z.ZodOptional<z.ZodString>;
291
+ posture: z.ZodOptional<z.ZodString>;
292
+ unusualCharacteristics: z.ZodOptional<z.ZodString>;
293
+ occupationAndAttitude: z.ZodOptional<z.ZodString>;
294
+ education: z.ZodOptional<z.ZodString>;
295
+ money: z.ZodOptional<z.ZodString>;
296
+ class: z.ZodOptional<z.ZodString>;
297
+ relationships: z.ZodOptional<z.ZodString>;
298
+ homeLife: z.ZodOptional<z.ZodString>;
299
+ religion: z.ZodOptional<z.ZodString>;
300
+ placeInCommunity: z.ZodOptional<z.ZodString>;
301
+ politics: z.ZodOptional<z.ZodString>;
302
+ interests: z.ZodOptional<z.ZodString>;
303
+ attitudeTowardLife: z.ZodOptional<z.ZodString>;
304
+ moralStandard: z.ZodOptional<z.ZodString>;
305
+ intelligence: z.ZodOptional<z.ZodString>;
306
+ ambitions: z.ZodOptional<z.ZodString>;
307
+ frustrations: z.ZodOptional<z.ZodString>;
308
+ fearsAndObsessions: z.ZodOptional<z.ZodString>;
309
+ extrovertOrIntrovert: z.ZodOptional<z.ZodString>;
310
+ specialQualities: z.ZodOptional<z.ZodString>;
311
+ proudestAchievement: z.ZodOptional<z.ZodString>;
312
+ greatestSorrow: z.ZodOptional<z.ZodString>;
313
+ greatestShame: z.ZodOptional<z.ZodString>;
314
+ noticedFirst: z.ZodOptional<z.ZodString>;
315
+ secret: z.ZodOptional<z.ZodString>;
316
+ noticedLast: z.ZodOptional<z.ZodString>;
317
+ coreContradictions: z.ZodOptional<z.ZodString>;
318
+ deepestDesire: z.ZodOptional<z.ZodString>;
319
+ }, z.core.$strip>;
320
+ dialogues: z.ZodArray<z.ZodObject<{
321
+ id: z.ZodString;
322
+ text: z.ZodString;
323
+ }, z.core.$strict>>;
324
+ intensity: z.ZodOptional<z.ZodEnum<{
325
+ bold: "bold";
326
+ light: "light";
327
+ medium: "medium";
328
+ }>>;
329
+ language: z.ZodOptional<z.ZodString>;
330
+ }, z.core.$strict>;
331
+ export type PolishCharacterDialogueRequest = z.infer<typeof polishCharacterDialogueRequestSchema>;
332
+ export declare const polishCharacterDialogueModelSchema: z.ZodObject<{
333
+ dialogues: z.ZodArray<z.ZodObject<{
334
+ id: z.ZodString;
335
+ text: z.ZodString;
336
+ }, z.core.$strict>>;
337
+ }, z.core.$strict>;
338
+ export declare const polishCharacterDialogueResultSchema: z.ZodObject<{
339
+ dialogues: z.ZodArray<z.ZodObject<{
340
+ id: z.ZodString;
341
+ text: z.ZodString;
342
+ }, z.core.$strict>>;
343
+ }, z.core.$strict>;
344
+ export type PolishCharacterDialogueResult = z.infer<typeof polishCharacterDialogueResultSchema>;
345
+ export declare const sceneCharacterSchema: z.ZodObject<{
346
+ name: z.ZodString;
347
+ skeleton: z.ZodObject<{
348
+ age: z.ZodString;
349
+ health: z.ZodOptional<z.ZodString>;
350
+ appearance: z.ZodOptional<z.ZodString>;
351
+ race: z.ZodOptional<z.ZodString>;
352
+ height: z.ZodOptional<z.ZodString>;
353
+ weight: z.ZodOptional<z.ZodString>;
354
+ sexOrientationExperience: z.ZodOptional<z.ZodString>;
355
+ posture: z.ZodOptional<z.ZodString>;
356
+ unusualCharacteristics: z.ZodOptional<z.ZodString>;
357
+ occupationAndAttitude: z.ZodOptional<z.ZodString>;
358
+ education: z.ZodOptional<z.ZodString>;
359
+ money: z.ZodOptional<z.ZodString>;
360
+ class: z.ZodOptional<z.ZodString>;
361
+ relationships: z.ZodOptional<z.ZodString>;
362
+ homeLife: z.ZodOptional<z.ZodString>;
363
+ religion: z.ZodOptional<z.ZodString>;
364
+ placeInCommunity: z.ZodOptional<z.ZodString>;
365
+ politics: z.ZodOptional<z.ZodString>;
366
+ interests: z.ZodOptional<z.ZodString>;
367
+ attitudeTowardLife: z.ZodOptional<z.ZodString>;
368
+ moralStandard: z.ZodOptional<z.ZodString>;
369
+ intelligence: z.ZodOptional<z.ZodString>;
370
+ ambitions: z.ZodOptional<z.ZodString>;
371
+ frustrations: z.ZodOptional<z.ZodString>;
372
+ fearsAndObsessions: z.ZodOptional<z.ZodString>;
373
+ extrovertOrIntrovert: z.ZodOptional<z.ZodString>;
374
+ specialQualities: z.ZodOptional<z.ZodString>;
375
+ proudestAchievement: z.ZodOptional<z.ZodString>;
376
+ greatestSorrow: z.ZodOptional<z.ZodString>;
377
+ greatestShame: z.ZodOptional<z.ZodString>;
378
+ noticedFirst: z.ZodOptional<z.ZodString>;
379
+ secret: z.ZodOptional<z.ZodString>;
380
+ noticedLast: z.ZodOptional<z.ZodString>;
381
+ coreContradictions: z.ZodOptional<z.ZodString>;
382
+ deepestDesire: z.ZodOptional<z.ZodString>;
383
+ }, z.core.$strip>;
384
+ }, z.core.$strict>;
385
+ export type SceneCharacter = z.infer<typeof sceneCharacterSchema>;
386
+ export declare const polishSceneRequestSchema: z.ZodObject<{
387
+ scene: z.ZodObject<{
388
+ heading: z.ZodOptional<z.ZodString>;
389
+ elements: z.ZodArray<z.ZodObject<{
390
+ type: z.ZodEnum<{
391
+ action: "action";
392
+ character: "character";
393
+ dialogue: "dialogue";
394
+ parenthetical: "parenthetical";
395
+ transition: "transition";
396
+ }>;
397
+ text: z.ZodString;
398
+ }, z.core.$strict>>;
399
+ }, z.core.$strict>;
400
+ characters: z.ZodArray<z.ZodObject<{
401
+ name: z.ZodString;
402
+ skeleton: z.ZodObject<{
403
+ age: z.ZodString;
404
+ health: z.ZodOptional<z.ZodString>;
405
+ appearance: z.ZodOptional<z.ZodString>;
406
+ race: z.ZodOptional<z.ZodString>;
407
+ height: z.ZodOptional<z.ZodString>;
408
+ weight: z.ZodOptional<z.ZodString>;
409
+ sexOrientationExperience: z.ZodOptional<z.ZodString>;
410
+ posture: z.ZodOptional<z.ZodString>;
411
+ unusualCharacteristics: z.ZodOptional<z.ZodString>;
412
+ occupationAndAttitude: z.ZodOptional<z.ZodString>;
413
+ education: z.ZodOptional<z.ZodString>;
414
+ money: z.ZodOptional<z.ZodString>;
415
+ class: z.ZodOptional<z.ZodString>;
416
+ relationships: z.ZodOptional<z.ZodString>;
417
+ homeLife: z.ZodOptional<z.ZodString>;
418
+ religion: z.ZodOptional<z.ZodString>;
419
+ placeInCommunity: z.ZodOptional<z.ZodString>;
420
+ politics: z.ZodOptional<z.ZodString>;
421
+ interests: z.ZodOptional<z.ZodString>;
422
+ attitudeTowardLife: z.ZodOptional<z.ZodString>;
423
+ moralStandard: z.ZodOptional<z.ZodString>;
424
+ intelligence: z.ZodOptional<z.ZodString>;
425
+ ambitions: z.ZodOptional<z.ZodString>;
426
+ frustrations: z.ZodOptional<z.ZodString>;
427
+ fearsAndObsessions: z.ZodOptional<z.ZodString>;
428
+ extrovertOrIntrovert: z.ZodOptional<z.ZodString>;
429
+ specialQualities: z.ZodOptional<z.ZodString>;
430
+ proudestAchievement: z.ZodOptional<z.ZodString>;
431
+ greatestSorrow: z.ZodOptional<z.ZodString>;
432
+ greatestShame: z.ZodOptional<z.ZodString>;
433
+ noticedFirst: z.ZodOptional<z.ZodString>;
434
+ secret: z.ZodOptional<z.ZodString>;
435
+ noticedLast: z.ZodOptional<z.ZodString>;
436
+ coreContradictions: z.ZodOptional<z.ZodString>;
437
+ deepestDesire: z.ZodOptional<z.ZodString>;
438
+ }, z.core.$strip>;
439
+ }, z.core.$strict>>;
440
+ intensity: z.ZodOptional<z.ZodEnum<{
441
+ bold: "bold";
442
+ light: "light";
443
+ medium: "medium";
444
+ }>>;
445
+ language: z.ZodOptional<z.ZodString>;
446
+ }, z.core.$strict>;
447
+ export type PolishSceneRequest = z.infer<typeof polishSceneRequestSchema>;
448
+ /** The scene may be freely rewritten, so the result is a fresh element list rather than a per-id mapping. */
449
+ export declare const polishSceneModelSchema: z.ZodObject<{
450
+ elements: z.ZodArray<z.ZodObject<{
451
+ type: z.ZodEnum<{
452
+ action: "action";
453
+ character: "character";
454
+ dialogue: "dialogue";
455
+ parenthetical: "parenthetical";
456
+ transition: "transition";
457
+ }>;
458
+ text: z.ZodString;
459
+ }, z.core.$strict>>;
460
+ }, z.core.$strict>;
461
+ export declare const polishSceneResultSchema: z.ZodObject<{
462
+ elements: z.ZodArray<z.ZodObject<{
463
+ type: z.ZodEnum<{
464
+ action: "action";
465
+ character: "character";
466
+ dialogue: "dialogue";
467
+ parenthetical: "parenthetical";
468
+ transition: "transition";
469
+ }>;
470
+ text: z.ZodString;
471
+ }, z.core.$strict>>;
472
+ }, z.core.$strict>;
473
+ export type PolishSceneResult = z.infer<typeof polishSceneResultSchema>;
474
+ /** Action -> schema of what the model returns (stored on the ShapeShyft endpoint). */
475
+ export declare const AI_ACTION_MODEL_SCHEMAS: {
476
+ readonly 'generate-character-skeleton': z.ZodObject<{
477
+ skeleton: z.ZodObject<{
478
+ age: z.ZodString;
479
+ health: z.ZodNullable<z.ZodString>;
480
+ appearance: z.ZodNullable<z.ZodString>;
481
+ race: z.ZodNullable<z.ZodString>;
482
+ height: z.ZodNullable<z.ZodString>;
483
+ weight: z.ZodNullable<z.ZodString>;
484
+ sexOrientationExperience: z.ZodNullable<z.ZodString>;
485
+ posture: z.ZodNullable<z.ZodString>;
486
+ unusualCharacteristics: z.ZodNullable<z.ZodString>;
487
+ occupationAndAttitude: z.ZodNullable<z.ZodString>;
488
+ education: z.ZodNullable<z.ZodString>;
489
+ money: z.ZodNullable<z.ZodString>;
490
+ class: z.ZodNullable<z.ZodString>;
491
+ relationships: z.ZodNullable<z.ZodString>;
492
+ homeLife: z.ZodNullable<z.ZodString>;
493
+ religion: z.ZodNullable<z.ZodString>;
494
+ placeInCommunity: z.ZodNullable<z.ZodString>;
495
+ politics: z.ZodNullable<z.ZodString>;
496
+ interests: z.ZodNullable<z.ZodString>;
497
+ attitudeTowardLife: z.ZodNullable<z.ZodString>;
498
+ moralStandard: z.ZodNullable<z.ZodString>;
499
+ intelligence: z.ZodNullable<z.ZodString>;
500
+ ambitions: z.ZodNullable<z.ZodString>;
501
+ frustrations: z.ZodNullable<z.ZodString>;
502
+ fearsAndObsessions: z.ZodNullable<z.ZodString>;
503
+ extrovertOrIntrovert: z.ZodNullable<z.ZodString>;
504
+ specialQualities: z.ZodNullable<z.ZodString>;
505
+ proudestAchievement: z.ZodNullable<z.ZodString>;
506
+ greatestSorrow: z.ZodNullable<z.ZodString>;
507
+ greatestShame: z.ZodNullable<z.ZodString>;
508
+ noticedFirst: z.ZodNullable<z.ZodString>;
509
+ secret: z.ZodNullable<z.ZodString>;
510
+ noticedLast: z.ZodNullable<z.ZodString>;
511
+ coreContradictions: z.ZodNullable<z.ZodString>;
512
+ deepestDesire: z.ZodNullable<z.ZodString>;
513
+ }, z.core.$strict>;
514
+ }, z.core.$strict>;
515
+ readonly 'generate-script': z.ZodObject<{
516
+ title: z.ZodNullable<z.ZodString>;
517
+ scenes: z.ZodArray<z.ZodObject<{
518
+ heading: z.ZodObject<{
519
+ setting: z.ZodEnum<{
520
+ int: "int";
521
+ ext: "ext";
522
+ intExt: "intExt";
523
+ }>;
524
+ location: z.ZodString;
525
+ time: z.ZodString;
526
+ }, z.core.$strict>;
527
+ elements: z.ZodArray<z.ZodObject<{
528
+ type: z.ZodEnum<{
529
+ action: "action";
530
+ character: "character";
531
+ dialogue: "dialogue";
532
+ parenthetical: "parenthetical";
533
+ transition: "transition";
534
+ }>;
535
+ text: z.ZodString;
536
+ }, z.core.$strict>>;
537
+ }, z.core.$strict>>;
538
+ }, z.core.$strict>;
539
+ readonly 'polish-character-dialogue': z.ZodObject<{
540
+ dialogues: z.ZodArray<z.ZodObject<{
541
+ id: z.ZodString;
542
+ text: z.ZodString;
543
+ }, z.core.$strict>>;
544
+ }, z.core.$strict>;
545
+ readonly 'polish-scene': z.ZodObject<{
546
+ elements: z.ZodArray<z.ZodObject<{
547
+ type: z.ZodEnum<{
548
+ action: "action";
549
+ character: "character";
550
+ dialogue: "dialogue";
551
+ parenthetical: "parenthetical";
552
+ transition: "transition";
553
+ }>;
554
+ text: z.ZodString;
555
+ }, z.core.$strict>>;
556
+ }, z.core.$strict>;
557
+ };
558
+ /** Action -> schema of the request body the client sends. */
559
+ export declare const AI_ACTION_REQUEST_SCHEMAS: {
560
+ readonly 'generate-character-skeleton': z.ZodObject<{
561
+ text: z.ZodString;
562
+ language: z.ZodOptional<z.ZodString>;
563
+ }, z.core.$strict>;
564
+ readonly 'generate-script': z.ZodObject<{
565
+ story: z.ZodString;
566
+ title: z.ZodOptional<z.ZodString>;
567
+ language: z.ZodOptional<z.ZodString>;
568
+ }, z.core.$strict>;
569
+ readonly 'polish-character-dialogue': z.ZodObject<{
570
+ character: z.ZodString;
571
+ skeleton: z.ZodObject<{
572
+ age: z.ZodString;
573
+ health: z.ZodOptional<z.ZodString>;
574
+ appearance: z.ZodOptional<z.ZodString>;
575
+ race: z.ZodOptional<z.ZodString>;
576
+ height: z.ZodOptional<z.ZodString>;
577
+ weight: z.ZodOptional<z.ZodString>;
578
+ sexOrientationExperience: z.ZodOptional<z.ZodString>;
579
+ posture: z.ZodOptional<z.ZodString>;
580
+ unusualCharacteristics: z.ZodOptional<z.ZodString>;
581
+ occupationAndAttitude: z.ZodOptional<z.ZodString>;
582
+ education: z.ZodOptional<z.ZodString>;
583
+ money: z.ZodOptional<z.ZodString>;
584
+ class: z.ZodOptional<z.ZodString>;
585
+ relationships: z.ZodOptional<z.ZodString>;
586
+ homeLife: z.ZodOptional<z.ZodString>;
587
+ religion: z.ZodOptional<z.ZodString>;
588
+ placeInCommunity: z.ZodOptional<z.ZodString>;
589
+ politics: z.ZodOptional<z.ZodString>;
590
+ interests: z.ZodOptional<z.ZodString>;
591
+ attitudeTowardLife: z.ZodOptional<z.ZodString>;
592
+ moralStandard: z.ZodOptional<z.ZodString>;
593
+ intelligence: z.ZodOptional<z.ZodString>;
594
+ ambitions: z.ZodOptional<z.ZodString>;
595
+ frustrations: z.ZodOptional<z.ZodString>;
596
+ fearsAndObsessions: z.ZodOptional<z.ZodString>;
597
+ extrovertOrIntrovert: z.ZodOptional<z.ZodString>;
598
+ specialQualities: z.ZodOptional<z.ZodString>;
599
+ proudestAchievement: z.ZodOptional<z.ZodString>;
600
+ greatestSorrow: z.ZodOptional<z.ZodString>;
601
+ greatestShame: z.ZodOptional<z.ZodString>;
602
+ noticedFirst: z.ZodOptional<z.ZodString>;
603
+ secret: z.ZodOptional<z.ZodString>;
604
+ noticedLast: z.ZodOptional<z.ZodString>;
605
+ coreContradictions: z.ZodOptional<z.ZodString>;
606
+ deepestDesire: z.ZodOptional<z.ZodString>;
607
+ }, z.core.$strip>;
608
+ dialogues: z.ZodArray<z.ZodObject<{
609
+ id: z.ZodString;
610
+ text: z.ZodString;
611
+ }, z.core.$strict>>;
612
+ intensity: z.ZodOptional<z.ZodEnum<{
613
+ bold: "bold";
614
+ light: "light";
615
+ medium: "medium";
616
+ }>>;
617
+ language: z.ZodOptional<z.ZodString>;
618
+ }, z.core.$strict>;
619
+ readonly 'polish-scene': z.ZodObject<{
620
+ scene: z.ZodObject<{
621
+ heading: z.ZodOptional<z.ZodString>;
622
+ elements: z.ZodArray<z.ZodObject<{
623
+ type: z.ZodEnum<{
624
+ action: "action";
625
+ character: "character";
626
+ dialogue: "dialogue";
627
+ parenthetical: "parenthetical";
628
+ transition: "transition";
629
+ }>;
630
+ text: z.ZodString;
631
+ }, z.core.$strict>>;
632
+ }, z.core.$strict>;
633
+ characters: z.ZodArray<z.ZodObject<{
634
+ name: z.ZodString;
635
+ skeleton: z.ZodObject<{
636
+ age: z.ZodString;
637
+ health: z.ZodOptional<z.ZodString>;
638
+ appearance: z.ZodOptional<z.ZodString>;
639
+ race: z.ZodOptional<z.ZodString>;
640
+ height: z.ZodOptional<z.ZodString>;
641
+ weight: z.ZodOptional<z.ZodString>;
642
+ sexOrientationExperience: z.ZodOptional<z.ZodString>;
643
+ posture: z.ZodOptional<z.ZodString>;
644
+ unusualCharacteristics: z.ZodOptional<z.ZodString>;
645
+ occupationAndAttitude: z.ZodOptional<z.ZodString>;
646
+ education: z.ZodOptional<z.ZodString>;
647
+ money: z.ZodOptional<z.ZodString>;
648
+ class: z.ZodOptional<z.ZodString>;
649
+ relationships: z.ZodOptional<z.ZodString>;
650
+ homeLife: z.ZodOptional<z.ZodString>;
651
+ religion: z.ZodOptional<z.ZodString>;
652
+ placeInCommunity: z.ZodOptional<z.ZodString>;
653
+ politics: z.ZodOptional<z.ZodString>;
654
+ interests: z.ZodOptional<z.ZodString>;
655
+ attitudeTowardLife: z.ZodOptional<z.ZodString>;
656
+ moralStandard: z.ZodOptional<z.ZodString>;
657
+ intelligence: z.ZodOptional<z.ZodString>;
658
+ ambitions: z.ZodOptional<z.ZodString>;
659
+ frustrations: z.ZodOptional<z.ZodString>;
660
+ fearsAndObsessions: z.ZodOptional<z.ZodString>;
661
+ extrovertOrIntrovert: z.ZodOptional<z.ZodString>;
662
+ specialQualities: z.ZodOptional<z.ZodString>;
663
+ proudestAchievement: z.ZodOptional<z.ZodString>;
664
+ greatestSorrow: z.ZodOptional<z.ZodString>;
665
+ greatestShame: z.ZodOptional<z.ZodString>;
666
+ noticedFirst: z.ZodOptional<z.ZodString>;
667
+ secret: z.ZodOptional<z.ZodString>;
668
+ noticedLast: z.ZodOptional<z.ZodString>;
669
+ coreContradictions: z.ZodOptional<z.ZodString>;
670
+ deepestDesire: z.ZodOptional<z.ZodString>;
671
+ }, z.core.$strip>;
672
+ }, z.core.$strict>>;
673
+ intensity: z.ZodOptional<z.ZodEnum<{
674
+ bold: "bold";
675
+ light: "light";
676
+ medium: "medium";
677
+ }>>;
678
+ language: z.ZodOptional<z.ZodString>;
679
+ }, z.core.$strict>;
680
+ };
681
+ /** What `POST /ai/{action}` returns in `data`: the normalised result plus what the call cost. */
682
+ export interface AiActionUsage {
683
+ /** Credits charged (0 for a site admin). */
684
+ credits: number;
685
+ promptTokens: number;
686
+ completionTokens: number;
687
+ }
688
+ export interface AiActionResponse<R> {
689
+ result: R;
690
+ usage: AiActionUsage;
691
+ }