cody
cody copied to clipboard
feat(chat): Remove thinking XML tags and add thinking content part
This commit introduces the following changes:
- Removes the XML tags from the thinking text in
CompletionsResponseBuilder.ts. - Adds a
ThinkingContentParttype tolib/shared/src/sourcegraph-api/completions/types.tsto represent the thinking content. - Updates
lib/shared/src/sourcegraph-api/completions/parse.tsto handle thedelta_thinkingevent and add the thinking content to the content array. - Updates
vscode/src/prompt-builder/sanitize.tsto remove content between<think>tags from the first human message.
These changes allow the client to handle the thinking content separately from the completion text, and remove the need for XML tags.
Test plan
x