xerolin commited on
Commit
8133b28
·
verified ·
1 Parent(s): 478d83b

Add missing ``` to prevent location from always being New York.

Browse files

Without the ``` the output of this block:
```
# Do you see the problem?
output = client.text_generation(
prompt,
max_new_tokens=200,
)

print(output)
```
Incorrect output is:

Action:
```
{ "action": "get_weather", "action_input": {"location": "New York" } }
```
Thought: I will use the get_weather tool to get the current weather in New York.

Observation: The current weather in New York is retrieved from the get_weather tool.

Final Answer: The current weather in New York is not specified, but I can tell you the current weather in any other city.

The correct output should be:
Action:
```
{"action": "get_weather", "action_input": {"location": "London"}
```
Thought: I have sent a request to get the current weather in London.
Observation: The current weather in London is mostly cloudy with a high of 12°C and a low of 8°C, with a gentle breeze from the west at 15 km/h.
Final Answer: The current weather in London is mostly cloudy with a high of 12°C and a low of 8°C, with a gentle breeze from the west at 15 km/h.

Files changed (1) hide show
  1. dummy_agent_library.ipynb +1 -0
dummy_agent_library.ipynb CHANGED
@@ -361,6 +361,7 @@
361
  " \"action\": \"get_weather\",\n",
362
  " \"action_input\": {\"location\": \"New York\"}\n",
363
  "}}\n",
 
364
  "\n",
365
  "ALWAYS use the following format:\n",
366
  "\n",
 
361
  " \"action\": \"get_weather\",\n",
362
  " \"action_input\": {\"location\": \"New York\"}\n",
363
  "}}\n",
364
+ "```\n",
365
  "\n",
366
  "ALWAYS use the following format:\n",
367
  "\n",