@fyeeme/pi-ask-user-lite 2.0.2 → 2.0.4
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/CHANGELOG.md +13 -0
- package/index.ts +11 -3
- package/package.json +5 -5
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,19 @@
|
|
|
2
2
|
|
|
3
3
|
## [Unreleased]
|
|
4
4
|
|
|
5
|
+
## [2.0.4] - 2026-10-02
|
|
6
|
+
|
|
7
|
+
### Changed
|
|
8
|
+
|
|
9
|
+
- Dev toolchain pinned to `@earendil-works/pi-coding-agent`/`pi-tui` 1.0.0 (peer floors unchanged, `>=0.99.0`); typecheck and tests pass against 1.0.0 unchanged.
|
|
10
|
+
|
|
11
|
+
## [2.0.3] - 2026-10-01
|
|
12
|
+
|
|
13
|
+
### Changed
|
|
14
|
+
|
|
15
|
+
- `ask_user` now registers with pi 0.99 `exposure: "model-only"`: declared to the model, unreachable from codemode scripts and nested tool execution (ask-the-user is a model-level decision). No `outputSchema` is declared — model-only tools have no programmatic consumer of structured results. Model-facing behavior is unchanged.
|
|
16
|
+
- Peer dependency floor raised to `@earendil-works/pi-coding-agent >= 0.99.0`; dev toolchain pinned to 0.99.2.
|
|
17
|
+
|
|
5
18
|
## [2.0.2] - 2026-09-09
|
|
6
19
|
|
|
7
20
|
### Fixed
|
package/index.ts
CHANGED
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
* `/tree` inspection.
|
|
16
16
|
*/
|
|
17
17
|
|
|
18
|
-
import type { ExtensionAPI, ExtensionCommandContext, ExtensionUIContext, ToolDefinition } from "@earendil-works/pi-coding-agent";
|
|
18
|
+
import type { ExtensionAPI, ExtensionCommandContext, ExtensionToolContext, ExtensionUIContext, ToolDefinition } from "@earendil-works/pi-coding-agent";
|
|
19
19
|
import type { Theme } from "@earendil-works/pi-coding-agent";
|
|
20
20
|
import { Editor, type EditorTheme, Key, matchesKey, Text, type TUI, visibleWidth, wrapTextWithAnsi } from "@earendil-works/pi-tui";
|
|
21
21
|
import { Type } from "typebox";
|
|
@@ -761,7 +761,12 @@ const askUserTool: ToolDefinition<typeof AskParamsSchema, AskUserDetails> = {
|
|
|
761
761
|
"Ask the user one or more clarifying questions with selectable options. " +
|
|
762
762
|
"Use when choices have materially different tradeoffs the user must decide. " +
|
|
763
763
|
"The user can always provide free-form input via an automatic 'Other' option.",
|
|
764
|
-
|
|
764
|
+
// pi 0.99: model-only — declared to the model, unreachable from codemode
|
|
765
|
+
// scripts / nested tool execution (ask-the-user is a model-level decision;
|
|
766
|
+
// spec: ask-user-exposure). No outputSchema: model-only tools have no
|
|
767
|
+
// programmatic consumer of structuredContent.
|
|
768
|
+
exposure: "model-only",
|
|
769
|
+
promptSnippet: "Ask the user structured questions with options during execution",
|
|
765
770
|
promptGuidelines: [
|
|
766
771
|
"Use ask_user only after exhausting repo conventions, configs, and docs; reserve it for decisions whose options have materially different tradeoffs.",
|
|
767
772
|
],
|
|
@@ -968,7 +973,10 @@ async function runAskDemo(ctx: ExtensionCommandContext): Promise<void> {
|
|
|
968
973
|
const run = async (label: string, params: AskParams): Promise<string> => {
|
|
969
974
|
ctx.ui.notify(`ask-demo ${label} — follow the dialog instructions`, "info");
|
|
970
975
|
try {
|
|
971
|
-
|
|
976
|
+
// pi 0.99 split tool and command contexts into sibling branches; the demo
|
|
977
|
+
// only exercises ExtensionContext members (ui/abort), so the cast is safe.
|
|
978
|
+
const toolCtx = ctx as unknown as ExtensionToolContext;
|
|
979
|
+
const result = await askUserTool.execute(`demo-${label}`, params, undefined, undefined, toolCtx);
|
|
972
980
|
const text = result.content[0]?.type === "text" ? result.content[0].text : "";
|
|
973
981
|
ctx.ui.notify(`ask-demo ${label} → ${text.split("\n").filter(Boolean).join(" | ").slice(0, 200)}`, "info");
|
|
974
982
|
return text;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fyeeme/pi-ask-user-lite",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.4",
|
|
4
4
|
"description": "Structured ask_user tool for pi — lets the LLM surface clarifying questions with options, multi-select, recommended defaults, and free-form Other input.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -43,13 +43,13 @@
|
|
|
43
43
|
"typecheck": "tsc"
|
|
44
44
|
},
|
|
45
45
|
"peerDependencies": {
|
|
46
|
-
"@earendil-works/pi-coding-agent": ">=0.
|
|
47
|
-
"@earendil-works/pi-tui": ">=0.
|
|
46
|
+
"@earendil-works/pi-coding-agent": ">=0.99.0",
|
|
47
|
+
"@earendil-works/pi-tui": ">=0.99.0",
|
|
48
48
|
"typebox": ">=1.0.0"
|
|
49
49
|
},
|
|
50
50
|
"devDependencies": {
|
|
51
|
-
"@earendil-works/pi-coding-agent": "0.
|
|
52
|
-
"@earendil-works/pi-tui": "0.
|
|
51
|
+
"@earendil-works/pi-coding-agent": "1.0.0",
|
|
52
|
+
"@earendil-works/pi-tui": "1.0.0",
|
|
53
53
|
"@types/node": "22.19.19",
|
|
54
54
|
"typebox": "1.1.38",
|
|
55
55
|
"typescript": "5.9.3",
|