@intentic/sandbox-contract 1.170.0 → 1.171.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/agent-catalog.d.ts +1 -0
- package/dist/agent-catalog.d.ts.map +1 -1
- package/dist/agent-catalog.js +1 -0
- package/dist/agent-catalog.js.map +1 -1
- package/dist/chores/chores.d.ts +45 -0
- package/dist/chores/chores.d.ts.map +1 -0
- package/dist/chores/chores.js +487 -0
- package/dist/chores/chores.js.map +1 -0
- package/dist/chores/digest.d.ts +3 -0
- package/dist/chores/digest.d.ts.map +1 -0
- package/dist/chores/digest.js +0 -0
- package/dist/chores/digest.js.map +1 -0
- package/dist/chores/index.d.ts +10 -0
- package/dist/chores/index.d.ts.map +1 -0
- package/dist/chores/index.js +6 -0
- package/dist/chores/index.js.map +1 -0
- package/dist/chores/probes.d.ts +15 -0
- package/dist/chores/probes.d.ts.map +1 -0
- package/dist/chores/probes.js +177 -0
- package/dist/chores/probes.js.map +1 -0
- package/dist/chores/prompt.d.ts +14 -0
- package/dist/chores/prompt.d.ts.map +1 -0
- package/dist/chores/prompt.js +12 -0
- package/dist/chores/prompt.js.map +1 -0
- package/dist/chores/verdict.d.ts +20 -0
- package/dist/chores/verdict.d.ts.map +1 -0
- package/dist/chores/verdict.js +59 -0
- package/dist/chores/verdict.js.map +1 -0
- package/dist/contracts/agent.contract.d.ts +11 -0
- package/dist/contracts/agent.contract.d.ts.map +1 -1
- package/dist/contracts/agents.contract.d.ts +2 -0
- package/dist/contracts/agents.contract.d.ts.map +1 -1
- package/dist/contracts/automations.contract.d.ts +54 -0
- package/dist/contracts/automations.contract.d.ts.map +1 -1
- package/dist/contracts/chores.contract.d.ts +151 -0
- package/dist/contracts/chores.contract.d.ts.map +1 -0
- package/dist/contracts/chores.contract.js +8 -0
- package/dist/contracts/chores.contract.js.map +1 -0
- package/dist/contracts/system.contract.d.ts +14 -14
- package/dist/contracts/workspace.contract.d.ts +11 -24
- package/dist/contracts/workspace.contract.d.ts.map +1 -1
- package/dist/events.d.ts +10 -0
- package/dist/events.d.ts.map +1 -1
- package/dist/events.js +7 -1
- package/dist/events.js.map +1 -1
- package/dist/hostnames.d.ts +0 -1
- package/dist/hostnames.d.ts.map +1 -1
- package/dist/hostnames.js +0 -1
- package/dist/hostnames.js.map +1 -1
- package/dist/index.d.ts +243 -38
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -0
- package/dist/index.js.map +1 -1
- package/dist/schemas.d.ts +590 -40
- package/dist/schemas.d.ts.map +1 -1
- package/dist/schemas.js +136 -2
- package/dist/schemas.js.map +1 -1
- package/dist/tunnel-ids.d.ts +2 -0
- package/dist/tunnel-ids.d.ts.map +1 -1
- package/dist/tunnel-ids.js +2 -0
- package/dist/tunnel-ids.js.map +1 -1
- package/dist/workspace-state.d.ts.map +1 -1
- package/dist/workspace-state.js +5 -0
- package/dist/workspace-state.js.map +1 -1
- package/package.json +14 -2
- package/src/agent-catalog.test.ts +32 -1
- package/src/agent-catalog.ts +15 -0
- package/src/chores/chores.ts +837 -0
- package/src/chores/digest.test.ts +30 -0
- package/src/chores/digest.ts +0 -0
- package/src/chores/index.ts +9 -0
- package/src/chores/probes.test.ts +166 -0
- package/src/chores/probes.ts +273 -0
- package/src/chores/prompt.ts +64 -0
- package/src/chores/verdict.test.ts +394 -0
- package/src/chores/verdict.ts +167 -0
- package/src/contracts/chores.contract.ts +23 -0
- package/src/events.ts +15 -2
- package/src/hostnames.ts +4 -6
- package/src/index.ts +3 -0
- package/src/schemas.ts +383 -13
- package/src/tunnel-ids.test.ts +49 -0
- package/src/tunnel-ids.ts +24 -0
- package/src/workspace-state.ts +5 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"digest.d.ts","sourceRoot":"","sources":["../../src/chores/digest.ts"],"names":[],"mappings":"AAsBA,eAAO,MAAM,QAAQ,aAAc,SAAS,CAAC,MAAM,GAAG,MAAM,CAAC,EAAE,KAAG,MAQjE,CAAC;AAYF,eAAO,MAAM,QAAQ,UAAW,MAAM,KAAG,MAA0D,CAAC"}
|
|
Binary file
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"digest.js","sourceRoot":"","sources":["../../src/chores/digest.ts"],"names":[],"mappings":"AAiBA,MAAM,UAAU,GAAG,UAAU,CAAC;AAC9B,MAAM,SAAS,GAAG,UAAU,CAAC;AAI7B,MAAM,CAAC,MAAM,QAAQ,GAAG,CAAC,GAAG,KAAmC,EAAU,EAAE;IACvE,MAAM,KAAK,GAAG,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;IAC9B,IAAI,IAAI,GAAG,UAAU,CAAC;IACtB,KAAK,IAAI,KAAK,GAAG,CAAC,EAAE,KAAK,GAAG,KAAK,CAAC,MAAM,EAAE,KAAK,EAAE,EAAE,CAAC;QAChD,IAAI,GAAG,CAAC,CAAC,IAAI,GAAG,KAAK,CAAC,UAAU,CAAC,KAAK,CAAC,CAAC,KAAK,CAAC,CAAC,GAAG,SAAS,CAAC;QAC5D,IAAI,MAAM,CAAC,CAAC;IAChB,CAAC;IACD,OAAO,IAAI,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC;AAC9C,CAAC,CAAC;AAYF,MAAM,CAAC,MAAM,QAAQ,GAAG,CAAC,KAAa,EAAU,EAAE,CAAC,CAAC,KAAK,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export { CHORES, choreAutomationPrompt, choreById, chorePrompt, repoLabel } from "./chores.js";
|
|
2
|
+
export type { Chore, ChoreContext, ChoreFinding, ChoreStance } from "./chores.js";
|
|
3
|
+
export { bucketOf, digestOf } from "./digest.js";
|
|
4
|
+
export { CHORE_INVARIANTS, composeAsk, REFACTOR_INVARIANTS, REPORT_INVARIANTS, TRIAGE_NOTE } from "./prompt.js";
|
|
5
|
+
export type { Ask } from "./prompt.js";
|
|
6
|
+
export { PROBES, probeSpec } from "./probes.js";
|
|
7
|
+
export type { ProbeSpec } from "./probes.js";
|
|
8
|
+
export { assessChore, assessReport, ledgerKey, unseenVerdicts } from "./verdict.js";
|
|
9
|
+
export type { ChoreState, ChoreVerdict } from "./verdict.js";
|
|
10
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/chores/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,qBAAqB,EAAE,SAAS,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAC/F,YAAY,EAAE,KAAK,EAAE,YAAY,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAClF,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,UAAU,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAChH,YAAY,EAAE,GAAG,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAChD,YAAY,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAC7C,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AACpF,YAAY,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export { CHORES, choreAutomationPrompt, choreById, chorePrompt, repoLabel } from "./chores.js";
|
|
2
|
+
export { bucketOf, digestOf } from "./digest.js";
|
|
3
|
+
export { CHORE_INVARIANTS, composeAsk, REFACTOR_INVARIANTS, REPORT_INVARIANTS, TRIAGE_NOTE } from "./prompt.js";
|
|
4
|
+
export { PROBES, probeSpec } from "./probes.js";
|
|
5
|
+
export { assessChore, assessReport, ledgerKey, unseenVerdicts } from "./verdict.js";
|
|
6
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/chores/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,qBAAqB,EAAE,SAAS,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAE/F,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,UAAU,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAEhH,OAAO,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAEhD,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { ProbeFacts, ProbeId } from "../schemas.js";
|
|
2
|
+
export interface ProbeSpec {
|
|
3
|
+
readonly id: ProbeId;
|
|
4
|
+
readonly title: string;
|
|
5
|
+
readonly measures: string;
|
|
6
|
+
readonly tier: 1 | 2;
|
|
7
|
+
readonly ttlMs: number;
|
|
8
|
+
readonly timeoutMs: number;
|
|
9
|
+
readonly available: string;
|
|
10
|
+
readonly command: string;
|
|
11
|
+
readonly parse: (stdout: string) => ProbeFacts | undefined;
|
|
12
|
+
}
|
|
13
|
+
export declare const PROBES: readonly ProbeSpec[];
|
|
14
|
+
export declare const probeSpec: (id: ProbeId) => ProbeSpec;
|
|
15
|
+
//# sourceMappingURL=probes.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"probes.d.ts","sourceRoot":"","sources":["../../src/chores/probes.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAoD,UAAU,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AA0B3G,MAAM,WAAW,SAAS;IACtB,QAAQ,CAAC,EAAE,EAAE,OAAO,CAAC;IACrB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IAEvB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,IAAI,EAAE,CAAC,GAAG,CAAC,CAAC;IAGrB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAE3B,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAI3B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,KAAK,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,UAAU,GAAG,SAAS,CAAC;CAC9D;AAsKD,eAAO,MAAM,MAAM,EAAE,SAAS,SAAS,EAuDtC,CAAC;AAEF,eAAO,MAAM,SAAS,OAAQ,OAAO,KAAG,SAMvC,CAAC"}
|
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
const HOUR_MS = 3_600_000;
|
|
2
|
+
const DAY_MS = 24 * HOUR_MS;
|
|
3
|
+
const asObject = (text) => {
|
|
4
|
+
const start = text.indexOf(`{`);
|
|
5
|
+
if (start === -1) {
|
|
6
|
+
return undefined;
|
|
7
|
+
}
|
|
8
|
+
try {
|
|
9
|
+
const parsed = JSON.parse(text.slice(start));
|
|
10
|
+
return typeof parsed === `object` && parsed !== null && !Array.isArray(parsed) ? parsed : undefined;
|
|
11
|
+
}
|
|
12
|
+
catch {
|
|
13
|
+
return undefined;
|
|
14
|
+
}
|
|
15
|
+
};
|
|
16
|
+
const asString = (value) => (typeof value === `string` && value !== `` ? value : undefined);
|
|
17
|
+
const countOf = (value) => (Array.isArray(value) ? value.length : 0);
|
|
18
|
+
const versionParts = (version) => version.replace(/^[^\d]*/, ``).split(`.`).map((part) => Number.parseInt(part, 10) || 0);
|
|
19
|
+
const semverKind = (current, latest) => {
|
|
20
|
+
const [currentMajor = 0, currentMinor = 0] = versionParts(current);
|
|
21
|
+
const [latestMajor = 0, latestMinor = 0] = versionParts(latest);
|
|
22
|
+
if (latestMajor !== currentMajor) {
|
|
23
|
+
return `major`;
|
|
24
|
+
}
|
|
25
|
+
return latestMinor !== currentMinor ? `minor` : `patch`;
|
|
26
|
+
};
|
|
27
|
+
const parseOutdated = (stdout) => {
|
|
28
|
+
const root = asObject(stdout);
|
|
29
|
+
if (root === undefined) {
|
|
30
|
+
return undefined;
|
|
31
|
+
}
|
|
32
|
+
const packages = [];
|
|
33
|
+
for (const [name, raw] of Object.entries(root)) {
|
|
34
|
+
if (typeof raw !== `object` || raw === null) {
|
|
35
|
+
continue;
|
|
36
|
+
}
|
|
37
|
+
const entry = raw;
|
|
38
|
+
const current = asString(entry[`current`]);
|
|
39
|
+
const latest = asString(entry[`latest`]);
|
|
40
|
+
if (current === undefined || latest === undefined || current === latest) {
|
|
41
|
+
continue;
|
|
42
|
+
}
|
|
43
|
+
packages.push({ name, current, latest, kind: semverKind(current, latest), section: asString(entry[`dependencyType`]) ?? `dependencies` });
|
|
44
|
+
}
|
|
45
|
+
return { id: `outdated`, packages };
|
|
46
|
+
};
|
|
47
|
+
const SEVERITIES = new Set([`critical`, `high`, `moderate`, `low`, `info`]);
|
|
48
|
+
const parseAudit = (stdout) => {
|
|
49
|
+
const root = asObject(stdout);
|
|
50
|
+
if (root === undefined) {
|
|
51
|
+
return undefined;
|
|
52
|
+
}
|
|
53
|
+
const raw = root[`advisories`];
|
|
54
|
+
if (raw === undefined) {
|
|
55
|
+
return { id: `audit`, advisories: [] };
|
|
56
|
+
}
|
|
57
|
+
if (typeof raw !== `object` || raw === null) {
|
|
58
|
+
return undefined;
|
|
59
|
+
}
|
|
60
|
+
const advisories = [];
|
|
61
|
+
for (const value of Object.values(raw)) {
|
|
62
|
+
if (typeof value !== `object` || value === null) {
|
|
63
|
+
continue;
|
|
64
|
+
}
|
|
65
|
+
const entry = value;
|
|
66
|
+
const name = asString(entry[`module_name`]);
|
|
67
|
+
const severity = asString(entry[`severity`]);
|
|
68
|
+
if (name === undefined || severity === undefined || !SEVERITIES.has(severity)) {
|
|
69
|
+
continue;
|
|
70
|
+
}
|
|
71
|
+
const patched = asString(entry[`patched_versions`]);
|
|
72
|
+
const findings = Array.isArray(entry[`findings`]) ? entry[`findings`] : [];
|
|
73
|
+
advisories.push({
|
|
74
|
+
name,
|
|
75
|
+
severity: severity,
|
|
76
|
+
title: asString(entry[`title`]) ?? name,
|
|
77
|
+
...(patched === undefined || patched === `<0.0.0` ? {} : { patched }),
|
|
78
|
+
dev: findings.length > 0 && findings.every((finding) => finding[`dev`] === true),
|
|
79
|
+
});
|
|
80
|
+
}
|
|
81
|
+
return { id: `audit`, advisories };
|
|
82
|
+
};
|
|
83
|
+
const DEAD_CODE_SAMPLE = 8;
|
|
84
|
+
const parseKnip = (stdout) => {
|
|
85
|
+
const raw = asObject(stdout)?.[`issues`];
|
|
86
|
+
if (!Array.isArray(raw)) {
|
|
87
|
+
return undefined;
|
|
88
|
+
}
|
|
89
|
+
const issues = raw.filter((issue) => typeof issue === `object` && issue !== null);
|
|
90
|
+
const sum = (key) => issues.reduce((total, issue) => total + countOf(issue[key]), 0);
|
|
91
|
+
const deadCode = {
|
|
92
|
+
files: sum(`files`),
|
|
93
|
+
exports: sum(`exports`),
|
|
94
|
+
types: sum(`types`),
|
|
95
|
+
dependencies: sum(`dependencies`),
|
|
96
|
+
devDependencies: sum(`devDependencies`),
|
|
97
|
+
sample: issues.flatMap((issue) => (countOf(issue[`files`]) === 0 ? [] : (asString(issue[`file`]) ?? []))).slice(0, DEAD_CODE_SAMPLE),
|
|
98
|
+
};
|
|
99
|
+
return { id: `knip`, deadCode };
|
|
100
|
+
};
|
|
101
|
+
const DUPLICATION_SAMPLE = 5;
|
|
102
|
+
const parseJscpd = (stdout) => {
|
|
103
|
+
const root = asObject(stdout);
|
|
104
|
+
const statistics = root?.[`statistics`];
|
|
105
|
+
if (typeof statistics !== `object` || statistics === null) {
|
|
106
|
+
return undefined;
|
|
107
|
+
}
|
|
108
|
+
const total = statistics[`total`];
|
|
109
|
+
const percentage = typeof total === `object` && total !== null ? total[`percentage`] : undefined;
|
|
110
|
+
const duplicates = Array.isArray(root?.[`duplicates`]) ? root[`duplicates`] : [];
|
|
111
|
+
const pathOf = (side) => (typeof side === `object` && side !== null ? (asString(side[`name`]) ?? `?`) : `?`);
|
|
112
|
+
const duplication = {
|
|
113
|
+
percentage: typeof percentage === `number` ? percentage : 0,
|
|
114
|
+
clones: duplicates.length,
|
|
115
|
+
top: duplicates
|
|
116
|
+
.map((clone) => ({ lines: typeof clone[`lines`] === `number` ? clone[`lines`] : 0, first: pathOf(clone[`firstFile`]), second: pathOf(clone[`secondFile`]) }))
|
|
117
|
+
.toSorted((left, right) => right.lines - left.lines)
|
|
118
|
+
.slice(0, DUPLICATION_SAMPLE),
|
|
119
|
+
};
|
|
120
|
+
return { id: `jscpd`, duplication };
|
|
121
|
+
};
|
|
122
|
+
const JSCPD_DIR = `/tmp/intentic-chore-jscpd`;
|
|
123
|
+
export const PROBES = [
|
|
124
|
+
{
|
|
125
|
+
id: `outdated`,
|
|
126
|
+
title: `Dependency versions`,
|
|
127
|
+
measures: `how far behind the registry each dependency is`,
|
|
128
|
+
tier: 1,
|
|
129
|
+
ttlMs: DAY_MS,
|
|
130
|
+
timeoutMs: 5 * 60_000,
|
|
131
|
+
available: `test -f package.json`,
|
|
132
|
+
command: `pnpm outdated -r --json 2>/dev/null || true`,
|
|
133
|
+
parse: parseOutdated,
|
|
134
|
+
},
|
|
135
|
+
{
|
|
136
|
+
id: `audit`,
|
|
137
|
+
title: `Security advisories`,
|
|
138
|
+
measures: `published advisories against this dependency tree`,
|
|
139
|
+
tier: 1,
|
|
140
|
+
ttlMs: DAY_MS,
|
|
141
|
+
timeoutMs: 5 * 60_000,
|
|
142
|
+
available: `test -f pnpm-lock.yaml || test -f package-lock.json`,
|
|
143
|
+
command: `pnpm audit --json 2>/dev/null || true`,
|
|
144
|
+
parse: parseAudit,
|
|
145
|
+
},
|
|
146
|
+
{
|
|
147
|
+
id: `knip`,
|
|
148
|
+
title: `Unreachable code`,
|
|
149
|
+
measures: `files, exports and dependencies nothing references`,
|
|
150
|
+
tier: 2,
|
|
151
|
+
ttlMs: 7 * DAY_MS,
|
|
152
|
+
timeoutMs: 15 * 60_000,
|
|
153
|
+
available: `pnpm exec knip --version >/dev/null 2>&1`,
|
|
154
|
+
command: `pnpm exec knip --reporter json --no-exit-code 2>/dev/null || true`,
|
|
155
|
+
parse: parseKnip,
|
|
156
|
+
},
|
|
157
|
+
{
|
|
158
|
+
id: `jscpd`,
|
|
159
|
+
title: `Copy-paste`,
|
|
160
|
+
measures: `how much of the tree is duplicated elsewhere in it`,
|
|
161
|
+
tier: 2,
|
|
162
|
+
ttlMs: 7 * DAY_MS,
|
|
163
|
+
timeoutMs: 20 * 60_000,
|
|
164
|
+
available: `test -f package.json`,
|
|
165
|
+
command: `pnpm dlx jscpd --reporters json --output ${JSCPD_DIR} --min-lines 12 --threshold 100 . >/dev/null 2>&1; ` +
|
|
166
|
+
`cat ${JSCPD_DIR}/jscpd-report.json 2>/dev/null`,
|
|
167
|
+
parse: parseJscpd,
|
|
168
|
+
},
|
|
169
|
+
];
|
|
170
|
+
export const probeSpec = (id) => {
|
|
171
|
+
const spec = PROBES.find((probe) => probe.id === id);
|
|
172
|
+
if (spec === undefined) {
|
|
173
|
+
throw new Error(`chores: no probe named "${id}"`);
|
|
174
|
+
}
|
|
175
|
+
return spec;
|
|
176
|
+
};
|
|
177
|
+
//# sourceMappingURL=probes.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"probes.js","sourceRoot":"","sources":["../../src/chores/probes.ts"],"names":[],"mappings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,KAAK,EAAE,UAAU;KACpB;CACJ,CAAC;AAEF,MAAM,CAAC,MAAM,SAAS,GAAG,CAAC,EAAW,EAAa,EAAE;IAChD,MAAM,IAAI,GAAG,MAAM,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,EAAE,KAAK,EAAE,CAAC,CAAC;IACrD,IAAI,IAAI,KAAK,SAAS,EAAE,CAAC;QACrB,MAAM,IAAI,KAAK,CAAC,2BAA2B,EAAE,GAAG,CAAC,CAAC;IACtD,CAAC;IACD,OAAO,IAAI,CAAC;AAChB,CAAC,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export interface Ask {
|
|
2
|
+
readonly subject: string;
|
|
3
|
+
readonly why: string;
|
|
4
|
+
readonly diagnosis: string;
|
|
5
|
+
readonly goal: string;
|
|
6
|
+
readonly invariants: string;
|
|
7
|
+
readonly done: string;
|
|
8
|
+
}
|
|
9
|
+
export declare const composeAsk: ({ subject, why, diagnosis, goal, invariants, done }: Ask) => string;
|
|
10
|
+
export declare const TRIAGE_NOTE: string;
|
|
11
|
+
export declare const CHORE_INVARIANTS: string;
|
|
12
|
+
export declare const REPORT_INVARIANTS: string;
|
|
13
|
+
export declare const REFACTOR_INVARIANTS: string;
|
|
14
|
+
//# sourceMappingURL=prompt.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"prompt.d.ts","sourceRoot":"","sources":["../../src/chores/prompt.ts"],"names":[],"mappings":"AAiBA,MAAM,WAAW,GAAG;IAChB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;CACzB;AAED,eAAO,MAAM,UAAU,wDAAyD,GAAG,KAAG,MACD,CAAC;AAQtF,eAAO,MAAM,WAAW,QAGuC,CAAC;AAQhE,eAAO,MAAM,gBAAgB,QAGuF,CAAC;AAKrH,eAAO,MAAM,iBAAiB,QAEuF,CAAC;AAKtH,eAAO,MAAM,mBAAmB,QAEkC,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export const composeAsk = ({ subject, why, diagnosis, goal, invariants, done }) => [subject, `Why: ${why} ${diagnosis}`, goal, `${invariants} ${done}`].join(`\n\n`);
|
|
2
|
+
export const TRIAGE_NOTE = `The measurement woke you; it did not decide anything. Read the repository before you touch it, and treat every ` +
|
|
3
|
+
`finding as a claim to verify rather than a task to execute. If a finding is wrong, say why in one line and leave ` +
|
|
4
|
+
`it — a run that verifies ten and fixes two is a good run.`;
|
|
5
|
+
export const CHORE_INVARIANTS = `Keep it mechanical and separately explainable: nothing lands that you could not justify on its own line of the ` +
|
|
6
|
+
`summary. Do not reformat, rename or "while I was in here" anything the finding did not name. Run the repository's ` +
|
|
7
|
+
`own type-check and tests before you finish, and if you cannot make them pass, leave the change out and say so.`;
|
|
8
|
+
export const REPORT_INVARIANTS = `Change nothing. This is a survey: the output is your findings, cited file:line, and a recommendation the owner ` +
|
|
9
|
+
`can act on or dismiss. Where you would propose an edit, describe it and where it would go instead of making it.`;
|
|
10
|
+
export const REFACTOR_INVARIANTS = `Read it first. Behaviour stays identical, and the blast radius is this file, whatever it splits into, and the ` +
|
|
11
|
+
`importers that must follow — no re-export shims left behind.`;
|
|
12
|
+
//# sourceMappingURL=prompt.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"prompt.js","sourceRoot":"","sources":["../../src/chores/prompt.ts"],"names":[],"mappings":"AA0BA,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,EAAE,OAAO,EAAE,GAAG,EAAE,SAAS,EAAE,IAAI,EAAE,UAAU,EAAE,IAAI,EAAO,EAAU,EAAE,CAC3F,CAAC,OAAO,EAAE,QAAQ,GAAG,IAAI,SAAS,EAAE,EAAE,IAAI,EAAE,GAAG,UAAU,IAAI,IAAI,EAAE,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;AAQtF,MAAM,CAAC,MAAM,WAAW,GACpB,iHAAiH;IACjH,mHAAmH;IACnH,2DAA2D,CAAC;AAQhE,MAAM,CAAC,MAAM,gBAAgB,GACzB,iHAAiH;IACjH,oHAAoH;IACpH,gHAAgH,CAAC;AAKrH,MAAM,CAAC,MAAM,iBAAiB,GAC1B,iHAAiH;IACjH,iHAAiH,CAAC;AAKtH,MAAM,CAAC,MAAM,mBAAmB,GAC5B,gHAAgH;IAChH,8DAA8D,CAAC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { ChoreLedgerEntry, ChoresReport } from "../schemas.js";
|
|
2
|
+
import { type Chore, type ChoreContext, type ChoreFinding } from "./chores.js";
|
|
3
|
+
export type ChoreState = "due" | "clear" | "snoozed" | "unavailable" | "not-applicable";
|
|
4
|
+
export interface ChoreVerdict {
|
|
5
|
+
readonly chore: Chore;
|
|
6
|
+
readonly repo: string;
|
|
7
|
+
readonly state: ChoreState;
|
|
8
|
+
readonly severity: ChoreFinding["severity"];
|
|
9
|
+
readonly headline: string;
|
|
10
|
+
readonly detail: readonly string[];
|
|
11
|
+
readonly digest: string;
|
|
12
|
+
readonly prompt: string | undefined;
|
|
13
|
+
readonly lastRun: ChoreLedgerEntry | undefined;
|
|
14
|
+
readonly settled: boolean;
|
|
15
|
+
}
|
|
16
|
+
export declare const assessChore: (chore: Chore, context: ChoreContext, ledger: ChoreLedgerEntry | undefined) => ChoreVerdict;
|
|
17
|
+
export declare const ledgerKey: (repo: string, chore: string) => string;
|
|
18
|
+
export declare const assessReport: (report: ChoresReport, nowMs: number) => ChoreVerdict[];
|
|
19
|
+
export declare const unseenVerdicts: (verdicts: readonly ChoreVerdict[], seen: Readonly<Record<string, string>>) => ChoreVerdict[];
|
|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AC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,KAAG,YAAY,EAC4B,CAAC"}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { CHORES, chorePrompt } from "./chores.js";
|
|
2
|
+
import { probeSpec } from "./probes.js";
|
|
3
|
+
const clearHeadline = (chore, lastRun, nowMs) => chore.survey === true && lastRun !== undefined ? `Surveyed ${Math.round((nowMs - lastRun.ranAt) / 86_400_000)} days ago` : `Nothing to do`;
|
|
4
|
+
const unmeasuredDetail = (needs, probes) => needs.flatMap((id) => {
|
|
5
|
+
const probe = probes.get(id);
|
|
6
|
+
const spec = probeSpec(id);
|
|
7
|
+
if (probe === undefined) {
|
|
8
|
+
return [`${spec.title} · not measured yet`];
|
|
9
|
+
}
|
|
10
|
+
if (probe.state === `ok`) {
|
|
11
|
+
return [];
|
|
12
|
+
}
|
|
13
|
+
return [`${spec.title} · ${probe.state === `unavailable` ? `not available in this repository` : `failed`}${probe.reason === undefined ? `` : ` — ${probe.reason}`}`];
|
|
14
|
+
});
|
|
15
|
+
export const assessChore = (chore, context, ledger) => {
|
|
16
|
+
const base = { chore, repo: context.repo, lastRun: ledger, settled: false, prompt: undefined };
|
|
17
|
+
const inapplicable = chore.applies?.(context.signals);
|
|
18
|
+
if (inapplicable !== undefined) {
|
|
19
|
+
return { ...base, state: `not-applicable`, severity: `info`, headline: inapplicable, detail: [], digest: `` };
|
|
20
|
+
}
|
|
21
|
+
const unmeasured = unmeasuredDetail(chore.needs, context.probes);
|
|
22
|
+
if (unmeasured.length > 0) {
|
|
23
|
+
return { ...base, state: `unavailable`, severity: `info`, headline: `Not measured`, detail: unmeasured, digest: `` };
|
|
24
|
+
}
|
|
25
|
+
const finding = chore.assess(context);
|
|
26
|
+
if (finding === undefined) {
|
|
27
|
+
return { ...base, state: `clear`, severity: `info`, headline: clearHeadline(chore, ledger, context.nowMs), detail: [], digest: `` };
|
|
28
|
+
}
|
|
29
|
+
const lapsed = ledger !== undefined && chore.cadenceMs > 0 && context.nowMs - ledger.ranAt >= chore.cadenceMs;
|
|
30
|
+
const sameEvidence = ledger?.digest === finding.digest && !lapsed;
|
|
31
|
+
if (chore.survey === true && ledger !== undefined && context.nowMs - ledger.ranAt < chore.cadenceMs) {
|
|
32
|
+
return { ...base, state: `clear`, severity: `info`, headline: clearHeadline(chore, ledger, context.nowMs), detail: finding.detail, digest: finding.digest };
|
|
33
|
+
}
|
|
34
|
+
const prompt = chorePrompt(chore, finding, context.repo);
|
|
35
|
+
if (ledger?.snoozedUntil !== undefined && ledger.snoozedUntil > context.nowMs) {
|
|
36
|
+
return { ...base, state: `snoozed`, severity: `info`, headline: finding.headline, detail: finding.detail, digest: finding.digest, prompt };
|
|
37
|
+
}
|
|
38
|
+
if (sameEvidence && ledger?.outcome === `clean`) {
|
|
39
|
+
return {
|
|
40
|
+
...base,
|
|
41
|
+
state: `clear`,
|
|
42
|
+
severity: `info`,
|
|
43
|
+
headline: `Checked — the findings did not hold up`,
|
|
44
|
+
detail: finding.detail,
|
|
45
|
+
digest: finding.digest,
|
|
46
|
+
};
|
|
47
|
+
}
|
|
48
|
+
return { ...base, state: `due`, severity: finding.severity, headline: finding.headline, detail: finding.detail, digest: finding.digest, prompt, settled: sameEvidence };
|
|
49
|
+
};
|
|
50
|
+
export const ledgerKey = (repo, chore) => `${repo}|${chore}`;
|
|
51
|
+
export const assessReport = (report, nowMs) => {
|
|
52
|
+
const ledger = new Map(report.ledger.map((entry) => [ledgerKey(entry.repo, entry.chore), entry]));
|
|
53
|
+
return report.repos.flatMap(({ repo, probes, signals }) => {
|
|
54
|
+
const context = { repo, probes: new Map(probes.map((probe) => [probe.id, probe])), signals, node: report.node, nowMs };
|
|
55
|
+
return CHORES.map((chore) => assessChore(chore, context, ledger.get(ledgerKey(repo, chore.id))));
|
|
56
|
+
});
|
|
57
|
+
};
|
|
58
|
+
export const unseenVerdicts = (verdicts, seen) => verdicts.filter((verdict) => verdict.state === `due` && !verdict.settled && seen[ledgerKey(verdict.repo, verdict.chore.id)] !== verdict.digest);
|
|
59
|
+
//# sourceMappingURL=verdict.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"verdict.js","sourceRoot":"","sources":["../../src/chores/verdict.ts"],"names":[],"mappings":"AACA,OAAO,EAAoD,MAAM,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AACpG,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AA0DxC,MAAM,aAAa,GAAG,CAAC,KAAY,EAAE,OAAqC,EAAE,KAAa,EAAU,EAAE,CACjG,KAAK,CAAC,MAAM,KAAK,IAAI,IAAI,OAAO,KAAK,SAAS,CAAC,CAAC,CAAC,YAAY,IAAI,CAAC,KAAK,CAAC,CAAC,KAAK,GAAG,OAAO,CAAC,KAAK,CAAC,GAAG,UAAU,CAAC,WAAW,CAAC,CAAC,CAAC,eAAe,CAAC;AAI/I,MAAM,gBAAgB,GAAG,CAAC,KAAyB,EAAE,MAAyC,EAAY,EAAE,CACxG,KAAK,CAAC,OAAO,CAAC,CAAC,EAAE,EAAE,EAAE;IACjB,MAAM,KAAK,GAAG,MAAM,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;IAC7B,MAAM,IAAI,GAAG,SAAS,CAAC,EAAE,CAAC,CAAC;IAC3B,IAAI,KAAK,KAAK,SAAS,EAAE,CAAC;QACtB,OAAO,CAAC,GAAG,IAAI,CAAC,KAAK,qBAAqB,CAAC,CAAC;IAChD,CAAC;IACD,IAAI,KAAK,CAAC,KAAK,KAAK,IAAI,EAAE,CAAC;QACvB,OAAO,EAAE,CAAC;IACd,CAAC;IACD,OAAO,CAAC,GAAG,IAAI,CAAC,KAAK,MAAM,KAAK,CAAC,KAAK,KAAK,aAAa,CAAC,CAAC,CAAC,kCAAkC,CAAC,CAAC,CAAC,QAAQ,GAAG,KAAK,CAAC,MAAM,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,MAAM,KAAK,CAAC,MA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E,CAAC,WAAW,CAAC,KAAK,EAAE,OAAO,EAAE,MAAM,CAAC,GAAG,CAAC,SAAS,CAAC,IAAI,EAAE,KAAK,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC;IACrG,CAAC,CAAC,CAAC;AACP,CAAC,CAAC;AAaF,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,QAAiC,EAAE,IAAsC,EAAkB,EAAE,CACxH,QAAQ,CAAC,MAAM,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,OAAO,CAAC,KAAK,KAAK,KAAK,IAAI,CAAC,OAAO,CAAC,OAAO,IAAI,IAAI,CAAC,SAAS,CAAC,OAAO,CAAC,IAAI,EAAE,OAAO,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC,KAAK,OAAO,CAAC,MAAM,CAAC,CAAC"}
|
|
@@ -32,6 +32,7 @@ export declare const agentContract: {
|
|
|
32
32
|
default: "default";
|
|
33
33
|
plan: "plan";
|
|
34
34
|
}>>;
|
|
35
|
+
allowedTools: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString>>;
|
|
35
36
|
effort: import("zod").ZodOptional<import("zod").ZodString>;
|
|
36
37
|
thinking: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
37
38
|
editorContext: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
@@ -64,6 +65,10 @@ export declare const agentContract: {
|
|
|
64
65
|
branch: string;
|
|
65
66
|
base: string;
|
|
66
67
|
unenforced?: boolean | undefined;
|
|
68
|
+
sync?: {
|
|
69
|
+
commits: number;
|
|
70
|
+
blocked: string[];
|
|
71
|
+
} | undefined;
|
|
67
72
|
} | {
|
|
68
73
|
kind: "landed";
|
|
69
74
|
landed: boolean;
|
|
@@ -74,6 +79,7 @@ export declare const agentContract: {
|
|
|
74
79
|
reason: "binary" | "diverged" | "workspace";
|
|
75
80
|
}[];
|
|
76
81
|
clean: number;
|
|
82
|
+
mainBranch?: string | undefined;
|
|
77
83
|
}[] | undefined;
|
|
78
84
|
held?: boolean | undefined;
|
|
79
85
|
} | {
|
|
@@ -301,6 +307,10 @@ export declare const agentContract: {
|
|
|
301
307
|
branch: string;
|
|
302
308
|
base: string;
|
|
303
309
|
unenforced?: boolean | undefined;
|
|
310
|
+
sync?: {
|
|
311
|
+
commits: number;
|
|
312
|
+
blocked: string[];
|
|
313
|
+
} | undefined;
|
|
304
314
|
} | {
|
|
305
315
|
kind: "landed";
|
|
306
316
|
landed: boolean;
|
|
@@ -311,6 +321,7 @@ export declare const agentContract: {
|
|
|
311
321
|
reason: "binary" | "diverged" | "workspace";
|
|
312
322
|
}[];
|
|
313
323
|
clean: number;
|
|
324
|
+
mainBranch?: string | undefined;
|
|
314
325
|
}[] | undefined;
|
|
315
326
|
held?: boolean | undefined;
|
|
316
327
|
} | {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agent.contract.d.ts","sourceRoot":"","sources":["../../src/contracts/agent.contract.ts"],"names":[],"mappings":"AAkBA,eAAO,MAAM,aAAa;IACtB,GAAG
|
|
1
|
+
{"version":3,"file":"agent.contract.d.ts","sourceRoot":"","sources":["../../src/contracts/agent.contract.ts"],"names":[],"mappings":"AAkBA,eAAO,MAAM,aAAa;IACtB,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IACH,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IACN,KAAK;;;;;;;;;;;;;;;;;;;;;;;;;;;;IACL,KAAK;;;;;;;;;;;;;IACL,IAAI;;;;;IAGJ,QAAQ;;;;;;;;;IAIR,QAAQ;;;;;;;;;;;CACX,CAAC"}
|
|
@@ -537,6 +537,7 @@ export declare const agentsContract: {
|
|
|
537
537
|
}>;
|
|
538
538
|
}, import("zod/v4/core").$strip>>;
|
|
539
539
|
clean: import("zod").ZodNumber;
|
|
540
|
+
mainBranch: import("zod").ZodOptional<import("zod").ZodString>;
|
|
540
541
|
}, import("zod/v4/core").$strip>>>;
|
|
541
542
|
}, import("zod/v4/core").$strip>, Record<never, never>, Record<never, never>>;
|
|
542
543
|
fileDiff: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<import("zod").ZodObject<{
|
|
@@ -569,6 +570,7 @@ export declare const agentsContract: {
|
|
|
569
570
|
}>;
|
|
570
571
|
}, import("zod/v4/core").$strip>>;
|
|
571
572
|
clean: import("zod").ZodNumber;
|
|
573
|
+
mainBranch: import("zod").ZodOptional<import("zod").ZodString>;
|
|
572
574
|
}, import("zod/v4/core").$strip>>>;
|
|
573
575
|
resolving: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodObject<{
|
|
574
576
|
repo: import("zod").ZodString;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agents.contract.d.ts","sourceRoot":"","sources":["../../src/contracts/agents.contract.ts"],"names":[],"mappings":"AA8CA,eAAO,MAAM,cAAc;IACvB,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IACJ,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IACJ,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IACP,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IACJ,QAAQ;;;;;;;;;;IACR,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;IACJ,OAAO;;;;;IACP,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IACP,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IACT,KAAK;;;CACR,CAAC"}
|
|
@@ -25,6 +25,33 @@ export declare const automationsContract: {
|
|
|
25
25
|
}, import("zod/v4/core").$strip>], "kind">;
|
|
26
26
|
guard: import("zod").ZodOptional<import("zod").ZodString>;
|
|
27
27
|
prompt: import("zod").ZodString;
|
|
28
|
+
webchat: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
29
|
+
access: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
30
|
+
google: "google";
|
|
31
|
+
public: "public";
|
|
32
|
+
}>>;
|
|
33
|
+
requireName: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
34
|
+
antiBot: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
35
|
+
pow: "pow";
|
|
36
|
+
turnstile: "turnstile";
|
|
37
|
+
}>>;
|
|
38
|
+
turnstileSiteKey: import("zod").ZodOptional<import("zod").ZodString>;
|
|
39
|
+
turnstileSecret: import("zod").ZodOptional<import("zod").ZodString>;
|
|
40
|
+
googleClientId: import("zod").ZodOptional<import("zod").ZodString>;
|
|
41
|
+
title: import("zod").ZodOptional<import("zod").ZodString>;
|
|
42
|
+
greeting: import("zod").ZodOptional<import("zod").ZodString>;
|
|
43
|
+
accent: import("zod").ZodOptional<import("zod").ZodString>;
|
|
44
|
+
position: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
45
|
+
"bottom-left": "bottom-left";
|
|
46
|
+
"bottom-right": "bottom-right";
|
|
47
|
+
"top-left": "top-left";
|
|
48
|
+
"top-right": "top-right";
|
|
49
|
+
}>>;
|
|
50
|
+
dailyMessageMax: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
51
|
+
conversationMessageMax: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
52
|
+
sessionTtlMinutes: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
53
|
+
}, import("zod/v4/core").$strip>>;
|
|
54
|
+
allowedTools: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString>>;
|
|
28
55
|
agent: import("zod").ZodOptional<import("zod").ZodString>;
|
|
29
56
|
harness: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
30
57
|
"claude-code": "claude-code";
|
|
@@ -73,6 +100,33 @@ export declare const automationsContract: {
|
|
|
73
100
|
}, import("zod/v4/core").$strip>], "kind">;
|
|
74
101
|
guard: import("zod").ZodOptional<import("zod").ZodString>;
|
|
75
102
|
prompt: import("zod").ZodString;
|
|
103
|
+
webchat: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
104
|
+
access: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
105
|
+
google: "google";
|
|
106
|
+
public: "public";
|
|
107
|
+
}>>;
|
|
108
|
+
requireName: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
109
|
+
antiBot: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
110
|
+
pow: "pow";
|
|
111
|
+
turnstile: "turnstile";
|
|
112
|
+
}>>;
|
|
113
|
+
turnstileSiteKey: import("zod").ZodOptional<import("zod").ZodString>;
|
|
114
|
+
turnstileSecret: import("zod").ZodOptional<import("zod").ZodString>;
|
|
115
|
+
googleClientId: import("zod").ZodOptional<import("zod").ZodString>;
|
|
116
|
+
title: import("zod").ZodOptional<import("zod").ZodString>;
|
|
117
|
+
greeting: import("zod").ZodOptional<import("zod").ZodString>;
|
|
118
|
+
accent: import("zod").ZodOptional<import("zod").ZodString>;
|
|
119
|
+
position: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
120
|
+
"bottom-left": "bottom-left";
|
|
121
|
+
"bottom-right": "bottom-right";
|
|
122
|
+
"top-left": "top-left";
|
|
123
|
+
"top-right": "top-right";
|
|
124
|
+
}>>;
|
|
125
|
+
dailyMessageMax: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
126
|
+
conversationMessageMax: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
127
|
+
sessionTtlMinutes: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
128
|
+
}, import("zod/v4/core").$strip>>;
|
|
129
|
+
allowedTools: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString>>;
|
|
76
130
|
agent: import("zod").ZodOptional<import("zod").ZodString>;
|
|
77
131
|
harness: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
78
132
|
"claude-code": "claude-code";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"automations.contract.d.ts","sourceRoot":"","sources":["../../src/contracts/automations.contract.ts"],"names":[],"mappings":"AAeA,eAAO,MAAM,mBAAmB;IAC5B,IAAI
|
|
1
|
+
{"version":3,"file":"automations.contract.d.ts","sourceRoot":"","sources":["../../src/contracts/automations.contract.ts"],"names":[],"mappings":"AAeA,eAAO,MAAM,mBAAmB;IAC5B,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IACJ,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IACN,MAAM;;;;;IAaN,GAAG;;;;;IACH,WAAW;;;;;;;;;;;;;;;IACX,OAAO;;;;;IACP,MAAM;;;;;CACT,CAAC"}
|