forked from google/minja
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtool_use.json
167 lines (167 loc) · 3.83 KB
/
tool_use.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
{
"messages": [
{
"role": "user",
"content": "Print a hello world message with python."
},
{
"role": "assistant",
"content": "",
"tool_calls": [
{
"id": "call_1___",
"type": "function",
"function": {
"arguments": "{\"code\": \"print('Hello, World!')\"}",
"name": "ipython"
}
}
]
},
{
"role": "tool",
"tool_call_id": "call_1___",
"name": "ipython",
"content": "{\"stdout\": \"Hello, World!\"}"
},
{
"role": "assistant",
"content": "Anything else?"
},
{
"role": "user",
"content": "Test a tautology."
},
{
"role": "assistant",
"content": "",
"tool_calls": [
{
"id": "call_2___",
"type": "function",
"function": {
"arguments": "{\"condition\":true}",
"name": "test"
}
}
]
},
{
"role": "tool",
"tool_call_id": "call_2___",
"name": "test",
"content": "true"
},
{
"role": "assistant",
"content": "Truth is definitely true."
},
{
"role": "user",
"content": "Check it on the web."
},
{
"role": "assistant",
"content": "",
"tool_calls": [
{
"id": "call_3___",
"type": "function",
"function": {
"arguments": "{\"query\": \"what is truth anyway am I right?\"}",
"name": "brave_search"
}
}
]
},
{
"role": "tool",
"tool_call_id": "call_3___",
"name": "brave_search",
"content": "{\"title\":\"Truth: don't ask the web, ask an LLM instead!\",\"url\":\"https://en.wikipedia.org/wiki/Truth\"}"
},
{
"role": "assistant",
"content": "I don't need the web to answer you but I did check, as you asked. What now?"
}
],
"add_generation_prompt": true,
"bos_token": "<|startoftext|>",
"eos_token": "<|endoftext|>",
"builtin_tools": [
"wolfram_alpha",
"brave_search"
],
"cutting_knowledge_date": "2023-04-01",
"todays_date": "2024-09-03",
"tools": [
{
"type": "function",
"function": {
"name": "ipython",
"description": "Runs code in an ipython interpreter and returns the result of the execution after 60 seconds.",
"parameters": {
"type": "object",
"properties": {
"code": {
"type": "string",
"description": "The code to run in the ipython interpreter."
}
},
"required": ["code"]
}
}
},
{
"type": "function",
"function": {
"name": "brave_search",
"description": "Executes a web search with Brave.",
"parameters": {
"type": "object",
"properties": {
"query": {
"type": "string",
"description": "The query to search for."
}
},
"required": ["query"]
}
}
},
{
"type": "function",
"function": {
"name": "wolfram_alpha",
"description": "Executes a query with Wolfram Alpha.",
"parameters": {
"type": "object",
"properties": {
"query": {
"type": "string",
"description": "The query to execute."
}
},
"required": ["query"]
}
}
},
{
"type": "function",
"function": {
"name": "test",
"description": "Runs a test.",
"parameters": {
"type": "object",
"properties": {
"condition": {
"type": "boolean",
"description": "The condition to test."
}
},
"required": ["condition"]
}
}
}
]
}