mirror of
https://github.com/VinciGit00/Scrapegraph-ai.git
synced 2026-07-04 21:00:36 +08:00
fix: abstract_graph moel token bug
This commit is contained in:
parent
208ab267ce
commit
ce6be37fbc
@ -148,6 +148,10 @@ class AbstractGraph(ABC):
|
||||
|
||||
# If model instance is passed directly instead of the model details
|
||||
if "model_instance" in llm_params:
|
||||
try:
|
||||
self.model_token = llm_params["model_tokens"]
|
||||
except KeyError as exc:
|
||||
raise KeyError("model_tokens not specified") from exc
|
||||
return llm_params["model_instance"]
|
||||
|
||||
# Instantiate the language model based on the model name
|
||||
|
||||
Loading…
Reference in New Issue
Block a user