Add @langchain/core dependency and update imports***

***Update SidepanelRouting to use dark mode***
***Add image support to PlaygroundMessage component
This commit is contained in:
n4ze3m
2024-02-03 17:51:11 +05:30
parent e6130f11da
commit be3a4ed256
13 changed files with 294 additions and 57 deletions

View File

@@ -68,11 +68,18 @@ export const fetchModels = async () => {
}
export const setOllamaURL = async (ollamaURL: string) => {
await chromeRunTime(cleanUrl(ollamaURL))
await storage.set("ollamaURL", cleanUrl(ollamaURL))
let formattedUrl = ollamaURL
if (formattedUrl.startsWith("http://localhost:")) {
formattedUrl = formattedUrl.replace(
"http://localhost:",
"http://127.0.0.1:"
)
}
await chromeRunTime(cleanUrl(formattedUrl))
await storage.set("ollamaURL", cleanUrl(formattedUrl))
}
export const systemPromptForNonRag = async () => {
const prompt = await storage.get("systemPromptForNonRag")
return prompt
}
}