tui: follow kai-engine's kai_* tool namespace - #54
Merged
Conversation
Kai review
Risky claims — 1 statement to verify
+20 −20 · 3 files · reaches 39 View finding → · Awaiting your verdict — Kai never approves its own finding. |
kai-engine renamed its four generic tools (bash/view/write/edit) to
kai_bash/kai_view/kai_write/kai_edit. The REPL's tool renderers match
those names as string literals off the event stream, so they go blind
without this — summarizeToolCall would fall through to the bare-name
branch and every file read would render as "→ kai_view" with no path,
every shell call with no command.
Renamed in planner_dispatch.go's summarizer (the view/write/edit and
bash cases, plus the bashLineCount reset that keys off the tool name)
and in the tests that pin their output.
Note the event Kind strings ("bash" for streamed stdout lines) are NOT
tool names and stay as they are.
Requires kai-engine >= the release carrying the rename.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
jschatz1
force-pushed
the
feat/kai-tool-namespace
branch
from
August 30, 2026 04:43
7646434 to
d900399
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Downstream of kaicontext/kai-engine#42, which renames the four generic tools:
Why this repo needs a change at all
The REPL's tool renderers match those names as string literals off the event stream. Without this they go blind:
summarizeToolCallfalls through to the bare-name branch, so every file read renders as→ kai_viewwith no path and every shell call with no command. Nothing errors — the output just quietly gets less useful, which is the worst failure mode for a rename.Changed in
internal/tui/views/planner_dispatch.go:view/write/editandbashcases in the summarizerbashLineCountreset, which keys off the tool nameDeliberately unchanged
The event
Kindstrings ("bash"for streamed stdout lines) are not tool names — they're the activity-feed channel — and stay as they are. Same forexec.Command("bash", ...)and the shell-completionValidArgs.Ordering
Merge after kai-engine#42 ships in a release and this repo's
go.modis bumped to it. Merging earlier is harmless but inert — the renderers would match names the pinned engine doesn't emit yet.🤖 Generated with Claude Code