{"kind":"task","effective_mode":"full","benchmark":{"kind":"benchmark","effective_mode":"full","slug":"bigcodebench","formal_name":"BigCodeBench","introduction":"BigCodeBench poses 1,140 function-level tasks drawn across 139 libraries. It tests whether a model can compose several real APIs correctly rather than write one self-contained function.","introduction_ja":"","introduction_en":"","category":"Category not supplied","task_count":null,"acquisition_status":"Acquisition status not supplied","official_url":"https://bigcode-bench.github.io/","indexing_mode":"index","profile":{"resources":[],"task_format":"","scoring":"","metric":"","size":"","answer_access":"","license":"","citation":"","maintainer":"","released":"","why_hard":"","related":[],"history":"","construction":"","limitations":"","saturation":"","scores":[]}},"task_id":"55f9208b-5c52-587a-9abf-1966f2cdb83e","task_key":"default--v0~2e1~2e0~5fhf--55f9208b-5c52-587a-9abf-1966f2cdb83e","task_revision_id":"1","upstream_id":"","short_description":"BigCodeBench v0.1.0_hf 55f9208b-5c52-587a-9abf-1966f2cdb83e","config":"default","split":"v0.1.0_hf","body":"{\"code_prompt\":\"import requests\\nimport pandas as pd\\ndef task_func(api_url):\\n\",\"complete_prompt\":\"import requests\\nimport pandas as pd\\n\\n\\ndef task_func(api_url):\\n    \\\"\\\"\\\"\\n    Fetches data from a specified API, processes the JSON response, converts it into a pandas DataFrame,\\n    and plots the data using matplotlib.\\n    If the data is empty, no plot is generated. If the API request fails, it raises an HTTPError.\\n    The function also checks if the provided API URL is a string.\\n\\n    Parameters:\\n    - api_url (str): The URL of the API to fetch data from.\\n\\n    Returns:\\n    - DataFrame: A pandas DataFrame with the parsed data from the API.\\n    - Axes or None: A matplotlib Axes object representing the plot of the data, or None if the data is empty.\\n\\n    Raises:\\n    - HTTPError: If the API request fails due to issues like network problems, invalid response, etc.\\n    - TypeError: If the `api_url` is not a string.\\n\\n    Requirements:\\n    - requests\\n    - pandas\\n    - matplotlib.pyplot\\n\\n    Example:\\n    >>> df, plot = task_func(\\\"https://api.example.com/data\\\")\\n    >>> df.head()\\n    >>> if plot:\\n    >>>     plot.show()\\n    \\\"\\\"\\\"\\n\",\"entry_point\":\"task_func\",\"instruct_prompt\":\"Fetches data from a specified API, processes the JSON response, converts it into a pandas DataFrame, and plots the data using matplotlib. If the data is empty, no plot is generated. If the API request fails, it raises an HTTPError. The function also checks if the provided API URL is a string.\\nThe function should raise the exception for: HTTPError: If the API request fails due to issues like network problems, invalid response, etc. TypeError: If the `api_url` is not a string.\\nThe function should output with:\\n    DataFrame: A pandas DataFrame with the parsed data from the API.\\n    Axes or None: A matplotlib Axes object representing the plot of the data, or None if the data is empty.\\nYou should write self-contained code starting with:\\n```\\nimport requests\\nimport pandas as pd\\ndef task_func(api_url):\\n```\",\"libs\":\"['pandas', 'requests']\"}","display_format":"code","language":"","answer_status":"published","assets":[],"source_url":"https://bigcode-bench.github.io/","history":"initial import","indexing_mode":"index","subproblems":[],"grids":[]}