{"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":"a7f159df-1199-5674-a12f-3e55766bf46e","task_key":"default--v0~2e1~2e0~5fhf--a7f159df-1199-5674-a12f-3e55766bf46e","task_revision_id":"1","upstream_id":"","short_description":"BigCodeBench v0.1.0_hf a7f159df-1199-5674-a12f-3e55766bf46e","config":"default","split":"v0.1.0_hf","body":"{\"code_prompt\":\"import json\\nimport random\\n# Constants\\nDATA = [\\n    {'name': 'John', 'age': 30, 'city': 'New York'},\\n    {'name': 'Peter', 'age': 35, 'city': 'London'},\\n    {'name': 'Susan', 'age': 25, 'city': 'Sydney'},\\n    {'name': 'Alice', 'age': 28, 'city': 'Paris'},\\n    {'name': 'Bob', 'age': 40, 'city': 'Tokyo'},\\n    {'name': 'Charlie', 'age': 22, 'city': 'Beijing'},\\n    {'name': 'David', 'age': 33, 'city': 'Mumbai'},\\n    {'name': 'Eve', 'age': 27, 'city': 'Berlin'},\\n    {'name': 'Frank', 'age': 32, 'city': 'Moscow'},\\n    {'name': 'Grace', 'age': 29, 'city': 'Rome'}\\n]\\ndef task_func(utc_datetime, seed=0):\\n\",\"complete_prompt\":\"import json\\nimport random\\n\\n\\n# Constants\\nDATA = [\\n    {'name': 'John', 'age': 30, 'city': 'New York'},\\n    {'name': 'Peter', 'age': 35, 'city': 'London'},\\n    {'name': 'Susan', 'age': 25, 'city': 'Sydney'},\\n    {'name': 'Alice', 'age': 28, 'city': 'Paris'},\\n    {'name': 'Bob', 'age': 40, 'city': 'Tokyo'},\\n    {'name': 'Charlie', 'age': 22, 'city': 'Beijing'},\\n    {'name': 'David', 'age': 33, 'city': 'Mumbai'},\\n    {'name': 'Eve', 'age': 27, 'city': 'Berlin'},\\n    {'name': 'Frank', 'age': 32, 'city': 'Moscow'},\\n    {'name': 'Grace', 'age': 29, 'city': 'Rome'}\\n]\\n\\ndef task_func(utc_datetime, seed=0):\\n    \\\"\\\"\\\"\\n    Select a random person from a dataset of people and their attributes (name, age, city) provided as a global \\n    variable DATA. Add a UTC timestamp to the person's data which is passed as an argument utc_datetime 'timestamp'. Finally, \\n    encode that person's data as a JSON string.\\n    \\n    Parameters:\\n    utc_datetime (datetime): The datetime in UTC.\\n    seed (int, optional): The seed for the random number generator. Defaults to 0.\\n    \\n    Returns:\\n    str: The person's data encoded as a JSON string.\\n    \\n    Requirements:\\n    - json\\n    - datetime\\n    - random\\n    \\n    Example:\\n    >>> from datetime import datetime\\n    >>> utc_time = datetime(2023, 6, 15, 12, 0, 0, tzinfo=pytz.UTC)\\n    >>> person_json_str = task_func(utc_time)\\n    >>> json_data = json.loads(person_json_str)\\n    >>> print(json_data[\\\"name\\\"])\\n    David\\n    >>> print(json_data[\\\"age\\\"])\\n    33\\n    \\\"\\\"\\\"\\n\",\"entry_point\":\"task_func\",\"instruct_prompt\":\"Select a random person from a dataset of people and their attributes (name, age, city) provided as a global variable DATA. Add a UTC timestamp to the person's data which is passed as an argument utc_datetime 'timestamp'. Finally, encode that person's data as a JSON string.\\nThe function should output with:\\n    str: The person's data encoded as a JSON string.\\nYou should write self-contained code starting with:\\n```\\nimport json\\nimport random\\n# Constants\\nDATA = [\\n    {'name': 'John', 'age': 30, 'city': 'New York'},\\n    {'name': 'Peter', 'age': 35, 'city': 'London'},\\n    {'name': 'Susan', 'age': 25, 'city': 'Sydney'},\\n    {'name': 'Alice', 'age': 28, 'city': 'Paris'},\\n    {'name': 'Bob', 'age': 40, 'city': 'Tokyo'},\\n    {'name': 'Charlie', 'age': 22, 'city': 'Beijing'},\\n    {'name': 'David', 'age': 33, 'city': 'Mumbai'},\\n    {'name': 'Eve', 'age': 27, 'city': 'Berlin'},\\n    {'name': 'Frank', 'age': 32, 'city': 'Moscow'},\\n    {'name': 'Grace', 'age': 29, 'city': 'Rome'}\\n]\\ndef task_func(utc_datetime, seed=0):\\n```\",\"libs\":\"['random', 'json']\"}","display_format":"code","language":"","answer_status":"published","assets":[],"source_url":"https://bigcode-bench.github.io/","history":"initial import","indexing_mode":"index","subproblems":[],"grids":[]}