@bluewombat/slot-kit 0.8.0 → 0.10.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/README.md +7 -12
- package/dist/agent.d.ts +1 -1
- package/dist/agent.js +1 -1
- package/dist/argv.d.ts +1 -4
- package/dist/argv.d.ts.map +1 -1
- package/dist/argv.js +2 -12
- package/dist/argv.js.map +1 -1
- package/dist/emit.d.ts +2 -10
- package/dist/emit.d.ts.map +1 -1
- package/dist/emit.js +2 -14
- package/dist/emit.js.map +1 -1
- package/dist/index.d.ts +4 -7
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -6
- package/dist/index.js.map +1 -1
- package/dist/prompt.d.ts.map +1 -1
- package/dist/prompt.js +5 -2
- package/dist/prompt.js.map +1 -1
- package/package.json +2 -2
- package/dist/plan.d.ts +0 -23
- package/dist/plan.d.ts.map +0 -1
- package/dist/plan.js +0 -94
- package/dist/plan.js.map +0 -1
package/README.md
CHANGED
|
@@ -2,9 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
What a slot needs to answer the Transformer that spawned it.
|
|
4
4
|
|
|
5
|
-
A slot is an opaque command. Implementer spawns a Builder and its Gates,
|
|
6
|
-
|
|
7
|
-
line on stdout**. That is the whole contract, and nothing here is required to
|
|
5
|
+
A slot is an opaque command. Implementer spawns a Builder and its Gates, and
|
|
6
|
+
each one reads argv and writes **one JSON line on stdout**. That is the whole contract, and nothing here is required to
|
|
8
7
|
meet it: a shell script that prints the right line is a Gate. This package is
|
|
9
8
|
the plumbing every slot written in Node would otherwise write again — and it is
|
|
10
9
|
what keeps the shipped slots from each growing their own version of it.
|
|
@@ -12,7 +11,7 @@ what keeps the shipped slots from each growing their own version of it.
|
|
|
12
11
|
The contract line must be written with `writeContract` (or an `emit*` that uses
|
|
13
12
|
it). `process.stdout.write` followed by `process.exit` drops the tail of any
|
|
14
13
|
payload larger than the pipe buffer — a finished Cursor/Claude stream-json run
|
|
15
|
-
|
|
14
|
+
reaches the role as "The agent command wrote no result." Diagnostics on
|
|
16
15
|
stderr use `writeDiagnostic` for the same reason.
|
|
17
16
|
|
|
18
17
|
A slot is a **layer** in a chain it does not own: Implementer ends the chain
|
|
@@ -22,8 +21,7 @@ its own — a child that left it would outlive its ceiling. The rule and its
|
|
|
22
21
|
check are in [`packages/README.md`](../../README.md).
|
|
23
22
|
|
|
24
23
|
The behaviour a slot must have is specified where its caller is:
|
|
25
|
-
[Implementer](../../kernel/implementer/SPECS.md) for Builders and Gates
|
|
26
|
-
[FeatureBreakdown](../../kernel/feature-breakdown/SPECS.md) for Planners.
|
|
24
|
+
[Implementer](../../kernel/implementer/SPECS.md) for Builders and Gates.
|
|
27
25
|
Slots that use this kit: [`@bluewombat/slots`](../../plugins/slots/README.md).
|
|
28
26
|
|
|
29
27
|
## Install
|
|
@@ -53,25 +51,23 @@ first and the caller's flags appended, and it must not trip over the second set.
|
|
|
53
51
|
|
|
54
52
|
| Area | Exports |
|
|
55
53
|
| ---------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
56
|
-
| argv | `ownArgv`, `splitRunner`, `take`, `stageOf`, `GATE_FLAGS`, `BUILDER_FLAGS
|
|
54
|
+
| argv | `ownArgv`, `splitRunner`, `take`, `stageOf`, `GATE_FLAGS`, `BUILDER_FLAGS` |
|
|
57
55
|
| options | `parseOptions` — a spec of flags, with choices, fallbacks and repeatable ones |
|
|
58
|
-
| stdout | `emitVerdict`, `emitFailure`, `
|
|
56
|
+
| stdout | `emitVerdict`, `emitFailure`, `writeContract`, `writeDiagnostic` — emits use `writeContract` so `process.exit` cannot truncate |
|
|
59
57
|
| agent CLIs | `findExecutable`, `runAgent`, `readResult`, `serializeRun`, `extrasOf`, `finishRun`, `failureOf` — `serializeRun` always writes `skills` / `usage` / `tools` (`null` = unknown), and `plugins` (`AgentPlugin`) when the wrapper loaded any |
|
|
60
58
|
| prompts | `renderPrompt`, `readTemplate`, `PROMPT_RULES` — fill is generic; each role owns its names |
|
|
61
59
|
| roles | `parseRole`, `loadPrompt`, `loadRules`, `fillPrompt`, `spawnFilled`, `transcriptArgs`, `ROLE_OPTIONS` — a role fills its template and hands it to the agent after `--` |
|
|
62
60
|
| transcript | `openTranscript`, `transcriptFor`, `TRANSCRIPT_PARTS`, `skillsLabel`, `usageLabel`, `toolsFacts`, `pluginsLabel` — optional extras on `write` |
|
|
63
|
-
| plans | `checkPlan` |
|
|
64
61
|
| paths | `pathMatchesGlob` |
|
|
65
62
|
|
|
66
63
|
Each `emit*` takes an optional `write`, which is how they are tested without a
|
|
67
64
|
process. Everything else is a plain function over its arguments; `finishRun` is
|
|
68
65
|
the one exception, and ends the process on purpose.
|
|
69
66
|
|
|
70
|
-
## The
|
|
67
|
+
## The two roles
|
|
71
68
|
|
|
72
69
|
| Role | Spawned by | Answers |
|
|
73
70
|
| ------- | ---------------- | ----------------------------------------------------------------------------- |
|
|
74
|
-
| Planner | FeatureBreakdown | `{"subtasks":[…]}`, or `{"outcome":"refused",…}` for an unsplittable one |
|
|
75
71
|
| Builder | Implementer | Nothing on a pass — the workspace is the answer. `{"outcome":…}` on a failure |
|
|
76
72
|
| Gate | Implementer | `{"verdict":"pass"}`, or `fail-retryable` / `fail-blocking` with a `report` |
|
|
77
73
|
|
|
@@ -106,6 +102,5 @@ src/
|
|
|
106
102
|
prompt.ts generic fill, rules, agent prompt (already rendered)
|
|
107
103
|
role.ts parse a role, fill its template, spawn the agent after `--`
|
|
108
104
|
transcript.ts one file per turn, when a Project asks for one
|
|
109
|
-
plan.ts whether a Plan can be acted on
|
|
110
105
|
glob.ts path globs
|
|
111
106
|
```
|
package/dist/agent.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* What every slot that drives an agent CLI needs, and nothing about any one of
|
|
3
|
-
* them. A Builder and a
|
|
3
|
+
* them. A Builder and a Describer answer different contracts; finding a binary,
|
|
4
4
|
* running it and reading its result is the same work twice.
|
|
5
5
|
*/
|
|
6
6
|
/**
|
package/dist/agent.js
CHANGED
|
@@ -3,7 +3,7 @@ import { accessSync, constants } from "node:fs";
|
|
|
3
3
|
import { delimiter, join } from "node:path";
|
|
4
4
|
/**
|
|
5
5
|
* What every slot that drives an agent CLI needs, and nothing about any one of
|
|
6
|
-
* them. A Builder and a
|
|
6
|
+
* them. A Builder and a Describer answer different contracts; finding a binary,
|
|
7
7
|
* running it and reading its result is the same work twice.
|
|
8
8
|
*/
|
|
9
9
|
/**
|
package/dist/argv.d.ts
CHANGED
|
@@ -8,8 +8,6 @@
|
|
|
8
8
|
export declare const GATE_FLAGS: ReadonlySet<string>;
|
|
9
9
|
/** Flags Implementer appends after a Builder's own argv. */
|
|
10
10
|
export declare const BUILDER_FLAGS: ReadonlySet<string>;
|
|
11
|
-
/** Flags FeatureBreakdown appends after a Planner's own argv. */
|
|
12
|
-
export declare const PLANNER_FLAGS: ReadonlySet<string>;
|
|
13
11
|
export declare const PUBLISHER_FLAGS: ReadonlySet<string>;
|
|
14
12
|
export declare const REFRESHER_FLAGS: ReadonlySet<string>;
|
|
15
13
|
/** Flags Host appends after a Describer's own argv. */
|
|
@@ -18,8 +16,7 @@ export declare const MESSAGE_FLAGS: ReadonlySet<string>;
|
|
|
18
16
|
* Argv tokens that belong to the slot, not to the Transformer that spawned it.
|
|
19
17
|
*
|
|
20
18
|
* `caller` is that Transformer's flag set — `GATE_FLAGS`, `BUILDER_FLAGS`,
|
|
21
|
-
* `
|
|
22
|
-
* `REFRESHER_FLAGS`. Each of them takes a value, so a match consumes two tokens.
|
|
19
|
+
* `PUBLISHER_FLAGS` or `REFRESHER_FLAGS`. Each of them takes a value, so a match consumes two tokens.
|
|
23
20
|
*/
|
|
24
21
|
export declare function ownArgv(argv: readonly string[], caller: ReadonlySet<string>): string[];
|
|
25
22
|
/**
|
package/dist/argv.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"argv.d.ts","sourceRoot":"","sources":["../src/argv.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,yDAAyD;AACzD,eAAO,MAAM,UAAU,EAAE,WAAW,CAAC,MAAM,
|
|
1
|
+
{"version":3,"file":"argv.d.ts","sourceRoot":"","sources":["../src/argv.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,yDAAyD;AACzD,eAAO,MAAM,UAAU,EAAE,WAAW,CAAC,MAAM,CAOzC,CAAC;AAEH,4DAA4D;AAC5D,eAAO,MAAM,aAAa,EAAE,WAAW,CAAC,MAAM,CAQ5C,CAAC;AAEH,eAAO,MAAM,eAAe,EAAE,WAAW,CAAC,MAAM,CAA0C,CAAC;AAE3F,eAAO,MAAM,eAAe,EAAE,WAAW,CAAC,MAAM,CAAmC,CAAC;AAEpF,uDAAuD;AACvD,eAAO,MAAM,aAAa,EAAE,WAAW,CAAC,MAAM,CAK5C,CAAC;AAEH;;;;;GAKG;AACH,wBAAgB,OAAO,CAAC,IAAI,EAAE,SAAS,MAAM,EAAE,EAAE,MAAM,EAAE,WAAW,CAAC,MAAM,CAAC,GAAG,MAAM,EAAE,CActF;AAED;;;;;;GAMG;AACH,wBAAgB,WAAW,CACzB,MAAM,EAAE,SAAS,MAAM,EAAE,GACxB;IAAE,EAAE,EAAE,IAAI,CAAC;IAAC,GAAG,EAAE,MAAM,EAAE,CAAC;IAAC,MAAM,EAAE,MAAM,EAAE,CAAA;CAAE,GAAG;IAAE,EAAE,EAAE,KAAK,CAAA;CAAE,CAU/D;AAED,0EAA0E;AAC1E,wBAAgB,IAAI,CAAC,IAAI,EAAE,SAAS,MAAM,EAAE,EAAE,IAAI,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAG9E;AAED,2EAA2E;AAC3E,wBAAgB,OAAO,CAAC,IAAI,EAAE,SAAS,MAAM,EAAE,GAAG,MAAM,CAGvD"}
|
package/dist/argv.js
CHANGED
|
@@ -10,7 +10,6 @@ export const GATE_FLAGS = new Set([
|
|
|
10
10
|
"--attempt",
|
|
11
11
|
"--gate-id",
|
|
12
12
|
"--intention",
|
|
13
|
-
"--definition-of-done",
|
|
14
13
|
"--timeout-ms",
|
|
15
14
|
"--stage",
|
|
16
15
|
]);
|
|
@@ -19,21 +18,13 @@ export const BUILDER_FLAGS = new Set([
|
|
|
19
18
|
"--id",
|
|
20
19
|
"--attempt",
|
|
21
20
|
"--intention",
|
|
22
|
-
"--definition-of-done",
|
|
23
21
|
"--report",
|
|
24
22
|
"--report-from",
|
|
25
23
|
"--history",
|
|
26
24
|
"--context",
|
|
27
25
|
]);
|
|
28
|
-
/** Flags FeatureBreakdown appends after a Planner's own argv. */
|
|
29
|
-
export const PLANNER_FLAGS = new Set([
|
|
30
|
-
"--key",
|
|
31
|
-
"--intention",
|
|
32
|
-
"--max-units",
|
|
33
|
-
"--title",
|
|
34
|
-
]);
|
|
35
26
|
export const PUBLISHER_FLAGS = new Set(["--id", "--ref", "--target"]);
|
|
36
|
-
export const REFRESHER_FLAGS = new Set(["--target"]);
|
|
27
|
+
export const REFRESHER_FLAGS = new Set(["--target", "--base"]);
|
|
37
28
|
/** Flags Host appends after a Describer's own argv. */
|
|
38
29
|
export const MESSAGE_FLAGS = new Set([
|
|
39
30
|
"--id",
|
|
@@ -45,8 +36,7 @@ export const MESSAGE_FLAGS = new Set([
|
|
|
45
36
|
* Argv tokens that belong to the slot, not to the Transformer that spawned it.
|
|
46
37
|
*
|
|
47
38
|
* `caller` is that Transformer's flag set — `GATE_FLAGS`, `BUILDER_FLAGS`,
|
|
48
|
-
* `
|
|
49
|
-
* `REFRESHER_FLAGS`. Each of them takes a value, so a match consumes two tokens.
|
|
39
|
+
* `PUBLISHER_FLAGS` or `REFRESHER_FLAGS`. Each of them takes a value, so a match consumes two tokens.
|
|
50
40
|
*/
|
|
51
41
|
export function ownArgv(argv, caller) {
|
|
52
42
|
const out = [];
|
package/dist/argv.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"argv.js","sourceRoot":"","sources":["../src/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AAC,CAAC,IAAI,MAAM,CAAC,CAAC;AACpD,CAAC"}
|
package/dist/emit.d.ts
CHANGED
|
@@ -16,7 +16,7 @@ export type Write = (line: string) => void;
|
|
|
16
16
|
* Uses `writeSync` so an immediate `process.exit` cannot drop the tail of a
|
|
17
17
|
* large JSON line. `process.stdout.write` only fills a userspace buffer that
|
|
18
18
|
* `process.exit` abandons before the kernel drain finishes — that is how a
|
|
19
|
-
* finished agent run
|
|
19
|
+
* finished agent run reaches the role as "wrote no result".
|
|
20
20
|
*/
|
|
21
21
|
export declare function writeContract(line: string): void;
|
|
22
22
|
/**
|
|
@@ -28,8 +28,6 @@ export declare function writeDiagnostic(text: string): void;
|
|
|
28
28
|
export declare function emitVerdict(verdict: Verdict, report?: string, write?: Write): void;
|
|
29
29
|
/** A Builder's failure. A pass says nothing: the workspace is the answer. */
|
|
30
30
|
export declare function emitFailure(outcome: Failure, report: string, write?: Write): void;
|
|
31
|
-
/** A Plan on stdout, and nothing else on it. */
|
|
32
|
-
export declare function emitPlan(subtasks: unknown, write?: Write): void;
|
|
33
31
|
/**
|
|
34
32
|
* Where the work now is, for the Authority to read.
|
|
35
33
|
*
|
|
@@ -53,7 +51,7 @@ export declare function emitPublishRefusal(reason: string, write?: Write): void;
|
|
|
53
51
|
*/
|
|
54
52
|
export declare function emitMessage(subject: string, body?: string, write?: Write): void;
|
|
55
53
|
/**
|
|
56
|
-
* The work line copy
|
|
54
|
+
* The work line copy holds what the Authority holds.
|
|
57
55
|
*
|
|
58
56
|
* Nothing to bring back is a success, not a special case: a Refresher that
|
|
59
57
|
* found the copy already up to date answers the same way.
|
|
@@ -66,10 +64,4 @@ export declare function emitRefreshed(write?: Write): void;
|
|
|
66
64
|
* exists, so this refusal stops the pass rather than letting it run.
|
|
67
65
|
*/
|
|
68
66
|
export declare function emitRefreshRefusal(reason: string, write?: Write): void;
|
|
69
|
-
/**
|
|
70
|
-
* The FeatureStandard cannot be split. This is a verdict on the intention, not
|
|
71
|
-
* a failure of the slot: a slot that could not answer must exit non-zero and
|
|
72
|
-
* say why on stderr, so the Breakdown is retried rather than the feature buried.
|
|
73
|
-
*/
|
|
74
|
-
export declare function emitRefusal(reason: string, write?: Write): void;
|
|
75
67
|
//# sourceMappingURL=emit.d.ts.map
|
package/dist/emit.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"emit.d.ts","sourceRoot":"","sources":["../src/emit.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAIH,kDAAkD;AAClD,MAAM,MAAM,OAAO,GAAG,MAAM,GAAG,gBAAgB,GAAG,eAAe,CAAC;AAElE,6DAA6D;AAC7D,MAAM,MAAM,OAAO,GAAG,OAAO,CAAC,OAAO,EAAE,MAAM,CAAC,CAAC;AAE/C,MAAM,MAAM,KAAK,GAAG,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;AAE3C;;;;;;;GAOG;AACH,wBAAgB,aAAa,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAEhD;AAED;;;GAGG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAElD;AAID,mEAAmE;AACnE,wBAAgB,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,MAAM,SAAK,EAAE,KAAK,GAAE,KAAgB,GAAG,IAAI,CAExF;AAED,6EAA6E;AAC7E,wBAAgB,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,KAAK,GAAE,KAAgB,GAAG,IAAI,CAE3F;AAED
|
|
1
|
+
{"version":3,"file":"emit.d.ts","sourceRoot":"","sources":["../src/emit.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAIH,kDAAkD;AAClD,MAAM,MAAM,OAAO,GAAG,MAAM,GAAG,gBAAgB,GAAG,eAAe,CAAC;AAElE,6DAA6D;AAC7D,MAAM,MAAM,OAAO,GAAG,OAAO,CAAC,OAAO,EAAE,MAAM,CAAC,CAAC;AAE/C,MAAM,MAAM,KAAK,GAAG,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;AAE3C;;;;;;;GAOG;AACH,wBAAgB,aAAa,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAEhD;AAED;;;GAGG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAElD;AAID,mEAAmE;AACnE,wBAAgB,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,MAAM,SAAK,EAAE,KAAK,GAAE,KAAgB,GAAG,IAAI,CAExF;AAED,6EAA6E;AAC7E,wBAAgB,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,KAAK,GAAE,KAAgB,GAAG,IAAI,CAE3F;AAED;;;;;;GAMG;AACH,wBAAgB,eAAe,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,GAAE,KAAgB,GAAG,IAAI,CAE1E;AAED;;;;;;GAMG;AACH,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,MAAM,EAAE,KAAK,GAAE,KAAgB,GAAG,IAAI,CAEhF;AAED;;;;GAIG;AACH,wBAAgB,WAAW,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM,EAAE,KAAK,GAAE,KAAgB,GAAG,IAAI,CAEzF;AAED;;;;;GAKG;AACH,wBAAgB,aAAa,CAAC,KAAK,GAAE,KAAgB,GAAG,IAAI,CAE3D;AAED;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,MAAM,EAAE,KAAK,GAAE,KAAgB,GAAG,IAAI,CAEhF"}
|
package/dist/emit.js
CHANGED
|
@@ -12,7 +12,7 @@ import { writeSync } from "node:fs";
|
|
|
12
12
|
* Uses `writeSync` so an immediate `process.exit` cannot drop the tail of a
|
|
13
13
|
* large JSON line. `process.stdout.write` only fills a userspace buffer that
|
|
14
14
|
* `process.exit` abandons before the kernel drain finishes — that is how a
|
|
15
|
-
* finished agent run
|
|
15
|
+
* finished agent run reaches the role as "wrote no result".
|
|
16
16
|
*/
|
|
17
17
|
export function writeContract(line) {
|
|
18
18
|
writeSync(1, line);
|
|
@@ -33,10 +33,6 @@ export function emitVerdict(verdict, report = "", write = toStdout) {
|
|
|
33
33
|
export function emitFailure(outcome, report, write = toStdout) {
|
|
34
34
|
write(`${JSON.stringify({ outcome, report })}\n`);
|
|
35
35
|
}
|
|
36
|
-
/** A Plan on stdout, and nothing else on it. */
|
|
37
|
-
export function emitPlan(subtasks, write = toStdout) {
|
|
38
|
-
write(`${JSON.stringify({ subtasks })}\n`);
|
|
39
|
-
}
|
|
40
36
|
/**
|
|
41
37
|
* Where the work now is, for the Authority to read.
|
|
42
38
|
*
|
|
@@ -66,7 +62,7 @@ export function emitMessage(subject, body, write = toStdout) {
|
|
|
66
62
|
write(`${JSON.stringify(body === undefined ? { subject } : { subject, body })}\n`);
|
|
67
63
|
}
|
|
68
64
|
/**
|
|
69
|
-
* The work line copy
|
|
65
|
+
* The work line copy holds what the Authority holds.
|
|
70
66
|
*
|
|
71
67
|
* Nothing to bring back is a success, not a special case: a Refresher that
|
|
72
68
|
* found the copy already up to date answers the same way.
|
|
@@ -83,12 +79,4 @@ export function emitRefreshed(write = toStdout) {
|
|
|
83
79
|
export function emitRefreshRefusal(reason, write = toStdout) {
|
|
84
80
|
write(`${JSON.stringify({ outcome: "refused", reason })}\n`);
|
|
85
81
|
}
|
|
86
|
-
/**
|
|
87
|
-
* The FeatureStandard cannot be split. This is a verdict on the intention, not
|
|
88
|
-
* a failure of the slot: a slot that could not answer must exit non-zero and
|
|
89
|
-
* say why on stderr, so the Breakdown is retried rather than the feature buried.
|
|
90
|
-
*/
|
|
91
|
-
export function emitRefusal(reason, write = toStdout) {
|
|
92
|
-
write(`${JSON.stringify({ outcome: "refused", code: "not-specifiable", reason })}\n`);
|
|
93
|
-
}
|
|
94
82
|
//# sourceMappingURL=emit.js.map
|
package/dist/emit.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"emit.js","sourceRoot":"","sources":["../src/emit.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAUpC;;;;;;;GAOG;AACH,MAAM,UAAU,aAAa,CAAC,IAAY;IACxC,SAAS,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC;AACrB,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,eAAe,CAAC,IAAY;IAC1C,SAAS,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC;AACrB,CAAC;AAED,MAAM,QAAQ,GAAU,aAAa,CAAC;AAEtC,mEAAmE;AACnE,MAAM,UAAU,WAAW,CAAC,OAAgB,EAAE,MAAM,GAAG,EAAE,EAAE,QAAe,QAAQ;IAChF,KAAK,CAAC,GAAG,IAAI,CAAC,SAAS,CAAC,EAAE,OAAO,EAAE,MAAM,EAAE,CAAC,IAAI,CAAC,CAAC;AACpD,CAAC;AAED,6EAA6E;AAC7E,MAAM,UAAU,WAAW,CAAC,OAAgB,EAAE,MAAc,EAAE,QAAe,QAAQ;IACnF,KAAK,CAAC,GAAG,IAAI,CAAC,SAAS,CAAC,EAAE,OAAO,EAAE,MAAM,EAAE,CAAC,IAAI,CAAC,CAAC;AACpD,CAAC;AAED
|
|
1
|
+
{"version":3,"file":"emit.js","sourceRoot":"","sources":["../src/emit.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAUpC;;;;;;;GAOG;AACH,MAAM,UAAU,aAAa,CAAC,IAAY;IACxC,SAAS,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC;AACrB,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,eAAe,CAAC,IAAY;IAC1C,SAAS,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC;AACrB,CAAC;AAED,MAAM,QAAQ,GAAU,aAAa,CAAC;AAEtC,mEAAmE;AACnE,MAAM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AkB,CAAC,MAAc,EAAE,QAAe,QAAQ;IACxE,KAAK,CAAC,GAAG,IAAI,CAAC,SAAS,CAAC,EAAE,OAAO,EAAE,SAAS,EAAE,MAAM,EAAE,CAAC,IAAI,CAAC,CAAC;AAC/D,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,24 +1,21 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* What a slot needs to answer the Transformer that spawned it.
|
|
3
3
|
*
|
|
4
|
-
* A slot is an opaque command: Implementer spawns a Builder and its Gates,
|
|
5
|
-
*
|
|
6
|
-
* JSON line on stdout. Nothing here is required to fill a slot — a shell script
|
|
4
|
+
* A slot is an opaque command: Implementer spawns a Builder and its Gates, and
|
|
5
|
+
* each one reads argv and writes one JSON line on stdout. Nothing here is required to fill a slot — a shell script
|
|
7
6
|
* that prints the right line is a Gate. This is the plumbing that every slot
|
|
8
7
|
* written in Node would otherwise write again.
|
|
9
8
|
*/
|
|
10
9
|
export type { AgentExtras, AgentInvocation, AgentPlugin, AgentRun, AgentTools, AgentUsage, SerializeAbout, SerializedRun, } from "./agent.js";
|
|
11
10
|
export { deserializeRun, extrasOf, findExecutable, readResult, runAgent, serializeRun, } from "./agent.js";
|
|
12
|
-
export { BUILDER_FLAGS, GATE_FLAGS, MESSAGE_FLAGS, ownArgv,
|
|
11
|
+
export { BUILDER_FLAGS, GATE_FLAGS, MESSAGE_FLAGS, ownArgv, PUBLISHER_FLAGS, REFRESHER_FLAGS, splitRunner, stageOf, take, } from "./argv.js";
|
|
13
12
|
export type { Failure, Verdict, Write } from "./emit.js";
|
|
14
|
-
export { emitFailure, emitMessage,
|
|
13
|
+
export { emitFailure, emitMessage, emitPublication, emitPublishRefusal, emitRefreshed, emitRefreshRefusal, emitVerdict, writeContract, writeDiagnostic, } from "./emit.js";
|
|
15
14
|
export type { FinishedRun, RunJudgement } from "./finish.js";
|
|
16
15
|
export { blockedReason, failureOf, finishRun, judgeRun } from "./finish.js";
|
|
17
16
|
export { pathMatchesGlob } from "./glob.js";
|
|
18
17
|
export type { OptionRule, OptionSpec, OptionValues, ParsedOptions } from "./options.js";
|
|
19
18
|
export { listOption, parseOptions, textOption } from "./options.js";
|
|
20
|
-
export type { CheckedPlan, PlanSubtask } from "./plan.js";
|
|
21
|
-
export { checkPlan } from "./plan.js";
|
|
22
19
|
export type { ReadTemplate, Rendered, TranscriptSubject } from "./prompt.js";
|
|
23
20
|
export { AGENT_OPTIONS, PROMPT_RULES, readAgentPrompt, readTemplate, renderPrompt, transcriptFor, } from "./prompt.js";
|
|
24
21
|
export type { AgentAbout, ParsedRole, SpawnedAgent, TranscriptExtras } from "./role.js";
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,YAAY,EACV,WAAW,EACX,eAAe,EACf,WAAW,EACX,QAAQ,EACR,UAAU,EACV,UAAU,EACV,cAAc,EACd,aAAa,GACd,MAAM,YAAY,CAAC;AACpB,OAAO,EACL,cAAc,EACd,QAAQ,EACR,cAAc,EACd,UAAU,EACV,QAAQ,EACR,YAAY,GACb,MAAM,YAAY,CAAC;AACpB,OAAO,EACL,aAAa,EACb,UAAU,EACV,aAAa,EACb,OAAO,EACP,eAAe,EACf,eAAe,EACf,WAAW,EACX,OAAO,EACP,IAAI,GACL,MAAM,WAAW,CAAC;AACnB,YAAY,EAAE,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,WAAW,CAAC;AACzD,OAAO,EACL,WAAW,EACX,WAAW,EACX,eAAe,EACf,kBAAkB,EAClB,aAAa,EACb,kBAAkB,EAClB,WAAW,EACX,aAAa,EACb,eAAe,GAChB,MAAM,WAAW,CAAC;AACnB,YAAY,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAC7D,OAAO,EAAE,aAAa,EAAE,SAAS,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAC5E,OAAO,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;AAC5C,YAAY,EAAE,UAAU,EAAE,UAAU,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AACxF,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AACpE,YAAY,EAAE,YAAY,EAAE,QAAQ,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC;AAC7E,OAAO,EACL,aAAa,EACb,YAAY,EACZ,eAAe,EACf,YAAY,EACZ,YAAY,EACZ,aAAa,GACd,MAAM,aAAa,CAAC;AACrB,YAAY,EAAE,UAAU,EAAE,UAAU,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,WAAW,CAAC;AACxF,OAAO,EACL,UAAU,EACV,UAAU,EACV,SAAS,EACT,SAAS,EACT,YAAY,EACZ,WAAW,EACX,cAAc,GACf,MAAM,WAAW,CAAC;AACnB,YAAY,EAAE,UAAU,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAClF,OAAO,EACL,cAAc,EACd,YAAY,EACZ,WAAW,EACX,gBAAgB,EAChB,UAAU,EACV,UAAU,GACX,MAAM,iBAAiB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -1,19 +1,17 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* What a slot needs to answer the Transformer that spawned it.
|
|
3
3
|
*
|
|
4
|
-
* A slot is an opaque command: Implementer spawns a Builder and its Gates,
|
|
5
|
-
*
|
|
6
|
-
* JSON line on stdout. Nothing here is required to fill a slot — a shell script
|
|
4
|
+
* A slot is an opaque command: Implementer spawns a Builder and its Gates, and
|
|
5
|
+
* each one reads argv and writes one JSON line on stdout. Nothing here is required to fill a slot — a shell script
|
|
7
6
|
* that prints the right line is a Gate. This is the plumbing that every slot
|
|
8
7
|
* written in Node would otherwise write again.
|
|
9
8
|
*/
|
|
10
9
|
export { deserializeRun, extrasOf, findExecutable, readResult, runAgent, serializeRun, } from "./agent.js";
|
|
11
|
-
export { BUILDER_FLAGS, GATE_FLAGS, MESSAGE_FLAGS, ownArgv,
|
|
12
|
-
export { emitFailure, emitMessage,
|
|
10
|
+
export { BUILDER_FLAGS, GATE_FLAGS, MESSAGE_FLAGS, ownArgv, PUBLISHER_FLAGS, REFRESHER_FLAGS, splitRunner, stageOf, take, } from "./argv.js";
|
|
11
|
+
export { emitFailure, emitMessage, emitPublication, emitPublishRefusal, emitRefreshed, emitRefreshRefusal, emitVerdict, writeContract, writeDiagnostic, } from "./emit.js";
|
|
13
12
|
export { blockedReason, failureOf, finishRun, judgeRun } from "./finish.js";
|
|
14
13
|
export { pathMatchesGlob } from "./glob.js";
|
|
15
14
|
export { listOption, parseOptions, textOption } from "./options.js";
|
|
16
|
-
export { checkPlan } from "./plan.js";
|
|
17
15
|
export { AGENT_OPTIONS, PROMPT_RULES, readAgentPrompt, readTemplate, renderPrompt, transcriptFor, } from "./prompt.js";
|
|
18
16
|
export { fillPrompt, loadPrompt, loadRules, parseRole, ROLE_OPTIONS, spawnFilled, transcriptArgs, } from "./role.js";
|
|
19
17
|
export { openTranscript, pluginsLabel, skillsLabel, TRANSCRIPT_PARTS, toolsFacts, usageLabel, } from "./transcript.js";
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAYH,OAAO,EACL,cAAc,EACd,QAAQ,EACR,cAAc,EACd,UAAU,EACV,QAAQ,EACR,YAAY,GACb,MAAM,YAAY,CAAC;AACpB,OAAO,EACL,aAAa,EACb,UAAU,EACV,aAAa,EACb,OAAO,EACP,eAAe,EACf,eAAe,EACf,WAAW,EACX,OAAO,EACP,IAAI,GACL,MAAM,WAAW,CAAC;AAEnB,OAAO,EACL,WAAW,EACX,WAAW,EACX,eAAe,EACf,kBAAkB,EAClB,aAAa,EACb,kBAAkB,EAClB,WAAW,EACX,aAAa,EACb,eAAe,GAChB,MAAM,WAAW,CAAC;AAEnB,OAAO,EAAE,aAAa,EAAE,SAAS,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAC5E,OAAO,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;AAE5C,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAEpE,OAAO,EACL,aAAa,EACb,YAAY,EACZ,eAAe,EACf,YAAY,EACZ,YAAY,EACZ,aAAa,GACd,MAAM,aAAa,CAAC;AAErB,OAAO,EACL,UAAU,EACV,UAAU,EACV,SAAS,EACT,SAAS,EACT,YAAY,EACZ,WAAW,EACX,cAAc,GACf,MAAM,WAAW,CAAC;AAEnB,OAAO,EACL,cAAc,EACd,YAAY,EACZ,WAAW,EACX,gBAAgB,EAChB,UAAU,EACV,UAAU,GACX,MAAM,iBAAiB,CAAC"}
|
package/dist/prompt.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"prompt.d.ts","sourceRoot":"","sources":["../src/prompt.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAE9C,OAAO,EAAE,KAAK,UAAU,EAAE,KAAK,YAAY,EAAc,MAAM,cAAc,CAAC;AAC9E,OAAO,EAAoC,KAAK,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAEpF;;;;;;;;;GASG;AACH,eAAO,MAAM,YAAY,
|
|
1
|
+
{"version":3,"file":"prompt.d.ts","sourceRoot":"","sources":["../src/prompt.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM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G,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACzB,IAAI,CAAC,EAAE,SAAS,MAAM,EAAE,GAAG,SAAS,CAAC;IACrC,MAAM,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC5B,OAAO,CAAC,EAAE,SAAS,WAAW,EAAE,GAAG,SAAS,CAAC;CAC9C,CAAC;AAEF,oEAAoE;AACpE,wBAAgB,aAAa,CAC3B,IAAI,EAAE,SAAS,MAAM,EAAE,EACvB,OAAO,EAAE,YAAY,EACrB,KAAK,EAAE,iBAAiB,GACvB,UAAU,CAUZ"}
|
package/dist/prompt.js
CHANGED
|
@@ -17,7 +17,10 @@ export const PROMPT_RULES = [
|
|
|
17
17
|
"- Follow the conventions already in this repository: its structure, its naming,",
|
|
18
18
|
" its tests. Read the code around what you touch before you write.",
|
|
19
19
|
"- Change only what the task needs.",
|
|
20
|
-
"- If the project has checks of its own, run them and leave them passing.",
|
|
20
|
+
"- If the project has checks of its own, run them and leave them passing. Run each",
|
|
21
|
+
" once, at the scope of what you changed: a machine runs the project's complete",
|
|
22
|
+
" checks on your work after you finish, and the time you have is not for running",
|
|
23
|
+
" the whole sequence again and again.",
|
|
21
24
|
"- Nobody is watching this run and nobody will answer a question. Where the task",
|
|
22
25
|
" is ambiguous, take the reading most consistent with the existing code, and say",
|
|
23
26
|
" which one you took in your final message.",
|
|
@@ -102,7 +105,7 @@ export const AGENT_OPTIONS = {
|
|
|
102
105
|
"--pass-env": { many: true },
|
|
103
106
|
"--deny-shell": { many: true },
|
|
104
107
|
"--plugin-dir": { many: true },
|
|
105
|
-
"--profile": {},
|
|
108
|
+
"--app-deck-profile": {},
|
|
106
109
|
"--plugins-out": {},
|
|
107
110
|
"--deck-bin": {},
|
|
108
111
|
"--id": {},
|
package/dist/prompt.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"prompt.js","sourceRoot":"","sources":["../src/prompt.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YA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MAAM,KAAK,GAAG,OAAO,CAAC,cAAc,CAAC;IACrC,OAAO,cAAc,CAAC;QACpB,GAAG,EAAE,UAAU,CAAC,OAAO,EAAE,eAAe,CAAC;QACzC,GAAG,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QAC9D,OAAO,EAAE,IAAI,CAAC,IAAI,EAAE,WAAW,CAAC;QAChC,EAAE,EAAE,IAAI,CAAC,IAAI,EAAE,MAAM,CAAC;QACtB,OAAO,EAAE,IAAI,CAAC,IAAI,EAAE,WAAW,CAAC;QAChC,GAAG,KAAK;KACT,CAAC,CAAC;AACL,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bluewombat/slot-kit",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.10.0",
|
|
4
4
|
"type": "module",
|
|
5
|
-
"description": "What a
|
|
5
|
+
"description": "What a Builder or Gate written in Node needs to answer the Transformer that spawned it.",
|
|
6
6
|
"keywords": [
|
|
7
7
|
"mason",
|
|
8
8
|
"bluewombat",
|
package/dist/plan.d.ts
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
export type PlanSubtask = {
|
|
2
|
-
id: string;
|
|
3
|
-
intention: string;
|
|
4
|
-
definition_of_done: string;
|
|
5
|
-
depends_on: string[];
|
|
6
|
-
};
|
|
7
|
-
export type CheckedPlan = {
|
|
8
|
-
ok: true;
|
|
9
|
-
subtasks: PlanSubtask[];
|
|
10
|
-
} | {
|
|
11
|
-
ok: false;
|
|
12
|
-
reason: string;
|
|
13
|
-
};
|
|
14
|
-
/**
|
|
15
|
-
* Whether this is a Plan the rest of the system can act on — and, when it is,
|
|
16
|
-
* the subtasks typed as one.
|
|
17
|
-
*
|
|
18
|
-
* Checked here rather than trusted, because a Planner that hands back a broken
|
|
19
|
-
* graph has failed at its one job, and the failure should read as this slot's,
|
|
20
|
-
* not as a refusal of the feature.
|
|
21
|
-
*/
|
|
22
|
-
export declare function checkPlan(subtasks: unknown, maxUnits?: number): CheckedPlan;
|
|
23
|
-
//# sourceMappingURL=plan.d.ts.map
|
package/dist/plan.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"plan.d.ts","sourceRoot":"","sources":["../src/plan.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,WAAW,GAAG;IACxB,EAAE,EAAE,MAAM,CAAC;IACX,SAAS,EAAE,MAAM,CAAC;IAClB,kBAAkB,EAAE,MAAM,CAAC;IAC3B,UAAU,EAAE,MAAM,EAAE,CAAC;CACtB,CAAC;AAEF,MAAM,MAAM,WAAW,GAAG;IAAE,EAAE,EAAE,IAAI,CAAC;IAAC,QAAQ,EAAE,WAAW,EAAE,CAAA;CAAE,GAAG;IAAE,EAAE,EAAE,KAAK,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,CAAC;AAEhG;;;;;;;GAOG;AACH,wBAAgB,SAAS,CAAC,QAAQ,EAAE,OAAO,EAAE,QAAQ,CAAC,EAAE,MAAM,GAAG,WAAW,CAkD3E"}
|
package/dist/plan.js
DELETED
|
@@ -1,94 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Whether this is a Plan the rest of the system can act on — and, when it is,
|
|
3
|
-
* the subtasks typed as one.
|
|
4
|
-
*
|
|
5
|
-
* Checked here rather than trusted, because a Planner that hands back a broken
|
|
6
|
-
* graph has failed at its one job, and the failure should read as this slot's,
|
|
7
|
-
* not as a refusal of the feature.
|
|
8
|
-
*/
|
|
9
|
-
export function checkPlan(subtasks, maxUnits) {
|
|
10
|
-
if (!Array.isArray(subtasks) || subtasks.length === 0) {
|
|
11
|
-
return { ok: false, reason: "The plan has no subtasks." };
|
|
12
|
-
}
|
|
13
|
-
if (maxUnits !== undefined && Number.isInteger(maxUnits) && subtasks.length > maxUnits) {
|
|
14
|
-
return {
|
|
15
|
-
ok: false,
|
|
16
|
-
reason: `The plan has ${subtasks.length} subtasks, over the ${maxUnits} allowed.`,
|
|
17
|
-
};
|
|
18
|
-
}
|
|
19
|
-
const ids = new Set();
|
|
20
|
-
for (const subtask of subtasks) {
|
|
21
|
-
if (subtask === null || typeof subtask !== "object") {
|
|
22
|
-
return { ok: false, reason: "A subtask is not an object." };
|
|
23
|
-
}
|
|
24
|
-
const record = subtask;
|
|
25
|
-
for (const field of ["id", "intention", "definition_of_done"]) {
|
|
26
|
-
const value = record[field];
|
|
27
|
-
if (typeof value !== "string" || value.trim().length === 0) {
|
|
28
|
-
return { ok: false, reason: `A subtask has no "${field}".` };
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
const id = record.id;
|
|
32
|
-
if (ids.has(id)) {
|
|
33
|
-
return { ok: false, reason: `Two subtasks share the id "${id}".` };
|
|
34
|
-
}
|
|
35
|
-
ids.add(id);
|
|
36
|
-
if (!Array.isArray(record.depends_on)) {
|
|
37
|
-
return { ok: false, reason: `Subtask "${id}" has no depends_on list.` };
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
const plan = subtasks;
|
|
41
|
-
for (const subtask of plan) {
|
|
42
|
-
for (const dependency of subtask.depends_on) {
|
|
43
|
-
if (dependency === subtask.id) {
|
|
44
|
-
return { ok: false, reason: `Subtask "${subtask.id}" depends on itself.` };
|
|
45
|
-
}
|
|
46
|
-
if (!ids.has(dependency)) {
|
|
47
|
-
return {
|
|
48
|
-
ok: false,
|
|
49
|
-
reason: `Subtask "${subtask.id}" depends on "${dependency}", which is not in the plan.`,
|
|
50
|
-
};
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
const cycle = findCycle(plan);
|
|
55
|
-
if (cycle !== undefined) {
|
|
56
|
-
return { ok: false, reason: `The plan has a cycle: ${cycle.join(" → ")}.` };
|
|
57
|
-
}
|
|
58
|
-
return { ok: true, subtasks: plan };
|
|
59
|
-
}
|
|
60
|
-
/** Depth-first, so the answer names the loop rather than only reporting one. */
|
|
61
|
-
function findCycle(subtasks) {
|
|
62
|
-
const edges = new Map(subtasks.map((subtask) => [subtask.id, subtask.depends_on]));
|
|
63
|
-
const done = new Set();
|
|
64
|
-
const path = [];
|
|
65
|
-
const open = new Set();
|
|
66
|
-
const walk = (id) => {
|
|
67
|
-
if (done.has(id)) {
|
|
68
|
-
return undefined;
|
|
69
|
-
}
|
|
70
|
-
if (open.has(id)) {
|
|
71
|
-
return [...path.slice(path.indexOf(id)), id];
|
|
72
|
-
}
|
|
73
|
-
open.add(id);
|
|
74
|
-
path.push(id);
|
|
75
|
-
for (const next of edges.get(id) ?? []) {
|
|
76
|
-
const found = walk(next);
|
|
77
|
-
if (found !== undefined) {
|
|
78
|
-
return found;
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
path.pop();
|
|
82
|
-
open.delete(id);
|
|
83
|
-
done.add(id);
|
|
84
|
-
return undefined;
|
|
85
|
-
};
|
|
86
|
-
for (const subtask of subtasks) {
|
|
87
|
-
const found = walk(subtask.id);
|
|
88
|
-
if (found !== undefined) {
|
|
89
|
-
return found;
|
|
90
|
-
}
|
|
91
|
-
}
|
|
92
|
-
return undefined;
|
|
93
|
-
}
|
|
94
|
-
//# sourceMappingURL=plan.js.map
|
package/dist/plan.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"plan.js","sourceRoot":"","sources":["../src/plan.ts"],"names":[],"mappings":"AASA;;;;;;;GAOG;AACH,MAAM,UAAU,SAAS,CAAC,QAAiB,EAAE,QAAiB;IAC5D,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,QAAQ,CAAC,IAAI,QAAQ,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACtD,OAAO,EAAE,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,2BAA2B,EAAE,CAAC;IAC5D,CAAC;IACD,IAAI,QAA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