Skip to content

Commit 4a1fbed

Browse files
authored
Merge pull request #100 from yankay/Add-Ollama-backends
docs: Add Ollama backends
2 parents abbc431 + 58ea49d commit 4a1fbed

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

docs/reference/providers/backend.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ Currently, we have a total of 11 backends available:
1414
- [Hugging Face](https://huggingface.co)
1515
- [IBM watsonx.ai](https://www.ibm.com/products/watsonx-ai)
1616
- [LocalAI](https://github.com/go-skynet/LocalAI)
17+
- [Ollama](https://github.com/ollama/ollama)
1718
- FakeAI
1819

1920
## OpenAI
@@ -208,6 +209,27 @@ Ollama is a local model, which has an OpenAI compatible API. It supports the mod
208209
k8sgpt analyze --explain --backend localai
209210
```
210211
212+
## Ollama
213+
214+
Ollama can get up and running locally with large language models. It runs Llama 2, Code Llama, and other models.
215+
216+
- To start the Ollama server, follow the instruction in [Ollama](https://github.com/ollama/ollama?tab=readme-ov-file#start-ollama).
217+
```bash
218+
ollama serve
219+
```
220+
It can also run as an docker image, follow the instruction in [Ollama BLog](https://ollama.com/blog/ollama-is-now-available-as-an-official-docker-image)
221+
```bash
222+
docker run -d -v ollama:/root/.ollama -p 11434:11434 --name ollama ollama/ollama
223+
```
224+
225+
- Authenticate K8sGPT with Ollama:
226+
```bash
227+
k8sgpt auth add --backend ollama --model llama2 --baseurl http://localhost:11434/v1
228+
```
229+
- Analyze with a Ollama backend:
230+
```bash
231+
k8sgpt analyze --explain --backend ollama
232+
```
211233
## FakeAI
212234
213235
FakeAI or the NoOpAiProvider might be useful in situations where you need to test a new feature or simulate the behaviour of an AI based-system without actually invoking it. It can help you with local development, testing and troubleshooting.

0 commit comments

Comments
 (0)