File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -96,10 +96,12 @@ def execute(self, state: dict) -> dict:
9696 base_url = f"{ parsed_url .scheme } ://{ parsed_url .netloc } "
9797 loader = AsyncChromiumLoader (f"{ base_url } /robots.txt" )
9898 document = loader .load ()
99- if "ollama" in self .llm_model .model_name :
99+ if hasattr ( self . llm_model , "model_name" ) and "ollama" in self .llm_model .model_name :
100100 self .llm_model .model_name = self .llm_model .model_name .split ("/" )[- 1 ]
101101 model = self .llm_model .model_name .split ("/" )[- 1 ]
102-
102+ elif hasattr (self .llm_model , "model_id" ): # Bedrock uses model IDs, not model names
103+ self .llm_model .model_name = self .llm_model .model_id .split ("/" )[- 1 ]
104+ model = self .llm_model .model_name
103105 else :
104106 model = self .llm_model .model_name
105107 try :
You can’t perform that action at this time.
0 commit comments