Skip to content

Instantly share code, notes, and snippets.

@milad621
Created January 23, 2024 21:51
Show Gist options
  • Save milad621/be91085148455d1d2a81505f8b29315d to your computer and use it in GitHub Desktop.
Save milad621/be91085148455d1d2a81505f8b29315d to your computer and use it in GitHub Desktop.
Toollama train examples
{
"id": "Step 2: I'm organizing a team-building event for my company and I want to start it off with some lighthearted jokes. Can you fetch jokes from the Jokester API and categorize them as 'team-building' and 'fun'? Also, it would be great if you could provide me with some motivational quotes from the mydailyinspiration API to inspire my team.",
"conversations": [
{
"from": "system",
"value": "You are AutoGPT, you can use many tools(functions) to do the following task.\nFirst I will give you the task description, and your task start.\nAt each step, you need to give your thought to analyze the status now and what to do next, with a function call to actually excute your step. Your output should follow this format:\nThought:\nAction\nAction Input:\n\nAfter the call, you will get the call result, and you are now in a new state.\nThen you will analyze your status now, then decide what to do next...\nAfter many (Thought-call) pairs, you finally perform the task, then you can give your finial answer.\nRemember: \n1.the state change is irreversible, you can't go back to one of the former state, if you want to restart the task, say \"I give up and restart\".\n2.All the thought is short, at most in 5 sentence.\n3.You can do more then one trys, so if your plan is to continusly try some conditions, you can do one of the conditions per try.\nLet's Begin!\nTask description: You should use functions to help handle the real time user querys. Remember:\n1.ALWAYS call \"Finish\" function at the end of the task. And the final answer should contain enough information to show to the user,If you can't handle the task, or you find that function calls always fail(the function is not valid now), use function Finish->give_up_and_restart.\n2.Do not use origin tool names, use only subfunctions' names.\nYou have access of the following tools:\n1.jokester: Your Source for Endless Laughter - Jokester API is your go-to source for hilarious jokes and puns.\n2.mydailyinspiration: Sync API for the My Daily Inspiration App\n\nSpecifically, you have access to the following APIs: [{'name': 'jokes_categories_for_jokester', 'description': 'This is the subfunction for tool \"jokester\", you can use this tool.', 'parameters': {'type': 'object', 'properties': {}, 'required': [], 'optional': []}}, {'name': 'jokes_for_jokester', 'description': 'This is the subfunction for tool \"jokester\", you can use this tool.', 'parameters': {'type': 'object', 'properties': {}, 'required': [], 'optional': []}}, {'name': 'helloworld_for_mydailyinspiration', 'description': 'This is the subfunction for tool \"mydailyinspiration\", you can use this tool.The description of this function is: \"Test the API\"', 'parameters': {'type': 'object', 'properties': {}, 'required': [], 'optional': []}}, {'name': 'Finish', 'description': \"If you think you get the result which can answer the task, call this function to give the final answer. Or, if you think you can't handle the task from this status, call this function to restart. Remember: you should ALWAYS call this function at the end of your try, and the final answer is the ONLY part that will be showed to user, so final answer should contain enough information.\", 'parameters': {'type': 'object', 'properties': {'return_type': {'type': 'string', 'enum': ['give_answer', 'give_up_and_restart']}, 'final_answer': {'type': 'string', 'description': 'The final answer you want to give the user. You should have this field if \"return_type\"==\"give_answer\"'}}, 'required': ['return_type']}}]"
},
{
"from": "user",
"value": "\nI'm organizing a team-building event for my company and I want to start it off with some lighthearted jokes. Can you fetch jokes from the Jokester API and categorize them as 'team-building' and 'fun'? Also, it would be great if you could provide me with some motivational quotes from the mydailyinspiration API to inspire my team.\nBegin!\n"
},
{
"from": "assistant",
"value": "\nThought: \nAction: jokes_categories_for_jokester\nAction Input: {}"
}
]
},
{
"id": "Step 3: I'm planning a vacation to a foreign country and I need to know the current exchange rates. Can you provide me with the live currency conversion rates for the currencies I'll be using? Also, suggest some local hotels in that country for accommodation.",
"conversations": [
{
"from": "system",
"value": "You are AutoGPT, you can use many tools(functions) to do the following task.\nFirst I will give you the task description, and your task start.\nAt each step, you need to give your thought to analyze the status now and what to do next, with a function call to actually excute your step. Your output should follow this format:\nThought:\nAction\nAction Input:\n\nAfter the call, you will get the call result, and you are now in a new state.\nThen you will analyze your status now, then decide what to do next...\nAfter many (Thought-call) pairs, you finally perform the task, then you can give your finial answer.\nRemember: \n1.the state change is irreversible, you can't go back to one of the former state, if you want to restart the task, say \"I give up and restart\".\n2.All the thought is short, at most in 5 sentence.\n3.You can do more then one trys, so if your plan is to continusly try some conditions, you can do one of the conditions per try.\nLet's Begin!\nTask description: You should use functions to help handle the real time user querys. Remember:\n1.ALWAYS call \"Finish\" function at the end of the task. And the final answer should contain enough information to show to the user,If you can't handle the task, or you find that function calls always fail(the function is not valid now), use function Finish->give_up_and_restart.\n2.Do not use origin tool names, use only subfunctions' names.\nYou have access of the following tools:\n1.trading_view: This API helps you to query for data which is obtained by professional providers who have direct and extensive access to stock quotes, futures, popular indices, Forex, Bitcoin and CFDs to create a financial community site/application, such as : tradingview.com\n2.global_ethereum_price_index_gex: Ethereum Price Index supplied by BitcoinAverage\r\rThe GEX data accessed via the BitcoinAverage API features:\r\rUp to 1 second refresh rate\rRates for 165+ currencies\rDaily rates at preferred lock in time or live rates\rHistoric daily rates dating back to 2010\rJSON or CSV formats\r\r-------\r\rAbout BitcoinAverage\r\rBitcoinAverage.com is proud of the fact that we were the first global price index in the cryptocurrency and blockchain industry, and have proven over the years to also be one of the most rel\n3.currencyapi_net: Real-time currency conversion on 152 currencies and cryptos\n\nSpecifically, you have access to the following APIs: [{'name': 'calendars_get_economic_calendar_for_trading_view', 'description': 'This is the subfunction for tool \"trading_view\", you can use this tool.The description of this function is: \"Get economic calendar by specific date range and countries\"', 'parameters': {'type': 'object', 'properties': {'is_from': {'type': 'string', 'description': 'The date format is yyyy-MM-dd. Ex : 2022-08-21'}, 'to': {'type': 'string', 'description': 'The date format is yyyy-MM-dd. Ex : 2022-09-05'}, 'minimportance': {'type': 'integer', 'description': 'One of the following : -1|0|1'}, 'lang': {'type': 'string', 'description': 'The language code', 'example_value': 'en'}, 'countries': {'type': 'string', 'description': 'One of the following : US|EU|JP|AU|DE|GB|CA|FR|IT|NZ|ES|MX|CH|TR|ZA. Separated by comma for multiple options', 'example_value': 'US,EU,JP,AU,DE,GB,CA,FR,IT,NZ,ES,MX,CH,TR,ZA'}}, 'required': ['is_from', 'to'], 'optional': ['minimportance', 'lang', 'countries']}}, {'name': 'ideas_get_comments_for_trading_view', 'description': 'This is the subfunction for tool \"trading_view\", you can use this tool.The description of this function is: \"Get comments relating to an ideal post\"', 'parameters': {'type': 'object', 'properties': {'uuid': {'type': 'string', 'description': 'The value of image_url field returned in .../ideas/list endpoint', 'example_value': 'CRK6Iv51'}, 'lang': {'type': 'string', 'description': 'The language code', 'example_value': 'en'}}, 'required': ['uuid'], 'optional': ['lang']}}, {'name': 'ideas_get_view_count_for_trading_view', 'description': 'This is the subfunction for tool \"trading_view\", you can use this tool.The description of this function is: \"Get view count related to an ideal post\"', 'parameters': {'type': 'object', 'properties': {'uuid': {'type': 'string', 'description': 'The value of image_url field returned in .../ideas/list endpoint', 'example_value': 'CRK6Iv51'}, 'lang': {'type': 'string', 'description': 'The language code', 'example_value': 'en'}}, 'required': ['uuid'], 'optional': ['lang']}}, {'name': 'custom_ticker_for_global_ethereum_price_index_gex', 'description': 'This is the subfunction for tool \"global_ethereum_price_index_gex\", you can use this tool.The description of this function is: \"This endpoint can be used to generate a custom index in a certain currency. The \u201cinex\u201d path parameter represents \u201cinclude\u201d or \u201cexclude\u201d, you can choose to generate an index removing specified exchanges, or only including the few that you require.\"', 'parameters': {'type': 'object', 'properties': {'inex': {'type': 'string', 'description': 'include - if you want the ticker to be calculated using only the exchanges sent as query parameter; exclude - if you want the price to be calculated using all exchanges, but the ones sent as query parameter.', 'example_value': 'include'}, 'symbol': {'type': 'string', 'description': 'ETH<fiat> where <fiat> is valid ISO currency (ex. ETHUSD)', 'example_value': 'ETHUSD'}, 'exchanges': {'type': 'string', 'description': 'Comma separated list of exchanges.', 'example_value': 'bitfinex,bitstamp'}}, 'required': ['inex', 'symbol'], 'optional': ['exchanges']}}, {'name': 'all_ticker_data_for_global_ethereum_price_index_gex', 'description': 'This is the subfunction for tool \"global_ethereum_price_index_gex\", you can use this tool.The description of this function is: \"If no query parameters are sent, then returns ticker data for every supported symbol. If fiat(s) are sent as parameters, then only the ticker for those values is sent.\"', 'parameters': {'type': 'object', 'properties': {'market': {'type': 'string', 'description': 'Possible values: global, local', 'example_value': 'local'}, 'crypto': {'type': 'string', 'description': 'valid value: ETH', 'example_value': 'ETH'}, 'fiat': {'type': 'string', 'description': 'Comma separated list of ISO currency codes (ex. USD,EUR)', 'example_value': 'USD,EUR'}}, 'required': ['market'], 'optional': ['crypto', 'fiat']}}, {'name': 'ticker_per_symbol_for_global_ethereum_price_index_gex', 'description': 'This is the subfunction for tool \"global_ethereum_price_index_gex\", you can use this tool.The description of this function is: \"Returns ticker data for specified symbol\"', 'parameters': {'type': 'object', 'properties': {'market': {'type': 'string', 'description': 'Possible values: global, local', 'example_value': 'global'}, 'symbol': {'type': 'string', 'description': 'ETH<fiat>, where <fiat> is valid ISO currency (ex. ETHUSD, ETHEUR)', 'example_value': 'ETHUSD'}}, 'required': ['market', 'symbol'], 'optional': []}}, {'name': 'rates_for_currencyapi_net', 'description': 'This is the subfunction for tool \"currencyapi_net\", you can use this tool.The description of this function is: \"Get live currency conversion rates of a given currency\"', 'parameters': {'type': 'object', 'properties': {}, 'required': [], 'optional': []}}, {'name': 'convert_for_currencyapi_net', 'description': 'This is the subfunction for tool \"currencyapi_net\", you can use this tool.The description of this function is: \"convert_for_currencyapi_net a custom amount value from one currency to another\"', 'parameters': {'type': 'object', 'properties': {'to': {'type': 'string', 'description': 'Currency code of the currency you want to convert to. Eg, USD if you want to convert GBP to USD'}, 'amount': {'type': 'string', 'description': 'The value you want to convert. Eg 10.99 or 15'}, 'is_from': {'type': 'string', 'description': 'Currency code of the currency you want to convert from. Eg, GBP if you want to convert GBP to USD'}, 'output': {'type': 'string', 'description': 'The output of the response. Either JSON or XML', 'example_value': 'JSON'}}, 'required': ['to', 'amount', 'is_from'], 'optional': ['output']}}, {'name': 'timeframe_for_currencyapi_net', 'description': 'This is the subfunction for tool \"currencyapi_net\", you can use this tool.The description of this function is: \"Display a currency conversion\\'s historical rates within a given timeframe\"', 'parameters': {'type': 'object', 'properties': {'end_date': {'type': 'string', 'description': 'Display the start date you wish to get the historical data from. Eg 2010-12-29'}, 'base': {'type': 'string', 'description': 'The currency code you want to get the historical data of. Eg, USD', 'example_value': 'USD'}, 'start_date': {'type': 'string', 'description': 'Display the start date you wish to get the historical data from. Eg 2010-12-25'}, 'output': {'type': 'string', 'description': 'The output of the response. Either JSON or XML', 'example_value': 'JSON'}}, 'required': ['end_date', 'base', 'start_date'], 'optional': ['output']}}, {'name': 'Finish', 'description': 'If you believe that you have obtained a result that can answer the task, please call this function to provide the final answer. Alternatively, if you recognize that you are unable to proceed with the task in the current state, call this function to restart. Remember: you must ALWAYS call this function at the end of your attempt, and the only part that will be shown to the user is the final answer, so it should contain sufficient information.', 'parameters': {'type': 'object', 'properties': {'return_type': {'type': 'string', 'enum': ['give_answer', 'give_up_and_restart']}, 'final_answer': {'type': 'string', 'description': 'The final answer you want to give the user. You should have this field if \"return_type\"==\"give_answer\"'}}, 'required': ['return_type']}}]"
},
{
"from": "user",
"value": "\nI'm planning a vacation to a foreign country and I need to know the current exchange rates. Can you provide me with the live currency conversion rates for the currencies I'll be using? Also, suggest some local hotels in that country for accommodation.\nBegin!\n"
},
{
"from": "user",
"value": "This is not the first time you try this task, all previous trails failed.\nBefore you generate my thought for this state, I will first show you your previous actions for this state, and then you must generate actions that is different from all of them. Here are some previous actions candidates:\n[\n {\n \"name\": \"rates_for_currencyapi_net\",\n \"arguments\": \"{}\",\n \"function_output\": \"{\\\"error\\\": \\\"\\\", \\\"response\\\": \\\"{'valid': True, 'updated': 1688277605, 'base': 'USD', 'rates': {'AED': 3.67321, 'AFN': 87.505, 'ALL': 97.37985, 'AMD': 386.0795, 'ANG': 1.80253, 'AOA': 825.54, 'ARS': 256.46753, 'AUD': 1.50093, 'AWG': 1.80259, 'AZN': 1.7, 'BAM': 1.80224, 'BBD': 2.01934, 'BCH': 0.0033262926804929565, 'BDT': 108.19151, 'BGN': 1.79264, 'BHD': 0.37664, 'BIF': 2842.15, 'BMD': 1, 'BND': 1.35688, 'BOB': 6.9112, 'BRL': 4.79004, 'BSD': 1.00009, 'BTC': 3.282655694718273e-05, 'BTG': 0.06230529595015576, 'BWP': 13.57058, 'BZD': 2.01593, 'CAD': 1.32428, 'CDF': 2410.1, 'CHF': 0.8945, 'CLP': 802.22, 'CNH': 7.26778, 'CNY': 7.2656, 'COP': 4168.2, 'CRC': 542.94355, 'CUC': 1, 'CUP': 25.75, 'CVE': 101.38005, 'CZK': 21.77669, 'DASH': 0.027122321670735017, 'DJF': 177.729, 'DKK': 6.8216, 'DOP': 55.353, 'DZD': 135.8158, 'EGP': 30.86895, 'EOS': 1.335113484646195, 'ETB': 54.605, 'ETH': 0.0005190491020450534, 'EUR': 0.9161, 'FJD': 2.22781, 'GBP': 0.78704, 'GEL': 2.61, 'GHS': 11.4505, 'GIP': 0.78704, 'GMD': 59.553, 'GNF': 8650...\",\n \"mento-carlo-action-value\": 0.0\n }\n]\n\nRemember you are now in the intermediate state of a trail, you will first analyze the now state and previous action candidates, then make actions that is different from all the previous."
},
{
"from": "assistant",
"value": "\nThought: \nAction: convert_for_currencyapi_net\nAction Input: {\n \"to\": \"EUR\",\n \"amount\": \"1\",\n \"is_from\": \"USD\"\n}"
}
]
},
{
"id": "Step 5: I'm a music blogger and I want to write an article about the top labels in the music industry. Can you provide me with the top labels for the current year? It would be great if you could fetch the Luxembourg songs chart and provide me with the genre information for a specific playlist. I'm excited to explore the music scene and share my findings with my readers.",
"conversations": [
{
"from": "system",
"value": "You are AutoGPT, you can use many tools(functions) to do the following task.\nFirst I will give you the task description, and your task start.\nAt each step, you need to give your thought to analyze the status now and what to do next, with a function call to actually excute your step. Your output should follow this format:\nThought:\nAction\nAction Input:\n\nAfter the call, you will get the call result, and you are now in a new state.\nThen you will analyze your status now, then decide what to do next...\nAfter many (Thought-call) pairs, you finally perform the task, then you can give your finial answer.\nRemember: \n1.the state change is irreversible, you can't go back to one of the former state, if you want to restart the task, say \"I give up and restart\".\n2.All the thought is short, at most in 5 sentence.\n3.You can do more then one trys, so if your plan is to continusly try some conditions, you can do one of the conditions per try.\nLet's Begin!\nTask description: You should use functions to help handle the real time user querys. Remember:\n1.ALWAYS call \"Finish\" function at the end of the task. And the final answer should contain enough information to show to the user,If you can't handle the task, or you find that function calls always fail(the function is not valid now), use function Finish->give_up_and_restart.\n2.Do not use origin tool names, use only subfunctions' names.\nYou have access of the following tools:\n1.billboard_api: Providing the Billboard chart rankings and information on titles, artists, lyrics, images, and more.\n2.deezer: Deezer is the No. 1 site for listening to music on demand. Discover more than 30 million tracks, create your own playlists, and share your favourite tracks.\n\nSpecifically, you have access to the following APIs: [{'name': 'top_labels_for_billboard_api', 'description': 'This is the subfunction for tool \"billboard_api\", you can use this tool.The description of this function is: \"Provide the YEAR-END top_labels_for_billboard_api chart information\\n\\nIf `year` is not supplied, will default to last year.\"', 'parameters': {'type': 'object', 'properties': {}, 'required': [], 'optional': []}}, {'name': 'luxembourg_songs_for_billboard_api', 'description': 'This is the subfunction for tool \"billboard_api\", you can use this tool.The description of this function is: \"Provide the luxembourg_songs_for_billboard_api chart information\"', 'parameters': {'type': 'object', 'properties': {'range': {'type': 'string', 'description': '', 'example_value': '1-10'}, 'date': {'type': 'string', 'description': 'date format(YYYY-MM-DD)', 'example_value': '2022-05-07'}}, 'required': ['range', 'date'], 'optional': []}}, {'name': 'bolivia_songs_for_billboard_api', 'description': 'This is the subfunction for tool \"billboard_api\", you can use this tool.The description of this function is: \"Provide the bolivia_songs_for_billboard_api chart information\"', 'parameters': {'type': 'object', 'properties': {'range': {'type': 'string', 'description': '', 'example_value': '1-10'}, 'date': {'type': 'string', 'description': 'date format(YYYY-MM-DD)', 'example_value': '2022-05-07'}}, 'required': ['range', 'date'], 'optional': []}}, {'name': 'comment_for_deezer', 'description': 'This is the subfunction for tool \"deezer\", you can use this tool.The description of this function is: \"A comment object\"', 'parameters': {'type': 'object', 'properties': {'is_id': {'type': 'string', 'description': \"The playlist's Deezer id\"}}, 'required': ['is_id'], 'optional': []}}, {'name': 'genre_for_deezer', 'description': 'This is the subfunction for tool \"deezer\", you can use this tool.The description of this function is: \"A genre object\"', 'parameters': {'type': 'object', 'properties': {'is_id': {'type': 'string', 'description': \"The editorial's Deezer id\"}}, 'required': ['is_id'], 'optional': []}}, {'name': 'infos_for_deezer', 'description': 'This is the subfunction for tool \"deezer\", you can use this tool.The description of this function is: \"Get the infos about the api in the current country\"', 'parameters': {'type': 'object', 'properties': {}, 'required': [], 'optional': []}}, {'name': 'Finish', 'description': 'If you believe that you have obtained a result that can answer the task, please call this function to provide the final answer. Alternatively, if you recognize that you are unable to proceed with the task in the current state, call this function to restart. Remember: you must ALWAYS call this function at the end of your attempt, and the only part that will be shown to the user is the final answer, so it should contain sufficient information.', 'parameters': {'type': 'object', 'properties': {'return_type': {'type': 'string', 'enum': ['give_answer', 'give_up_and_restart']}, 'final_answer': {'type': 'string', 'description': 'The final answer you want to give the user. You should have this field if \"return_type\"==\"give_answer\"'}}, 'required': ['return_type']}}]"
},
{
"from": "user",
"value": "\nI'm a music blogger and I want to write an article about the top labels in the music industry. Can you provide me with the top labels for the current year? It would be great if you could fetch the Luxembourg songs chart and provide me with the genre information for a specific playlist. I'm excited to explore the music scene and share my findings with my readers.\nBegin!\n"
},
{
"from": "user",
"value": "This is not the first time you try this task, all previous trails failed.\nBefore you generate my thought for this state, I will first show you your previous actions for this state, and then you must generate actions that is different from all of them. Here are some previous actions candidates:\n[\n {\n \"name\": \"top_labels_for_billboard_api\",\n \"arguments\": \"{}\",\n \"function_output\": \"{\\\"error\\\": \\\"request invalid, data error. status_code=400\\\", \\\"response\\\": \\\"\\\"}\",\n \"mento-carlo-action-value\": 0.0\n }\n]\n\nRemember you are now in the intermediate state of a trail, you will first analyze the now state and previous action candidates, then make actions that is different from all the previous."
},
{
"from": "assistant",
"value": "\nThought: \nAction: luxembourg_songs_for_billboard_api\nAction Input: {\n \"range\": \"current\",\n \"date\": \"2022-10-31\"\n}"
},
{
"from": "function",
"value": "{\"error\": \"Rate limit error...\", \"response\": \"{'message': 'You have exceeded the MONTHLY quota for Requests on your current plan, BASIC. Upgrade your plan at https://rapidapi.com/LDVIN/api/billboard-api'}\"}"
},
{
"from": "assistant",
"value": "\nThought: \nAction: Finish\nAction Input: {\n \"return_type\": \"give_up_and_restart\"\n}"
}
]
},
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment