mirror of
https://github.com/RooVetGit/Roo-Code.git
synced 2026-10-06 02:47:56 +00:00
Include tool format in environment details (#9661)
This commit is contained in:
parent
bd2c50142c
commit
53d1f43cc1
1 changed files with 6 additions and 0 deletions
|
|
@ -8,6 +8,7 @@ import delay from "delay"
|
|||
import type { ExperimentId } from "@roo-code/types"
|
||||
import { DEFAULT_TERMINAL_OUTPUT_CHARACTER_LIMIT } from "@roo-code/types"
|
||||
|
||||
import { resolveToolProtocol } from "../../utils/resolveToolProtocol"
|
||||
import { EXPERIMENT_IDS, experiments as Experiments } from "../../shared/experiments"
|
||||
import { formatLanguage } from "../../shared/language"
|
||||
import { defaultModeSlug, getFullModeDetails, getModeBySlug, isToolAllowedForMode } from "../../shared/modes"
|
||||
|
|
@ -235,10 +236,15 @@ export async function getEnvironmentDetails(cline: Task, includeFileDetails: boo
|
|||
language: language ?? formatLanguage(vscode.env.language),
|
||||
})
|
||||
|
||||
// Resolve and add tool protocol information
|
||||
const modelInfo = cline.api.getModel().info
|
||||
const toolProtocol = resolveToolProtocol(state?.apiConfiguration ?? {}, modelInfo)
|
||||
|
||||
details += `\n\n# Current Mode\n`
|
||||
details += `<slug>${currentMode}</slug>\n`
|
||||
details += `<name>${modeDetails.name}</name>\n`
|
||||
details += `<model>${modelId}</model>\n`
|
||||
details += `<tool_format>${toolProtocol}</tool_format>\n`
|
||||
|
||||
if (Experiments.isEnabled(experiments ?? {}, EXPERIMENT_IDS.POWER_STEERING)) {
|
||||
details += `<role>${modeDetails.roleDefinition}</role>\n`
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue