@robbeverhelst/do 1.70.0 → 1.71.0
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/do.js +37 -1
- package/package.json +1 -1
package/dist/do.js
CHANGED
|
@@ -5086,6 +5086,22 @@ var insightsHabitStreaks = pgView("insights_habit_streaks", {
|
|
|
5086
5086
|
latestRunLength: integer("latest_run_length").notNull(),
|
|
5087
5087
|
latestRunEnd: date("latest_run_end").notNull()
|
|
5088
5088
|
}).existing();
|
|
5089
|
+
var insightsFindings = pgTable("insights_findings", {
|
|
5090
|
+
id: text("id").primaryKey(),
|
|
5091
|
+
tenantId: text("tenant_id").notNull().references(() => tenants.id, { onDelete: "cascade" }),
|
|
5092
|
+
kind: text("kind").notNull(),
|
|
5093
|
+
subject: text("subject").notNull(),
|
|
5094
|
+
entityId: text("entity_id"),
|
|
5095
|
+
sentence: text("sentence").notNull(),
|
|
5096
|
+
metrics: jsonb("metrics").$type().notNull(),
|
|
5097
|
+
confidence: text("confidence").notNull(),
|
|
5098
|
+
sampleSize: integer("sample_size").notNull(),
|
|
5099
|
+
effectSize: doublePrecision("effect_size").notNull(),
|
|
5100
|
+
windowDays: integer("window_days").notNull(),
|
|
5101
|
+
generatedAt: timestamp("generated_at", { withTimezone: true }).notNull().defaultNow()
|
|
5102
|
+
}, (t) => [
|
|
5103
|
+
index("insights_findings_tenant_idx").on(t.tenantId)
|
|
5104
|
+
]);
|
|
5089
5105
|
// ../../node_modules/zod/v4/classic/external.js
|
|
5090
5106
|
var exports_external = {};
|
|
5091
5107
|
__export(exports_external, {
|
|
@@ -21841,9 +21857,29 @@ var insightsStreakSchema = exports_external.object({
|
|
|
21841
21857
|
lastCheckin: exports_external.string(),
|
|
21842
21858
|
currentStreak: exports_external.number().int().nonnegative()
|
|
21843
21859
|
});
|
|
21860
|
+
var insightsConfidenceSchema = exports_external.enum(["low", "medium", "high"]);
|
|
21861
|
+
var insightsFindingKindSchema = exports_external.enum([
|
|
21862
|
+
"habit_consistency",
|
|
21863
|
+
"habit_average",
|
|
21864
|
+
"habit_correlation"
|
|
21865
|
+
]);
|
|
21866
|
+
var insightsFindingSchema = exports_external.object({
|
|
21867
|
+
id: exports_external.string(),
|
|
21868
|
+
kind: insightsFindingKindSchema,
|
|
21869
|
+
sentence: exports_external.string(),
|
|
21870
|
+
subject: exports_external.string(),
|
|
21871
|
+
entityId: exports_external.string().nullable(),
|
|
21872
|
+
metrics: exports_external.record(exports_external.string(), exports_external.number()),
|
|
21873
|
+
confidence: insightsConfidenceSchema,
|
|
21874
|
+
sampleSize: exports_external.number().int().nonnegative(),
|
|
21875
|
+
effectSize: exports_external.number(),
|
|
21876
|
+
windowDays: exports_external.number().int().positive(),
|
|
21877
|
+
generatedAt: exports_external.coerce.date()
|
|
21878
|
+
});
|
|
21844
21879
|
var insightsOverviewSchema = exports_external.object({
|
|
21845
21880
|
generatedAt: exports_external.coerce.date(),
|
|
21846
21881
|
windowDays: exports_external.number().int().positive(),
|
|
21882
|
+
findings: exports_external.array(insightsFindingSchema),
|
|
21847
21883
|
activity: exports_external.array(insightsActivityPointSchema),
|
|
21848
21884
|
correlations: exports_external.array(insightsCorrelationSchema),
|
|
21849
21885
|
streaks: exports_external.array(insightsStreakSchema)
|
|
@@ -24331,7 +24367,7 @@ function parseCapture2(input, now) {
|
|
|
24331
24367
|
|
|
24332
24368
|
// src/meta.ts
|
|
24333
24369
|
var CLI_NAME = "do";
|
|
24334
|
-
var VERSION = "1.
|
|
24370
|
+
var VERSION = "1.71.0";
|
|
24335
24371
|
var API_PREFIX = "/api/v1";
|
|
24336
24372
|
var DEFAULT_API_URL = "http://localhost:3001";
|
|
24337
24373
|
|