Some models (Opus 4.6, GLM-5.1) send the edits parameter as a JSON
string instead of a parsed array. This fails AJV validation with
'must be array' and models fall back to sed/python.
Parse stringified edits in prepareEditArguments before validation.
* feat(agent,coding-agent): add per-tool executionMode field to AgentTool and ToolDefinition
Add optional executionMode?: ToolExecutionMode to AgentTool and
ToolDefinition interfaces. Propagate through wrapToolDefinition and
createToolDefinitionFromAgentTool. No behavioral change yet — agent
loop will read this field in a follow-up.
* feat(agent): support per-tool executionMode override for sequential execution
When a tool defines executionMode='sequential', the agent loop
forces sequential execution of all tool calls in that batch,
even if the global config is parallel.
* feat(coding-agent): re-export ToolExecutionMode from @mariozechner/pi-agent-core
Makes the type available to extensions that want to set
executionMode on tool definitions.
* feat(coding-agent): add tic-tac-toe extension example with executionMode: sequential
Demonstrates per-tool executionMode: the agent plays via move/play
tool calls that share a cursor. Without sequential execution, play
can resolve before earlier moves finish, landing on the wrong cell.
The find tool previously collected every .gitignore under the search
path and passed them to fd via --ignore-file. fd treats --ignore-file
entries as a single global ignore source, so rules from a/.gitignore
also filtered files under sibling b/.
Drop the manual collection and pass --no-require-git instead, which
makes fd apply hierarchical .gitignore semantics whether or not a git
repo is present.
closes#3303
* feat(coding-agent,tui): support argument-hint frontmatter in prompt templates
Parse argument-hint from prompt template frontmatter and display it
in the autocomplete dropdown description, matching Claude Code's
convention for custom commands.
Frontmatter format:
---
description: Code review
argument-hint: "[file | #PR | PR-URL]"
---
The hint renders in the description column of the autocomplete list:
review [file | #PR | PR-URL] — Code review
Closes#2761
* docs(coding-agent,tui): add argument-hint documentation, tests, and built-in hints
- Document argument-hint frontmatter in prompt-templates.md with <required>/[optional] convention
- Add argument-hint to built-in prompts: pr, is, wr
- Expand tests: required/optional hints, missing hints, empty hints, special characters
- Add changelog entries for coding-agent and tui
fd --glob matches against the basename unless --full-path is set, so
patterns containing '/' (e.g. 'src/**/*.spec.ts') silently returned no
results. When the pattern contains '/', switch fd into --full-path mode
and prepend '**/' unless the pattern already starts with '/', '**/', or
is '**'. Basename patterns keep the default matcher.
closes#3302
* fix(coding-agent): surface models.json load errors on stderr in --list-models
When models.json has validation errors, --list-models silently
discarded custom models and overrides without any user-visible
feedback. Now prints the error to stderr via chalk.yellow warning
before listing available models.
* fix(coding-agent): allow custom models for built-in providers in models.json
Built-in providers (openrouter, anthropic, etc.) already have api and
baseUrl on every model, and auth comes from env vars / auth storage.
Relax validation so custom models under built-in providers don't need
redundant baseUrl, apiKey, or api fields. Inherit them from the first
built-in model for that provider.
fixes#2921
---------
Co-authored-by: Mario Zechner <badlogicgames@gmail.com>
Previously, getLatestNpmVersion() hardcoded a fetch to
registry.npmjs.org, which 404s for packages on alternate
registries (private, Verdaccio, GitHub Packages, etc.).
The error was silently swallowed, so users never saw update
notifications for these packages.
Replace the direct fetch with
via the existing runCommandCapture helper. This uses the same
registry resolution as npm install (reads .npmrc config chain),
respects the npmCommand setting, and runs with this.cwd for
correct .npmrc lookup.