@taskless/cli 0.11.1 → 0.11.2
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 +3 -2
- package/dist/binary-DZahYwrf.js +108 -0
- package/dist/index.js +12899 -12280
- package/dist/node/runtimes.js +1 -1
- package/dist/prompts/index.d.ts +7 -1
- package/dist/prompts/recipes.d.ts +20 -0
- package/dist/prompts.js +16 -14
- package/dist/{recipes-w68swLg4.js → recipes-tkku5bYo.js} +627 -295
- package/dist/rules/capabilities.d.ts +19 -2
- package/dist/schemas/feedback.d.ts +19 -0
- package/dist/schemas/index.d.ts +14 -1
- package/dist/survey/constants.d.ts +50 -0
- package/dist/util/invocation.d.ts +18 -0
- package/package.json +15 -15
- package/dist/binary-DSACXL6n.js +0 -107
package/dist/node/runtimes.js
CHANGED
package/dist/prompts/index.d.ts
CHANGED
|
@@ -56,8 +56,14 @@ export declare const TOPICS: readonly ["create-sg-rule", "create-vale-rule", "cr
|
|
|
56
56
|
* the boundary from the client's side, `detect` documents a CLI subprocess a
|
|
57
57
|
* Worker cannot spawn, `create-legacy-rule` targets a local toolchain, and
|
|
58
58
|
* `rule-meta` describes a local sidecar file the CLI never writes.
|
|
59
|
+
* - `feedback` and `feedback-invite` belong to the survey the CLI appends to
|
|
60
|
+
* a served recipe. The invite is a fragment the `agent` command renders
|
|
61
|
+
* header-less and attaches after a recipe's last section; it lives here as
|
|
62
|
+
* a recipe so Vale and the cross-reference tests cover its prose, and it is
|
|
63
|
+
* servable by name only as a side effect of that. Neither has a reader
|
|
64
|
+
* outside the CLI that sends the response.
|
|
59
65
|
*/
|
|
60
|
-
export declare const INTERNAL_TOPICS: readonly ["auth", "check", "ci", "create-legacy-rule", "create-remote-rule", "delete-rule", "detect", "improve-rule", "info", "init", "onboard", "rule", "rule-meta", "update", "verify-rule"];
|
|
66
|
+
export declare const INTERNAL_TOPICS: readonly ["auth", "check", "ci", "create-legacy-rule", "create-remote-rule", "delete-rule", "detect", "feedback", "feedback-invite", "improve-rule", "info", "init", "onboard", "rule", "rule-meta", "update", "verify-rule"];
|
|
61
67
|
/** A topic name the package exports. Unknown names fail to type-check. */
|
|
62
68
|
export type PromptTopic = (typeof TOPICS)[number];
|
|
63
69
|
/** Options accepted by every prompt render function. */
|
|
@@ -64,6 +64,20 @@ export interface RecipeOptions {
|
|
|
64
64
|
* @default true
|
|
65
65
|
*/
|
|
66
66
|
header?: boolean;
|
|
67
|
+
/**
|
|
68
|
+
* Add the fetch-time directive as the header block's second line: the
|
|
69
|
+
* text was resolved by the CLI when it was fetched, the next task fetches
|
|
70
|
+
* it again, and a session that saw an install or upgrade holds a stale
|
|
71
|
+
* skill until it reloads. The `agent` command asks for it, because what it
|
|
72
|
+
* serves IS a fetch. The prompts export does not, because a consumer
|
|
73
|
+
* embedding a recipe in its own prompt has no CLI to re-run, and the
|
|
74
|
+
* statement would be false there.
|
|
75
|
+
*
|
|
76
|
+
* Lives in the header block so `header: false` drops it with the version.
|
|
77
|
+
*
|
|
78
|
+
* @default false
|
|
79
|
+
*/
|
|
80
|
+
directive?: boolean;
|
|
67
81
|
}
|
|
68
82
|
export declare function buildVariables(content: string, topic: string, options?: RecipeOptions): Record<string, string>;
|
|
69
83
|
/** A recipe's text plus the sprintf variables its template contains. */
|
|
@@ -71,6 +85,12 @@ export interface RecipeText {
|
|
|
71
85
|
text: string;
|
|
72
86
|
variables: string[];
|
|
73
87
|
}
|
|
88
|
+
/**
|
|
89
|
+
* The fetch-time directive, identical for every topic except the invocation.
|
|
90
|
+
* Rendered from the same resolution `%(TASKLESS_CLI)s` uses, so the command
|
|
91
|
+
* an agent is told to re-run is the one that served it.
|
|
92
|
+
*/
|
|
93
|
+
export declare function fetchTimeDirective(invocation: string): string;
|
|
74
94
|
/**
|
|
75
95
|
* Look up an agent recipe topic from the embedded recipe map and return the rendered
|
|
76
96
|
* text. Anonymous variants are preferred when `anonymous` is set and a
|
package/dist/prompts.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { g as n, a as i, b as
|
|
2
|
-
const
|
|
1
|
+
import { g as n, a as i, b as a } from "./recipes-tkku5bYo.js";
|
|
2
|
+
const u = [
|
|
3
3
|
"create-sg-rule",
|
|
4
4
|
"create-vale-rule",
|
|
5
5
|
"create-runtime-rule",
|
|
@@ -12,6 +12,8 @@ const o = [
|
|
|
12
12
|
"create-remote-rule",
|
|
13
13
|
"delete-rule",
|
|
14
14
|
"detect",
|
|
15
|
+
"feedback",
|
|
16
|
+
"feedback-invite",
|
|
15
17
|
"improve-rule",
|
|
16
18
|
"info",
|
|
17
19
|
"init",
|
|
@@ -21,14 +23,14 @@ const o = [
|
|
|
21
23
|
"update",
|
|
22
24
|
"verify-rule"
|
|
23
25
|
];
|
|
24
|
-
function
|
|
26
|
+
function c(e, r) {
|
|
25
27
|
return t(n(e, r), e);
|
|
26
28
|
}
|
|
27
|
-
function
|
|
29
|
+
function d(e, r) {
|
|
28
30
|
return t(i(e, r), e);
|
|
29
31
|
}
|
|
30
|
-
function
|
|
31
|
-
return t(
|
|
32
|
+
function l(e, r) {
|
|
33
|
+
return t(a(e, r), e);
|
|
32
34
|
}
|
|
33
35
|
function t(e, r) {
|
|
34
36
|
if (e === void 0)
|
|
@@ -37,17 +39,17 @@ function t(e, r) {
|
|
|
37
39
|
);
|
|
38
40
|
return e;
|
|
39
41
|
}
|
|
40
|
-
const
|
|
41
|
-
|
|
42
|
+
const f = Object.fromEntries(
|
|
43
|
+
u.map((e) => [
|
|
42
44
|
e,
|
|
43
|
-
(r) =>
|
|
45
|
+
(r) => c(e, r)
|
|
44
46
|
])
|
|
45
47
|
);
|
|
46
48
|
export {
|
|
47
49
|
s as INTERNAL_TOPICS,
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
50
|
+
f as PROMPTS,
|
|
51
|
+
u as TOPICS,
|
|
52
|
+
d as getInstructions,
|
|
53
|
+
c as getPrompt,
|
|
54
|
+
l as getRawInstructions
|
|
53
55
|
};
|