microsoft/vscode · error · Error
Setting github.copilot.${settingId} is too low; use a ratio
Error message
Setting github.copilot.${settingId} is too low; use a ratio in the range (0, 1] (e.g. 0.8 for 80%) or an absolute token count of at least 100. What it means
Error "Setting github.copilot.${settingId} is too low; use a ratio in the range (0, 1] (e.g. 0.8 for 80%) or an absolute token count of at least 100." thrown in microsoft/vscode.
Source
Thrown at extensions/copilot/src/extension/intents/node/agentIntent.ts:190
* small to be a useful token budget) are rejected so a typo like `80` — which a
* user likely meant as "80%" — fails loudly instead of silently compacting after
* 80 tokens.
*
* Returns `undefined` when unset (or non-positive), meaning "use the model's full
* context window".
*
* @internal - exported for testing
*/
export function resolveSummarizeThresholdTokens(value: number | undefined, effectiveMaxTokens: number, settingId: string): number | undefined {
if (typeof value !== 'number' || value <= 0) {
return undefined;
}
if (value <= 1) {
// Ratio of the model's context window.
return Math.max(1, Math.floor(effectiveMaxTokens * value));
}
if (value < 100) {
throw new Error(`Setting github.copilot.${settingId} is too low; use a ratio in the range (0, 1] (e.g. 0.8 for 80%) or an absolute token count of at least 100.`);
}
// Absolute token count.
return value;
}
export const getAgentTools = async (accessor: ServicesAccessor, request: vscode.ChatRequest, model?: IChatEndpoint) => {
const toolsService = accessor.get<IToolsService>(IToolsService);
const testService = accessor.get<ITestProvider>(ITestProvider);
const tasksService = accessor.get<ITasksService>(ITasksService);
const configurationService = accessor.get<IConfigurationService>(IConfigurationService);
const experimentationService = accessor.get<IExperimentationService>(IExperimentationService);
const endpointProvider = accessor.get<IEndpointProvider>(IEndpointProvider);
const editToolLearningService = accessor.get<IEditToolLearningService>(IEditToolLearningService);
const authenticationService = accessor.get<IAuthenticationService>(IAuthenticationService);
const logService = accessor.get<ILogService>(ILogService);
model ??= await endpointProvider.getChatEndpoint(request);
View on GitHub (pinned to a94b963a32)
When it happens
Trigger: Thrown at extensions/copilot/src/extension/intents/node/agentIntent.ts:190 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of microsoft/vscode@a94b963a32 (2026-08-12).
Data as JSON: /api/errors/a5002ca5e2c77f59.
Report an issue: GitHub.