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:
96
96
base_url = f"{ parsed_url .scheme } ://{ parsed_url .netloc } "
97
97
loader = AsyncChromiumLoader (f"{ base_url } /robots.txt" )
98
98
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 :
100
100
self .llm_model .model_name = self .llm_model .model_name .split ("/" )[- 1 ]
101
101
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
103
105
else :
104
106
model = self .llm_model .model_name
105
107
try :
You can’t perform that action at this time.
0 commit comments