monacopilot 0.9.27 → 0.9.29

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +10 -8
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -23,15 +23,15 @@
23
23
  - [FAQ](#faq)
24
24
  - [Contributing](#contributing)
25
25
 
26
- ## Demo
27
-
28
- https://github.com/user-attachments/assets/4af4e24a-1b05-4bee-84aa-1521ad7098cd
26
+ [Demo Video](https://github.com/user-attachments/assets/4af4e24a-1b05-4bee-84aa-1521ad7098cd)
29
27
 
30
28
  ## Examples
31
29
 
32
30
  Here are some examples of how to use Monacopilot in different project setups:
33
31
 
34
- - Next.js ([app](https://github.com/arshad-yaseen/monacopilot/tree/main/examples/nextjs/app) | [pages](https://github.com/arshad-yaseen/monacopilot/tree/main/examples/nextjs/pages))
32
+ - Next.js
33
+ - [App Router](https://github.com/arshad-yaseen/monacopilot/tree/main/examples/nextjs/app)
34
+ - [Pages Router](https://github.com/arshad-yaseen/monacopilot/tree/main/examples/nextjs/pages)
35
35
  - [Remix](https://github.com/arshad-yaseen/monacopilot/tree/main/examples/remix)
36
36
 
37
37
  ## Installation
@@ -106,6 +106,8 @@ registerCopilot(monaco, editor, {
106
106
  - `endpoint`: The URL of the API endpoint that we created in the previous step.
107
107
  - `language`: The language of the editor.
108
108
 
109
+ 🎉 Hurray! Monacopilot is now connected to the Monaco Editor. Start typing and see completions in the editor.
110
+
109
111
  ## Copilot Options
110
112
 
111
113
  ### Changing the Provider and Model
@@ -167,13 +169,13 @@ The `model` option accepts an object with two functions:
167
169
 
168
170
  1. `config`: A function that receives the API key and prompt data, and returns the configuration for the custom model API request.
169
171
 
170
- - `endpoint`: The URL for the custom model's API (required)
171
- - `body`: The request body data for the custom model API (optional)
172
- - `headers`: Additional HTTP headers for the API request (optional)
172
+ - `endpoint`: The URL for the custom model's API.
173
+ - `body`: (optional) The request body data for the custom model API.
174
+ - `headers`: (optional) Additional HTTP headers for the API request.
173
175
 
174
176
  2. `transformResponse`: A function that takes the raw response from the custom model API and converts it into an object with the following structure:
175
177
  - `completion`: A string containing the generated text from the model to be used as the completion.
176
- - `error`: A string describing any error that occurred during the completion process (optional)
178
+ - `error`: (optional) A string describing any error that occurred during the completion process.
177
179
 
178
180
  This structure allows for easy integration of the custom model's output with the rest of the Monacopilot system, providing either the generated completion text or an error message if something went wrong.
179
181
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "monacopilot",
3
- "version": "0.9.27",
3
+ "version": "0.9.29",
4
4
  "description": "AI auto-completion plugin for Monaco Editor",
5
5
  "main": "./build/index.js",
6
6
  "module": "./build/index.mjs",