{"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":"7b2245ee-0573-5271-b955-cc68a098ef33","task_key":"default--v0~2e1~2e0~5fhf--7b2245ee-0573-5271-b955-cc68a098ef33","task_revision_id":"1","upstream_id":"","short_description":"BigCodeBench v0.1.0_hf 7b2245ee-0573-5271-b955-cc68a098ef33","config":"default","split":"v0.1.0_hf","body":"{\"code_prompt\":\"import json\\nimport random\\nimport hashlib\\nfrom datetime import datetime\\ndef task_func(utc_datetime, salt='salt', password_length=10, seed=0):\\n\",\"complete_prompt\":\"import json\\nimport random\\nimport hashlib\\nfrom datetime import datetime\\n\\n\\ndef task_func(utc_datetime, salt='salt', password_length=10, seed=0):\\n    \\\"\\\"\\\"\\n    Generate a random lowercase alphanumeric password of length password_length\\n    and then encrypt it as a JSON string. The password is hashed using SHA-256.\\n    The hashing uses the combination of the user provided salt and the complete \\n    conventional string representation of the user provided UTC datetime. \\n    \\n    Parameters:\\n    utc_datetime (datetime): The datetime in UTC.\\n    salt (str, optional): The salt to be used for hashing the password. Defaults to 'salt'.\\n    password_length (int, optional): The length of the password to be generated. Defaults to 10.\\n    seed (int, optional): The seed for the random number generator. Defaults to 0.\\n    \\n    Returns:\\n    str: The hashed password encoded as a JSON string.\\n    \\n    Requirements:\\n    - json\\n    - datetime\\n    - random\\n    - hashlib\\n\\n    Raises:\\n    - ValueError: If the utc_datetime is not a datetime object or the salt is not a string.\\n    \\n    Example:\\n    >>> utc_time = datetime(2023, 6, 15, 12, 0, 0, tzinfo=pytz.UTC)\\n    >>> password_json_str = task_func(utc_time)\\n    \\\"\\\"\\\"\\n\",\"entry_point\":\"task_func\",\"instruct_prompt\":\"Generate a random lowercase alphanumeric password of length password_length and then encrypt it as a JSON string. The password is hashed using SHA-256. The hashing uses the combination of the user provided salt and the complete conventional string representation of the user provided UTC datetime.\\nThe function should raise the exception for: ValueError: If the utc_datetime is not a datetime object or the salt is not a string.\\nThe function should output with:\\n    str: The hashed password encoded as a JSON string.\\nYou should write self-contained code starting with:\\n```\\nimport json\\nimport random\\nimport hashlib\\nfrom datetime import datetime\\ndef task_func(utc_datetime, salt='salt', password_length=10, seed=0):\\n```\",\"libs\":\"['datetime', 'random', 'hashlib', 'json']\"}","display_format":"code","language":"","answer_status":"published","assets":[],"source_url":"https://bigcode-bench.github.io/","history":"initial import","indexing_mode":"index","subproblems":[],"grids":[]}