tweak: adjust way skills are presented to agent to increase likelyhood of skill invocations. (#17053)

This commit is contained in:
Aiden Cline
2026-03-11 10:24:55 -05:00
committed by GitHub
parent 7291e28273
commit 0f6bc8ae71
4 changed files with 50 additions and 24 deletions

View File

@@ -650,7 +650,12 @@ export namespace SessionPrompt {
await Plugin.trigger("experimental.chat.messages.transform", {}, { messages: msgs })
// Build system prompt, adding structured output instruction if needed
const system = [...(await SystemPrompt.environment(model)), ...(await InstructionPrompt.system())]
const skills = await SystemPrompt.skills(agent)
const system = [
...(await SystemPrompt.environment(model)),
...(skills ? [skills] : []),
...(await InstructionPrompt.system()),
]
const format = lastUser.format ?? { type: "text" }
if (format.type === "json_schema") {
system.push(STRUCTURED_OUTPUT_SYSTEM_PROMPT)