Commit graph

21292 commits

Author SHA1 Message Date
Nate Sesti
d47cbfb436
Merge pull request #10953 from continuedev/wt-6
Add smoke tests for real API connectivity
2026-03-01 12:32:31 -08:00
Nate
310ad57b9c fix: set utf8 encoding on child process streams
Use setEncoding("utf8") on stdout/stderr streams instead of
per-chunk Buffer.toString() to avoid breaking multi-byte characters
at chunk boundaries.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-01 11:12:22 -08:00
Nate
4a0bc1e624 fix: eslint import order and continue-proxy model name format
Move execa type import before vitest to satisfy eslint import/order.
Require SMOKE_PROXY_MODEL env var for continue-proxy test since the
proxy needs a 4-part model name (owner/package/provider/model) that
depends on org-specific configuration.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-01 11:00:45 -08:00
Nate
82672294bf fix: format smoke-api files with prettier
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-01 10:42:28 -08:00
Nate
25fe40a546 Add smoke tests for real API connectivity
Add a new smoke-api test suite that proves the CLI can complete real LLM
round-trips against the Anthropic API. Tests cover headless mode,
serve mode, and all-tools execution. Runs sequentially to avoid rate
limits, skips gracefully when API keys are missing (fork PRs), and
is wired into CI as a required check with allowed-skips.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-01 10:30:41 -08:00
Nate Sesti
533fb83c3c
Merge pull request #10951 from continuedev/nate/fix-ci01
Fix stable release npm publish with OIDC trusted publishing
2026-03-01 09:42:30 -08:00
Nate
9fe15eeea8 Fix stable release npm publish by enabling OIDC trusted publishing
Add --provenance flag to npm publish so it uses the GitHub OIDC token
exchange instead of the expired NODE_AUTH_TOKEN for authentication.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-01 09:40:51 -08:00
Nate Sesti
de12be19ce
Merge pull request #10874 from uinstinct/back-job-perm
feat: allow background job perm check by default
2026-03-01 09:31:12 -08:00
Nate Sesti
4c0f3b66ca
Merge branch 'main' into back-job-perm 2026-03-01 09:31:04 -08:00
Nate Sesti
b70d69ff83
Merge pull request #10845 from uinstinct/cli-quiz
feat(cli): quiz answers
2026-03-01 09:30:25 -08:00
Nate Sesti
5ab2368f37
Merge pull request #10784 from uinstinct/more-prov-1
feat: ai-sdk support for xai and deepseek
2026-03-01 09:28:01 -08:00
Nate Sesti
2dba04fe32
Merge pull request #10775 from uinstinct/env-var-ai-sdk
feat: use env variable to enable ai sdk
2026-03-01 09:27:08 -08:00
Nate Sesti
60646e5dd5
Merge pull request #10950 from continuedev/sestinj-patch-1
Remove NODE_AUTH_TOKEN from stable-release workflow
2026-03-01 09:18:12 -08:00
Nate Sesti
966ffe9883
Remove NODE_AUTH_TOKEN from stable-release workflow
Removed NODE_AUTH_TOKEN environment variable from various steps in the stable release workflow.
2026-03-01 09:17:53 -08:00
Nate Sesti
64d58c4d98
Merge pull request #10801 from continuedev/nate/prompt-caching
feat: add turn-level prompt caching + PostHog metrics + live API tests
2026-02-28 21:18:36 -08:00
uinstinct
9ae00f592b move QuizService to services folder 2026-02-27 09:41:47 +05:30
uinstinct
6187143567 feat: allow background job perm check by default 2026-02-27 09:24:29 +05:30
uinstinct
cd41f57491 fix installation package 2026-02-27 08:48:42 +05:30
uinstinct
3eab50f3d1 feat: use env variable to enable ai sdk 2026-02-26 12:30:23 +05:30
uinstinct
7fd21370ed add support for deepseek 2026-02-26 12:29:50 +05:30
uinstinct
6b693337c9 add support for xai provider 2026-02-26 12:29:50 +05:30
uinstinct
35725099c1 remove allowCustomAnswer
- also refine the prompt
2026-02-26 12:16:10 +05:30
uinstinct
bd5a4cad9d refine prompt 2026-02-26 12:04:00 +05:30
uinstinct
dd9177fe76 add quiz prompt component 2026-02-26 11:52:40 +05:30
uinstinct
6d082f2ff7 add quiz service 2026-02-26 11:50:47 +05:30
uinstinct
fe4ec8ebcd rename to askquestion and set permission to allow 2026-02-26 11:40:27 +05:30
uinstinct
489aa49663 add quiz tool 2026-02-26 11:40:05 +05:30
Nate Sesti
9b88c27373
Merge pull request #10674 from continuedev/gemini-429
fix: detect embedded 429 errors from Gemini/VertexAI APIs
2026-02-25 20:36:17 -08:00
Nate Sesti
97ff73e7bf
Merge pull request #10642 from uinstinct/ai-sdk-upgrade-2
chore: upgrade ai sdk to v6
2026-02-25 20:35:30 -08:00
Nate
a754a33527 fix: spread configDefaults.exclude in vitest config
Preserve Vitest's default excludes (dist, node_modules, etc.) when
adding the live test exclusion pattern.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-24 18:40:56 -08:00
Nate
d526941f9e fix: exclude live API tests from CI test runs
Live test files (*.live.test.ts) make real Anthropic API calls and are
intended for manual validation only. Exclude them from the default
vitest configuration to prevent flaky CI failures.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-24 18:26:55 -08:00
Nate
b690c89ba2 fix: address review feedback - clone messages, void async, fix test loop
- Clone message content blocks before mutating for cache_control
  (prevents mutation of original input body)
