@character-foundry/character-foundry 0.1.9 → 0.4.0-dev.1765937896
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/app-framework.cjs +291 -95
- package/dist/app-framework.cjs.map +1 -1
- package/dist/app-framework.d.cts +1 -1
- package/dist/app-framework.d.ts +1 -1
- package/dist/app-framework.js +292 -96
- package/dist/app-framework.js.map +1 -1
- package/dist/charx.cjs +44 -23
- package/dist/charx.cjs.map +1 -1
- package/dist/charx.d.cts +368 -207
- package/dist/charx.d.ts +368 -207
- package/dist/charx.js +44 -23
- package/dist/charx.js.map +1 -1
- package/dist/exporter.cjs +27 -22
- package/dist/exporter.cjs.map +1 -1
- package/dist/exporter.d.cts +368 -207
- package/dist/exporter.d.ts +368 -207
- package/dist/exporter.js +27 -22
- package/dist/exporter.js.map +1 -1
- package/dist/federation.cjs +16 -4
- package/dist/federation.cjs.map +1 -1
- package/dist/federation.d.cts +368 -207
- package/dist/federation.d.ts +368 -207
- package/dist/federation.js +16 -4
- package/dist/federation.js.map +1 -1
- package/dist/image-utils.cjs.map +1 -1
- package/dist/image-utils.d.cts +12 -0
- package/dist/image-utils.d.ts +12 -0
- package/dist/image-utils.js.map +1 -1
- package/dist/index.cjs +106 -56
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +708 -423
- package/dist/index.d.ts +708 -423
- package/dist/index.js +106 -56
- package/dist/index.js.map +1 -1
- package/dist/loader.cjs +106 -56
- package/dist/loader.cjs.map +1 -1
- package/dist/loader.d.cts +564 -318
- package/dist/loader.d.ts +564 -318
- package/dist/loader.js +106 -56
- package/dist/loader.js.map +1 -1
- package/dist/lorebook.cjs +5 -5
- package/dist/lorebook.cjs.map +1 -1
- package/dist/lorebook.d.cts +674 -381
- package/dist/lorebook.d.ts +674 -381
- package/dist/lorebook.js +5 -5
- package/dist/lorebook.js.map +1 -1
- package/dist/normalizer.cjs +33 -23
- package/dist/normalizer.cjs.map +1 -1
- package/dist/normalizer.d.cts +896 -560
- package/dist/normalizer.d.ts +896 -560
- package/dist/normalizer.js +33 -23
- package/dist/normalizer.js.map +1 -1
- package/dist/png.cjs +27 -22
- package/dist/png.cjs.map +1 -1
- package/dist/png.d.cts +512 -312
- package/dist/png.d.ts +512 -312
- package/dist/png.js +27 -22
- package/dist/png.js.map +1 -1
- package/dist/schemas.cjs +41 -26
- package/dist/schemas.cjs.map +1 -1
- package/dist/schemas.d.cts +1444 -896
- package/dist/schemas.d.ts +1444 -896
- package/dist/schemas.js +41 -26
- package/dist/schemas.js.map +1 -1
- package/dist/voxta.cjs +48 -25
- package/dist/voxta.cjs.map +1 -1
- package/dist/voxta.d.cts +564 -318
- package/dist/voxta.d.ts +564 -318
- package/dist/voxta.js +48 -25
- package/dist/voxta.js.map +1 -1
- package/package.json +6 -6
package/dist/exporter.cjs
CHANGED
|
@@ -260,22 +260,24 @@ var ExtractedAssetSchema = import_zod.z.object({
|
|
|
260
260
|
mimeType: import_zod.z.string()
|
|
261
261
|
});
|
|
262
262
|
var CCv2LorebookEntrySchema = import_zod2.z.object({
|
|
263
|
-
keys: import_zod2.z.array(import_zod2.z.string()),
|
|
263
|
+
keys: import_zod2.z.array(import_zod2.z.string()).optional(),
|
|
264
|
+
// Some tools use 'key' instead
|
|
264
265
|
content: import_zod2.z.string(),
|
|
265
|
-
enabled: import_zod2.z.boolean(),
|
|
266
|
-
|
|
267
|
-
|
|
266
|
+
enabled: import_zod2.z.boolean().default(true),
|
|
267
|
+
// Default to enabled if missing
|
|
268
|
+
insertion_order: import_zod2.z.number().int().default(0),
|
|
269
|
+
// Optional fields - be lenient with nulls since wild data has them
|
|
268
270
|
extensions: import_zod2.z.record(import_zod2.z.unknown()).optional(),
|
|
269
|
-
case_sensitive: import_zod2.z.boolean().optional(),
|
|
271
|
+
case_sensitive: import_zod2.z.boolean().nullable().optional(),
|
|
270
272
|
name: import_zod2.z.string().optional(),
|
|
271
273
|
priority: import_zod2.z.number().int().optional(),
|
|
272
274
|
id: import_zod2.z.number().int().optional(),
|
|
273
275
|
comment: import_zod2.z.string().optional(),
|
|
274
|
-
selective: import_zod2.z.boolean().optional(),
|
|
276
|
+
selective: import_zod2.z.boolean().nullable().optional(),
|
|
275
277
|
secondary_keys: import_zod2.z.array(import_zod2.z.string()).optional(),
|
|
276
|
-
constant: import_zod2.z.boolean().optional(),
|
|
277
|
-
position: import_zod2.z.enum(["before_char", "after_char"]).optional()
|
|
278
|
-
});
|
|
278
|
+
constant: import_zod2.z.boolean().nullable().optional(),
|
|
279
|
+
position: import_zod2.z.union([import_zod2.z.enum(["before_char", "after_char"]), import_zod2.z.number().int()]).nullable().optional()
|
|
280
|
+
}).passthrough();
|
|
279
281
|
var CCv2CharacterBookSchema = import_zod2.z.object({
|
|
280
282
|
name: import_zod2.z.string().optional(),
|
|
281
283
|
description: import_zod2.z.string().optional(),
|
|
@@ -312,31 +314,34 @@ var CCv2WrappedSchema = import_zod2.z.object({
|
|
|
312
314
|
data: CCv2DataSchema
|
|
313
315
|
});
|
|
314
316
|
var CCv3LorebookEntrySchema = import_zod3.z.object({
|
|
315
|
-
keys: import_zod3.z.array(import_zod3.z.string()),
|
|
317
|
+
keys: import_zod3.z.array(import_zod3.z.string()).optional(),
|
|
318
|
+
// Some tools use 'key' instead
|
|
316
319
|
content: import_zod3.z.string(),
|
|
317
|
-
enabled: import_zod3.z.boolean(),
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
320
|
+
enabled: import_zod3.z.boolean().default(true),
|
|
321
|
+
// Default to enabled if missing
|
|
322
|
+
insertion_order: import_zod3.z.number().int().default(0),
|
|
323
|
+
// Optional fields - be lenient with nulls since wild data has them
|
|
324
|
+
case_sensitive: import_zod3.z.boolean().nullable().optional(),
|
|
321
325
|
name: import_zod3.z.string().optional(),
|
|
322
326
|
priority: import_zod3.z.number().int().optional(),
|
|
323
327
|
id: import_zod3.z.number().int().optional(),
|
|
324
328
|
comment: import_zod3.z.string().optional(),
|
|
325
|
-
selective: import_zod3.z.boolean().optional(),
|
|
329
|
+
selective: import_zod3.z.boolean().nullable().optional(),
|
|
326
330
|
secondary_keys: import_zod3.z.array(import_zod3.z.string()).optional(),
|
|
327
|
-
constant: import_zod3.z.boolean().optional(),
|
|
328
|
-
position: import_zod3.z.enum(["before_char", "after_char"]).optional(),
|
|
331
|
+
constant: import_zod3.z.boolean().nullable().optional(),
|
|
332
|
+
position: import_zod3.z.union([import_zod3.z.enum(["before_char", "after_char"]), import_zod3.z.number().int()]).nullable().optional(),
|
|
329
333
|
extensions: import_zod3.z.record(import_zod3.z.unknown()).optional(),
|
|
330
|
-
// v3 specific
|
|
334
|
+
// v3 specific - also lenient with types since SillyTavern uses numbers for enums
|
|
331
335
|
automation_id: import_zod3.z.string().optional(),
|
|
332
|
-
role: import_zod3.z.enum(["system", "user", "assistant"]).optional(),
|
|
336
|
+
role: import_zod3.z.union([import_zod3.z.enum(["system", "user", "assistant"]), import_zod3.z.number().int()]).nullable().optional(),
|
|
333
337
|
group: import_zod3.z.string().optional(),
|
|
334
338
|
scan_frequency: import_zod3.z.number().int().nonnegative().optional(),
|
|
335
|
-
probability: import_zod3.z.number().min(0).max(
|
|
339
|
+
probability: import_zod3.z.number().min(0).max(100).optional(),
|
|
340
|
+
// Some tools use 0-100 instead of 0-1
|
|
336
341
|
use_regex: import_zod3.z.boolean().optional(),
|
|
337
342
|
depth: import_zod3.z.number().int().nonnegative().optional(),
|
|
338
|
-
selective_logic: import_zod3.z.enum(["AND", "NOT"]).optional()
|
|
339
|
-
});
|
|
343
|
+
selective_logic: import_zod3.z.union([import_zod3.z.enum(["AND", "NOT"]), import_zod3.z.number().int()]).optional()
|
|
344
|
+
}).passthrough();
|
|
340
345
|
var CCv3CharacterBookSchema = import_zod3.z.object({
|
|
341
346
|
name: import_zod3.z.string().optional(),
|
|
342
347
|
description: import_zod3.z.string().optional(),
|