Это ide на основе vs code(code oss), в ней будет встроенный умный апи роутинг, свой маркет с плагинами(агент харнесс, поддержка java/kotlin/мобильной разработки, командная разработка проектов, orca, оркестратор агентов
/**
* The default value which is used when no other value is defined
*/
?
:
T
;
/**
* The global or installation-wide value.
*/
?
:
T
;
/**
* The workspace-specific value.
*/
?
:
T
;
/**
* The workspace-folder-specific value.
*/
?
:
T
;
/**
* Language specific default value when this configuration value is created for a {@link ConfigurationScope language scope}.
*/
?
:
T
;
/**
* Language specific global value when this configuration value is created for a {@link ConfigurationScope language scope}.
*/
?
:
T
;
/**
* Language specific workspace value when this configuration value is created for a {@link ConfigurationScope language scope}.
*/
?
:
T
;
/**
* Language specific workspace-folder value when this configuration value is created for a {@link ConfigurationScope language scope}.
*/
?
:
T
;
/**
* All language identifiers for which this configuration is defined.
*/
?
:
string
[
]
;
}
export
interface
IConfigurationService
{
readonly
:
undefined
;
/**
* Gets user configuration for a key from vscode (which if not defined, pulls default value from package.json).
* If not defined, returns the default value.
*
* @remark For object values, the user config will replace the default config.
*/
getConfig<T>
(
:
<
T
>
,
?
:
)
:
T
;
/**
* Gets an observable for the configuration of a key from vscode (which if not defined, pulls default value from package.json).
* If not defined, returns the default value.
*
* @remark For object values, the user config will replace the default config.
*/
getConfigObservable<T>
(
:
<
T
>
)
:
<
T
>
;
/**
* Retrieve all information about a configuration setting. A configuration value
* often consists of a *default* value, a global or installation-wide value,
* a workspace-specific value and folder-specific value
* @paramconfigKey The config key to look up
* @returns Information about a configuration setting or `undefined`.
*/
inspectConfig<T>
(
:
<
T
>
,
?
:
)
:
<
T
>
|
undefined
;
/**
* Checks if the key is configured by the user in any of the configuration scopes.
*/
isConfigured<T>
(
:
<
T
>
,
?
:
)
:
boolean
;
/**
* Proxies vscode.workspace.getConfiguration to allow getting a configuration value that is not in the Copilot namespace.
* @paramconfigKey The config key to look up
*/
getNonExtensionConfig<T>
(
:
string
)
:
T
|
undefined
;
/**
* Sets user configuration for a key in vscode.
*/
setConfig<T>
(
:
<
T
>
,
:
T
,
?
:
)
:
<
void
>
;
/**
* Gets user configuration for a key from vscode (which if not defined, pulls default value from package.json).
* If not defined, returns the experimentation based value or falls back to the default value.
*
* @remark For object values, the user config will replace the default config.
*/
/**
* Gets the observable of a user configuration for a key from vscode (which if not defined, pulls default value from package.json).
* If not defined, returns the experimentation based value or falls back to the default value.
*
* @remark For object values, the user config will replace the default config.
*/
/**
* Like {@link getExperimentBasedConfig}, but returns `undefined` when neither the user's settings
* nor an experiment provide a value, instead of falling back to the setting's default.
*
* Use this when some other source supplies a default that must stay overridable by the user and by
* experimentation, so that source can be consulted only when the setting is not explicitly driven.
*
* @remark Only meaningful for settings that are not contributed in `package.json`
* ({@link BaseConfig.isPublic} is `false`). For contributed settings tagged `onExp`, VS Code folds
* the treatment into `inspect().defaultValue`, so an experiment value is indistinguishable from the
* default and this method reports it as unset.
*/
/**
* Emitted whenever a configuration value changes.
* This emits for all changes, not just changes to the Copilot settings.
*/
:
<
>
;
/**
* Called by experimentation service to trigger updates to ExP based configurations
*
* @paramtreatments List of treatments that have been changed
*/
updateExperimentBasedConfiguration
(
:
string
[
]
)
:
void
;
dumpConfig
(
)
:
{
[
:
string
]
:
string
}
;
}
export
abstract
class
AbstractConfigurationService
extends
Disposable
implements
IConfigurationService
{
declare
readonly
:
undefined
;
protected
=
this
.
_register
(
new
Emitter<ConfigurationChangeEvent>
(
)
)
;
readonly
=
this
.
.
;
protected
:
boolean
=
false
;
constructor
(
?
:
)
{
super
(
)
;
if
(
)
{
this
.
_register
(
.
onDidStoreUpdate
(
(
)
=>
{
this
.
_setUserInfo
(
{
:
!
!
.
?.
}
)
;
}
)
)
;
}
}
getConfigMixedWithDefaults<T>
(
:
<
T
>
)
:
T
{
if
(
.
?.
&&
!
this
.
)
{
return
this
.
getDefaultValue
(
)
;
}
const
=
this
.
getConfig
(
)
;
// if user doesn't override the setting, return the default
if
(
===
undefined
)
{
return
this
.
getDefaultValue
(
)
;
}
// if user overrides the setting and the setting is an object, combine default with user value, with the preference to user settings
if
(
.
isObject
(
)
&&
.
isObject
(
.
)
)
{
// If default is an object apply the default and then apply the setting
return
{
...
.
,
...
}
;
}
return
;
}
public
getDefaultValue<T>
(
:
<
T
>
)
:
T
{
const
=
this
.
getDefaultValueForConfig
(
)
;
// Preserve legacy behavior for settings whose code default is undefined.
// VS Code may return type-default sentinels (false/0/''/null/undefined) from inspect().defaultValue,
// which should not override an intentional undefined default in code.
const
=
===
undefined
||
===
null
||
===
false
||
===
0
||
===
''
;
if
(
.
===
undefined
&&
)
{
return
.
;
}
if
(
!==
undefined
)
{
return
;
}
return
.
;
}
protected
_setUserInfo
(
:
{
:
boolean
}
)
:
void
{
if
(
this
.
===
.
)
{
// no change
return
;
}
const
=
this
.
!==
.
;
this
.
=
.
;
// collect potential affected settings
const
=
new
Set<string>
(
)
;
for
(
const
of
.
.
values
(
)
)
{
if
(
&&
.
?.
)
{
.
add
(
.
)
;
}
}
if
(
.
>
0
)
{
// fire a fake change event to refresh potential affected settings
this
.
.
fire
(
{
affectsConfiguration
:
(
)
=>
{
// Check for exact match or prefix match with dot separator
/**
* The value the user explicitly configured for `key` in any settings scope, or `undefined` when the
* setting is not configured. Implementations backed only by defaults have nothing to report.
*/
/**
* The value assigned to `key` by experimentation, looked up under every treatment name the key has
* ever been published as, or `undefined` when no experiment assigns it.
*/
// This is the pattern we've been using for a while now. We need to maintain it for older experiments.
const
=
.
getTreatmentVariable<Exclude<T,undefined>>
(
`copilotchat.config.${key.id}`
)
;
if
(
!==
undefined
)
{
return
;
}
// This is the pattern vscode uses for settings using the `onExp` tag. But vscode only supports it for
// settings defined in package.json, so this is why we're also reading the value from exp here.
const
=
.
getTreatmentVariable<Exclude<T,undefined>>
(
`config.${key.fullyQualifiedId}`
)
;
if
(
!==
undefined
)
{
return
;
}
if
(
.
)
{
const
=
.
getTreatmentVariable<Exclude<T,undefined>>
(
`copilotchat.config.${key.oldId}`
)
;
if
(
!==
undefined
)
{
return
;
}
const
=
.
getTreatmentVariable<Exclude<T,undefined>>
(
`config.${key.fullyQualifiedOldId}`
)
;
if
(
!==
undefined
)
{
return
;
}
}
return
undefined
;
}
public
updateExperimentBasedConfiguration
(
:
string
[
]
)
:
void
{
if
(
.
===
0
)
{
return
;
}
this
.
.
fire
(
{
affectsConfiguration
:
(
)
=>
true
}
)
;
}
/**
* Whether any of `treatments` can supply a value for `section`.
*
* Mirrors the alias list in {@link _getExperimentTreatment}: a treatment arriving under one of the
* older names assigns the setting just as much as one under the `config.` name, so it has to
* invalidate the setting's observers too.
*/
/**
* Cached observables, keyed by accessor *and* setting id.
*
* {@link getExperimentBasedConfigObservable} and {@link getExperimentBasedConfigIfSetObservable}
* report different values for the same setting: the latter reports `undefined` where the former
* reports the setting's default. Keying on the setting alone would hand whichever accessor asked
* second the observable built for the first, so an unset setting would read as explicitly set to
* its default -- silently reintroducing the precedence bug the `IfSet` accessor exists to fix.
*/
private
=
new
Map<string, IObservable<any>>
(
)
;
private
_getObservable_$show2FramesUp<T>
(
:
'config'
|
'exp'
|
'expIfSet'
,
:
<
T
>
,
getValue
:
(
)
=>
T
)
:
<
T
>
{
const
=
`${kind}:${key.id}`
;
let
=
this
.
.
get
(
)
;
if
(
!
)
{
=
observableFromEventOpts
(
{
debugName
:
(
)
=>
`Configuration Key "${key.id}"`
}
,
(
)
=>
this
.
_register
(
this
.
onDidChangeConfiguration
(
=>
{
if
(
.
affectsConfiguration
(
.
)
)
{
handleChange
(
)
;
}
}
)
)
,
)
;
this
.
.
set
(
,
)
;
}
return
;
}
/**
* Checks if the key is configured by the user in any of the configuration scopes.
*/
public
isConfigured<T>
(
:
<
T
>
,
?
:
)
:
boolean
{
const
=
this
.
inspectConfig<T>
(
,
)
;
const
=
(
?.
!==
undefined
||
?.
!==
undefined
||
?.
!==
undefined
||
?.
!==
undefined
||
?.
!==
undefined
||
?.
!==
undefined
)
;
return
;
}
protected
getDefaultValueForConfig<T>
(
:
<
T
>
)
:
T
|
undefined
{
return
undefined
;
}
}
export
interface
BaseConfig<T>
{
/**
* Key as it appears in settings.json minus the "github.copilot." prefix.
* e.g. "advanced.debug.overrideProxyUrl"
*/
readonly
:
string
;
/**
* The old key as it appears in settings.json minus the "github.copilot." prefix.
*/
readonly
?
:
string
;
/**
* This setting is present in package.json and is visible to the general public.
*/
readonly
:
boolean
;
/**
* The fully qualified id, e.g. "github.copilot.advanced.debug.overrideProxyUrl".
* Use this with `affectsConfiguration` from the ConfigurationChangeEvent
*/
readonly
:
string
;
/**
* The fully qualified old id, e.g. "github.copilot.advanced.debug.overrideProxyUrl".
*/
readonly
?
:
string
|
undefined
;
/**
* The `X` in `github.copilot.advanced.X` settings.
*/
readonly
:
string
|
undefined
;
/**
* The default value (defined either in code for hidden settings, or in package.json for non-hidden settings)
*/
readonly
:
T
;
/**
* Setting options
*/
readonly
?
:
;
readonly
?
:
<
T
>
;
}
export
const
enum
{
,
}
export
interface
ConfigOptions
{
readonly
?
:
string
;
readonly
?
:
boolean
;
/**
* When true, only reads from user (global) scope, ignoring workspace and folder values.
* Use for security-sensitive settings (e.g., API endpoint overrides) that must not be
* controllable via a workspace's .vscode/settings.json.
*/
// These values are used in the request and are case sensitive. Do not change them unless advised by CAPI.
// It is also not recommended to use this as a type as it will never be an exhaustive list
export
const
enum
CHAT_MODEL
{
GPT41
=
'gpt-4.1-2025-04-14'
,
GPT4OMINI
=
'gpt-4o-mini'
,
NES_XTAB
=
'copilot-nes-xtab'
,
// xtab model hosted in prod in proxy
CUSTOM_NES
=
'custom-nes'
,
XTAB_4O_MINI_FINETUNED
=
'xtab-4o-mini-finetuned'
,
GPT4OPROXY
=
'gpt-4o-instant-apply-full-ft-v66'
,
SHORT_INSTANT_APPLY
=
'gpt-4o-instant-apply-full-ft-v66-short'
,
CLAUDE_SONNET
=
'claude-sonnet-4.5'
,
CLAUDE_37_SONNET
=
'claude-3.7-sonnet'
,
DEEPSEEK_CHAT
=
'deepseek-chat'
,
GEMINI_25_PRO
=
'gemini-2.5-pro'
,
GEMINI_20_PRO
=
'gemini-2.0-pro-exp-02-05'
,
GEMINI_FLASH
=
'gemini-2.0-flash-001'
,
O1
=
'o1'
,
O3MINI
=
'o3-mini'
,
O1MINI
=
'o1-mini'
,
// A placeholder model that is used for just quickly testing new Azure endpoints.
// This model is not intended to be used for any real work.
EXPERIMENTAL
=
'experimental-01'
}
export
enum
{
=
'github'
,
=
'github-enterprise'
,
=
'microsoft'
,
}
export
enum
{
=
'default'
,
=
'minimal'
}
export
enum
{
=
'entraId'
,
=
'apiKey'
}
export
namespace
{
/** Microsoft authentication provider ID for VS Code authentication API */
export
const
MICROSOFT_AUTH_PROVIDER
=
'microsoft'
;
/** Azure Cognitive Services scope for Entra ID authentication */
export
const
COGNITIVE_SERVICES_SCOPE
=
'https://cognitiveservices.azure.com/.default'
;
}
export
type
CodeGenerationImportInstruction
=
{
?
:
string
;
:
string
}
;
export
type
CodeGenerationTextInstruction
=
{
?
:
string
;
:
string
}
;
export
type
CodeGenerationInstruction
=
|
;
export
type
CommitMessageGenerationInstruction
=
{
:
string
}
|
{
:
string
}
;
export
const
=
'XtabProvider'
;
export
namespace
{
/**
* These settings are defined in the completions extensions and shared.
*
* We should not change the names of these settings without coordinating with Completions extension.
*/
export
namespace
{
/** Allows for overriding the base domain we use for making requests to the CAPI. This helps CAPI devs develop against a local instance. */
export
const
=
defineSetting<string|undefined>
(
'advanced.debug.overrideProxyUrl'
,
.
,
undefined
,
undefined
,
{
:
true
}
)
;
/** Auth type to use when overrideProxyUrl or overrideCapiUrl is set. 'hmac' (default) for internal dev builds, 'token' for smoke tests / mock servers that don't support HMAC. */
export
const
=
defineSetting<'hmac'|'token'>
(
'advanced.debug.overrideAuthType'
,
.
,
'hmac'
)
;
export
const
=
defineSetting<string|undefined>
(
'advanced.debug.overrideCapiUrl'
,
.
,
undefined
,
undefined
,
{
:
true
}
)
;
export
const
=
defineSetting
(
'advanced.debug.useNodeFetchFetcher'
,
.
,
true
)
;
export
const
=
defineSetting
(
'advanced.debug.useNodeFetcher'
,
.
,
false
)
;
export
const
=
defineSetting
(
'advanced.debug.useElectronFetcher'
,
.
,
true
)
;
export
const
=
defineSetting<'off'|'memory'|'persistent'>
(
'advanced.debug.nodeFetchCache'
,
.
,
'memory'
)
;
export
const
=
defineSetting<AuthProviderId>
(
'advanced.authProvider'
,
.
,
.
)
;
export
const
=
defineSetting<AuthPermissionMode>
(
'advanced.authPermissions'
,
.
,
.
)
;
}
/**
* Advanced settings that are available for all users to configure.
*/
export
namespace
{
/** Allows forcing a particular model.
* Note: this should not be used while self-hosting because it might lead to
* a fundamental different experience compared to our end-users.
*/
/** Use the agentic proxy for the search subagent tool */
export
const
=
defineSetting<boolean>
(
'chat.searchSubagent.useAgenticProxy'
,
.
,
false
)
;
/** Model to use for the search subagent. When useAgenticProxy is true, defaults to 'vscode-agentic-search-router-a'. When false, defaults to the main agent model. */
export
const
=
defineSetting<string>
(
'chat.searchSubagent.model'
,
.
,
''
)
;
/** Maximum number of tool calls the search subagent can make */
export
const
=
defineSetting<number>
(
'chat.searchSubagent.toolCallLimit'
,
.
,
4
)
;
/** Enable the thoroughness parameter on the search subagent tool, which adjusts turn limits based on requested thoroughness */
export
const
=
defineSetting<boolean>
(
'chat.searchSubagent.thoroughnessEnabled'
,
.
,
false
)
;
export
const
=
defineSetting<boolean>
(
'chat.executionSubagent.enabled'
,
.
,
false
)
;
export
const
=
defineSetting<boolean>
(
'chat.skillTool.enabled'
,
.
,
false
)
;
/** When enabled, the get_changed_files tool is available to the agent. */
export
const
=
defineSetting<boolean>
(
'chat.getChangedFilesTool.enabled'
,
.
,
false
)
;
/** Model to use for the execution subagent */
/** Use the agentic proxy for the execution subagent */
export
const
=
defineSetting<boolean>
(
'chat.executionSubagent.useAgenticProxy'
,
.
,
false
)
;
/** Model to use for the execution subagent. When useAgenticProxy is true, defaults to 'exec-subagent-router-a'. When false, defaults to Gemini-3-Flash. */
export
const
=
defineSetting<string>
(
'chat.executionSubagent.model'
,
.
,
'gemini-3-flash'
)
;
/** Maximum number of tool calls the execution subagent can make */
export
const
=
defineSetting<number>
(
'chat.executionSubagent.toolCallLimit'
,
.
,
10
)
;
/** When enabled, the main agent's manage_todo_list tool is disabled and a background copilot-utility-small model maintains the todo list instead. */
/**
* Settings for switch between old tools and new skills
*/
export
const
=
defineSetting<boolean>
(
'chat.installExtensionSkill.enabled'
,
.
,
false
)
;
/**
* When enabled, large tool results (above the threshold in bytes) are written to disk
* instead of being included directly in the prompt. This helps manage context window usage.
*/
export
const
=
defineSetting<boolean>
(
'chat.agent.largeToolResultsToDisk.enabled'
,
.
,
true
)
;
/**
* The size threshold in bytes above which tool results are written to disk.
* Only applies when LargeToolResultsToDiskEnabled is true.
*/
/** Internal: override reasoning/thinking effort sent to model APIs (e.g. Responses API, Messages API). Used by evals. */
export
const
=
defineSetting<string|null>
(
'chat.reasoningEffortOverride'
,
.
,
null
)
;
export
const
=
defineSetting
(
'chat.chatCompletionsTokenParameter'
,
.
,
'max_tokens'
,
vEnum
(
'max_completion_tokens'
,
'max_tokens'
)
)
;
/**
* Internal: override the routing tier sent to `POST /auto`, ignoring both the
* model picker and the tier inline chat defaults to. Unlike the picker this
* accepts `fast`, so evals can exercise every profile.
*/
export
const
=
defineSetting<string|null>
(
'chat.autoModeTierOverride'
,
.
,
null
)
;
/**
* When enabled, periodic keep-alive probes are sent during long-running tool calls
* to keep the server-side prompt cache warm.
*/
/** Enable extended (1 hour) prompt cache TTL on tools and system blocks for the Anthropic Messages API. Applied to Claude Opus 4.5/4.6/4.7 and Sonnet 4.5/4.6 variants. */
export
const
=
defineSetting<boolean>
(
'chat.anthropic.promptCaching.extendedTtl'
,
.
,
false
)
;
/** Enable extended (1 hour) prompt cache TTL on the rolling message-level breakpoints (last cacheable user/tool-result blocks) for the Anthropic Messages API. Same model/location/subagent gating as {@link AnthropicExtendedCacheTtl}. */
/** Per-model capability overrides. Keys are model ids, values declare an aliased `family`. Lets evals route an unknown preview model id to a known production family (e.g. `"claude-opus-4.7"`) so the Anthropic prompt resolver, multi-replace tools, tool search, context editing, etc. all activate without a code change. */
/**
* Internal settings those only team members can configure
* Features should only be in this list temporarily, moving on to experimental to be accessible to early adopters.
*/
export
namespace
{
/** Allows forcing a particular context window size.
* This setting doesn't validate values so large windows may not be supported by the model.
* Note: this should not be used while self-hosting because it might lead to
* a fundamental different experience compared to our end-users.
*/
export
const
=
defineTeamInternalSetting<number>
(
'chat.advanced.debug.overrideChatMaxTokenNum'
,
.
,
0
)
;
/** Allow reporting issue when clicking on the Unhelpful button
* Requires a window reload to take effect
*/
/**
* When enabled, a cached NES suggestion that was once rendered as an inline
* (ghost text at cursor) suggestion will not be re-served from cache unless
* it can again be rendered as an inline suggestion. The cache entry is not
* evicted — it is simply gated until the cursor returns to an
* inline-renderable position.
*/
/**
* When enabled, a cached NES suggestion whose strict rebase fails *only*
* because the user re-typed a line's leading indentation differently than
* the model predicted (e.g. pressing Tab to insert a tab character, or a
* different number of spaces, on an otherwise-empty body line) is salvaged
* instead of dropped: the model's still-valid content is re-anchored as a
* clean at-cursor insertion that respects the indentation the user typed.
*/
/** Enable WebSocket transport for Responses API requests. When enabled, uses a persistent WebSocket connection per conversation instead of individual HTTP requests. */
export
const
=
defineTeamInternalSetting<boolean>
(
'chat.advanced.responsesApi.webSocket.enabled'
,
.
,
true
)
;
export
const
=
defineTeamInternalSetting<string>
(
'chat.advanced.debug.simulateWebSocketResponse'
,
.
,
''
)
;
/** Max events per cloud session sync flush request — also acts as a buffer-size flush trigger. */
export
const
=
defineTeamInternalSetting<number>
(
'chat.advanced.sessionSync.maxEventsPerFlush'
,
.
,
500
)
;
/** Safety-net interval (ms) for buffered cloud session sync events that did not trigger a terminal flush. */
export
const
=
defineTeamInternalSetting<number>
(
'chat.advanced.sessionSync.safetyIntervalMs'
,
.
,
60_000
)
;
}
/**
* Deprecated settings that are no longer in use.
*/
export
namespace
{
/** Model override for Plan agent — migrated to core `chat.planAgent.defaultModel` */