Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add ollama model provider configuration docs #616

Merged
merged 2 commits into from
Nov 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 10 additions & 4 deletions docs/docs/04-configuration/02-model-providers.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Model Providers

Each packaged model provider has a slightly different configuration, but all require at least, the `OTTO8_*_MODEL_PROVIDER_API_KEY` environment variable are required, where `*` stands in for the name of the provider (e.g. `OTTO8_AZURE_OPENAI_MODEL_PROVIDER_API_KEY`).
Each packaged model provider has a slightly different configuration set via environment variables. The environment variables for the packaged model providers are of the form `OTTO8_*_MODEL_PROVIDER_CONFIG_ITEM` where `*` stands in for the name of the provider (e.g. `OTTO8_AZURE_OPENAI_MODEL_PROVIDER_API_KEY`).

Below is a summary of the configuration options for each provider. However, the packaged model providers are configured to indicate which environment variables are required and which ones are not set in the current environment. For example, `/api/tool-references/azure-openai-model-provider` would indicate the status of the Azure OpenAI model provider. If the environment variables are not set, then the API would return something like:
Below is a summary of the configuration options for each provider. However, the packaged model providers indicate which environment variables they require and which ones aren't set in the current environment. For example, `/api/tool-references/azure-openai-model-provider` would indicate the status of the Azure OpenAI model provider. If you don't set the environment variables, then the API would return something like:

```json
{
Expand Down Expand Up @@ -58,11 +58,17 @@ The OpenAI model provider is the default and is configured by either setting `OP

## Azure OpenAI

The Azure OpenAI model provider is configured by setting the following environment variables:
The Azure OpenAI model provider requires setting the following environment variables:
- `OTTO8_AZURE_OPENAI_MODEL_PROVIDER_API_KEY`: Found on the "Home" page of the Azure OpenAI Studio.
- `OTTO8_AZURE_OPENAI_MODEL_PROVIDER_DEPLOYMENT_NAME`: The name of the deployment to use, found on the "Deployments" page of the Azure OpenAI Studio.
- `OTTO8_AZURE_OPENAI_MODEL_PROVIDER_ENDPOINT`: The endpoint to use, found by clicking on the "Deployment" name from the "Deployments" page of the Azure OpenAI Studio.

## Anthropic

The Anthropic model provider is configured by setting the `OTTO8_ANTHROPIC_MODEL_PROVIDER_API_KEY` environment variable. An API key for your Anthropic account can be obtained [here](https://console.anthropic.com/settings/keys).
The Anthropic model provider requires setting the `OTTO8_ANTHROPIC_MODEL_PROVIDER_API_KEY` environment variable. You can get an API key for your Anthropic account [here](https://console.anthropic.com/settings/keys).

## Ollama

The Ollama model provider requires the `OTTO8_OLLAMA_MODEL_PROVIDER_HOST` environment variable. This host must point to a running instance of Ollama. For your reference, the default host and port for Ollama is `127.0.0.1:11434`. Otto8 doesn't set this by default.

To set up and run an instance of Ollama, refer to the [Ollama GitHub readme](https://github.com/ollama/ollama/blob/main/README.md).
Loading