Skip to content

Commit fec9d65

Browse files
committed
feat(examples): add repeatQiz test case
1 parent 93caa13 commit fec9d65

File tree

4 files changed

+105
-2
lines changed

4 files changed

+105
-2
lines changed

README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ $ npm install -g @offline-ai/cli
183183
$ ai COMMAND
184184
running command...
185185
$ ai (--version)
186-
@offline-ai/cli/0.5.9 linux-x64 node-v20.17.0
186+
@offline-ai/cli/0.5.10 linux-x64 node-v20.17.0
187187
$ ai --help [COMMAND]
188188
USAGE
189189
$ ai COMMAND
@@ -413,7 +413,7 @@ EXAMPLES
413413
$ ai agent publish <agent-name>
414414
```
415415

416-
_See code: [src/commands/agent/index.ts](https://github.com/offline-ai/cli/blob/v0.5.9/src/commands/agent/index.ts)_
416+
_See code: [src/commands/agent/index.ts](https://github.com/offline-ai/cli/blob/v0.5.10/src/commands/agent/index.ts)_
417417

418418
## `ai autocomplete [SHELL]`
419419

examples/repeatQiz/repeatQiz.ai.yaml

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
---
2+
input:
3+
- content: {required: true}
4+
- language
5+
- suffix
6+
- assistant_prefix
7+
parameters:
8+
temperature: 0.01
9+
---
10+
# 你是一名最佳数学问题解决专家,善于仔细分解问题一步一步思考,轻松解决各类数学难题。
11+
system: |-
12+
You are an expert in solving math problems. You are good at breaking down problems carefully according to all conditions, and you can easily solve various math problems.
13+
user: |-
14+
{{content}}
15+
Read the question again: {{content}}
16+
{%if language%}
17+
Please answer in {{language}}
18+
{%endif%}
19+
assistant: "{{prefix}}[[thinking]]"
+64
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
- input:
2+
content: |-
3+
蒂姆获得晋升,月薪 20000 美元的基础上加薪 5%。还给了他相当于半个月工资的奖金。他一年能赚多少钱?最后回答:"The Answer is number."
4+
language: 中文
5+
output: !re /The Answer is 262500[.。*]*$/
6+
- input:
7+
content: >-
8+
科尔比喜欢看电影,他的父母每个月都会给他 150 美元用于看电影。周五和周六的电影票价格为 10 美元。其他任何一天的电影
9+
票价格为 7 美元。爆米花售价 8 美元,盒装糖果售价 2 美元。如果他已经在周五或周六看了 5 部电影,其他日子看了 8 部电影,已经吃了 2 桶爆米花和 4 盒糖果,今天是这个月的最后一天,也是星期五,他想确保今天晚上他还能买
10+
到一桶爆米花和一盒糖果后,他还能看多少部电影? 最后在文末输出: "The Answer is number."
11+
language: 中文
12+
output: !re /The Answer is 1[.。*]*$/
13+
- input:
14+
content: |-
15+
Colby loves going to the movies and every month his parents give him $150 to spend at the movies. Tickets for Fridays and
16+
Saturdays cost $10. Tickets for any other day cost $7. Popcorn costs $8 and boxes of candy cost $2. It is the last day of the
17+
month and it's a Friday. He wants to make sure he gets a popcorn and box of candy that night. How many movies can he see if
18+
he already saw 5 movies on a Friday or Saturday, 8 movies on other days, had 2 tubs of popcorn, and four boxes of candy that
19+
month?
20+
Think it carefully. At last output the answer: "The Answer is number."
21+
# prefix: "Let's break it down carefully one by one:"
22+
output: !re /The Answer is 1[.。*]*$/
23+
- input:
24+
content: >-
25+
Mike was a pen pal with 5 people. He stopped being penpals with 2 of them. They each send 2 letters a week that are 5 pages
26+
long. He responds in kind. He can write a page every 6 minutes. How many hours does he spend writing a week?
27+
At last output the answer: "The Answer is number."
28+
output: !re /The Answer is 3[.。*]*$/
29+
- input:
30+
content: |-
31+
Terri is knitting a sweater with two sleeves, a collar, and a decorative rosette. The body of the sweater takes 900 stitches to
32+
complete, the collar takes a tenth of that number of stitches, and the rosette takes twice as many as the collar. The whole sweater
33+
is an 1800-stitch project. How many stitches does each sleeve take?
34+
At last output the answer: "The Answer is number."
35+
output: !re /The Answer is 315[.。*'"]*$/
36+
- input:
37+
content: |-
38+
Would a nickel fit inside a koala pouch?
39+
At last output the answer: "The Answer is yes/no."
40+
output: !re /The Answer is yes[.。*]*$/i
41+
skip: true
42+
- input:
43+
content: 一枚硬币正面朝上。汉克没有翻转硬币。珍妮没有翻转硬币。弗兰基翻转了硬币。伊莎翻转了硬币。硬币还是正面吗?最后回答true或false。
44+
language: 中文
45+
output: !re /true/
46+
- input:
47+
content: |-
48+
Yesterday was April 30, 2021. What is the date tomorrow in MM/DD/YYYY?
49+
At last output the answer: "The Answer is MM/DD/YYYY."
50+
output: !re /The Answer is 05\/02\/2021[.。*]*$/i
51+
skip: true
52+
- input:
53+
content: |-
54+
Ned had to wash 9 short sleeve shirts and 21 long sleeve shirts before school. If he had only washed 29 of them by the time school started, how many did he not wash?
55+
At last output the answer: "The Answer is number."
56+
output: !re /The Answer is 1[.。*]*$/i
57+
skip: true
58+
- input:
59+
content: |-
60+
A trader sold an article at a profit of 20% for Rs.360. What is the cost price of the article?
61+
Answer Choices: A) 270, B) 300, C) 280, D) 320, E) 315
62+
At last output the answer: "My choice is A/B/C/D/E."
63+
output: !re /My choice is [*]*B[.。*]*$/i
64+
skip: true
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
---
2+
input:
3+
- content: {required: true}
4+
- language
5+
- suffix
6+
- assistant_prefix
7+
parameters:
8+
temperature: 0.01
9+
test:
10+
# only: true
11+
---
12+
# 你是一名最佳数学问题解决专家,善于仔细分解问题一步一步思考,轻松解决各类数学难题。
13+
system: |-
14+
You are an expert in solving math problems. You are good at breaking down problems carefully according to all conditions, and you can easily solve various math problems.
15+
user: |-
16+
{{content}}
17+
{%if language%}
18+
Please answer in {{language}}
19+
{%endif%}
20+
assistant: "{{prefix}}[[thinking]]"

0 commit comments

Comments
 (0)