Skip to content

[testplan-item] Add API for providing dynamic prompt files #290506

@pwang347

Description

@pwang347

Refs #288486

Complexity: 3

Create Issue


Context

Added new extension API for contributing dynamic prompt file types. This is currently a proposed API, but we would like to make it stable in the Feb release so feedback is appreciated.

Test Steps

  1. Consider using the following branch as a base: Add chat prompt files sample vscode-extension-samples#1259.

Custom Agents Provider

  1. Use vscode.chat.registerCustomAgentProvider to dynamically contribute a custom agent.
  2. The custom agent appears in the dropdown; selecting the agent and sending a chat message should use the instructions for that agent.
  3. When clicking on settings wheel at top of chat window > Custom Agents, the custom agent file should also appear and clicking it should also show an editor with the correct contents.
  4. Verify that calling onDidChangeCustomAgents refreshes the custom agent content properly.

Instructions Provider

  1. Use vscode.chat.registerInstructionsProvider to dynamically contribute instructions. Make sure you use applyTo: '**' to always include the instructions for testing.
  2. Make sure the instruction reference shows up when any message is sent and the instructions are affect the response.
  3. When clicking on settings wheel at top of chat window > Chat Instructions, the instruction file should also appear and clicking it should also show an editor with the correct contents.
  4. Verify that calling onDidChangeInstructions refreshes the instructions content properly.

Prompt Files Provider

  1. Use vscode.chat.registerPromptFilesProvider to dynamically contribute prompt files / slash commands.
  2. Make sure the slash commands show up and can be invoked.
  3. When clicking on settings wheel at top of chat window > Prompt Files, the prompt file should also appear and clicking it should also show an editor with the correct contents.
  4. Verify that calling onDidChangePromptFiles refreshes the prompt files content properly.

Skills Provider

  1. Use vscode.chat.registerSkillsProvider to dynamically contribute skills.
  2. Make sure the skills show up when you ask "What skills do you know?"
  3. When clicking on settings wheel at top of chat window > Skills, the SKILL.md should also appear and clicking it should also show an editor with the correct contents.
  4. Verify that calling onDidChangeSkills refreshes the skills content properly. You can ask the agent to re-read the skill file to see if it changed.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions