Route both synthesized failure descriptions through @vscode/l10n with
placeholders for the provider code and diagnostic details, matching the
localized endpoint error pattern in imageLimits.ts. These strings reach the
user as the BYOK failure reason, so a non-English install should not receive
untranslated text. The bracketed identifiers stay verbatim so they remain
greppable and pasteable into a provider support request.
Revert the Agent Host integration test expansion. It exercised parameterless
tool schemas and tool-call continuations, which ruled out two alternative
causes while investigating, but no production tool handling changes here and
that coverage does not validate this fix.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
A provider can end a Responses stream with a terminal event whose error
object omits the code and message the API contract requires. Serializing
that object produced {"code":0,"message":"","metadata":{}}, which the BYOK
endpoint promotes to the entire user-facing reason, so an outage and a
malformed request looked identical and neither users nor maintainers could
tell them apart.
Describe such failures instead, naming the terminal event, response status,
and response id so the failure stays correlatable with the provider, and
omit absent metadata keys so serialization cannot collapse them to an empty
object. Keep the fetcher's original reason when a stream error carries no
message, so a hollow struct never replaces an actionable one.
The mapping predates the reports; the Agent Host BYOK proxy moving from
Chat Completions to Responses in 1.132.0 is what first exposed it in the
Agents Window. This restores diagnosability rather than stopping the
upstream failure, so it does not close the report on its own.
Related to #330408
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Revert to showing all context size options
Removes the `github.copilot.chat.preferLongContext.enabled` setting and
reverts to always showing both the default and long-context options in the
model picker. Also removes the now-dead `freeLongContext` plumbing that the
setting gated.
Reverts:
- https://github.com/microsoft/vscode/pull/322950
- https://github.com/microsoft/vscode/pull/323116
- https://github.com/microsoft/vscode/pull/324650
- https://github.com/microsoft/vscode/pull/328628
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Add context-size picker coverage for both surfaces
Addresses PR review: cover the reverted "always show both context options"
behavior for each independently implemented picker surface.
- languageModelAccess.test.ts: a free/no-surcharge endpoint publishes both
the default and full windows, with the smaller window as the default.
- copilotCliModels.spec.ts: a CLI model with defaultContextMax < maxInputTokens
and no long-context surcharge exposes both sizes, smaller as default.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Default to the longer window for free long-context models
Keeps both context-size options in every picker, but when the long-context
tier has no surcharge (free long context) the default selection — and the
no-selection behavioral fallback — is the full window rather than the smaller
default tier. Models with a long-context surcharge still default to the
smaller tier so users opt into the extra cost.
Applied consistently across all four surfaces:
- Main chat picker: getContextSizeOptions default + applyContextSizeOverride fallback
- Copilot CLI picker: buildConfigurationSchema default + resolveContextTier fallback
- Agent host: _createContextSizeConfigSchemaProperty default + getCopilotContextTier
via the restored freeLongContext flag (and hasLongContextSurcharge helper)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Shorten context-size comments
Condense the free-long-context comments added across the picker surfaces to
concise one-liners; no behavior change.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Preserve the cleared cache state when the last observer removes itself during event notification, and cover re-observation with a regression test.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Forward adaptive and budget-based thinking capabilities from custom model
configuration into endpoint metadata. Preserve the per-request thinking flag
across the extension-contributed language model boundary so Messages requests
can activate the configured mode.
Refs #330712
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
CAPI now returns `max_prompt_tokens` and `cache_read_price` inside
`billing.token_prices.<tier>`, replacing `context_max` and `cache_price`.
`normalizeTokenPrices` only read the old names, so
`tokenPricing.default.contextMax` came back undefined and
`getContextSizeOptions` bailed on its first guard, dropping the Context Size
control from the model picker entirely.
The budget side of that contract kept working, which turned a missing dropdown
into a billing problem: `modelMetadataFetcher` still raises the prompt budget to
the full context window whenever a `long_context` tier is present, on the stated
assumption that `defaultContextMax` holds users at the default tier. With
`contextMax` undefined, requests ran unclamped against the full window and
`applyContextSizeOverride` had nothing to clamp to.
Since this is a server-side rename, older clients are affected too, which is why
rolling back did not help. The agent host normalizer in `agentModelPricing.ts`
already accepts both spellings, which is why the Copilot harness kept the control
while the in-editor path lost it. Accept both here as well: this normalizer is
shared by CAPI `/models`, the `@github/copilot` SDK and the cloud agents
endpoint, which move on independent cadences.
Fixes#330481
Emit an explicit object schema for parameterless function tools so strict
OpenAI-compatible Responses endpoints accept the request.
Fixes#330610
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Revert "Revert new TAS endpoint changes (#330175)"
This reverts commit f30e3f3600.
* Re-land new TAS assignments endpoint with proxy-aware transport + tas-call telemetry
* bump remote + remote/web to tas-client 0.4.3
* Add tests and feedback update
Avoid treating unmatched virtual resources as local filesystem paths when
looking up repository remotes.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Remove the team-only value restriction from the hidden advanced Xtab nLinesAbove and nLinesBelow settings. Extend external-user coverage with the requested 0 and 7 values.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 97f1135d-4a33-4139-ab2c-9cb8045ece70
Propagate Responses summary-part completion markers through the language model thinking stream so transport chunks remain combined without merging distinct semantic summaries.\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Keep transport-level thinking deltas in one reasoning summary entry while preserving explicit multi-part summaries. This prevents Copilot CLI from rendering each DeepSeek reasoning chunk as a separate line.\n\nFixes #329873\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
copilot: fix: allow external users to configure inline edit settings
Remove the team-only value restriction from selected hidden advanced inline edit settings while preserving their keys, defaults, validators, and experiment behavior. Add coverage that verifies an external user can configure all ten settings.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 97f1135d-4a33-4139-ab2c-9cb8045ece70
* Revert "New TAS assignments endpoint updates (lifecycle, readiness, disposal) (#329736)"
This reverts commit c780ea9613.
* Revert "Add new exp TAS assignments endpoint (/api/v1/assignments) alongside legacy TAS (#329653)"
This reverts commit 58dc612992.
* Fix lockfile: add MIT license fields to reverted tas-client entries
* Agent Host changes for osortega/agents/remove-all-the-code-for-backend-v1-of
* Preserve pending cloud tasks until workspace opens
Only consume cross-window task deep links after Git reports the matching repository, preventing the source window from clearing shared pending state.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Migrate cloud session state from pull request URIs
PR-backed cloud tasks are listed under a stable /task/<id> resource and report the /<prNumber> URI they were previously listed under, so archived, pinned and read state migrates forward instead of being orphaned.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
An empty `tool_calls: []` array in a chat-completions SSE delta is truthy, so SSEProcessor entered the tool-call branch and skipped the content path, silently dropping the assistant text. Backends like vLLM attach an empty array to every content delta, which lost the entire response.
Guard the branch on `tool_calls?.length` so empty arrays fall through to normal content handling.
Fixes#329963
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Remove extension-host Claude implementation
Make Agent Host the sole Claude sessions implementation and remove the obsolete provider preference settings, extension runtime, SDK dependency, commands, tests, and integration glue.\n\n(Written by Copilot)\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Remove extension-host Claude smoke tests
Delete smoke cases and commands that target the removed extension-host Claude implementation.\n\n(Written by Copilot)\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Fix Agent Host Claude permissions link
Keep the Claude-specific permission documentation link for Agent Host Claude after removing the extension-host implementation.\n\n(Written by Copilot)\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Restore theme colors in Modern UI shell
Honor contributed title, activity, and status bar colors while preserving the floating-card hierarchy. Use the title bar color for shell gutters, frame activity and content surfaces consistently, and remove the Modern UI title separator.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Update how modern UI applies themes
* Address Modern UI shell review feedback
Keep inactive title gutters synchronized, correct activity rail sizing at exposed window edges, and refresh status bar edge styling when Modern UI is toggled.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Add rejected edit memory to PatchBased02
Keep rejected suggestions in a separate bounded compact history and annotate them in PatchBased02 prompts behind a default-off model memory option.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: db1eb24e-67e7-4c60-8dc6-15dd94044638
* simplify
* simplify telemetry
* Apply model config once instead of per-request (too complicated
* Update tests
* simplify
* Clean up prompt creation
* Test history entry ordering when we insert rejection entries
* Make helper function for defining rejection annotation option
* Fix type error
* Make memory declaration match that of lintOptions
* Assign sequence for all additions to xtab edit history and skip entries with no sequence when inserting rejection annotations
* Make sequence required
* Move rejection memory setting to string enum
* Document sequence number
* Clean up postscript implementation
* Document memory mode enum
* Disable rejection annotations for next cursor prediction prompts
* Discard stale undefined check
* Add explanation comment
* ws
* Restore opts.includePostScript
* Add sequence field to test fixtures
* Revese test to match new behavior -- don't output the rejection annotation explanation when postscript is disabled
* Restore outer check postscript
* inlineEdits: refactor: simplify rejected edit memory
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 93b030a9-f47a-461a-92c1-7853ea7693bc
---------
Co-authored-by: Ben Steenhoek <bensteenhoek@github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: ulugbekna <ulugbekna@gmail.com>
Copilot-Session: db1eb24e-67e7-4c60-8dc6-15dd94044638
Copilot-Session: 93b030a9-f47a-461a-92c1-7853ea7693bc