* perf(vscode): stop O(N) reactive cascade on every streaming token
The webview DataBridge wrapped the whole session Data shape in a
`createMemo`, whose body walked `store.parts[msg.id]` for every message
in the session family. Any single part mutation — i.e. every token
delta — invalidated the memo, produced a fresh POJO, and invalidated
every downstream consumer (including O(N) scans inside each mounted
SessionTurn). On a 200-message session a Chrome CPU profile showed
three back-to-back 440ms main-thread blocks per SSE batch, ~46% of
the time in Solid reactive runtime alone.
Expose `data` as a plain object with reactive getters over
`session.allMessages`/`allParts`/`allStatusMap` so consumers reading
`data.store.part[Y]` subscribe to only that key. Removes the now-unused
`familyData` helper and its interface/mock entries.
* perf(ui): drop TextShimmer JS timer — CSS-only animation
A createEffect inside TextShimmer ran clearTimeout + setTimeout on every
`active` prop change to gate the sweep animation via a `data-run`
attribute. During LLM token streaming in long sessions, `active` props
(bound to `pending()` / `running()` accessors) thrashed as tools
started/finished across many shimmer instances. CPU profile of a 7s
streaming window showed ~2,500 timer operations — 16% of the blocked
main-thread time.
Remove the effect and drive the animation purely from the `data-active`
attribute. The opacity transition on the shimmer char (220ms) already
handles the fade, so visual behavior is unchanged. Adds one static
regression guard and one runtime perf assertion (with happy-dom) that
toggling the prop 1000 times results in zero timer calls.
* perf(kilo-ui): skip layout reads in GrowBox watch-mode ResizeObserver
The GrowBox component wraps each assistant part and, when watch=true
(which is set on the currently-streaming text part), runs a
ResizeObserver that called body.getBoundingClientRect() via
targetHeight() on every body-size change. During streaming this fires
at ~60Hz and each call forces a synchronous layout. CPU profile of a
7s streaming window showed 1,362 gBCR samples (~9% of blocked
main-thread time) all attributable to this path.
Reuse the browser's pre-measured contentBoxSize / contentRect from the
observer entries — no extra layout read. Also skip sub-pixel updates
(<2px) that the spring absorbs imperceptibly anyway, cutting per-token
spring work when tokens add tiny height deltas.
* perf(ui): coalesce markdown parse to one per animation frame
During LLM token streaming, the Markdown render effect ran
temp.innerHTML = content + morphdom on every content update. SSE
tokens arrive at 60–200Hz and each delta reparsed the entire
accumulated HTML. CPU profile of a 7s streaming window showed 2,940
ParseHTML events totaling ~619ms (~46% of blocked main-thread time).
Queue the latest content in a component-scoped pending variable and
run the morphdom pass inside requestAnimationFrame. K rapid updates
before the frame fires now collapse to one parse. The onCleanup
handler cancels any queued frame so it doesn't touch an unmounted
DOM. Fast-path is preserved untouched so non-streaming first paint
stays synchronous.
* chore(changeset): consolidate streaming-perf changesets into one
Per-commit changesets produced four nearly-identical release-note
entries. The user-visible change is a single perceptual improvement —
streaming is smooth in long sessions — so roll them up into one
feature-oriented entry.
* test(vscode): consolidate streaming perf tests + wire into CI
Replace three synthetic reactivity tests with a single end-to-end
streaming perf benchmark that:
- Renders the real TextShimmer component and asserts zero setTimeout/
clearTimeout calls during a 100-toggle burst (TextShimmer fix).
- Asserts per-key Solid reactivity: 100 text deltas on one message
must re-run only that message's consumer, not O(N) consumers
(DataBridge cascade fix).
- Uses only count-based assertions against deterministic APIs
(setTimeout/clearTimeout/innerHTML setter) — no wall-clock
thresholds, so it doesn't flake under CI load.
Also wire `bun run test:webview-reactivity` into the test-vscode
workflow so the benchmark runs on every PR that touches
packages/kilo-vscode, packages/ui, or packages/kilo-ui. Without this
wiring the perf regression guard would have shipped dormant.
* test(vscode): declare @happy-dom/global-registrator as devDep
The streaming-perf benchmark imports @happy-dom/global-registrator to
get a DOM for mounting the real TextShimmer component. It resolved
locally through workspace hoisting but CI's clean install didn't have
it. Make the dependency explicit.
* test(vscode): import TextShimmer via package export so JSX resolves
Using the deep relative path (../../../ui/src/components/text-shimmer)
made Bun's test transpiler apply kilo-vscode's tsconfig — which has no
`jsxImportSource` — so the .tsx file was compiled with the default
React runtime, producing "React is not defined" in CI.
Resolving through the package export (@opencode-ai/ui/text-shimmer)
picks up packages/ui/tsconfig.json which sets
`jsxImportSource: solid-js`. Works consistently across Linux/macOS/
Windows CI without needing bunfig-level JSX overrides.
* test(vscode): address bot review — add runtime coverage for Markdown + GrowBox, drop empty smoke test
Two kilo-code-bot findings on the streaming perf bench:
1. The 'benchmark completes quickly' smoke test timed an empty block,
so `elapsed` was always near zero and the assertion never fired.
Drop it — the real benchmarks below already complete in ~90ms.
2. The original file installed spy counters for innerHTML writes and
getBoundingClientRect but never asserted against them, leaving
Markdown rAF coalescing and GrowBox layout-read regressions silently
uncaught.
Add two runtime mirrors:
- Markdown rAF pattern: 100 async content updates coalesce to <20 parses
(would be exactly 100 pre-fix).
- GrowBox ResizeObserver pattern: 100 synthetic resize callbacks using
contentBoxSize/contentRect trigger zero getBoundingClientRect calls
(would be exactly 100 pre-fix).
Source-level regression guards in tests/unit/markdown-raf-coalesce.test.ts
and tests/unit/growbox-no-layout-thrash.test.ts cover the actual
component code. The runtime tests here prove the patterns the guards
require actually deliver the perf property at runtime.
Benchmark runs in ~90ms, 5 consecutive local runs all green.
* test(vscode): drop unstable TextShimmer runtime mount from streaming perf bench
The benchmark tried to mount the real @opencode-ai/ui TextShimmer to
assert zero setTimeout/clearTimeout calls. That required Bun's test
runner to transpile text-shimmer.tsx with Solid's JSX runtime, which
depends on tsconfig resolution walking up to packages/ui/tsconfig.json.
In CI (fresh workspace, different node_modules layout) this resolution
was unstable and kept falling back to React JSX ("React is not
defined").
Keep the three runtime patterns that don't need JSX transpilation
(DataBridge cascade, Markdown rAF coalescing, GrowBox contentRect),
plus the source-level regression guard at
tests/unit/textshimmer-no-timer.test.ts which asserts text-shimmer.tsx
contains no setTimeout/clearTimeout/createEffect/data-run. Together
these cover all four fixes without CI flakiness.
5 consecutive local runs pass in ~80ms.
* test(vscode): remove streaming perf tests
Static source-parsing guards and pattern-mirror runtime tests didn't
actually exercise the fixed component code — a regression in the real
code could have left them green. Remove them along with the
test:webview-reactivity script, the workflow step, the
@happy-dom/global-registrator devDep, and the tests/webview-reactivity
directory. The four perf fixes stand on their own; adding dubious
guards was worse than adding none.
* test(vscode): restore static perf-regression guards wired to real source
Restore four guards that each parse the actual fixed component source
and fail loudly if the fix pattern is removed:
- databridge-shape.test.ts reads webview-ui/src/App.tsx, asserts
`data` is not wrapped in createMemo
- textshimmer-no-timer.test.ts reads ui/src/components/text-shimmer.tsx
+ .css, asserts no setTimeout/
clearTimeout/createEffect, animation
gated on data-active
- markdown-raf-coalesce.test.ts reads ui/src/components/markdown.tsx,
asserts the render createEffect uses
requestAnimationFrame + cancelAnimationFrame
- growbox-no-layout-thrash.test.ts reads kilo-ui/src/components/grow-box.tsx,
asserts the ResizeObserver callback
does not call gBCR, uses contentRect/
contentBoxSize, and has the sub-pixel
delta guard
Verified by mutation: each guard fails when its fix pattern is removed
from the real source file and passes again once restored. Runs as part
of the existing test:unit script (no extra CI wiring).
🚀 Kilo
Kilo is the all-in-one agentic engineering platform. Build, ship, and iterate faster with the most popular open source coding agent.
- ✨ Generate code from natural language
- ✅ Checks its own work
- 🧪 Run terminal commands
- 🌐 Automate the browser
- ⚡ Inline autocomplete suggestions
- 🤖 Latest AI models
- 🎁 API keys optional
Quick Links
- VS Code Marketplace (download)
- Install CLI:
npm install -g @kilocode/cli - Official Kilo.ai Home page (learn more)
Key Features
- Code Generation: Kilo can generate code using natural language.
- Inline Autocomplete: Get intelligent code completions as you type, powered by AI.
- Task Automation: Kilo can automate repetitive coding tasks to save time.
- Automated Refactoring: Kilo can refactor and improve existing code efficiently.
- MCP Server Marketplace: Kilo can easily find, and use MCP servers to extend the agent capabilities.
- Multi Mode: Plan with Architect, Code with Coder, and Debug with Debugger, and make your own custom modes.
Get Started in Visual Studio Code
- Install the Kilo Code extension from the VS Code Marketplace.
- Create your account to access 500+ cutting-edge AI models including Gemini 3.1 Pro, Claude 4.6 Sonnet & Opus, and GPT-5.4 – with transparent pricing that matches provider rates exactly.
- Start coding with AI that adapts to your workflow. Watch our quick-start guide to see Kilo in action:
Get Started with the CLI
# npm
npm install -g @kilocode/cli
# Or run directly with npx
npx @kilocode/cli
Then run kilo in any project directory to start.
npm Install Note: Hidden .kilo File
On some systems and npm versions, installing @kilocode/cli can create a hidden .kilo file near the installed kilo command (for example in a global npm bin directory). This file is an npm-generated launcher helper, not project data.
- Why it exists: npm may create helper artifacts while wiring CLI executables.
- Size caveat: size can vary by platform, npm version, and install mode (symlink vs copied launcher), so a strict fixed size is not guaranteed.
- Safety: it is safe to leave in place. Do not edit it manually. Use your package manager's uninstall (
npm uninstall -g @kilocode/cli) to remove install artifacts cleanly.
Install from GitHub Releases (Optional)
Download the latest binary or source code from the Releases page, use this quick guide:
kilo-<os>-<arch>.zipis the CLI binary for your OS and CPU architecture on Windows and macOS. (kilo-linux-<arch>.tar.gzfor Linux)darwinmeans macOS.x64is standard 64-bit Intel/AMD CPUs.x64-baselineis a compatibility build for older x64 CPUs(do not support AVX Instruction).arm64is ARM-based Linux/MacOS.muslis statically linked Linux build for Alpine/minimal Docker without glibc. Alpine/minimal Docker users should prefer the matching *-musl asset.kilo-vscode-*.vsixis the VS Code extension package and not the CLI binary.Source codereleases are for building from source, not normal installation.
For most users:
- Windows (most PCs):
kilo-windows-x64.zip - macOS Apple Silicon:
kilo-darwin-arm64.zip - macOS Intel:
kilo-darwin-x64.zip - Linux x64:
kilo-linux-x64.tar.gz - Linux on ARM:
kilo-linux-arm64.tar.gz
Autonomous Mode (CI/CD)
Use the --auto flag with kilo run to enable fully autonomous operation without user interaction. This is ideal for CI/CD pipelines and automated workflows:
kilo run --auto "run tests and fix any failures"
Important: The --auto flag disables all permission prompts and allows the agent to execute any action without confirmation. Only use this in trusted environments like CI/CD pipelines.
Contributing
We welcome contributions from developers, writers, and enthusiasts! To get started, please read our Contributing Guide. It includes details on setting up your environment, coding standards, types of contribution and how to submit pull requests.
See RELEASING.md for the release process.
Code of Conduct
Our community is built on respect, inclusivity, and collaboration. Please review our Code of Conduct to understand the expectations for all contributors and community members.
License
This project is licensed under the MIT License. You’re free to use, modify, and distribute this code, including for commercial purposes as long as you include proper attribution and license notices. See License.
Where did Kilo CLI come from?
Kilo CLI is a fork of OpenCode, enhanced to work within the Kilo agentic engineering platform.
