{"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":"bbccead7-710e-5469-a550-680851af53a4","task_key":"default--v0~2e1~2e0~5fhf--bbccead7-710e-5469-a550-680851af53a4","task_revision_id":"1","upstream_id":"","short_description":"BigCodeBench v0.1.0_hf bbccead7-710e-5469-a550-680851af53a4","config":"default","split":"v0.1.0_hf","body":"{\"code_prompt\":\"import pandas as pd\\nimport collections\\ndef task_func(df):\\n\",\"complete_prompt\":\"import pandas as pd\\nimport collections\\n\\ndef task_func(df):\\n    \\\"\\\"\\\"\\n    Generate a sales report from a DataFrame, excluding duplicate customer names. \\n    The report includes total sales and the most popular sales category.\\n\\n    Parameters:\\n    df (DataFrame): A pandas DataFrame with columns 'Customer', 'Category', and 'Sales'.\\n\\n    Returns:\\n    dict: A dictionary with keys 'Total Sales' (sum of sales) and 'Most Popular Category' (most frequent category).\\n\\n    Requirements:\\n    - pandas\\n    - collections\\n\\n    Raises:\\n    - The function will raise a ValueError is input df is not a DataFrame.\\n\\n    Note:\\n    - The function would return the first category in alphabetical order for \\\"Most Popular Category' in the case of tie\\n\\n    Example:\\n    >>> data = pd.DataFrame([{'Customer': 'John', 'Category': 'Electronics', 'Sales': 500}, {'Customer': 'Mary', 'Category': 'Home', 'Sales': 300}])\\n    >>> report = task_func(data)\\n    >>> print(report)\\n    {'Total Sales': 800, 'Most Popular Category': 'Electronics'}\\n    \\\"\\\"\\\"\\n\",\"entry_point\":\"task_func\",\"instruct_prompt\":\"Generate a sales report from a DataFrame, excluding duplicate customer names. The report includes total sales and the most popular sales category.\\nNote that: The function would return the first category in alphabetical order for \\\"Most Popular Category' in the case of tie\\nThe function should raise the exception for: The function will raise a ValueError is input df is not a DataFrame.\\nThe function should output with:\\n    dict: A dictionary with keys 'Total Sales' (sum of sales) and 'Most Popular Category' (most frequent category).\\nYou should write self-contained code starting with:\\n```\\nimport pandas as pd\\nimport collections\\ndef task_func(df):\\n```\",\"libs\":\"['pandas', 'collections']\"}","display_format":"code","language":"","answer_status":"published","assets":[],"source_url":"https://bigcode-bench.github.io/","history":"initial import","indexing_mode":"index","subproblems":[],"grids":[]}