Add Atomic Chat as a first-class local provider.#10555
Merged
johnnyeric merged 19 commits intoJun 4, 2026
Merged
Conversation
Contributor
Code Review SummaryStatus: 1 Issue Found | Recommendation: Address before merge Overview
Issue Details (click to expand)SUGGESTION
Resolved since last review
Files Reviewed (incremental — 1 file)
Fix these issues in Kilo Cloud Reviewed by claude-4.6-sonnet-20260217 · 292,328 tokens Review guidance: REVIEW.md from base branch |
chrarnoldus
reviewed
May 26, 2026
chrarnoldus
reviewed
Jun 1, 2026
169fcf6 to
3858240
Compare
lambertjosh
reviewed
Jun 3, 2026
lambertjosh
reviewed
Jun 3, 2026
f18a700 to
1844b8b
Compare
| try { | ||
| const { ok } = await fetchModelsEndpoint(baseURL) | ||
| return ok | ||
| } catch { |
Contributor
There was a problem hiding this comment.
WARNING: Empty catch block silently swallows errors — violates style guide
The style guide requires that catch blocks never be empty. At minimum, bind the error and log it so failures are visible:
} catch (err) {
// network/timeout error — treat as unhealthy
return false
}Same applies to the analogous blocks in discoverAtomicChatModels (line 61) and autoDetectAtomicChat (line 82).
2fcc7fe to
4d79233
Compare
Ship the atomic-chat plugin with auto-discovery on localhost:1337, register the provider in models.dev fixtures, and document setup for VS Code and CLI. Co-authored-by: Cursor <cursoragent@cursor.com>
Removed atomicChat provider mapping from legacy migration.
Replace the embedded raster icon with a currentColor SVG symbol so it matches provider icon styling and inherits UI color consistently. Co-authored-by: Cursor <cursoragent@cursor.com>
Load the atomic-chat plugin despite named constant exports, register local-server auth in the plugin, and let CLI and VS Code connect with an empty key on localhost. Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: kilo-code-bot[bot] <240665456+kilo-code-bot[bot]@users.noreply.github.com>
Drop the modelID check (never equals provider key) and the duplicate providerID branch. Co-authored-by: Cursor <cursoragent@cursor.com>
Restore atomic-chat in default-plugins after main merge, add missing sidebar locale keys, and annotate shared upstream diffs. Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Reorder local-models providers per maintainer feedback; use inline kilocode_change markers in dialog-provider. Share ModelStatusCache, fix config discovery abort/timeout, throw on fetch failure, and resolve bot review warnings. Co-authored-by: Cursor <cursoragent@cursor.com>
Restore useBindings instead of useKeyboard so shared-file diff stays minimal and passes annotation checks. Co-authored-by: Cursor <cursoragent@cursor.com>
…erConnectDialog.tsx Co-authored-by: kilo-code-bot[bot] <240665456+kilo-code-bot[bot]@users.noreply.github.com>
Use a single shared models endpoint request in enhanceConfig instead of separate health and discovery calls. Co-authored-by: Cursor <cursoragent@cursor.com>
Export ATOMIC_CHAT_PROVIDER_KEY from local-providers for the webview, log cache warm failures, and throw on network errors in fetchModelsEndpoint. Co-authored-by: Cursor <cursoragent@cursor.com>
Reuse auto-detect model list to avoid duplicate /v1/models calls, wire AbortSignal into fetch, replace silent catches with logging, and only surface validation errors in chat.params. Co-authored-by: Cursor <cursoragent@cursor.com>
Bypass the 15s model list cache after the first failed attempt so retryWithBackoff can observe newly loaded models. Co-authored-by: Cursor <cursoragent@cursor.com>
31eef5f to
bc29b1e
Compare
Co-authored-by: kilo-code-bot[bot] <240665456+kilo-code-bot[bot]@users.noreply.github.com>
Restore return statement and map "not loaded" validation errors to not_found after bot commit broke the if block. Co-authored-by: Cursor <cursoragent@cursor.com>
johnnyeric
approved these changes
Jun 4, 2026
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.
Summary
Ship the Atomic Chat plugin with auto-discovery on
localhost:1337, register the provider in models.dev fixtures, and document setup for VS Code and CLI.Context
Atomic Chat runs local models and exposes an OpenAI-compatible API at
http://127.0.0.1:1337/v1(alternate port 1338). Kilo Code already supports local backends like LM Studio via@ai-sdk/openai-compatible, but users had to configurebaseURLand model IDs manually, and Atomic Chat did not appear as a first-class provider with discovery or loaded-model checks.This PR adds Atomic Chat as a built-in local provider: default plugin, catalog entry, documentation, icon, and VS Code migration mapping—so users can pick Atomic Chat in the UI and get models populated automatically when the app is running.
Implementation
@kilocode/plugin-atomic-chat(new package)provider.atomic-chat.options.baseURLis unset or still the default origin (http://127.0.0.1:1337), probe ports 1337 and 1338 with a health check, then callGET /v1/models.provider.atomic-chat, setoptions.baseURL, and show success/error toasts.chat.paramshook: Validate the selected model is loaded (with cache/retry) before sending a request; surface a clear error if not.Default plugin registration
atomic-chat-feature.ts— resolve and dedupe@kilocode/plugin-atomic-chat.KilocodeDefaultPlugins— append the plugin alongside the indexing plugin (same builtin-origin pattern).Catalog, UI, migration
atomic-chattopackages/opencode/test/tool/fixtures/models-api.json(@ai-sdk/openai-compatible, envATOMIC_CHAT_API_KEY, default APIhttp://127.0.0.1:1337/v1).atomicChat→atomic-chat.pages/ai-providers/atomic-chat.md, nav, and local-models page (Atomic Chat listed first under self-hosted).Notes for reviewers
models-snapshot.jsremains gitignored; the fixture is the source of truth for tests (regenerate locally viapackages/opencode/script/generate.tsif needed).atomic-chaton models.dev for live catalog fetches outside the bundled snapshot path.How to Test
Prerequisites
Automated
Manual — VS Code
-Build/run this branch of the Kilo Code extension.
-Open Settings → Providers → Atomic Chat.
-Confirm models appear (from discovery) and chat works with a loaded model id from /v1/models.
-Stop or unload the model in Atomic Chat and retry chat — expect a validation error or toast.
Manual — CLI
In
~/.config/kilo/kilo.jsonc(or./kilo.jsonc):Run the Kilo CLI; confirm the default plugin discovers the server without manually adding
@kilocode/plugin-atomic-chat.Edge cases
Custom baseURL (non-default host/port): auto-probe should not override user config.
Atomic Chat on port 1338: should be detected when 1337 is down.