@mariozechner/pi-coding-agent 0.55.2 → 0.55.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 +26 -0
- package/README.md +1 -9
- package/dist/core/agent-session.d.ts +9 -0
- package/dist/core/agent-session.d.ts.map +1 -1
- package/dist/core/agent-session.js +141 -44
- package/dist/core/agent-session.js.map +1 -1
- package/dist/core/export-html/tool-renderer.d.ts.map +1 -1
- package/dist/core/export-html/tool-renderer.js +6 -0
- package/dist/core/export-html/tool-renderer.js.map +1 -1
- package/dist/core/extensions/loader.d.ts.map +1 -1
- package/dist/core/extensions/loader.js +3 -0
- package/dist/core/extensions/loader.js.map +1 -1
- package/dist/core/extensions/runner.d.ts.map +1 -1
- package/dist/core/extensions/runner.js +1 -0
- package/dist/core/extensions/runner.js.map +1 -1
- package/dist/core/extensions/types.d.ts +8 -2
- package/dist/core/extensions/types.d.ts.map +1 -1
- package/dist/core/extensions/types.js.map +1 -1
- package/dist/core/keybindings.d.ts.map +1 -1
- package/dist/core/keybindings.js +1 -1
- package/dist/core/keybindings.js.map +1 -1
- package/dist/core/system-prompt.d.ts +4 -0
- package/dist/core/system-prompt.d.ts.map +1 -1
- package/dist/core/system-prompt.js +34 -12
- package/dist/core/system-prompt.js.map +1 -1
- package/dist/modes/interactive/components/tool-execution.d.ts +2 -0
- package/dist/modes/interactive/components/tool-execution.d.ts.map +1 -1
- package/dist/modes/interactive/components/tool-execution.js +28 -3
- package/dist/modes/interactive/components/tool-execution.js.map +1 -1
- package/dist/modes/interactive/interactive-mode.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-mode.js +0 -1
- package/dist/modes/interactive/interactive-mode.js.map +1 -1
- package/docs/extensions.md +20 -1
- package/examples/extensions/README.md +1 -0
- package/examples/extensions/custom-provider-anthropic/package-lock.json +2 -2
- package/examples/extensions/custom-provider-anthropic/package.json +1 -1
- package/examples/extensions/custom-provider-gitlab-duo/package.json +1 -1
- package/examples/extensions/custom-provider-qwen-cli/package.json +1 -1
- package/examples/extensions/dynamic-tools.ts +74 -0
- package/examples/extensions/with-deps/package-lock.json +2 -2
- package/examples/extensions/with-deps/package.json +1 -1
- package/package.json +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,31 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [0.55.4] - 2026-03-02
|
|
4
|
+
|
|
5
|
+
### New Features
|
|
6
|
+
|
|
7
|
+
- Runtime tool registration now applies immediately in active sessions. Tools registered via `pi.registerTool()` after startup are available to `pi.getAllTools()` and the LLM without `/reload` ([docs/extensions.md](docs/extensions.md), [examples/extensions/dynamic-tools.ts](examples/extensions/dynamic-tools.ts), [#1720](https://github.com/badlogic/pi-mono/issues/1720)).
|
|
8
|
+
- Tool definitions can customize the default system prompt with `promptSnippet` (`Available tools`) and `promptGuidelines` (`Guidelines`) while the tool is active ([docs/extensions.md](docs/extensions.md), [#1720](https://github.com/badlogic/pi-mono/issues/1720)).
|
|
9
|
+
- Custom tool renderers can suppress transcript output without leaving extra spacing or empty transcript footprint in interactive rendering ([docs/extensions.md](docs/extensions.md), [#1719](https://github.com/badlogic/pi-mono/pull/1719)).
|
|
10
|
+
|
|
11
|
+
### Added
|
|
12
|
+
|
|
13
|
+
- Added optional `promptSnippet` to `ToolDefinition` for one-line entries in the default system prompt's `Available tools` section. Active extension tools appear there when registered and active ([#1237](https://github.com/badlogic/pi-mono/pull/1237) by [@semtexzv](https://github.com/semtexzv)).
|
|
14
|
+
- Added optional `promptGuidelines` to `ToolDefinition` so active tools can append tool-specific bullets to the default system prompt `Guidelines` section ([#1720](https://github.com/badlogic/pi-mono/issues/1720)).
|
|
15
|
+
|
|
16
|
+
### Fixed
|
|
17
|
+
|
|
18
|
+
- Fixed `pi.registerTool()` dynamic registration after session initialization. Tools registered in `session_start` and later handlers now refresh immediately, become active, and are visible to the LLM without `/reload` ([#1720](https://github.com/badlogic/pi-mono/issues/1720))
|
|
19
|
+
- Fixed session message persistence ordering by serializing `AgentSession` event processing, preventing `toolResult` entries from being written before their corresponding assistant tool-call messages when extension handlers are asynchronous ([#1717](https://github.com/badlogic/pi-mono/issues/1717))
|
|
20
|
+
- Fixed spacing artifacts when custom tool renderers intentionally suppress per-call transcript output, including extra blank rows in interactive streaming and non-zero transcript footprint for empty custom renders ([#1719](https://github.com/badlogic/pi-mono/pull/1719) by [@alasano](https://github.com/alasano))
|
|
21
|
+
- Fixed `session.prompt()` returning before retry completion by creating the retry promise synchronously at `agent_end` dispatch, which closes a race when earlier queued event handlers are async ([#1726](https://github.com/badlogic/pi-mono/pull/1726) by [@pasky](https://github.com/pasky))
|
|
22
|
+
|
|
23
|
+
## [0.55.3] - 2026-02-27
|
|
24
|
+
|
|
25
|
+
### Fixed
|
|
26
|
+
|
|
27
|
+
- Changed the default image paste keybinding on Windows to `alt+v` to avoid `ctrl+v` conflicts with terminal paste behavior ([#1682](https://github.com/badlogic/pi-mono/pull/1682) by [@mrexodia](https://github.com/mrexodia)).
|
|
28
|
+
|
|
3
29
|
## [0.55.2] - 2026-02-27
|
|
4
30
|
|
|
5
31
|
### New Features
|
package/README.md
CHANGED
|
@@ -1,11 +1,3 @@
|
|
|
1
|
-
# 🏖️ OSS Vacation
|
|
2
|
-
|
|
3
|
-
**Issue tracker and PRs reopen March 2, 2026.**
|
|
4
|
-
|
|
5
|
-
All PRs will be auto-closed until then. Approved contributors can submit PRs after vacation without reapproval. For support, join [Discord](https://discord.com/invite/3cU7Bz4UPx).
|
|
6
|
-
|
|
7
|
-
---
|
|
8
|
-
|
|
9
1
|
<p align="center">
|
|
10
2
|
<a href="https://shittycodingagent.ai">
|
|
11
3
|
<img src="https://shittycodingagent.ai/logo.svg" alt="pi logo" width="128">
|
|
@@ -136,7 +128,7 @@ The editor can be temporarily replaced by other UI, like built-in `/settings` or
|
|
|
136
128
|
| File reference | Type `@` to fuzzy-search project files |
|
|
137
129
|
| Path completion | Tab to complete paths |
|
|
138
130
|
| Multi-line | Shift+Enter (or Ctrl+Enter on Windows Terminal) |
|
|
139
|
-
| Images | Ctrl+V to paste, or drag onto terminal |
|
|
131
|
+
| Images | Ctrl+V to paste (Alt+V on Windows), or drag onto terminal |
|
|
140
132
|
| Bash commands | `!command` runs and sends output to LLM, `!!command` runs without sending |
|
|
141
133
|
|
|
142
134
|
Standard editing keybindings for delete word, undo, etc. See [docs/keybindings.md](docs/keybindings.md).
|
|
@@ -134,6 +134,7 @@ export declare class AgentSession {
|
|
|
134
134
|
private _scopedModels;
|
|
135
135
|
private _unsubscribeAgent?;
|
|
136
136
|
private _eventListeners;
|
|
137
|
+
private _agentEventQueue;
|
|
137
138
|
/** Tracks pending steering messages for UI display. Removed when delivered. */
|
|
138
139
|
private _steeringMessages;
|
|
139
140
|
/** Tracks pending follow-up messages for UI display. Removed when delivered. */
|
|
@@ -165,6 +166,8 @@ export declare class AgentSession {
|
|
|
165
166
|
private _extensionErrorUnsubscriber?;
|
|
166
167
|
private _modelRegistry;
|
|
167
168
|
private _toolRegistry;
|
|
169
|
+
private _toolPromptSnippets;
|
|
170
|
+
private _toolPromptGuidelines;
|
|
168
171
|
private _baseSystemPrompt;
|
|
169
172
|
constructor(config: AgentSessionConfig);
|
|
170
173
|
/** Model registry for API key resolution and model discovery */
|
|
@@ -174,6 +177,9 @@ export declare class AgentSession {
|
|
|
174
177
|
private _lastAssistantMessage;
|
|
175
178
|
/** Internal handler for agent events - shared by subscribe and reconnect */
|
|
176
179
|
private _handleAgentEvent;
|
|
180
|
+
private _createRetryPromiseForAgentEnd;
|
|
181
|
+
private _findLastAssistantInMessages;
|
|
182
|
+
private _processAgentEvent;
|
|
177
183
|
/** Resolve the pending retry promise */
|
|
178
184
|
private _resolveRetry;
|
|
179
185
|
/** Extract text content from a message */
|
|
@@ -257,6 +263,8 @@ export declare class AgentSession {
|
|
|
257
263
|
}>): void;
|
|
258
264
|
/** File-based prompt templates */
|
|
259
265
|
get promptTemplates(): ReadonlyArray<PromptTemplate>;
|
|
266
|
+
private _normalizePromptSnippet;
|
|
267
|
+
private _normalizePromptGuidelines;
|
|
260
268
|
private _rebuildSystemPrompt;
|
|
261
269
|
/**
|
|
262
270
|
* Send a prompt to the agent.
|
|
@@ -435,6 +443,7 @@ export declare class AgentSession {
|
|
|
435
443
|
private getExtensionSourceLabel;
|
|
436
444
|
private _applyExtensionBindings;
|
|
437
445
|
private _bindExtensionCore;
|
|
446
|
+
private _refreshToolRegistry;
|
|
438
447
|
private _buildRuntime;
|
|
439
448
|
reload(): Promise<void>;
|
|
440
449
|
/**
|