@handlebar/governance-schema 0.0.6-dev.10 → 0.0.6-dev.12
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/audit/events.d.ts +2 -1
- package/dist/audit/events.llm.d.ts +1 -1
- package/dist/audit/events.tools.d.ts +1 -0
- package/dist/audit/run-metrics.d.ts +2 -0
- package/dist/index.js +3 -2
- package/dist/rules/condition.d.ts +7 -0
- package/dist/rules/metrics.d.ts +2 -0
- package/dist/rules/rule.d.ts +8 -0
- package/package.json +1 -1
package/dist/audit/events.d.ts
CHANGED
|
@@ -320,6 +320,7 @@ export declare const AuditEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
320
320
|
records_out: "records_out";
|
|
321
321
|
llm_tokens_in: "llm_tokens_in";
|
|
322
322
|
llm_tokens_out: "llm_tokens_out";
|
|
323
|
+
llm_cost_usd: "llm_cost_usd";
|
|
323
324
|
}> & z.core.$partial, z.ZodObject<{
|
|
324
325
|
value: z.ZodNumber;
|
|
325
326
|
unit: z.ZodOptional<z.ZodString>;
|
|
@@ -490,7 +491,7 @@ export declare const AuditEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
490
491
|
kind: z.ZodLiteral<"llm.result">;
|
|
491
492
|
data: z.ZodObject<{
|
|
492
493
|
model: z.ZodObject<{
|
|
493
|
-
|
|
494
|
+
name: z.ZodString;
|
|
494
495
|
provider: z.ZodOptional<z.ZodString>;
|
|
495
496
|
}, z.core.$strip>;
|
|
496
497
|
tokens: z.ZodObject<{
|
|
@@ -130,7 +130,7 @@ export declare const LLMResultEventSchema: z.ZodObject<{
|
|
|
130
130
|
kind: z.ZodLiteral<"llm.result">;
|
|
131
131
|
data: z.ZodObject<{
|
|
132
132
|
model: z.ZodObject<{
|
|
133
|
-
|
|
133
|
+
name: z.ZodString;
|
|
134
134
|
provider: z.ZodOptional<z.ZodString>;
|
|
135
135
|
}, z.core.$strip>;
|
|
136
136
|
tokens: z.ZodObject<{
|
|
@@ -141,6 +141,7 @@ export declare const ToolResultEventSchema: z.ZodObject<{
|
|
|
141
141
|
records_out: "records_out";
|
|
142
142
|
llm_tokens_in: "llm_tokens_in";
|
|
143
143
|
llm_tokens_out: "llm_tokens_out";
|
|
144
|
+
llm_cost_usd: "llm_cost_usd";
|
|
144
145
|
}> & z.core.$partial, z.ZodObject<{
|
|
145
146
|
value: z.ZodNumber;
|
|
146
147
|
unit: z.ZodOptional<z.ZodString>;
|
|
@@ -7,6 +7,7 @@ export declare const InbuiltAgentMetricKind: z.ZodEnum<{
|
|
|
7
7
|
records_out: "records_out";
|
|
8
8
|
llm_tokens_in: "llm_tokens_in";
|
|
9
9
|
llm_tokens_out: "llm_tokens_out";
|
|
10
|
+
llm_cost_usd: "llm_cost_usd";
|
|
10
11
|
}>;
|
|
11
12
|
export declare const CustomAgentMetricKind: z.ZodString;
|
|
12
13
|
export declare const AgentMetrics: z.ZodObject<{
|
|
@@ -18,6 +19,7 @@ export declare const AgentMetrics: z.ZodObject<{
|
|
|
18
19
|
records_out: "records_out";
|
|
19
20
|
llm_tokens_in: "llm_tokens_in";
|
|
20
21
|
llm_tokens_out: "llm_tokens_out";
|
|
22
|
+
llm_cost_usd: "llm_cost_usd";
|
|
21
23
|
}> & z.core.$partial, z.ZodObject<{
|
|
22
24
|
value: z.ZodNumber;
|
|
23
25
|
unit: z.ZodOptional<z.ZodString>;
|
package/dist/index.js
CHANGED
|
@@ -13622,7 +13622,7 @@ var LLMResultEventSchema = AuditEnvelopeSchema.extend({
|
|
|
13622
13622
|
kind: exports_external.literal("llm.result"),
|
|
13623
13623
|
data: exports_external.object({
|
|
13624
13624
|
model: exports_external.object({
|
|
13625
|
-
|
|
13625
|
+
name: exports_external.string(),
|
|
13626
13626
|
provider: exports_external.string().optional()
|
|
13627
13627
|
}),
|
|
13628
13628
|
tokens: exports_external.object({
|
|
@@ -13667,7 +13667,8 @@ var InbuiltAgentMetricKind = exports_external.enum([
|
|
|
13667
13667
|
"records_in",
|
|
13668
13668
|
"records_out",
|
|
13669
13669
|
"llm_tokens_in",
|
|
13670
|
-
"llm_tokens_out"
|
|
13670
|
+
"llm_tokens_out",
|
|
13671
|
+
"llm_cost_usd"
|
|
13671
13672
|
]);
|
|
13672
13673
|
var CustomAgentMetricKind = exports_external.string().regex(/^[a-zA-Z][a-zA-Z0-9_.-]{0,63}$/);
|
|
13673
13674
|
var AgentMetricInfo = exports_external.object({
|
|
@@ -123,6 +123,7 @@ declare const AndConditionSchema: z.ZodObject<{
|
|
|
123
123
|
records_out: "records_out";
|
|
124
124
|
llm_tokens_in: "llm_tokens_in";
|
|
125
125
|
llm_tokens_out: "llm_tokens_out";
|
|
126
|
+
llm_cost_usd: "llm_cost_usd";
|
|
126
127
|
}>;
|
|
127
128
|
}, z.core.$strict>, z.ZodObject<{
|
|
128
129
|
kind: z.ZodLiteral<"custom">;
|
|
@@ -348,6 +349,7 @@ declare const OrConditionSchema: z.ZodObject<{
|
|
|
348
349
|
records_out: "records_out";
|
|
349
350
|
llm_tokens_in: "llm_tokens_in";
|
|
350
351
|
llm_tokens_out: "llm_tokens_out";
|
|
352
|
+
llm_cost_usd: "llm_cost_usd";
|
|
351
353
|
}>;
|
|
352
354
|
}, z.core.$strict>, z.ZodObject<{
|
|
353
355
|
kind: z.ZodLiteral<"custom">;
|
|
@@ -573,6 +575,7 @@ declare const NotConditionSchema: z.ZodObject<{
|
|
|
573
575
|
records_out: "records_out";
|
|
574
576
|
llm_tokens_in: "llm_tokens_in";
|
|
575
577
|
llm_tokens_out: "llm_tokens_out";
|
|
578
|
+
llm_cost_usd: "llm_cost_usd";
|
|
576
579
|
}>;
|
|
577
580
|
}, z.core.$strict>, z.ZodObject<{
|
|
578
581
|
kind: z.ZodLiteral<"custom">;
|
|
@@ -799,6 +802,7 @@ export declare const RuleConditionSchema: z.ZodUnion<readonly [z.ZodUnion<readon
|
|
|
799
802
|
records_out: "records_out";
|
|
800
803
|
llm_tokens_in: "llm_tokens_in";
|
|
801
804
|
llm_tokens_out: "llm_tokens_out";
|
|
805
|
+
llm_cost_usd: "llm_cost_usd";
|
|
802
806
|
}>;
|
|
803
807
|
}, z.core.$strict>, z.ZodObject<{
|
|
804
808
|
kind: z.ZodLiteral<"custom">;
|
|
@@ -1022,6 +1026,7 @@ export declare const RuleConditionSchema: z.ZodUnion<readonly [z.ZodUnion<readon
|
|
|
1022
1026
|
records_out: "records_out";
|
|
1023
1027
|
llm_tokens_in: "llm_tokens_in";
|
|
1024
1028
|
llm_tokens_out: "llm_tokens_out";
|
|
1029
|
+
llm_cost_usd: "llm_cost_usd";
|
|
1025
1030
|
}>;
|
|
1026
1031
|
}, z.core.$strict>, z.ZodObject<{
|
|
1027
1032
|
kind: z.ZodLiteral<"custom">;
|
|
@@ -1246,6 +1251,7 @@ export declare const RuleConditionSchema: z.ZodUnion<readonly [z.ZodUnion<readon
|
|
|
1246
1251
|
records_out: "records_out";
|
|
1247
1252
|
llm_tokens_in: "llm_tokens_in";
|
|
1248
1253
|
llm_tokens_out: "llm_tokens_out";
|
|
1254
|
+
llm_cost_usd: "llm_cost_usd";
|
|
1249
1255
|
}>;
|
|
1250
1256
|
}, z.core.$strict>, z.ZodObject<{
|
|
1251
1257
|
kind: z.ZodLiteral<"custom">;
|
|
@@ -1470,6 +1476,7 @@ export declare const RuleConditionSchema: z.ZodUnion<readonly [z.ZodUnion<readon
|
|
|
1470
1476
|
records_out: "records_out";
|
|
1471
1477
|
llm_tokens_in: "llm_tokens_in";
|
|
1472
1478
|
llm_tokens_out: "llm_tokens_out";
|
|
1479
|
+
llm_cost_usd: "llm_cost_usd";
|
|
1473
1480
|
}>;
|
|
1474
1481
|
}, z.core.$strict>, z.ZodObject<{
|
|
1475
1482
|
kind: z.ZodLiteral<"custom">;
|
package/dist/rules/metrics.d.ts
CHANGED
|
@@ -9,6 +9,7 @@ export declare const MetricRefSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
9
9
|
records_out: "records_out";
|
|
10
10
|
llm_tokens_in: "llm_tokens_in";
|
|
11
11
|
llm_tokens_out: "llm_tokens_out";
|
|
12
|
+
llm_cost_usd: "llm_cost_usd";
|
|
12
13
|
}>;
|
|
13
14
|
}, z.core.$strict>, z.ZodObject<{
|
|
14
15
|
kind: z.ZodLiteral<"custom">;
|
|
@@ -31,6 +32,7 @@ export declare const MetricWindowConditionSchema: z.ZodObject<{
|
|
|
31
32
|
records_out: "records_out";
|
|
32
33
|
llm_tokens_in: "llm_tokens_in";
|
|
33
34
|
llm_tokens_out: "llm_tokens_out";
|
|
35
|
+
llm_cost_usd: "llm_cost_usd";
|
|
34
36
|
}>;
|
|
35
37
|
}, z.core.$strict>, z.ZodObject<{
|
|
36
38
|
kind: z.ZodLiteral<"custom">;
|
package/dist/rules/rule.d.ts
CHANGED
|
@@ -155,6 +155,7 @@ export declare const RuleSchema: z.ZodObject<{
|
|
|
155
155
|
records_out: "records_out";
|
|
156
156
|
llm_tokens_in: "llm_tokens_in";
|
|
157
157
|
llm_tokens_out: "llm_tokens_out";
|
|
158
|
+
llm_cost_usd: "llm_cost_usd";
|
|
158
159
|
}>;
|
|
159
160
|
}, z.core.$strict>, z.ZodObject<{
|
|
160
161
|
kind: z.ZodLiteral<"custom">;
|
|
@@ -378,6 +379,7 @@ export declare const RuleSchema: z.ZodObject<{
|
|
|
378
379
|
records_out: "records_out";
|
|
379
380
|
llm_tokens_in: "llm_tokens_in";
|
|
380
381
|
llm_tokens_out: "llm_tokens_out";
|
|
382
|
+
llm_cost_usd: "llm_cost_usd";
|
|
381
383
|
}>;
|
|
382
384
|
}, z.core.$strict>, z.ZodObject<{
|
|
383
385
|
kind: z.ZodLiteral<"custom">;
|
|
@@ -602,6 +604,7 @@ export declare const RuleSchema: z.ZodObject<{
|
|
|
602
604
|
records_out: "records_out";
|
|
603
605
|
llm_tokens_in: "llm_tokens_in";
|
|
604
606
|
llm_tokens_out: "llm_tokens_out";
|
|
607
|
+
llm_cost_usd: "llm_cost_usd";
|
|
605
608
|
}>;
|
|
606
609
|
}, z.core.$strict>, z.ZodObject<{
|
|
607
610
|
kind: z.ZodLiteral<"custom">;
|
|
@@ -826,6 +829,7 @@ export declare const RuleSchema: z.ZodObject<{
|
|
|
826
829
|
records_out: "records_out";
|
|
827
830
|
llm_tokens_in: "llm_tokens_in";
|
|
828
831
|
llm_tokens_out: "llm_tokens_out";
|
|
832
|
+
llm_cost_usd: "llm_cost_usd";
|
|
829
833
|
}>;
|
|
830
834
|
}, z.core.$strict>, z.ZodObject<{
|
|
831
835
|
kind: z.ZodLiteral<"custom">;
|
|
@@ -1095,6 +1099,7 @@ export declare const RuleSpecSchema: z.ZodObject<{
|
|
|
1095
1099
|
records_out: "records_out";
|
|
1096
1100
|
llm_tokens_in: "llm_tokens_in";
|
|
1097
1101
|
llm_tokens_out: "llm_tokens_out";
|
|
1102
|
+
llm_cost_usd: "llm_cost_usd";
|
|
1098
1103
|
}>;
|
|
1099
1104
|
}, z.core.$strict>, z.ZodObject<{
|
|
1100
1105
|
kind: z.ZodLiteral<"custom">;
|
|
@@ -1318,6 +1323,7 @@ export declare const RuleSpecSchema: z.ZodObject<{
|
|
|
1318
1323
|
records_out: "records_out";
|
|
1319
1324
|
llm_tokens_in: "llm_tokens_in";
|
|
1320
1325
|
llm_tokens_out: "llm_tokens_out";
|
|
1326
|
+
llm_cost_usd: "llm_cost_usd";
|
|
1321
1327
|
}>;
|
|
1322
1328
|
}, z.core.$strict>, z.ZodObject<{
|
|
1323
1329
|
kind: z.ZodLiteral<"custom">;
|
|
@@ -1542,6 +1548,7 @@ export declare const RuleSpecSchema: z.ZodObject<{
|
|
|
1542
1548
|
records_out: "records_out";
|
|
1543
1549
|
llm_tokens_in: "llm_tokens_in";
|
|
1544
1550
|
llm_tokens_out: "llm_tokens_out";
|
|
1551
|
+
llm_cost_usd: "llm_cost_usd";
|
|
1545
1552
|
}>;
|
|
1546
1553
|
}, z.core.$strict>, z.ZodObject<{
|
|
1547
1554
|
kind: z.ZodLiteral<"custom">;
|
|
@@ -1766,6 +1773,7 @@ export declare const RuleSpecSchema: z.ZodObject<{
|
|
|
1766
1773
|
records_out: "records_out";
|
|
1767
1774
|
llm_tokens_in: "llm_tokens_in";
|
|
1768
1775
|
llm_tokens_out: "llm_tokens_out";
|
|
1776
|
+
llm_cost_usd: "llm_cost_usd";
|
|
1769
1777
|
}>;
|
|
1770
1778
|
}, z.core.$strict>, z.ZodObject<{
|
|
1771
1779
|
kind: z.ZodLiteral<"custom">;
|