Fixes to support Cerebras Llama3.1 8b and 70b
This commit is contained in:
parent
97280cce7b
commit
c8ce3df4aa
6 changed files with 82 additions and 5 deletions
|
|
@ -10,7 +10,7 @@ class Cerebras extends OpenAI {
|
|||
|
||||
private static modelConversion: { [key: string]: string } = {
|
||||
"llama3.1-8b": "llama3.1-8b",
|
||||
"llama3.1-70b": "llama-3.1-70b",
|
||||
"llama3.1-70b": "llama3.1-70b",
|
||||
};
|
||||
protected _convertModelName(model: string): string {
|
||||
return Cerebras.modelConversion[model] ?? model;
|
||||
|
|
|
|||
23
docs/static/schemas/config.json
vendored
23
docs/static/schemas/config.json
vendored
|
|
@ -194,7 +194,8 @@
|
|||
"openrouter",
|
||||
"sambanova",
|
||||
"nvidia",
|
||||
"vllm"
|
||||
"vllm",
|
||||
"cerebras"
|
||||
],
|
||||
"markdownEnumDescriptions": [
|
||||
"### OpenAI\nUse gpt-4, gpt-3.5-turbo, or any other OpenAI model. See [here](https://openai.com/product#made-for-developers) to obtain an API key.\n\n> [Reference](https://docs.continue.dev/reference/Model%20Providers/openai)",
|
||||
|
|
@ -224,7 +225,8 @@
|
|||
"### IBM watsonx\nwatsonx, developed by IBM, offers a variety of pre-trained AI foundation models that can be used for natural language processing (NLP), computer vision, and speech recognition tasks.",
|
||||
"### OpenRouter\nOpenRouter offers a single API to access almost any language model. To get started, obtain an API key from [their console](https://openrouter.ai/settings/keys).",
|
||||
"### NVIDIA NIMs\nNVIDIA offers a single API to access almost any language model. To find out more, visit the [LLM APIs Documentation](https://docs.api.nvidia.com/nim/reference/llm-apis).\nFor information specific to getting a key, please check out the [docs here](https://docs.nvidia.com/nim/large-language-models/latest/getting-started.html#option-1-from-api-catalog)",
|
||||
"### vLLM\nvLLM is a highly performant way of hosting LLMs for a team. To get started, follow their [quickstart](https://docs.vllm.ai/en/latest/getting_started/quickstart.html) to set up your server."
|
||||
"### vLLM\nvLLM is a highly performant way of hosting LLMs for a team. To get started, follow their [quickstart](https://docs.vllm.ai/en/latest/getting_started/quickstart.html) to set up your server.",
|
||||
"### Cerebras\nCerebras Inference uses specialized silicon to provides superfast inference. To get started, get your API keys from [their console](https://cloud.cerebras.ai/)."
|
||||
],
|
||||
"type": "string"
|
||||
},
|
||||
|
|
@ -1142,6 +1144,23 @@
|
|||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": {
|
||||
"properties": {
|
||||
"provider": {
|
||||
"enum": ["cerebras"]
|
||||
}
|
||||
},
|
||||
"required": ["provider"]
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"model": {
|
||||
"enum": ["llama3.1-8b", "llama3.1-70b"]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": {
|
||||
"properties": {
|
||||
|
|
|
|||
|
|
@ -197,7 +197,8 @@
|
|||
"openrouter",
|
||||
"sambanova",
|
||||
"nvidia",
|
||||
"vllm"
|
||||
"vllm",
|
||||
"cerebras"
|
||||
],
|
||||
"markdownEnumDescriptions": [
|
||||
"### OpenAI\nUse gpt-4, gpt-3.5-turbo, or any other OpenAI model. See [here](https://openai.com/product#made-for-developers) to obtain an API key.\n\n> [Reference](https://docs.continue.dev/reference/Model%20Providers/openai)",
|
||||
|
|
@ -227,7 +228,8 @@
|
|||
"### IBM watsonx\nwatsonx, developed by IBM, offers a variety of pre-trained AI foundation models that can be used for natural language processing (NLP), computer vision, and speech recognition tasks.",
|
||||
"### OpenRouter\nOpenRouter offers a single API to access almost any language model. To get started, obtain an API key from [their console](https://openrouter.ai/settings/keys).",
|
||||
"### NVIDIA NIMs\nNVIDIA offers a single API to access almost any language model. To find out more, visit the [LLM APIs Documentation](https://docs.api.nvidia.com/nim/reference/llm-apis).\nFor information specific to getting a key, please check out the [docs here](https://docs.nvidia.com/nim/large-language-models/latest/getting-started.html#option-1-from-api-catalog)",
|
||||
"### vLLM\nvLLM is a highly performant way of hosting LLMs for a team. To get started, follow their [quickstart](https://docs.vllm.ai/en/latest/getting_started/quickstart.html) to set up your server."
|
||||
"### vLLM\nvLLM is a highly performant way of hosting LLMs for a team. To get started, follow their [quickstart](https://docs.vllm.ai/en/latest/getting_started/quickstart.html) to set up your server.",
|
||||
"### Cerebras\nCerebras Inference uses specialized silicon to provides superfast inference. To get started, get your API keys from [their console](https://cloud.cerebras.ai/)."
|
||||
],
|
||||
"type": "string"
|
||||
},
|
||||
|
|
@ -1265,6 +1267,30 @@
|
|||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": {
|
||||
"properties": {
|
||||
"provider": {
|
||||
"enum": [
|
||||
"cerebras"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"provider"
|
||||
]
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"model": {
|
||||
"enum": [
|
||||
"llama3.1-8b",
|
||||
"llama3.1-70b"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": {
|
||||
"properties": {
|
||||
|
|
|
|||
BIN
gui/public/logos/cerebras.png
Normal file
BIN
gui/public/logos/cerebras.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.9 KiB |
|
|
@ -68,6 +68,7 @@ export const models: { [key: string]: ModelPackage } = {
|
|||
"llama.cpp",
|
||||
"replicate",
|
||||
"sambanova",
|
||||
"cerebras",
|
||||
],
|
||||
isOpenSource: true,
|
||||
},
|
||||
|
|
|
|||
|
|
@ -595,4 +595,35 @@ To get started, [register](https://dataplatform.cloud.ibm.com/registration/stepo
|
|||
}),
|
||||
apiKeyUrl: "https://cloud.sambanova.ai/apis",
|
||||
},
|
||||
cerebras: {
|
||||
title: "Cerebras",
|
||||
provider: "cerebras",
|
||||
icon: "cerebras.png",
|
||||
description:
|
||||
"Cerebras Inference is a custom silicon for fast inference of LLM models.",
|
||||
longDescription:
|
||||
"Get your API key [here](https://cloud.cerebras.ai/).",
|
||||
tags: [ModelProviderTags.RequiresApiKey, ModelProviderTags.OpenSource],
|
||||
collectInputFor: [
|
||||
{
|
||||
inputType: "text",
|
||||
key: "apiKey",
|
||||
label: "API Key",
|
||||
placeholder: "Enter your Cerebras API key",
|
||||
required: true,
|
||||
},
|
||||
],
|
||||
packages: [
|
||||
models.llama3170bChat,
|
||||
models.llama318bChat,
|
||||
{
|
||||
...models.AUTODETECT,
|
||||
params: {
|
||||
...models.AUTODETECT.params,
|
||||
title: "Cerebras",
|
||||
},
|
||||
},
|
||||
],
|
||||
apiKeyUrl: "https://cloud.cerebras.ai/",
|
||||
},
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue