Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagejs
models: {
  "GPT-4 Turbo": {
    provider: "openai",
    model: "gpt-4-11060125-preview",
    apiKey: "sk-....."
  },
  "GPT-3.5 Turbo": {
    provider: "openai",
    model: "gpt-3.5-turbo-11060125",
    apiKey: "sk-....."
  },
  "Gemini Pro": {
    provider: "google",
    model: "gemini-pro",
    apiKey: "AI......"
  },
  "Azure OpenAI GPT-3.5": {
    provider: "openai",
    cloud: "azure",
    model: "azure-gpt-35-0613",
    resource: "profound-openai",
    apiKey: "......",
    apiVersion: "2023-12-01-preview"
  },  
  "Mistral Medium with Streaming": {
    provider: "mistral",
    model: "mistral-medium",
    stream: true,
    apiKey: "......"
  },
  "Mistral 7B via Anyscale": {
    endpoint: "https://api.endpoints.anyscale.com/v1",
    apiFormat: "completion",
    model: "mistralai/Mistral-7B-Instruct-v0.1",
    apiKey: "esecret_......"
  },
  "Llama 2 70B": {
    endpoint: "https://myserver",
    apiFormat: "completion",
    model: "Llama-2-70b-chat-hf-function-calling-v2",
    apiKey: "esecret_......"
  },
  "Claude 2 Streaming": {
    provider: "anthropic",
    model: "claude-2.1",
    apiKey: "sk-ant-......",
    stream: true
  },
  "AWS Bedrock - Claude 2": {
    provider: "anthropic",
    cloud: "aws",
    model: "claude-2.1",
    accessKeyId: "......",
    secretAccessKey: "......"
  }
}

Using Environment Variables for API Keys

Instead of placing your API keys directly into the Profound AI configuration (config.js file), it is recommended that that environment variables are used instead.

Environment variables can be placed into a .env file. For example, the file contents below store the OpenAI API Key and the OpenAI Assistant Id.

Code Block
OPENAI_API_KEY=sk-......
OPENAI_ASSISTANT_ID=asst_......

Then, your configuration file may refer to the environment variables, as demonstrated in the following example:

Code Block
languagejs
models: {
  "GPT-4 Turbo": {
    provider: "openai",
    model: "gpt-4-0125-preview",
    apiKey: process.env.OPENAI_API_KEY,
    defaultAssistantId: process.env.OPENAI_ASSISTANT_ID
  }, 
  "GPT-3.5 Turbo": {
    provider: "openai",
    model: "gpt-3.5-turbo-0125",
    apiKey: process.env.OPENAI_API_KEY,
    defaultAssistantId: process.env.OPENAI_ASSISTANT_ID
  },
  "GPT-3.5 Turbo Streaming": {
    provider: "openai",
    apiFormat: "completion",
    stream: true,
    model: "gpt-3.5-turbo-0125",
    apiKey: process.env.OPENAI_API_KEY
  },
  "GPT-4 Turbo Streaming": {
    provider: "openai",
    apiFormat: "completion",
    stream: true,
    model: "gpt-4-0125-preview",
    apiKey: process.env.OPENAI_API_KEY
  }
}

If you are using Git, the .env file is generally set to be ignored (using .git_ignore) and its contents should not be committed to your repository.

Model Properties

provider

When this property is specified (e.g. “openai”, “google”, “mistral”, “anthropic”), the endpoint and apiFormat properties assume default values for each respective provider.

...