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: docs/docs/features/codebase-embeddings.md
-84
Original file line number
Diff line number
Diff line change
@@ -91,90 +91,6 @@ export function modifyConfig(config: Config): Config {
91
91
}
92
92
```
93
93
94
-
## Reranking providers
95
-
96
-
The reranker plays a crucial role in refining the results retrieved from your codebase. It processes the initial set of results obtained through embeddings-based retrieval, improving their relevance and accuracy for your queries.
97
-
98
-
Continue offers several reranking options: `cohere`, `voyage`, `llm`, `hugginface-tei`, and `free-trial`, which can be configured in `config.json`.
99
-
100
-
### Voyage AI
101
-
102
-
Voyage AI offers the best reranking model for code with their rerank-lite-1 model. After obtaining an API key from [here](https://www.voyageai.com/), you can configure like this:
103
-
104
-
```json title="~/.continue/config.json"
105
-
{
106
-
"reranker": {
107
-
"name": "voyage",
108
-
"params": {
109
-
"model": "rerank-lite-1",
110
-
"apiKey": "<VOYAGE_API_KEY>"
111
-
}
112
-
}
113
-
}
114
-
```
115
-
116
-
### Cohere
117
-
118
-
See Cohere's documentation for rerankers [here](https://docs.cohere.com/docs/rerank-2).
119
-
120
-
```json title="~/.continue/config.json"
121
-
{
122
-
"reranker": {
123
-
"name": "cohere",
124
-
"params": {
125
-
"model": "rerank-english-v3.0",
126
-
"apiKey": "<COHERE_API_KEY>"
127
-
}
128
-
}
129
-
}
130
-
```
131
-
132
-
### LLM
133
-
134
-
If you only have access to a single LLM, then you can use it as a reranker. This is discouraged unless truly necessary, because it will be much more expensive and still less accurate than any of the above models trained specifically for the task. Note that this will not work if you are using a local model, for example with Ollama, because too many parallel requests need to be made.
135
-
136
-
```json title="~/.continue/config.json"
137
-
{
138
-
"reranker": {
139
-
"name": "llm",
140
-
"params": {
141
-
"modelTitle": "My Model Title"
142
-
}
143
-
}
144
-
}
145
-
```
146
-
147
-
The `"modelTitle"` field must match one of the models in your "models" array in config.json.
148
-
149
-
### Text Embeddings Inference
150
-
151
-
[Hugging Face Text Embeddings Inference](https://huggingface.co/docs/text-embeddings-inference/en/index) enables you to host your own [reranker endpoint](https://huggingface.github.io/text-embeddings-inference/#/Text%20Embeddings%20Inference/rerank). You can configure your reranker as follows:
152
-
153
-
```json title="~/.continue/config.json"
154
-
{
155
-
"reranker": {
156
-
"name": "huggingface-tei",
157
-
"params": {
158
-
"apiBase": "http://localhost:8080",
159
-
"truncate": true,
160
-
"truncation_direction": "Right"
161
-
}
162
-
},
163
-
}
164
-
```
165
-
166
-
### Free Trial (Voyage AI)
167
-
168
-
Continue offers a free trial of Voyage AI's reranking model.
169
-
170
-
```json title="~/.continue/config.json"
171
-
{
172
-
"reranker": {
173
-
"name": "free-trial"
174
-
}
175
-
}
176
-
```
177
-
178
94
## Ignore files during indexing
179
95
180
96
Continue respects `.gitignore` files in order to determine which files should not be indexed. If you'd like to exclude additional files, you can add them to a `.continueignore` file, which follows the exact same rules as `.gitignore`.
description: Overview of different reranking options available in Continue, including Cohere, Voyage AI, LLM, Hugging Face TEI, and free trial options.
4
+
---
5
+
6
+
The reranker plays a crucial role in refining the results retrieved from your codebase. It processes the initial set of results obtained through embeddings-based retrieval, improving their relevance and accuracy for your queries.
7
+
8
+
Continue offers several reranking options: `cohere`, `voyage`, `llm`, `hugginface-tei`, and `free-trial`, which can be configured in `config.json`.
9
+
10
+
## Cohere
11
+
12
+
See Cohere's documentation for rerankers [here](https://docs.cohere.com/docs/rerank-2).
13
+
14
+
```json title="~/.continue/config.json"
15
+
{
16
+
"reranker": {
17
+
"name": "cohere",
18
+
"params": {
19
+
"model": "rerank-english-v3.0",
20
+
"apiKey": "<COHERE_API_KEY>"
21
+
}
22
+
}
23
+
}
24
+
```
25
+
26
+
## Free Trial
27
+
28
+
Continue offers a free trial of Voyage AI's reranking model.
29
+
30
+
```json title="~/.continue/config.json"
31
+
{
32
+
"reranker": {
33
+
"name": "free-trial"
34
+
}
35
+
}
36
+
```
37
+
38
+
## LLM
39
+
40
+
If you only have access to a single LLM, then you can use it as a reranker. This is discouraged unless truly necessary, because it will be much more expensive and still less accurate than any of the above models trained specifically for the task. Note that this will not work if you are using a local model, for example with Ollama, because too many parallel requests need to be made.
41
+
42
+
```json title="~/.continue/config.json"
43
+
{
44
+
"reranker": {
45
+
"name": "llm",
46
+
"params": {
47
+
"modelTitle": "My Model Title"
48
+
}
49
+
}
50
+
}
51
+
```
52
+
53
+
The `"modelTitle"` field must match one of the models in your "models" array in config.json.
54
+
55
+
## Text Embeddings Inference
56
+
57
+
[Hugging Face Text Embeddings Inference](https://huggingface.co/docs/text-embeddings-inference/en/index) enables you to host your own [reranker endpoint](https://huggingface.github.io/text-embeddings-inference/#/Text%20Embeddings%20Inference/rerank). You can configure your reranker as follows:
58
+
59
+
```json title="~/.continue/config.json"
60
+
{
61
+
"reranker": {
62
+
"name": "huggingface-tei",
63
+
"params": {
64
+
"apiBase": "http://localhost:8080",
65
+
"truncate": true,
66
+
"truncation_direction": "Right"
67
+
}
68
+
},
69
+
}
70
+
```
71
+
72
+
## Voyage AI
73
+
74
+
Voyage AI offers the best reranking model for code with their rerank-lite-1 model. After obtaining an API key from [here](https://www.voyageai.com/), you can configure like this:
0 commit comments