OpenAI API
The OpenAI Extension can be used for any OpenAI-compatible API endpoints.
How to Integrate OpenAI API with Jan
This guide provides step-by-step instructions for integrating the OpenAI API with Jan, allowing users to utilize OpenAI's capabilities within Jan's conversational interface.
Integration Steps
Step 1: Configure OpenAI API Key
- Obtain OpenAI API Key from your OpenAI Platform (opens in a new tab) dashboard.
- Copy your OpenAI API Key.
- There are three ways to configure your API Key in Jan app:
- Navigate to the Jan app > Gear Icon (⚙️) > My Models tab > Add Icon (➕) next to OpenAI.
- Navigate to the Jan app > Thread > Model tab > Add Icon (➕) next to OpenAI.
- Navigate to the Jan app > Gear Icon (⚙️) > OpenAI section under Model Providers.
- Insert your OpenAI API Key.
Step 2: Start Chatting with the Model
- Select the OpenAI model you want to use.
The OpenAI is the default extension for the Jan application. All the OpenAI models are automatically installed when you install the Jan application.
- Specify the model's parameters.
- Start the conversation with the OpenAI model.
OpenAI Models
You can also use specific OpenAI models you cannot find in the Hub section by customizing the model.yaml
file, which you can see in the ~/jan/data/models/
. Follow the steps in the Manage Models to manually add a model.
- You can find the list of available models in the OpenAI Platform (opens in a new tab).
- The
id
property must match the model name in the list.- For example, if you want to use the GPT-4 Turbo (opens in a new tab), you must set the
id
property togpt-4-1106-preview
.
- For example, if you want to use the GPT-4 Turbo (opens in a new tab), you must set the
Troubleshooting
If you encounter any issues during the integration process or while using OpenAI with Jan, consider the following troubleshooting steps:
- Double-check your API credentials to ensure they are correct.
- Check for error messages or logs that may provide insight into the issue.
- Reach out to OpenAI API support for assistance if needed.