Reference
Settings
Section titled “Settings”Open VS Code settings (Ctrl+, or Cmd+, on macOS) and search for Prompty to
find all extension settings.
| Setting | Type | Default | Description |
|---|---|---|---|
prompty.currentModelConfiguration | string | "default" | The active model configuration name |
prompty.showV1DeprecationWarnings | boolean | true | Show deprecation warnings when loading .prompty files that use the legacy v1 format |
prompty.envFilePath | string | "" | Custom path to a .env file. If empty, the extension searches the workspace hierarchy |
promptyLanguageServer.trace.server | string | "off" | Trace level for VS Code ↔ language server communication. Values: off, messages, verbose |
Example settings.json:
{ "prompty.currentModelConfiguration": "my-azure-connection", "prompty.showV1DeprecationWarnings": true, "prompty.envFilePath": "${workspaceFolder}/.env", "promptyLanguageServer.trace.server": "off"}Keyboard Shortcuts
Section titled “Keyboard Shortcuts”| Action | Shortcut | Context |
|---|---|---|
| Run Prompt | F5 | When a .prompty file is active |
| New Prompty | Ctrl+Shift+P → “Prompty: New Prompty” | Any time |
| Preview | Ctrl+Shift+P → “Prompty: Preview” | When a .prompty file is active |
| Add Connection | Ctrl+Shift+P → “Prompty: Add Connection” | Any time |
All Commands
Section titled “All Commands”The complete list of commands registered by the extension:
| Command | Description |
|---|---|
Prompty: New Prompty | Create a new .prompty file |
Prompty: Run Prompt | Execute the current .prompty file |
Prompty: Preview | Open live preview panel |
Prompty: Add Connection | Add a new LLM provider connection |
Prompty: Edit Connection | Modify an existing connection |
Prompty: Delete Connection | Remove a connection |
Prompty: Test Connection | Test connectivity to a provider |
Prompty: Set Default Connection | Set a connection as the default for its provider |
Prompty: Refresh Connections | Reload connections from disk |
Prompty: Refresh Models | Re-fetch available models for a connection |
Prompty: View Trace | Open a trace file in the viewer |
Prompty: Refresh Traces | Reload the traces list |
Prompty: Sort Traces by Date | Sort traces newest first |
Prompty: Sort Traces by Name | Sort traces alphabetically |
Extension API
Section titled “Extension API”Other VS Code extensions can integrate with Prompty by activating the extension and using the returned API surface.
const promptyExt = vscode.extensions.getExtension('ms-toolsai.prompty');const api = await promptyExt?.activate();Methods
Section titled “Methods”| Method | Description |
|---|---|
registerConnectionProvider(provider) | Register a custom connection provider |
registerExecutor(key, executor) | Register a custom executor for a provider key |
registerProcessor(key, processor) | Register a custom processor for a provider key |
getConnections() | Query all configured connections |
onConnectionsChanged(listener) | Listen for connection changes |
Troubleshooting
Section titled “Troubleshooting”Connection test fails
Section titled “Connection test fails”- OpenAI / Anthropic — verify that your API key is correct and has not
expired. Run
Prompty: Test Connectionto see the exact error. - Microsoft Foundry — ensure you are signed into Azure (
Azure: Sign Inin the Command Palette). Double-check that the endpoint URL matches your deployed resource.
No autocomplete in frontmatter
Section titled “No autocomplete in frontmatter”The language server provides completions for frontmatter keys and values. If autocomplete stops working:
- Run Developer: Reload Window from the Command Palette.
- If the issue persists, the language server may need a restart — disable and re-enable the extension.
Traces not appearing
Section titled “Traces not appearing”- Open the Output panel (
Ctrl+Shift+U) and select the Prompty channel. Look for errors during execution. - Verify that a
.runs/directory exists in your workspace — traces are written there as.tracyfiles. - Click Refresh in the Traces view, or run
Prompty: Refresh Traces.
V1 deprecation warnings
Section titled “V1 deprecation warnings”If you see deprecation warnings when opening a .prompty file, the file uses
the legacy v1 frontmatter format. See the migration guide for
instructions on updating to the v2 format.
To suppress warnings without migrating, set:
{ "prompty.showV1DeprecationWarnings": false}Language server not starting
Section titled “Language server not starting”- Set
promptyLanguageServer.trace.serverto"verbose"in settings. - Open the Output panel and select Prompty Language Server.
- Look for startup errors or missing dependencies.
- If no output appears, try reinstalling the extension from the Marketplace.