Run model downloads and split conversations independently
This commit is contained in:
@@ -348,6 +348,11 @@ final class StudioModel: ObservableObject {
|
||||
|
||||
func removeToolAttachment() { toolAttachment = nil }
|
||||
|
||||
func copyInferenceCredentials(from source: StudioModel) {
|
||||
setOllamaToken(source.ollamaToken, endpoint: source.tokenEndpoint)
|
||||
setCompatibleToken(source.compatibleToken, endpoint: source.compatibleTokenEndpoint)
|
||||
}
|
||||
|
||||
func setOllamaToken(_ token: String, endpoint: String) {
|
||||
tokenEndpoint = endpoint
|
||||
ollamaToken = token
|
||||
@@ -362,7 +367,7 @@ final class StudioModel: ObservableObject {
|
||||
try CompatibleEndpoint(endpoint: endpoint, token: endpoint == compatibleTokenEndpoint ? compatibleToken : "")
|
||||
}
|
||||
|
||||
private func ollamaClient(endpoint: String) throws -> Ollama {
|
||||
func ollamaClient(endpoint: String) throws -> Ollama {
|
||||
try Ollama(endpoint: endpoint, token: endpoint == tokenEndpoint ? ollamaToken : "")
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user