Skip to content

Commit c8d556d

Browse files
committed
feat: fix an if
1 parent 8de720d commit c8d556d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

scrapegraphai/nodes/generate_answer_node.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
from tqdm import tqdm
1313

1414
from ..utils.logging import get_logger
15-
from ..models import Ollama, Groq
15+
from ..models import Ollama, Groq, OpenAI
1616
# Imports from the library
1717
from .base_node import BaseNode
1818
from ..helpers import template_chunks, template_no_chunks, template_merge, template_chunks_with_schema, template_no_chunks_with_schema
@@ -46,7 +46,7 @@ def __init__(
4646
super().__init__(node_name, "node", input, output, 2, node_config)
4747
self.llm_model = node_config["llm_model"]
4848

49-
if isinstance(node_config["llm_model"], Ollama):
49+
if isinstance(node_config["llm_model"], Ollama) or isinstance(node_config["llm_model"], OpenAI):
5050
self.llm_model.format="json"
5151
self.verbose = (
5252
True if node_config is None else node_config.get("verbose", False)

0 commit comments

Comments
 (0)