You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+12-1Lines changed: 12 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -34,6 +34,8 @@ If you are new to running a model locally, you can try [Ollama](https://ollama.c
34
34
35
35
- Use Tabby since they have extensive experience in code completion.
36
36
- Use models with completions API with Fill-in-the-Middle support (for example, codellama:7b-code), and use the "Fill-in-the-Middle" strategy.
37
+
38
+
You can find some [examples here](#example-use-of-local-models).
37
39
- Use models with FIM API.
38
40
39
41
When using custom models to generate suggestions, it is recommended to setup a lower suggestion limit for faster generation.
@@ -61,6 +63,15 @@ The template format differs in different tools.
61
63
- Naive: This strategy rearranges the code in a naive way to trick the model into believing it's appending code at the end of a file.
62
64
- Continue: This strategy employs the "Please Continue" technique to persuade the model that it has started a suggestion and must continue to complete it. (Only effective with the chat completion API).
63
65
66
+
## Example Use of Local Models
67
+
68
+
### Qwen Type in the Middle
69
+
70
+
1. Load `qwen2.5-coder:32b` with Ollama.
71
+
2. Setup the model with the completions API.
72
+
3. Set the request strategy to "Fill-in-the-Middle".
73
+
4. Set prompt format to `<|fim_prefix|>{prefix}<|fim_suffix|>{suffix}<|fim_middle|>` and turn on Raw Prompt.
74
+
64
75
## Contribution
65
76
66
77
Prompt engineering is a challenging task, and your assistance is invaluable.
@@ -69,4 +80,4 @@ The most complex things are located within the `Core` package.
69
80
70
81
- To add a new service, please refer to the `CodeCompletionService` folder.
71
82
- To add new request strategies, check out the `SuggestionService` folder.
72
-
83
+
- To add a new instructions of using a local model, update the `Example Use of Local Models` in the README.md.
0 commit comments