@ganju/utils 0.0.21 → 0.0.22
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/data.d.ts +4 -4
- package/dist/data.d.ts.map +1 -1
- package/dist/data.js +16 -2
- package/dist/dataApi.d.ts +32 -2
- package/dist/dataApi.d.ts.map +1 -1
- package/dist/dataApi.js +11 -1
- package/dist/dataCompiler.d.ts +1 -0
- package/dist/dataCompiler.d.ts.map +1 -1
- package/dist/dataCompiler.js +3 -2
- package/dist/dataEngine.d.ts +17 -1
- package/dist/dataEngine.d.ts.map +1 -1
- package/dist/dataEngine.js +368 -10
- package/dist/dataImport.d.ts +3 -0
- package/dist/dataImport.d.ts.map +1 -1
- package/dist/dataImport.js +12 -2
- package/dist/dataRpc.d.ts +9 -1
- package/dist/dataRpc.d.ts.map +1 -1
- package/dist/dataSheet.d.ts +34 -0
- package/dist/dataSheet.d.ts.map +1 -0
- package/dist/dataSheet.js +100 -0
- package/dist/dataTriggers.d.ts +43 -4
- package/dist/dataTriggers.d.ts.map +1 -1
- package/dist/dataTriggers.js +401 -19
- package/dist/dataTypes.d.ts +23 -0
- package/dist/dataTypes.d.ts.map +1 -1
- package/dist/dataTypes.js +15 -1
- package/dist/index.d.ts +35 -4
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -0
- package/dist/localizeDataError.d.ts.map +1 -1
- package/dist/localizeDataError.js +45 -1
- package/dist/schema.d.ts +33 -4
- package/dist/schema.d.ts.map +1 -1
- package/dist/schema.js +26 -3
- package/dist/untrustedContent.d.ts +7 -0
- package/dist/untrustedContent.d.ts.map +1 -1
- package/dist/untrustedContent.js +13 -1
- package/package.json +1 -1
- package/src/data.ts +19 -3
- package/src/dataApi.ts +14 -2
- package/src/dataCompiler.ts +4 -1
- package/src/dataEngine.ts +485 -10
- package/src/dataImport.ts +16 -1
- package/src/dataRpc.ts +10 -1
- package/src/dataSheet.ts +147 -0
- package/src/dataTriggers.ts +528 -19
- package/src/dataTypes.ts +46 -0
- package/src/index.ts +4 -0
- package/src/localizeDataError.ts +82 -1
- package/src/schema.ts +27 -3
- package/src/untrustedContent.ts +15 -0
package/dist/dataTypes.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// The shapes and limits shared by a project's database object (apps/data),
|
|
3
3
|
// the workers that call it, and the tests. Pure: nothing here touches SQLite.
|
|
4
4
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5
|
-
exports.toTableInput = exports.DATA_FILE_LINKS_MAX_URIS = exports.DATA_FILE_URI_MAX = exports.DATA_HISTORY_DAYS = exports.DATA_IMPACT_MAX_IDS = exports.DATA_IMPACT_MAX_ROWS = exports.DATA_COPY_STEP_ROWS = exports.DATA_REBUILD_MAX_ROWS = exports.DATA_MAX_GROUPS = exports.DATA_MAX_GROUP_BY = exports.DATA_MAX_AGGREGATES = exports.DATA_MAX_SORT_KEYS = exports.DATA_MAX_IN_VALUES = exports.DATA_MAX_ENUM_VALUES = exports.DATA_MAX_LABEL = exports.DATA_MAX_DESCRIPTION = exports.DATA_MAX_VALUE_BYTES = exports.DATA_MAX_ROWS_PER_WRITE = exports.DATA_MAX_INSERT_ROWS = exports.DATA_MAX_WRITE_OPERATIONS = exports.DATA_LARGE_TABLE_ROWS = exports.DATA_MAX_RESULT_BYTES = exports.DATA_MAX_PAGE = exports.DATA_DEFAULT_PAGE = exports.DATA_MAX_TABLES = exports.DATA_MAX_COLUMNS = exports.DATA_MAX_STATEMENT_BYTES = exports.DATA_MAX_PARAMS = exports.isDataError = exports.DataError = exports.DATA_ERROR_CODES = exports.DATA_MAX_USAGE_SHAPES = exports.DATA_ON_DELETE = exports.DATA_ACCESS_RANK = exports.DATA_ACCESS_LEVELS = exports.DATA_COLUMN_TYPES = void 0;
|
|
5
|
+
exports.toTableInput = exports.DATA_FILE_LINKS_MAX_URIS = exports.DATA_FILE_URI_MAX = exports.DATA_HISTORY_DAYS = exports.DATA_IMPACT_MAX_IDS = exports.DATA_IMPACT_MAX_ROWS = exports.DATA_COPY_STEP_ROWS = exports.DATA_REBUILD_MAX_ROWS = exports.DATA_MAX_GROUPS = exports.DATA_MAX_GROUP_BY = exports.DATA_MAX_AGGREGATES = exports.DATA_MAX_SORT_KEYS = exports.DATA_MAX_IN_VALUES = exports.DATA_MAX_ENUM_VALUES = exports.DATA_MAX_LABEL = exports.DATA_MAX_DESCRIPTION = exports.DATA_MAX_VALUE_BYTES = exports.DATA_MAX_ROWS_PER_WRITE = exports.DATA_MAX_INSERT_ROWS = exports.DATA_MAX_WRITE_OPERATIONS = exports.DATA_LARGE_TABLE_ROWS = exports.DATA_MAX_RESULT_BYTES = exports.DATA_MAX_PAGE = exports.DATA_DEFAULT_PAGE = exports.DATA_MAX_TABLES = exports.DATA_MAX_COLUMNS = exports.DATA_MAX_STATEMENT_BYTES = exports.DATA_MAX_PARAMS = exports.isDataError = exports.DataError = exports.DATA_ERROR_CODES = exports.DATA_MAX_USAGE_SHAPES = exports.DATA_SHEET_MAX_ROWS = exports.DATA_SHEET_MAX_BYTES = exports.DATA_SHEET_SYNC_ACTOR = exports.DATA_ON_DELETE = exports.DATA_ACCESS_RANK = exports.DATA_ACCESS_LEVELS = exports.DATA_COLUMN_TYPES = void 0;
|
|
6
6
|
exports.DATA_COLUMN_TYPES = [
|
|
7
7
|
'text',
|
|
8
8
|
'long_text',
|
|
@@ -29,6 +29,11 @@ exports.DATA_ACCESS_RANK = {
|
|
|
29
29
|
full: 3
|
|
30
30
|
};
|
|
31
31
|
exports.DATA_ON_DELETE = ['restrict', 'cascade', 'set_null'];
|
|
32
|
+
// Who a sync's changes are made by, in row history and trigger events.
|
|
33
|
+
exports.DATA_SHEET_SYNC_ACTOR = 'system:sheet-sync';
|
|
34
|
+
// A source file is read whole, so it stays small.
|
|
35
|
+
exports.DATA_SHEET_MAX_BYTES = 5 * 1024 * 1024;
|
|
36
|
+
exports.DATA_SHEET_MAX_ROWS = 20_000;
|
|
32
37
|
// At most this many shapes travel back with one call.
|
|
33
38
|
exports.DATA_MAX_USAGE_SHAPES = 20;
|
|
34
39
|
exports.DATA_ERROR_CODES = [
|
|
@@ -134,6 +139,15 @@ const toTableInput = (table) => ({
|
|
|
134
139
|
access: table.access,
|
|
135
140
|
customerScoped: table.customerScoped,
|
|
136
141
|
history: table.history,
|
|
142
|
+
...(table.source
|
|
143
|
+
? {
|
|
144
|
+
source: {
|
|
145
|
+
uri: table.source.uri,
|
|
146
|
+
...(table.source.sheet ? { sheet: table.source.sheet } : {}),
|
|
147
|
+
key: table.source.key
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
: {}),
|
|
137
151
|
columns: table.columns.map(column => {
|
|
138
152
|
const out = { name: column.name, type: column.type };
|
|
139
153
|
if (column.label)
|
package/dist/index.d.ts
CHANGED
|
@@ -202,6 +202,7 @@ export declare const utils: {
|
|
|
202
202
|
}, import("zod/v4/core").$strip>;
|
|
203
203
|
ARTIFACT_CREATE_PROMPT_VIEW: import("zod").ZodObject<{
|
|
204
204
|
description: import("zod").ZodOptional<import("zod").ZodString>;
|
|
205
|
+
title: import("zod").ZodString;
|
|
205
206
|
schema: import("zod").ZodObject<{
|
|
206
207
|
type: import("zod").ZodEnum<{
|
|
207
208
|
[x: string]: string;
|
|
@@ -216,7 +217,6 @@ export declare const utils: {
|
|
|
216
217
|
pattern: import("zod").ZodOptional<import("zod").ZodString>;
|
|
217
218
|
enum: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodAny>>;
|
|
218
219
|
}, import("zod/v4/core").$strip>;
|
|
219
|
-
title: import("zod").ZodString;
|
|
220
220
|
messages: import("zod").ZodArray<import("zod").ZodObject<{
|
|
221
221
|
role: import("zod").ZodEnum<{
|
|
222
222
|
user: "user";
|
|
@@ -256,6 +256,7 @@ export declare const utils: {
|
|
|
256
256
|
}, import("zod/v4/core").$strip>;
|
|
257
257
|
ARTIFACT_UPDATE_PROMPT_VIEW: import("zod").ZodObject<{
|
|
258
258
|
description: import("zod").ZodOptional<import("zod").ZodString>;
|
|
259
|
+
title: import("zod").ZodString;
|
|
259
260
|
schema: import("zod").ZodObject<{
|
|
260
261
|
type: import("zod").ZodEnum<{
|
|
261
262
|
[x: string]: string;
|
|
@@ -270,7 +271,6 @@ export declare const utils: {
|
|
|
270
271
|
pattern: import("zod").ZodOptional<import("zod").ZodString>;
|
|
271
272
|
enum: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodAny>>;
|
|
272
273
|
}, import("zod/v4/core").$strip>;
|
|
273
|
-
title: import("zod").ZodString;
|
|
274
274
|
messages: import("zod").ZodArray<import("zod").ZodObject<{
|
|
275
275
|
role: import("zod").ZodEnum<{
|
|
276
276
|
user: "user";
|
|
@@ -386,6 +386,10 @@ export declare const utils: {
|
|
|
386
386
|
organizationId: import("zod").ZodUUID;
|
|
387
387
|
q: import("zod").ZodOptional<import("zod").ZodString>;
|
|
388
388
|
limit: import("zod").ZodDefault<import("zod").ZodCoercedNumber<unknown>>;
|
|
389
|
+
tabular: import("zod").ZodPipe<import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
390
|
+
1: "1";
|
|
391
|
+
true: "true";
|
|
392
|
+
}>>, import("zod").ZodTransform<boolean, "1" | "true" | undefined>>;
|
|
389
393
|
}, import("zod/v4/core").$strip>;
|
|
390
394
|
ARTIFACT_CREATE_RESOURCE_VIEW: import("zod").ZodObject<{
|
|
391
395
|
type: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
@@ -443,8 +447,8 @@ export declare const utils: {
|
|
|
443
447
|
}>>;
|
|
444
448
|
content: import("zod").ZodOptional<import("zod").ZodString>;
|
|
445
449
|
description: import("zod").ZodOptional<import("zod").ZodString>;
|
|
446
|
-
size: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
447
450
|
title: import("zod").ZodString;
|
|
451
|
+
size: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
448
452
|
crawlConfig: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
449
453
|
maxPages: import("zod").ZodDefault<import("zod").ZodNumber>;
|
|
450
454
|
maxDepth: import("zod").ZodDefault<import("zod").ZodNumber>;
|
|
@@ -704,8 +708,8 @@ export declare const utils: {
|
|
|
704
708
|
}>>;
|
|
705
709
|
content: import("zod").ZodOptional<import("zod").ZodString>;
|
|
706
710
|
description: import("zod").ZodOptional<import("zod").ZodString>;
|
|
707
|
-
size: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
708
711
|
title: import("zod").ZodString;
|
|
712
|
+
size: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
709
713
|
encoding: import("zod").ZodOptional<import("zod").ZodString>;
|
|
710
714
|
fileKey: import("zod").ZodOptional<import("zod").ZodString>;
|
|
711
715
|
annotations: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
@@ -790,6 +794,11 @@ export declare const utils: {
|
|
|
790
794
|
min: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodNumber>>;
|
|
791
795
|
default: import("zod").ZodOptional<import("zod").ZodUnion<readonly [import("zod").ZodString, import("zod").ZodNumber, import("zod").ZodBoolean, import("zod").ZodNull]>>;
|
|
792
796
|
}, import("zod/v4/core").$strict>;
|
|
797
|
+
DATA_TABLE_SOURCE: import("zod").ZodObject<{
|
|
798
|
+
uri: import("zod").ZodString;
|
|
799
|
+
sheet: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodString>>;
|
|
800
|
+
key: import("zod").ZodString;
|
|
801
|
+
}, import("zod/v4/core").$strict>;
|
|
793
802
|
DATA_TABLE_INPUT: import("zod").ZodObject<{
|
|
794
803
|
name: import("zod").ZodString;
|
|
795
804
|
label: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodString>>;
|
|
@@ -803,6 +812,11 @@ export declare const utils: {
|
|
|
803
812
|
}>>;
|
|
804
813
|
customerScoped: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
805
814
|
history: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
815
|
+
source: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodObject<{
|
|
816
|
+
uri: import("zod").ZodString;
|
|
817
|
+
sheet: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodString>>;
|
|
818
|
+
key: import("zod").ZodString;
|
|
819
|
+
}, import("zod/v4/core").$strict>>>;
|
|
806
820
|
columns: import("zod").ZodArray<import("zod").ZodObject<{
|
|
807
821
|
name: import("zod").ZodString;
|
|
808
822
|
type: import("zod").ZodEnum<{
|
|
@@ -841,6 +855,11 @@ export declare const utils: {
|
|
|
841
855
|
}, import("zod/v4/core").$strict>;
|
|
842
856
|
DATA_TABLE_PATCH: import("zod").ZodObject<{
|
|
843
857
|
name: import("zod").ZodOptional<import("zod").ZodString>;
|
|
858
|
+
source: import("zod").ZodOptional<import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodObject<{
|
|
859
|
+
uri: import("zod").ZodString;
|
|
860
|
+
sheet: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodString>>;
|
|
861
|
+
key: import("zod").ZodString;
|
|
862
|
+
}, import("zod/v4/core").$strict>>>>;
|
|
844
863
|
label: import("zod").ZodOptional<import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodString>>>;
|
|
845
864
|
description: import("zod").ZodOptional<import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodString>>>;
|
|
846
865
|
displayColumn: import("zod").ZodOptional<import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodString>>>;
|
|
@@ -1058,7 +1077,12 @@ export declare const utils: {
|
|
|
1058
1077
|
insert: "insert";
|
|
1059
1078
|
update: "update";
|
|
1060
1079
|
delete: "delete";
|
|
1080
|
+
time: "time";
|
|
1061
1081
|
}>;
|
|
1082
|
+
after: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodObject<{
|
|
1083
|
+
column: import("zod").ZodString;
|
|
1084
|
+
minutes: import("zod").ZodNumber;
|
|
1085
|
+
}, import("zod/v4/core").$strict>>>;
|
|
1062
1086
|
when: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnknown>>>;
|
|
1063
1087
|
enabled: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
1064
1088
|
replace: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
@@ -1096,7 +1120,12 @@ export declare const utils: {
|
|
|
1096
1120
|
insert: "insert";
|
|
1097
1121
|
update: "update";
|
|
1098
1122
|
delete: "delete";
|
|
1123
|
+
time: "time";
|
|
1099
1124
|
}>;
|
|
1125
|
+
after: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodObject<{
|
|
1126
|
+
column: import("zod").ZodString;
|
|
1127
|
+
minutes: import("zod").ZodNumber;
|
|
1128
|
+
}, import("zod/v4/core").$strict>>>;
|
|
1100
1129
|
when: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnknown>>>;
|
|
1101
1130
|
enabled: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
1102
1131
|
replace: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
@@ -3860,9 +3889,11 @@ export declare const utils: {
|
|
|
3860
3889
|
stableJson: (value: unknown) => string;
|
|
3861
3890
|
wrapUntrustedContent: (source: string, text: string) => string;
|
|
3862
3891
|
unwrapUntrustedContent: (text: string) => string;
|
|
3892
|
+
stripUntrustedMarks: (text: string) => string;
|
|
3863
3893
|
isUntrustedToolResult: (result: unknown) => boolean;
|
|
3864
3894
|
findInstructionLikeText: (text: string) => string[];
|
|
3865
3895
|
UNTRUSTED_CONTENT_TAG: string;
|
|
3896
|
+
UNTRUSTED_CONTENT_MARK_PATTERN: string;
|
|
3866
3897
|
UNTRUSTED_CONTENT_META_KEY: string;
|
|
3867
3898
|
UNTRUSTED_CONTENT_NOTE: string;
|
|
3868
3899
|
INSTRUCTION_WARNING_METADATA_KEY: string;
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"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AAO,KAAK,EACV,uBAAuB,EACvB,wBAAwB,EACxB,UAAU,EACV,kBAAkB,EAClB,gBAAgB,EACjB,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EACV,sBAAsB,EACtB,kBAAkB,EAClB,sBAAsB,EACtB,0BAA0B,EAC1B,wBAAwB,EACxB,iBAAiB,EACjB,oBAAoB,EACpB,sBAAsB,EACtB,kBAAkB,EAClB,kBAAkB,EAClB,wBAAwB,EACzB,MAAM,UAAU,CAAC;AAElB,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAC1C,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAC;AAyCvD,OAAO,KAAK,EAAE,cAAc,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AACtE,OAAO,KAAK,EACV,cAAc,EACd,gBAAgB,EAChB,iBAAiB,EAClB,MAAM,aAAa,CAAC;AACrB,OAAO,KAAK,EACV,mBAAmB,EACnB,oBAAoB,EACpB,iCAAiC,EAClC,MAAM,gBAAgB,CAAC;AACxB,OAAO,KAAK,EACV,gBAAgB,EAChB,kBAAkB,EAClB,mBAAmB,EACpB,MAAM,eAAe,CAAC;AACvB,OAAO,KAAK,EACV,cAAc,EACd,gBAAgB,EAChB,iBAAiB,EACjB,8BAA8B,EAC/B,MAAM,aAAa,CAAC;AACrB,OAAO,KAAK,EACV,kBAAkB,EAClB,mBAAmB,EACnB,gCAAgC,EACjC,MAAM,eAAe,CAAC;AACvB,OAAO,KAAK,EACV,mBAAmB,EACnB,oBAAoB,EACpB,iCAAiC,EAClC,MAAM,gBAAgB,CAAC;AAKxB,OAAO,EACL,UAAU,EAGX,MAAM,wBAAwB,CAAC;AAChC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAG9D,OAAO,EAIL,kBAAkB,EAEnB,MAAM,cAAc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EACtB,uBAAuB,EACvB,mBAAmB,EACnB,kBAAkB,EAClB,kBAAkB,EAClB,uBAAuB,EACvB,cAAc,EACd,iBAAiB,EACjB,gBAAgB,EAChB,oBAAoB,EACpB,gBAAgB,EAChB,UAAU,EACV,wBAAwB,EACxB,qBAAqB,EACrB,uBAAuB,EACvB,qBAAqB,EACrB,yBAAyB,EAC1B,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -231,9 +231,11 @@ exports.utils = {
|
|
|
231
231
|
stableJson: toolConfirmation_1.stableJson,
|
|
232
232
|
wrapUntrustedContent: untrustedContent_1.wrapUntrustedContent,
|
|
233
233
|
unwrapUntrustedContent: untrustedContent_1.unwrapUntrustedContent,
|
|
234
|
+
stripUntrustedMarks: untrustedContent_1.stripUntrustedMarks,
|
|
234
235
|
isUntrustedToolResult: untrustedContent_1.isUntrustedToolResult,
|
|
235
236
|
findInstructionLikeText: untrustedContent_1.findInstructionLikeText,
|
|
236
237
|
UNTRUSTED_CONTENT_TAG: untrustedContent_1.UNTRUSTED_CONTENT_TAG,
|
|
238
|
+
UNTRUSTED_CONTENT_MARK_PATTERN: untrustedContent_1.UNTRUSTED_CONTENT_MARK_PATTERN,
|
|
237
239
|
UNTRUSTED_CONTENT_META_KEY: untrustedContent_1.UNTRUSTED_CONTENT_META_KEY,
|
|
238
240
|
UNTRUSTED_CONTENT_NOTE: untrustedContent_1.UNTRUSTED_CONTENT_NOTE,
|
|
239
241
|
INSTRUCTION_WARNING_METADATA_KEY: untrustedContent_1.INSTRUCTION_WARNING_METADATA_KEY,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"localizeDataError.d.ts","sourceRoot":"","sources":["../src/localizeDataError.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;GAWG;AACH,KAAK,MAAM,GAAG,CAAC,IAAI,EAAE,MAAM,EAAE,EAAE,MAAM,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,MAAM,KAAK,MAAM,CAAC;AA0C9E,eAAO,MAAM,sBAAsB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,
|
|
1
|
+
{"version":3,"file":"localizeDataError.d.ts","sourceRoot":"","sources":["../src/localizeDataError.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;GAWG;AACH,KAAK,MAAM,GAAG,CAAC,IAAI,EAAE,MAAM,EAAE,EAAE,MAAM,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,MAAM,KAAK,MAAM,CAAC;AA0C9E,eAAO,MAAM,sBAAsB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAkoBlE,CAAC;AA2DF,wEAAwE;AACxE,eAAO,MAAM,iBAAiB,GAC5B,SAAS,MAAM,EACf,UAAU,MAAM,KACf,MAUF,CAAC"}
|
|
@@ -251,7 +251,16 @@ exports.DATA_ERROR_MESSAGES_ES = {
|
|
|
251
251
|
'A trigger is an object.': 'Un disparador es un objeto.',
|
|
252
252
|
'There is no table named {0}.': 'No hay ninguna tabla llamada {0}.',
|
|
253
253
|
'A trigger needs "table".': 'Un disparador necesita "table".',
|
|
254
|
-
'"on" is insert, update or
|
|
254
|
+
'"on" is insert, update, delete or time.': '"on" es insert, update, delete o time.',
|
|
255
|
+
// Time triggers.
|
|
256
|
+
'"after" is for "on": "time" only.': '"after" es solo para "on": "time".',
|
|
257
|
+
'A time trigger needs "after": { "column", "minutes" }, such as { "column": "created_at", "minutes": 30 }.': 'Un disparador por tiempo necesita "after": { "column", "minutes" }, por ejemplo { "column": "created_at", "minutes": 30 }.',
|
|
258
|
+
'"after.column" is created_at, updated_at or a date or datetime column of {0}.': '"after.column" es created_at, updated_at o una columna de fecha o de fecha y hora de {0}.',
|
|
259
|
+
'"after.minutes" is a whole number of minutes from {0} to {1} (30 days), negative for before the column\'s time.': '"after.minutes" es un número entero de minutos de {0} a {1} (30 días), negativo para antes de la hora de la columna.',
|
|
260
|
+
'"after.minutes" can\'t be negative on {0}: that time has already passed when the row is written. Use a date or datetime column for a reminder before.': '"after.minutes" no puede ser negativo en {0}: esa hora ya pasó cuando se escribe la fila. Usa una columna de fecha o de fecha y hora para un recordatorio antes.',
|
|
261
|
+
'"when".{0}.{1}: a time trigger reads the row as it is when it comes due, so its tests are "equals" only.': '"when".{0}.{1}: un disparador por tiempo lee la fila tal como está cuando se cumple el plazo, así que sus pruebas son solo "equals".',
|
|
262
|
+
'A database holds up to {0} time triggers.': 'Una base de datos tiene hasta {0} disparadores por tiempo.',
|
|
263
|
+
'{0}.{1} stays a date or datetime while time triggers count from it ({2}); change or delete them first.': '{0}.{1} debe seguir siendo de fecha o de fecha y hora mientras haya disparadores por tiempo que cuenten desde ella ({2}); cámbialos o elimínalos primero.',
|
|
255
264
|
"A trigger's name is lowercase letters, digits, _ and -, starting with a letter.": 'El nombre de un disparador usa minúsculas, dígitos, _ y -, empezando por una letra.',
|
|
256
265
|
'"rateLimit" is 1 to {0} runs a minute.': '"rateLimit" va de 1 a {0} ejecuciones por minuto.',
|
|
257
266
|
'"enabled" is true or false.': '"enabled" es true o false.',
|
|
@@ -326,6 +335,7 @@ exports.DATA_ERROR_MESSAGES_ES = {
|
|
|
326
335
|
"You haven't linked a chat with this project's bots: write to the bot from your own phone and send /link.": 'No has vinculado un chat con los bots de este proyecto: escríbele al bot desde tu propio teléfono y envía /link.',
|
|
327
336
|
"{0} isn't one of your linked chats with this project's bots.": '{0} no es uno de tus chats vinculados con los bots de este proyecto.',
|
|
328
337
|
'Several of your chats are linked to this project\'s bots; pick one with "participantId".': 'Varios de tus chats están vinculados con los bots de este proyecto; elige uno con "participantId".',
|
|
338
|
+
"This organization's plan no longer includes Data, so its triggers are paused and can't be tested. Upgrade to Pro to send a test.": 'El plan de esta organización ya no incluye Datos, así que sus disparadores están en pausa y no se pueden probar. Pasa a Pro para enviar una prueba.',
|
|
329
339
|
'{0} has no rows yet; add one to build the test from.': '{0} aún no tiene filas; agrega una para armar la prueba.',
|
|
330
340
|
'Reading a row as its trigger event is for the project owner.': 'Leer una fila como su evento de disparador es solo para el dueño del proyecto.',
|
|
331
341
|
// The channel's refusals, which a test send answers with.
|
|
@@ -361,6 +371,40 @@ exports.DATA_ERROR_MESSAGES_ES = {
|
|
|
361
371
|
'The WhatsApp template {0} has {1} variable; {2} values were given.': 'La plantilla de WhatsApp {0} tiene {1} variable; se dieron {2} valores.',
|
|
362
372
|
'The WhatsApp template {0} has {1} variables; {2} value was given.': 'La plantilla de WhatsApp {0} tiene {1} variables; se dio {2} valor.',
|
|
363
373
|
'The WhatsApp template {0} has {1} variables; {2} values were given.': 'La plantilla de WhatsApp {0} tiene {1} variables; se dieron {2} valores.',
|
|
374
|
+
// Tables synced from a sheet
|
|
375
|
+
'{0} is synced from "{1}"; change the sheet, or stop syncing it.': '{0} se sincroniza desde "{1}"; cambia la hoja, o deja de sincronizarla.',
|
|
376
|
+
'"source" is { "uri", "sheet"?, "key" }, or null to stop syncing.': '"source" es { "uri", "sheet"?, "key" }, o null para dejar de sincronizar.',
|
|
377
|
+
'"source" takes uri, sheet and key, not "{0}".': '"source" recibe uri, sheet y key, no "{0}".',
|
|
378
|
+
'"source.uri" is the uri of a spreadsheet or CSV in the project\'s knowledge.': '"source.uri" es el uri de una hoja de cálculo o un CSV en el conocimiento del proyecto.',
|
|
379
|
+
'"source.sheet" is the name of a sheet in the file, up to 100 characters.': '"source.sheet" es el nombre de una hoja del archivo, de hasta 100 caracteres.',
|
|
380
|
+
'"source.key" is the column that names a row in both the sheet and {0}. Columns: {1}.': '"source.key" es la columna que identifica una fila tanto en la hoja como en {0}. Columnas: {1}.',
|
|
381
|
+
'{0}.{1} must be unique to be the sync key.': '{0}.{1} debe ser única para ser la clave de la sincronización.',
|
|
382
|
+
'{0}.{1} is the key the sheet sync matches rows by, so it stays unique.': '{0}.{1} es la clave con la que la sincronización empareja las filas, así que sigue siendo única.',
|
|
383
|
+
"{0}.{1} is the sheet sync's key: rename it on its own, then make the other changes.": '{0}.{1} es la clave de la sincronización: cámbiale el nombre por separado, y luego haz los demás cambios.',
|
|
384
|
+
'{0}.{1} is the key the sheet sync matches rows by; stop syncing the table, or pick another key, first.': '{0}.{1} es la clave con la que la sincronización empareja las filas; primero deja de sincronizar la tabla, o elige otra clave.',
|
|
385
|
+
"{0} isn't synced from a sheet.": '{0} no se sincroniza desde una hoja.',
|
|
386
|
+
'A sync takes "columns" and "rows".': 'Una sincronización recibe "columns" y "rows".',
|
|
387
|
+
"The sheet has no column for {0}'s key, {1}.": 'La hoja no tiene una columna para la clave de {0}, {1}.',
|
|
388
|
+
'The sheet has no column for {0}, which is required.': 'La hoja no tiene una columna para {0}, que es obligatoria.',
|
|
389
|
+
'The sheet has no column for {0}, which are required.': 'La hoja no tiene columnas para {0}, que son obligatorias.',
|
|
390
|
+
'The sheet has {0} rows; a synced table takes up to {1}.': 'La hoja tiene {0} filas; una tabla sincronizada recibe hasta {1}.',
|
|
391
|
+
'Line {0}: {1}': (a, t) => `Línea ${a[0]}: ${t(a[1])}`,
|
|
392
|
+
'A row is an object of column: value.': 'Una fila es un objeto de columna: valor.',
|
|
393
|
+
'The key, {0}, is empty.': 'La clave, {0}, está vacía.',
|
|
394
|
+
'{0} {1} is already on line {2}; each line of the sheet needs its own key.': '{0} {1} ya está en la línea {2}; cada línea de la hoja necesita su propia clave.',
|
|
395
|
+
'Rows in {0} still point at a row the sheet no longer has ({1}.{2}); put them back in the sheet, or change those rows first.': 'Filas de {0} todavía apuntan a una fila que la hoja ya no tiene ({1}.{2}); vuelve a ponerla en la hoja, o cambia esas filas primero.',
|
|
396
|
+
'Rows in {0} still point at {1} rows the sheet no longer has ({2}.{3}); put them back in the sheet, or change those rows first.': 'Filas de {0} todavía apuntan a {1} filas que la hoja ya no tiene ({2}.{3}); vuelve a ponerlas en la hoja, o cambia esas filas primero.',
|
|
397
|
+
"There is no file {0} in the project's knowledge.": 'No hay ningún archivo {0} en el conocimiento del proyecto.',
|
|
398
|
+
'{0} is {1}; a table syncs from a spreadsheet or CSV.': '{0} es {1}; una tabla se sincroniza desde una hoja de cálculo o un CSV.',
|
|
399
|
+
"{0} is no longer in the project's knowledge; pick the file again, or stop syncing {1}.": '{0} ya no está en el conocimiento del proyecto; vuelve a elegir el archivo, o deja de sincronizar {1}.',
|
|
400
|
+
'{0} is over {1} MB; a synced table reads files up to that size.': '{0} pesa más de {1} MB; una tabla sincronizada lee archivos de hasta ese tamaño.',
|
|
401
|
+
'The sheet could not be read; try "Sync now" again in a few minutes.': 'No se pudo leer la hoja; vuelve a intentar "Sincronizar ahora" en unos minutos.',
|
|
402
|
+
"{0} can't be both customer-scoped and synced from a sheet: synced rows have no customer, so the bots wouldn't see them.": '{0} no puede estar limitada al cliente y a la vez sincronizarse desde una hoja: las filas sincronizadas no tienen cliente, así que los bots no las verían.',
|
|
403
|
+
'Can\'t delete: it would change a row of {0} ({1}.{2}), which is synced from "{3}"; change the sheet first, or stop syncing it.': 'No se puede eliminar: cambiaría una fila de {0} ({1}.{2}), que se sincroniza desde "{3}"; primero cambia la hoja, o deja de sincronizarla.',
|
|
404
|
+
'Can\'t delete: it would change {0} rows of {1} ({2}.{3}), which is synced from "{4}"; change the sheet first, or stop syncing it.': 'No se puede eliminar: cambiaría {0} filas de {1} ({2}.{3}), que se sincroniza desde "{4}"; primero cambia la hoja, o deja de sincronizarla.',
|
|
405
|
+
'{0} has no sheet "{1}". Sheets: {2}.': '{0} no tiene una hoja "{1}". Hojas: {2}.',
|
|
406
|
+
'{0} is over {1} MB.': '{0} pesa más de {1} MB.',
|
|
407
|
+
'{0} is {1}; a table reads CSV and Excel files.': '{0} es {1}; una tabla lee archivos CSV y de Excel.',
|
|
364
408
|
'A post needs "chatId".': 'Una publicación necesita "chatId".',
|
|
365
409
|
'WhatsApp has no group chats for bots; message a customer with send().': 'WhatsApp no tiene chats de grupo para bots; escríbele a un cliente con send().'
|
|
366
410
|
};
|
package/dist/schema.d.ts
CHANGED
|
@@ -622,6 +622,7 @@ export declare const Schema: {
|
|
|
622
622
|
}, z.core.$strip>;
|
|
623
623
|
ARTIFACT_CREATE_PROMPT_VIEW: z.ZodObject<{
|
|
624
624
|
description: z.ZodOptional<z.ZodString>;
|
|
625
|
+
title: z.ZodString;
|
|
625
626
|
schema: z.ZodObject<{
|
|
626
627
|
type: z.ZodEnum<{
|
|
627
628
|
[x: string]: string;
|
|
@@ -636,7 +637,6 @@ export declare const Schema: {
|
|
|
636
637
|
pattern: z.ZodOptional<z.ZodString>;
|
|
637
638
|
enum: z.ZodOptional<z.ZodArray<z.ZodAny>>;
|
|
638
639
|
}, z.core.$strip>;
|
|
639
|
-
title: z.ZodString;
|
|
640
640
|
messages: z.ZodArray<z.ZodObject<{
|
|
641
641
|
role: z.ZodEnum<{
|
|
642
642
|
user: "user";
|
|
@@ -676,6 +676,7 @@ export declare const Schema: {
|
|
|
676
676
|
}, z.core.$strip>;
|
|
677
677
|
ARTIFACT_UPDATE_PROMPT_VIEW: z.ZodObject<{
|
|
678
678
|
description: z.ZodOptional<z.ZodString>;
|
|
679
|
+
title: z.ZodString;
|
|
679
680
|
schema: z.ZodObject<{
|
|
680
681
|
type: z.ZodEnum<{
|
|
681
682
|
[x: string]: string;
|
|
@@ -690,7 +691,6 @@ export declare const Schema: {
|
|
|
690
691
|
pattern: z.ZodOptional<z.ZodString>;
|
|
691
692
|
enum: z.ZodOptional<z.ZodArray<z.ZodAny>>;
|
|
692
693
|
}, z.core.$strip>;
|
|
693
|
-
title: z.ZodString;
|
|
694
694
|
messages: z.ZodArray<z.ZodObject<{
|
|
695
695
|
role: z.ZodEnum<{
|
|
696
696
|
user: "user";
|
|
@@ -806,6 +806,10 @@ export declare const Schema: {
|
|
|
806
806
|
organizationId: z.ZodUUID;
|
|
807
807
|
q: z.ZodOptional<z.ZodString>;
|
|
808
808
|
limit: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
809
|
+
tabular: z.ZodPipe<z.ZodOptional<z.ZodEnum<{
|
|
810
|
+
1: "1";
|
|
811
|
+
true: "true";
|
|
812
|
+
}>>, z.ZodTransform<boolean, "1" | "true" | undefined>>;
|
|
809
813
|
}, z.core.$strip>;
|
|
810
814
|
ARTIFACT_CREATE_RESOURCE_VIEW: z.ZodObject<{
|
|
811
815
|
type: z.ZodDefault<z.ZodEnum<{
|
|
@@ -863,8 +867,8 @@ export declare const Schema: {
|
|
|
863
867
|
}>>;
|
|
864
868
|
content: z.ZodOptional<z.ZodString>;
|
|
865
869
|
description: z.ZodOptional<z.ZodString>;
|
|
866
|
-
size: z.ZodOptional<z.ZodNumber>;
|
|
867
870
|
title: z.ZodString;
|
|
871
|
+
size: z.ZodOptional<z.ZodNumber>;
|
|
868
872
|
crawlConfig: z.ZodOptional<z.ZodObject<{
|
|
869
873
|
maxPages: z.ZodDefault<z.ZodNumber>;
|
|
870
874
|
maxDepth: z.ZodDefault<z.ZodNumber>;
|
|
@@ -1124,8 +1128,8 @@ export declare const Schema: {
|
|
|
1124
1128
|
}>>;
|
|
1125
1129
|
content: z.ZodOptional<z.ZodString>;
|
|
1126
1130
|
description: z.ZodOptional<z.ZodString>;
|
|
1127
|
-
size: z.ZodOptional<z.ZodNumber>;
|
|
1128
1131
|
title: z.ZodString;
|
|
1132
|
+
size: z.ZodOptional<z.ZodNumber>;
|
|
1129
1133
|
encoding: z.ZodOptional<z.ZodString>;
|
|
1130
1134
|
fileKey: z.ZodOptional<z.ZodString>;
|
|
1131
1135
|
annotations: z.ZodOptional<z.ZodObject<{
|
|
@@ -1210,6 +1214,11 @@ export declare const Schema: {
|
|
|
1210
1214
|
min: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
1211
1215
|
default: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>>;
|
|
1212
1216
|
}, z.core.$strict>;
|
|
1217
|
+
DATA_TABLE_SOURCE: z.ZodObject<{
|
|
1218
|
+
uri: z.ZodString;
|
|
1219
|
+
sheet: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1220
|
+
key: z.ZodString;
|
|
1221
|
+
}, z.core.$strict>;
|
|
1213
1222
|
DATA_TABLE_INPUT: z.ZodObject<{
|
|
1214
1223
|
name: z.ZodString;
|
|
1215
1224
|
label: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
@@ -1223,6 +1232,11 @@ export declare const Schema: {
|
|
|
1223
1232
|
}>>;
|
|
1224
1233
|
customerScoped: z.ZodOptional<z.ZodBoolean>;
|
|
1225
1234
|
history: z.ZodOptional<z.ZodBoolean>;
|
|
1235
|
+
source: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
1236
|
+
uri: z.ZodString;
|
|
1237
|
+
sheet: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1238
|
+
key: z.ZodString;
|
|
1239
|
+
}, z.core.$strict>>>;
|
|
1226
1240
|
columns: z.ZodArray<z.ZodObject<{
|
|
1227
1241
|
name: z.ZodString;
|
|
1228
1242
|
type: z.ZodEnum<{
|
|
@@ -1261,6 +1275,11 @@ export declare const Schema: {
|
|
|
1261
1275
|
}, z.core.$strict>;
|
|
1262
1276
|
DATA_TABLE_PATCH: z.ZodObject<{
|
|
1263
1277
|
name: z.ZodOptional<z.ZodString>;
|
|
1278
|
+
source: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
1279
|
+
uri: z.ZodString;
|
|
1280
|
+
sheet: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1281
|
+
key: z.ZodString;
|
|
1282
|
+
}, z.core.$strict>>>>;
|
|
1264
1283
|
label: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
1265
1284
|
description: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
1266
1285
|
displayColumn: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
@@ -1478,7 +1497,12 @@ export declare const Schema: {
|
|
|
1478
1497
|
insert: "insert";
|
|
1479
1498
|
update: "update";
|
|
1480
1499
|
delete: "delete";
|
|
1500
|
+
time: "time";
|
|
1481
1501
|
}>;
|
|
1502
|
+
after: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
1503
|
+
column: z.ZodString;
|
|
1504
|
+
minutes: z.ZodNumber;
|
|
1505
|
+
}, z.core.$strict>>>;
|
|
1482
1506
|
when: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
1483
1507
|
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
1484
1508
|
replace: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -1516,7 +1540,12 @@ export declare const Schema: {
|
|
|
1516
1540
|
insert: "insert";
|
|
1517
1541
|
update: "update";
|
|
1518
1542
|
delete: "delete";
|
|
1543
|
+
time: "time";
|
|
1519
1544
|
}>;
|
|
1545
|
+
after: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
1546
|
+
column: z.ZodString;
|
|
1547
|
+
minutes: z.ZodNumber;
|
|
1548
|
+
}, z.core.$strict>>>;
|
|
1520
1549
|
when: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
1521
1550
|
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
1522
1551
|
replace: z.ZodOptional<z.ZodBoolean>;
|
package/dist/schema.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../src/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../src/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAosCxB,QAAA,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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AM,CAAC;QAAC,QAAQ,CAAC,EAAE,OAAO,CAAA;KAAE,EAAE,CAAC;CAC1E;AAMD,MAAM,WAAW,iBAAiB;IAChC,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,CAAC,EAAE;QAAE,IAAI,CAAC,EAAE,MAAM,CAAC;QAAC,OAAO,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;IACjD,KAAK,EAAE,sBAAsB,EAAE,CAAC;IAChC,SAAS,CAAC,EAAE,0BAA0B,EAAE,CAAC;IACzC,OAAO,CAAC,EAAE,wBAAwB,EAAE,CAAC;CACtC"}
|
package/dist/schema.js
CHANGED
|
@@ -436,7 +436,12 @@ const ARTIFACT_PICK_RESOURCE = zod_1.z.object({
|
|
|
436
436
|
userId: zod_1.z.uuid(),
|
|
437
437
|
organizationId: zod_1.z.uuid(),
|
|
438
438
|
q: zod_1.z.string().trim().max(200).optional(),
|
|
439
|
-
limit: zod_1.z.coerce.number().int().min(1).max(50).default(20)
|
|
439
|
+
limit: zod_1.z.coerce.number().int().min(1).max(50).default(20),
|
|
440
|
+
// Only spreadsheets and CSV, for a table's sheet source.
|
|
441
|
+
tabular: zod_1.z
|
|
442
|
+
.enum(['1', 'true'])
|
|
443
|
+
.optional()
|
|
444
|
+
.transform(v => v !== undefined)
|
|
440
445
|
});
|
|
441
446
|
const ARTIFACT_REMOVE_RESOURCE = zod_1.z.object({
|
|
442
447
|
resourceId: zod_1.z.uuid(),
|
|
@@ -488,6 +493,13 @@ const DATA_COLUMN_INPUT = zod_1.z.strictObject({
|
|
|
488
493
|
default: DATA_DEFAULT_VALUE.optional()
|
|
489
494
|
});
|
|
490
495
|
// The CLI's schema file holds a list of these.
|
|
496
|
+
// A spreadsheet or CSV in the project's knowledge the table's rows come
|
|
497
|
+
// from, matched by `key`. Null stops syncing.
|
|
498
|
+
const DATA_TABLE_SOURCE = zod_1.z.strictObject({
|
|
499
|
+
uri: zod_1.z.string().min(1).max(2048),
|
|
500
|
+
sheet: zod_1.z.string().trim().min(1).max(100).nullable().optional(),
|
|
501
|
+
key: DATA_IDENTIFIER
|
|
502
|
+
});
|
|
491
503
|
const DATA_TABLE_INPUT = zod_1.z.strictObject({
|
|
492
504
|
name: DATA_IDENTIFIER,
|
|
493
505
|
label: DATA_TEXT(dataTypes_1.DATA_MAX_LABEL),
|
|
@@ -496,6 +508,7 @@ const DATA_TABLE_INPUT = zod_1.z.strictObject({
|
|
|
496
508
|
access: zod_1.z.enum(dataTypes_1.DATA_ACCESS_LEVELS).optional(),
|
|
497
509
|
customerScoped: zod_1.z.boolean().optional(),
|
|
498
510
|
history: zod_1.z.boolean().optional(),
|
|
511
|
+
source: DATA_TABLE_SOURCE.nullable().optional(),
|
|
499
512
|
columns: zod_1.z.array(DATA_COLUMN_INPUT).max(dataTypes_1.DATA_MAX_COLUMNS)
|
|
500
513
|
});
|
|
501
514
|
const DATA_TABLE_PATCH = DATA_TABLE_INPUT.omit({ columns: true }).partial();
|
|
@@ -670,9 +683,18 @@ const DATA_TRIGGER_INPUT = zod_1.z.strictObject({
|
|
|
670
683
|
name: DATA_TRIGGER_NAME.optional(),
|
|
671
684
|
description: zod_1.z.string().max(300).nullish(),
|
|
672
685
|
table: DATA_IDENTIFIER,
|
|
673
|
-
on: zod_1.z.enum(['insert', 'update', 'delete']),
|
|
686
|
+
on: zod_1.z.enum(['insert', 'update', 'delete', 'time']),
|
|
687
|
+
// With "time": fires this many minutes after the column's time (negative:
|
|
688
|
+
// before it). The column is created_at, updated_at or a date / datetime.
|
|
689
|
+
after: zod_1.z
|
|
690
|
+
.strictObject({
|
|
691
|
+
column: DATA_IDENTIFIER,
|
|
692
|
+
minutes: zod_1.z.number().int().min(-43_200).max(43_200)
|
|
693
|
+
})
|
|
694
|
+
.nullish(),
|
|
674
695
|
// { column: { changedTo | changedFrom | equals: value, changed: true } },
|
|
675
|
-
// combined with { all: [...] } or { any: [...] }.
|
|
696
|
+
// combined with { all: [...] } or { any: [...] }. A time trigger takes
|
|
697
|
+
// equals only.
|
|
676
698
|
when: zod_1.z.record(zod_1.z.string(), zod_1.z.unknown()).nullish(),
|
|
677
699
|
enabled: zod_1.z.boolean().optional(),
|
|
678
700
|
// false: refuse to save over an existing trigger of this name.
|
|
@@ -1906,6 +1928,7 @@ exports.Schema = {
|
|
|
1906
1928
|
DATA_DATABASE_CREATE,
|
|
1907
1929
|
DATA_DATABASE_DELETE,
|
|
1908
1930
|
DATA_COLUMN_INPUT,
|
|
1931
|
+
DATA_TABLE_SOURCE,
|
|
1909
1932
|
DATA_TABLE_INPUT,
|
|
1910
1933
|
DATA_TABLE_PATCH,
|
|
1911
1934
|
DATA_COLUMN_PATCH,
|
|
@@ -13,6 +13,13 @@ export declare const wrapUntrustedContent: (source: string, text: string) => str
|
|
|
13
13
|
* returned as it is.
|
|
14
14
|
*/
|
|
15
15
|
export declare const unwrapUntrustedContent: (text: string) => string;
|
|
16
|
+
export declare const UNTRUSTED_CONTENT_MARK_PATTERN: string;
|
|
17
|
+
/**
|
|
18
|
+
* Text with the marks around every wrapped block removed and the bodies kept,
|
|
19
|
+
* for showing a recorded result to a person: an error that quotes an
|
|
20
|
+
* endpoint's answer reads as the message and the answer.
|
|
21
|
+
*/
|
|
22
|
+
export declare const stripUntrustedMarks: (text: string) => string;
|
|
16
23
|
/** Whether a tool result carries the flag set by the server that ran it. */
|
|
17
24
|
export declare const isUntrustedToolResult: (result: unknown) => boolean;
|
|
18
25
|
export declare const INSTRUCTION_WARNING_METADATA_KEY = "instructionWarning";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"untrustedContent.d.ts","sourceRoot":"","sources":["../src/untrustedContent.ts"],"names":[],"mappings":"AAYA,eAAO,MAAM,qBAAqB,sBAAsB,CAAC;AAMzD,eAAO,MAAM,0BAA0B,uBAAuB,CAAC;AAI/D,eAAO,MAAM,sBAAsB,QASO,CAAC;AA0D3C;;;;GAIG;AACH,eAAO,MAAM,oBAAoB,GAAI,QAAQ,MAAM,EAAE,MAAM,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AC;IAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAA;CAAE,CAAC;AAE9E;;;;;GAKG;AACH,eAAO,MAAM,qBAAqB,GAAI,CAAC,SAAS,eAAe,EAC7D,UAAU,CAAC,EAAE,KACZ;IAAE,QAAQ,EAAE,CAAC,EAAE,CAAC;IAAC,eAAe,EAAE,OAAO,CAAA;CAW3C,CAAC;AA6BF;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,sBAAsB,GACjC,KAAK;IAAE,OAAO,CAAC,EAAE,OAAO,CAAC;IAAC,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAAC,OAAO,CAAC,EAAE,OAAO,CAAA;CAAE,EAC1E,QAAQ,MAAM,EACd,UAAU,MAAM,KACf,kBAsCF,CAAC"}
|
package/dist/untrustedContent.js
CHANGED
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
//
|
|
12
12
|
// Imports nothing, so the tests can load it on their own.
|
|
13
13
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
14
|
-
exports.labelProxiedToolResult = exports.labelResourceContents = exports.readsLikeInstructions = exports.untrustedErrorResult = exports.labelOwnToolResult = exports.ownWritingToolResult = exports.untrustedToolResult = exports.findInstructionLikeText = exports.INSTRUCTION_WARNING_METADATA_KEY = exports.isUntrustedToolResult = exports.unwrapUntrustedContent = exports.wrapUntrustedContent = exports.UNTRUSTED_CONTENT_NOTE = exports.UNTRUSTED_CONTENT_META_KEY = exports.UNTRUSTED_CONTENT_TAG = void 0;
|
|
14
|
+
exports.labelProxiedToolResult = exports.labelResourceContents = exports.readsLikeInstructions = exports.untrustedErrorResult = exports.labelOwnToolResult = exports.ownWritingToolResult = exports.untrustedToolResult = exports.findInstructionLikeText = exports.INSTRUCTION_WARNING_METADATA_KEY = exports.isUntrustedToolResult = exports.stripUntrustedMarks = exports.UNTRUSTED_CONTENT_MARK_PATTERN = exports.unwrapUntrustedContent = exports.wrapUntrustedContent = exports.UNTRUSTED_CONTENT_NOTE = exports.UNTRUSTED_CONTENT_META_KEY = exports.UNTRUSTED_CONTENT_TAG = void 0;
|
|
15
15
|
exports.UNTRUSTED_CONTENT_TAG = 'untrusted_content';
|
|
16
16
|
// Set on a tool result, under `_meta`, when the text in it came from someone
|
|
17
17
|
// outside the organization (an inbox, the web, a remote server) or when a
|
|
@@ -111,6 +111,18 @@ const unwrapUntrustedContent = (text) => {
|
|
|
111
111
|
return match ? match[2] : text;
|
|
112
112
|
};
|
|
113
113
|
exports.unwrapUntrustedContent = unwrapUntrustedContent;
|
|
114
|
+
// Either line wrapUntrustedContent adds around a block, with the newline that
|
|
115
|
+
// joins it to the body. A `<` of ours inside a body was escaped, so every
|
|
116
|
+
// match is a real mark. A source string so SQL can strip the same marks.
|
|
117
|
+
exports.UNTRUSTED_CONTENT_MARK_PATTERN = `\\n?<${exports.UNTRUSTED_CONTENT_TAG} id="[0-9a-f]+" source="[^"]*">\\n?` +
|
|
118
|
+
`|\\n?</${exports.UNTRUSTED_CONTENT_TAG} id="[0-9a-f]+">`;
|
|
119
|
+
/**
|
|
120
|
+
* Text with the marks around every wrapped block removed and the bodies kept,
|
|
121
|
+
* for showing a recorded result to a person: an error that quotes an
|
|
122
|
+
* endpoint's answer reads as the message and the answer.
|
|
123
|
+
*/
|
|
124
|
+
const stripUntrustedMarks = (text) => text.replace(new RegExp(exports.UNTRUSTED_CONTENT_MARK_PATTERN, 'g'), '\n').trim();
|
|
125
|
+
exports.stripUntrustedMarks = stripUntrustedMarks;
|
|
114
126
|
/** Whether a tool result carries the flag set by the server that ran it. */
|
|
115
127
|
const isUntrustedToolResult = (result) => {
|
|
116
128
|
if (!result || typeof result !== 'object')
|