Skip to content

Commit 3e46f8e

Browse files
authored
Merge pull request #305 from zjffdu/minor_fix
[MINOR] Doc fix
2 parents 4e36e14 + 53e5e24 commit 3e46f8e

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

docs/source/tutorials/tool_helper.rst

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -510,8 +510,8 @@ We will use :class:`components.output_parsers.outputs.JsonOutputParser` to strea
510510
511511
from adalflow.components.output_parsers import JsonOutputParser
512512
513-
func_parser = JsonOutputParser(data_class=Function)
514-
instructions = func_parser.format_instructions(exclude=["thought", "args"])
513+
func_parser = JsonOutputParser(data_class=Function, exclude_fields=["thought", "args"])
514+
instructions = func_parser.format_instructions()
515515
print(instructions)
516516
517517
The output is:
@@ -542,9 +542,7 @@ Now, let's prepare our generator with the above prompt, ``Function`` data class,
542542
model_kwargs = {"model": "gpt-3.5-turbo"}
543543
prompt_kwargs = {
544544
"tools": tool_manager.yaml_definitions,
545-
"output_format_str": func_parser.format_instructions(
546-
exclude=["thought", "args"]
547-
),
545+
"output_format_str": func_parser.format_instructions(),
548546
}
549547
generator = Generator(
550548
model_client=ModelClientType.OPENAI(),

0 commit comments

Comments
 (0)