This extension integrates with the Ollama model to provide TypeScript code completions directly in VS Code. It generates intelligent suggestions for code marked with placeholders (???) and replaces them with valid TypeScript code.
Features
Generate TypeScript completions by calling the Ollama model.
Replaces ??? placeholders in your code with valid TypeScript suggestions.
Intelligent error handling for missing editor, API errors, or mismatched suggestions.
Here’s how the placeholder works:
For example:
function doSomething() {
??? write a function to add two numbers
??? invoke the add function with two numbers
}
The extension will replace the ??? lines with valid TypeScript code based on the prompts provided to the Ollama model.
Requirements
Ollama model: The extension uses the llama3.1 model, which should be available and accessible through your environment.
To install and configure the Ollama library, follow these steps: