https://github.com/coder/picopilot
GitHub Copilot in 70 lines of JavaScript
https://github.com/coder/picopilot
Last synced: 16 days ago
JSON representation
GitHub Copilot in 70 lines of JavaScript
- Host: GitHub
- URL: https://github.com/coder/picopilot
- Owner: coder
- License: mit
- Created: 2024-06-24T19:01:33.000Z (10 months ago)
- Default Branch: main
- Last Pushed: 2024-06-24T20:56:08.000Z (10 months ago)
- Last Synced: 2025-04-02T02:42:48.303Z (24 days ago)
- Language: JavaScript
- Homepage:
- Size: 5.31 MB
- Stars: 247
- Watchers: 5
- Forks: 23
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
![]()
Picopilot[](https://marketplace.visualstudio.com/items?itemName=coder.picopilot)
[GitHub Copilot](https://marketplace.visualstudio.com/items?itemName=GitHub.copilot) in [70 lines of JavaScript](./extension.js).
System Prompt:
```text
You provide code completion results given a prefix and suffix.Respond with a JSON object with a key 'completion' containing the suggestion to place between the prefix and suffix.
Follow existing code styles. Listen to comments at the end of the prefix. The language is "${document.languageId}".
```Response Format:
```json
{
"completion": ""
}
```## Demos
_All demos are unedited._
### Creating a terminal game

### Generating aphorisms

### Using the GitHub API

## Install
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
```text
ext install coder.picopilot
```Feel free to configure a custom prompt in your settings.
## Development
Clone the repository, run `bun install`, `bun watch`, open VS Code, and press F5 to launch the extension in development mode.
Create your own AI extensions from this repo. It's remarkably simple!