feat: Add LlamaFile support

Add support for LlamaFile, a new model provider that allows users to interact with models stored in LlamaFile format. This includes:

- Adding an icon for LlamaFile in the provider selection menu.
- Updating the model provider selection to include LlamaFile.
- Updating the model handling logic to properly identify and process LlamaFile models.
- Updating the API providers list to include LlamaFile.

This enables users to leverage the capabilities of LlamaFile models within the application.
This commit is contained in:
n4ze3m
2024-11-10 14:02:44 +05:30
parent f52e3d564a
commit c6a62126dd
5 changed files with 117 additions and 2 deletions

View File

@@ -47,7 +47,8 @@ export const OpenAIApp = () => {
})
setOpen(false)
message.success(t("addSuccess"))
if (provider !== "lmstudio") {
const noPopupProvider = ["lmstudio", "llamafile"]
if (!noPopupProvider.includes(provider)) {
setOpenaiId(data)
setOpenModelModal(true)
}