@lexq/cli 0.1.56 → 0.1.58
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/index.js +17 -1
- package/package.json +1 -1
- package/skills/lexq-simulation/SKILL.md +13 -3
package/dist/index.js
CHANGED
|
@@ -2129,7 +2129,8 @@ function registerAnalyticsCommands(program) {
|
|
|
2129
2129
|
"after",
|
|
2130
2130
|
dedent8`
|
|
2131
2131
|
|
|
2132
|
-
Shows progress, match rate, metric comparison
|
|
2132
|
+
Shows progress, match rate, metric comparison and its change distribution (if a
|
|
2133
|
+
baseline is set), and per-rule stats.
|
|
2133
2134
|
|
|
2134
2135
|
Example:
|
|
2135
2136
|
$ lexq analytics simulation status --id <simId> --format table
|
|
@@ -2172,6 +2173,21 @@ function registerAnalyticsCommands(program) {
|
|
|
2172
2173
|
console.log(
|
|
2173
2174
|
`Change: ${data.metricSummary.deltaPercentage > 0 ? "+" : ""}${data.metricSummary.deltaPercentage.toFixed(1)}%`
|
|
2174
2175
|
);
|
|
2176
|
+
const dist = data.metricSummary.distribution;
|
|
2177
|
+
if (dist) {
|
|
2178
|
+
console.log(`
|
|
2179
|
+
\u2500\u2500 Distribution \u2500\u2500`);
|
|
2180
|
+
console.log(`Changed: ${dist.changedRecords}`);
|
|
2181
|
+
console.log(`Increased: ${dist.increasedRecords}`);
|
|
2182
|
+
console.log(`Decreased: ${dist.decreasedRecords}`);
|
|
2183
|
+
console.log(
|
|
2184
|
+
`Largest +: ${dist.largestIncrease === null ? "\u2013" : `${signPrefix(dist.largestIncrease)}${String(dist.largestIncrease)}`}`
|
|
2185
|
+
);
|
|
2186
|
+
console.log(
|
|
2187
|
+
`Largest -: ${dist.largestDecrease === null ? "\u2013" : String(dist.largestDecrease)}`
|
|
2188
|
+
);
|
|
2189
|
+
console.log(`Measured: ${dist.measuredRecords}`);
|
|
2190
|
+
}
|
|
2175
2191
|
}
|
|
2176
2192
|
if (data.policyImpact?.comparison) {
|
|
2177
2193
|
const diff = data.policyImpact.comparison.difference;
|
package/package.json
CHANGED
|
@@ -316,9 +316,11 @@ lexq analytics simulation export --id <simulationId> --as csv --output results.c
|
|
|
316
316
|
"status": "COMPLETED",
|
|
317
317
|
"summary": {
|
|
318
318
|
"totalRecords": 10000,
|
|
319
|
+
"processedRecords": 10000,
|
|
320
|
+
"errorRecords": 0,
|
|
319
321
|
"matchedRecords": 8500,
|
|
320
322
|
"executionTimeMs": 3200,
|
|
321
|
-
"matchRate": 0
|
|
323
|
+
"matchRate": 85.0
|
|
322
324
|
},
|
|
323
325
|
"metricSummary": {
|
|
324
326
|
"targetVariable": "paymentAmount__delta",
|
|
@@ -326,7 +328,15 @@ lexq analytics simulation export --id <simulationId> --as csv --output results.c
|
|
|
326
328
|
"baselineValue": 5000000,
|
|
327
329
|
"simulatedValue": 4500000,
|
|
328
330
|
"delta": -500000,
|
|
329
|
-
"deltaPercentage": -10.0
|
|
331
|
+
"deltaPercentage": -10.0,
|
|
332
|
+
"distribution": {
|
|
333
|
+
"changedRecords": 8700,
|
|
334
|
+
"increasedRecords": 400,
|
|
335
|
+
"decreasedRecords": 8300,
|
|
336
|
+
"largestIncrease": 1500,
|
|
337
|
+
"largestDecrease": -2000,
|
|
338
|
+
"measuredRecords": 8300
|
|
339
|
+
}
|
|
330
340
|
},
|
|
331
341
|
"policyImpact": {
|
|
332
342
|
"policyVersionId": "...",
|
|
@@ -334,7 +344,7 @@ lexq analytics simulation export --id <simulationId> --as csv --output results.c
|
|
|
334
344
|
"baselineVersionId": "...",
|
|
335
345
|
"difference": {
|
|
336
346
|
"matchedCountDelta": -200,
|
|
337
|
-
"matchedRateDelta": -0
|
|
347
|
+
"matchedRateDelta": -2.0,
|
|
338
348
|
"metricValueDelta": -500000
|
|
339
349
|
}
|
|
340
350
|
}
|