File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -85,15 +85,15 @@ def initialize_google(self):
8585 def initialize_ollama (self ):
8686 if self .ollama_host :
8787 if self .verbose :
88- print ("[Config][initialize_ollama] using cached ollama host" )
88+ print ("[Config][initialize_ollama] using ollama host" , self . ollama_host )
8989 else :
9090 if self .verbose :
9191 print (
9292 "[Config][initialize_ollama] no cached ollama host. Assuming ollama running locally."
9393 )
94- self .ollama_host = os .getenv ("OLLAMA_HOST" , None )
95- model = Client (host = self .ollama_host )
96- return model
94+ self .ollama_host = os .getenv ("OLLAMA_HOST" , "http://localhost:11434" )
95+ client = Client (host = self .ollama_host )
96+ return client
9797
9898 def initialize_anthropic (self ):
9999 if self .anthropic_api_key :
Original file line number Diff line number Diff line change @@ -563,7 +563,7 @@ def call_ollama_llava(messages):
563563 print ("[call_ollama_llava]" )
564564 time .sleep (1 )
565565 try :
566- model = config .initialize_ollama ()
566+ client = config .initialize_ollama ()
567567 screenshots_dir = "screenshots"
568568 if not os .path .exists (screenshots_dir ):
569569 os .makedirs (screenshots_dir )
@@ -590,7 +590,7 @@ def call_ollama_llava(messages):
590590 }
591591 messages .append (vision_message )
592592
593- response = model .chat (
593+ response = client .chat (
594594 model = "llava" ,
595595 messages = messages ,
596596 )
You can’t perform that action at this time.
0 commit comments