- Add `void` prefix to async posthogService.capture call
- Fix duplicate assistant messages in Scenario 3 test loop
- Add unit test verifying original body is not mutated

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-24 18:18:40 -08:00
Nate
697260712b fix: update anthropic adapter tests to expect cache_control on user messages
The systemAndTools caching strategy now adds cache_control to the last
two user messages via addCacheControlToLastTwoUserMessages(). Update
existing test expectations to include the cache_control field.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-24 18:08:13 -08:00
Nate
a7dcf8bd84 fix: add 'as any' casts for cache_read_tokens on PromptTokensDetails
The OpenAI PromptTokensDetails type doesn't include cache_read_tokens
(it's an Anthropic extension). Add 'as any' casts to fix TypeScript
build errors in the battle test file.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-24 17:55:05 -08:00
Nate
2a1b945f2c test: add battle test suite for Anthropic prompt caching scenarios
7 distinct scenarios covering tool use round-trips, parallel tool calls,
long 8-turn conversations, large tool results (~200 lines), cache
invalidation on system message changes, identical request replays, and
multi-step agentic workflows with chained tool calls.

All scenarios validate cache hit rates >90% where expected and proper
cache misses when the system message changes.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-24 17:37:59 -08:00
Nate
30406a0cda feat: add turn-level caching to systemAndTools strategy + PostHog cache metrics + live API test
- Add addCacheControlToLastTwoUserMessages call in systemAndToolsStrategy
  so the CLI path caches conversation turns (matching VS Code extension behavior)
- Report prompt_cache_metrics to PostHog with cache_read/write tokens and hit rate
- Add live API integration test validating cache writes on turn 1 and 99%+ hit
  rates on subsequent turns (guarded by ANTHROPIC_API_KEY env var)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-24 17:28:06 -08:00
uinstinct
ffe90db710 fix tests 2026-02-24 15:04:50 +05:30
uinstinct
07c3750a53 upgrade vercel tool format to v6 2026-02-24 14:32:48 +05:30
uinstinct
3c140514d4 aisdk llmapi function name changes 2026-02-24 14:32:48 +05:30
uinstinct
718f48fae4 install ai sdk v6 and corresponding deps 2026-02-24 14:32:48 +05:30
Nate Sesti
98c99d3a63
Merge pull request #10622 from uinstinct/ai-sdk-standalone
chore: remove feature flagged ai sdk usage
2026-02-23 20:10:38 -08:00
Nate Sesti
5695cc879c
Merge pull request #10734 from continuedev/nate/blueprint-suggestions-cli
feat: pre-install suggestions CLI in devbox blueprints
2026-02-22 21:00:20 -08:00
Nate
55b256cd14 feat: pre-install suggestions CLI in devbox blueprints
Download the suggestions CLI binary from GitHub Releases during
blueprint build so it's available at /usr/local/bin/suggestions
without runtime downloads.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 20:08:13 -08:00
Dallin Romney
a2c1fe6897
feat: model updates and + z.ai (#10638)
* Add latest model definitions across providers

Add new models for OpenAI (gpt-4.1, gpt-5.2, codex-mini, o1/o3/o4-mini),
Gemini (2.5 stable, 2.5-flash-lite, 3-flash-preview), Mistral (devstral,
magistral, ministral, mistral-nemo), xAI (grok-4-fast, grok-4-1-fast,
grok-3-fast), and Bedrock (Claude 4.5/4.6, Nova, Llama 4, DeepSeek).

Update tool support and reasoning detection for the new model families.

* Add Z.ai (GLM) provider, Kimi K2/K2.5 models, and fix OpenRouter tool support bug

- Add Z.ai as a new provider with GLM-5, GLM-4.7, GLM-4-plus, GLM-4.5 models
- Add Kimi K2 and K2.5 model packages to Moonshot provider
- Fix variable shadowing bug in OpenRouter tool support where loop
  variables shadowed the outer model parameter, causing specificModels
  and supportedContains checks to always return true
- Add moonshotai/kimi and zai-org/glm to OpenRouter supported prefixes
- Add Z.ai and Moonshot to docs navigation

* Clean up unnecessary import aliases for zAI

* Add Z.ai Coding Plan endpoint note to docs

* Replace placeholder zai.png icon with proper zAI.svg

* Add zAI provider to openai-adapters

* Fix Z.ai API key URL
2026-02-20 00:35:44 -08:00
Dallin Romney
9759ad657d fix: detect embedded 429 errors from Gemini/VertexAI APIs
Gemini and VertexAI can return rate-limit errors where the HTTP status
is not 429 but the error code is embedded in the response body JSON
(e.g., "code":429). Add regex-based detection of these embedded errors
in both retry paths so they trigger exponential backoff correctly.
2026-02-20 00:30:46 -08:00
Nate Sesti
785a7760a0
Merge pull request #10665 from continuedev/pe/docs-quickstart-check-route-v2
docs: simplify quickstart to continue.dev/check
2026-02-19 17:33:09 -08:00
Patrick Erichsen
342d1aa96e docs: simplify quickstart to continue.dev/check 2026-02-19 17:08:14 -08:00
Nate Sesti
c1f9518574
Merge pull request #10285 from uinstinct/cli-background-bash-exec
feat: bash tool execution in background
2026-02-18 14:20:46 -08:00
Nate
87a0464416 fix: break circular dependency causing test failures
ToolPermissionService imported ALL_BUILT_IN_TOOLS from allBuiltIns.ts,
which imports runTerminalCommand.ts, which imports services/index.ts,
which imports ToolPermissionService.ts - creating a circular dependency.

This caused "ToolPermissionService is not a constructor" errors in tests
because the module wasn't fully initialized when services/index.ts tried
to instantiate it.

Fix: Extract a lightweight builtInToolNames.ts with just the string names
(no heavy imports) and use that in ToolPermissionService instead. Also add
a vitest resolve alias for "src/" paths to match tsconfig baseUrl.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-18 13:11:03 -08:00
Nate
175c95b49d fix: add src path alias to vitest config for module resolution
The tsconfig uses baseUrl: "." which allows imports like "src/..." to
resolve correctly for tsc, but vitest doesn't read tsconfig paths by
default. This adds a resolve.alias to map "src" to the actual source
directory so tests can resolve these imports.

Fixes ToolPermissionService test failures (TypeError: ToolPermissionService
is not a constructor) caused by failed module resolution of "src/..." paths.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-18 13:03:03 -08:00