Skip to content

Commit af4400e

Browse files
authored
Skip test of gsm8k-plan and improve 9-react.pdl (#805)
1 parent d6359fc commit af4400e

File tree

2 files changed

+12
-14
lines changed

2 files changed

+12
-14
lines changed

examples/talk/9-react.pdl

Lines changed: 11 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -72,25 +72,22 @@ text:
7272
parameters:
7373
stop_sequences: "\n"
7474
parser: json
75+
- "\nObservation: "
7576
- match: ${ action[0].name }
7677
with:
7778
- case: 'Search'
7879
then:
79-
text:
80-
- "\nObservation: "
81-
- lang: python
82-
code: |
83-
import warnings, wikipedia
84-
warnings.simplefilter("ignore")
85-
try:
86-
result = wikipedia.summary("${ action[0].arguments.topic }")
87-
except wikipedia.WikipediaException as e:
88-
result = str(e)
80+
lang: python
81+
code: |
82+
import warnings, wikipedia
83+
warnings.simplefilter("ignore")
84+
try:
85+
result = wikipedia.summary("${ action[0].arguments.topic }")
86+
except wikipedia.WikipediaException as e:
87+
result = str(e)
8988
- case: 'Calc'
9089
then:
91-
text:
92-
- "\nObservation: "
93-
- lang: python
94-
code: result = ${ action[0].arguments.expr }
90+
lang: python
91+
code: result = ${ action[0].arguments.expr }
9592
- "\n"
9693
until: ${ action[0].name == "Finish" }

tests/test_examples_run.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@
3838
pathlib.Path("examples") / "gsm8k" / "math-python.pdl",
3939
pathlib.Path("examples") / "gsm8k" / "math.pdl",
4040
pathlib.Path("examples") / "gsm8k" / "gsm8.pdl", # TODO: check why
41+
pathlib.Path("examples") / "gsm8k" / "gsm8-plan.pdl", # TODO: check why
4142
pathlib.Path("examples") / "tfidf_rag" / "rag.pdl",
4243
pathlib.Path("examples") / "react" / "react_call.pdl",
4344
pathlib.Path("examples") / "callback" / "repair_prompt.pdl",

0 commit comments

Comments
 (0)