{"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":"noindex","profile":{"resources":[],"task_format":"","scoring":"","metric":"","size":"","answer_access":"","license":"","citation":"","maintainer":"","released":"","why_hard":"","related":[]}},"task_id":"a10c9e3d-d5b6-5b4c-98ac-306646b8dda5","task_key":"default--v0~2e1~2e0~5fhf--a10c9e3d-d5b6-5b4c-98ac-306646b8dda5","task_revision_id":"2","upstream_id":"","short_description":"BigCodeBench v0.1.0_hf a10c9e3d-d5b6-5b4c-98ac-306646b8dda5","config":"default","split":"v0.1.0_hf","body":"{\"code_prompt\":\"import pandas as pd\\nimport numpy as np\\nDEFAULT_COLUMNS = ['Element', 'Count']\\ndef task_func(elements, include_index=False):\\n\",\"complete_prompt\":\"import pandas as pd\\nimport numpy as np\\n\\nDEFAULT_COLUMNS = ['Element', 'Count']\\n\\n\\ndef task_func(elements, include_index=False):\\n    \\\"\\\"\\\"\\n    Constructs a DataFrame that enumerates the character counts of each string in a provided list of elements. This\\n    function can optionally include an index column for each row in the DataFrame.\\n\\n    Parameters:\\n    elements (List[str]): A list of strings whose character counts are to be calculated.\\n    include_index (bool): Flag to decide whether to add an index column in the resulting DataFrame.\\n\\n    Returns: DataFrame: Returns a pandas DataFrame with columns for elements and their respective character counts.\\n    Includes an 'Index' column if requested.\\n\\n    Requirements:\\n    - pandas\\n    - numpy\\n\\n    Note:\\n    The order of columns in the returned DataFrame will be ['Index', 'Element', 'Count'] if the index is included.\\n\\n    Example:\\n    >>> result = task_func(['abc', 'def'], include_index=True)\\n    >>> print(result.to_string(index=False))\\n     Index Element  Count\\n         0     abc      3\\n         1     def      3\\n    \\\"\\\"\\\"\\n\",\"entry_point\":\"task_func\",\"instruct_prompt\":\"Constructs a DataFrame that enumerates the character counts of each string in a provided list of elements. This function can optionally include an index column for each row in the DataFrame.\\nNote that: The order of columns in the returned DataFrame will be ['Index', 'Element', 'Count'] if the index is included.\\nThe function should output with:\\n    DataFrame: Returns a pandas DataFrame with columns for elements and their respective character counts.\\n    Includes an 'Index' column if requested.\\nYou should write self-contained code starting with:\\n```\\nimport pandas as pd\\nimport numpy as np\\nDEFAULT_COLUMNS = ['Element', 'Count']\\ndef task_func(elements, include_index=False):\\n```\",\"libs\":\"['pandas', 'numpy']\"}","display_format":"code","language":"","answer_status":"published","assets":[],"source_url":"https://bigcode-bench.github.io/","history":"initial import","indexing_mode":"noindex","subproblems":[],"grids":[]}