data_source
large_stringclasses
1 value
prompt
listlengths
1
1
ability
large_stringclasses
1 value
reward_model
dict
extra_info
dict
acecode
[ { "role": "user", "content": "You are tasked with creating a Python function that checks if a given string is a palindrome, meaning it reads the same forwards and backwards. The function should ignore spaces, punctuation, and capitalization. Write a Python function `is_palindrome(s)` that takes a string `s`...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert is_palindrome('A man, a plan, a canal, Panama') == True\", \"assert is_palindrome('racecar') == True\", \"assert is_palindrome('No lemon, no melon') == True\", \"assert is_palindrome('Hello, World!') == False\", \"assert is_palindrome('') == True\", \"assert...
{ "split": "train", "index": 78000, "acecode_id": "oss_19675", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Write a Python function that reverses an array up to a given position and sorts the remaining part of the array in ascending order. The function should handle edge cases such as an empty array, a single element array, or a position that is out of the array's bounds. Additionall...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert reverse_and_sort([], 3) == []\", \"assert reverse_and_sort([1], 1) == [1]\", \"assert reverse_and_sort([1, 2, 3], 2) == [2, 1, 3]\", \"assert reverse_and_sort([3, 2, 1], 3) == [1, 2, 3]\", \"assert reverse_and_sort([5.5, 3.3, 2.2, 1.1], 2) == [3.3, 5.5, 1.1,...
{ "split": "train", "index": 78001, "acecode_id": "evol_31456", "num_tests": 14 }
acecode
[ { "role": "user", "content": "Given a list of floating-point numbers, implement a function `hyperbolic_tangent(arr)` that returns a new list containing the hyperbolic tangent of each number in the input list. The hyperbolic tangent of a number x is defined as (e^x - e^-x) / (e^x + e^-x). You can assume that...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert hyperbolic_tangent([0]) == [0.0]\", \"assert hyperbolic_tangent([1, 0]) == [0.7615941559557649, 0.0]\", \"assert hyperbolic_tangent([2.5, -2.5]) == [0.9866142981514303, -0.9866142981514303]\", \"assert hyperbolic_tangent([100]) == [1.0]\", \"assert hyperboli...
{ "split": "train", "index": 78002, "acecode_id": "bigcode_python_fns_44998", "num_tests": 9 }
acecode
[ { "role": "user", "content": "You are given a list of input file names and a mapping that represents the relationship between input files and their corresponding output files. Your task is to implement a function that takes these two inputs and returns a dictionary where each output file name is mapped to i...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert convert_files(['input4.txt', 'input5.txt'], [('output1.txt', 'input1.txt'), ('output2.txt', 'input2.txt')]) == {}\", \"assert convert_files([], [('output1.txt', 'input1.txt')]) == {}\", \"assert convert_files(['input1.txt'], []) == {}\", \"assert convert_fil...
{ "split": "train", "index": 78003, "acecode_id": "oss_10236", "num_tests": 5 }
acecode
[ { "role": "user", "content": "Given a string representing a code, determine if it corresponds to a specific type of region or city code. A city code is considered valid if its first two characters are '97' or '98'. A region code is valid if it is one of the following: '01', '02', '03', '04', or '06'. Implem...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert is_valid_code('97000') == True\", \"assert is_valid_code('98000') == True\", \"assert is_valid_code('97001') == True\", \"assert is_valid_code('98001') == True\", \"assert is_valid_code('01000') == True\", \"assert is_valid_code('02000') == True\", \"assert ...
{ "split": "train", "index": 78004, "acecode_id": "bigcode_python_fns_6093", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a nested dictionary of varying depth, your task is to flatten this dictionary into a single-level dictionary. Each key in the final dictionary should represent the hierarchy of the input dictionary. The keys should be produced by joining the keys in the path from the root...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert flatten_dict({'a': 1, 'b': 2}) == {'a': 1, 'b': 2}\", \"assert flatten_dict({'a': {'b': 1}}) == {'a.b': 1}\", \"assert flatten_dict({'a': {'b': {'c': 1}}}) == {'a.b.c': 1}\", \"assert flatten_dict({'x': {'y': {'z': 3}}, 'a': 5}) == {'x.y.z': 3, 'a': 5}\", \"...
{ "split": "train", "index": 78005, "acecode_id": "evol_30150", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Implement a function that replaces an element in a list at a specified index with a new value. The function should take a list, an index, and a new value as parameters. If the index is valid, the function should replace the element at that index with the new value and return th...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert replace_element([10, 20, 30, 40, 50], 2, 99) == [10, 20, 99, 40, 50]\", \"assert replace_element([10, 20, 30, 40, 50], 0, 100) == [100, 20, 30, 40, 50]\", \"assert replace_element([10, 20, 30, 40, 50], 4, 200) == [10, 20, 30, 40, 200]\", \"assert replace_ele...
{ "split": "train", "index": 78006, "acecode_id": "evol_25951", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that dynamically adds logging shims to a specified class. The logging shims should log a message indicating that a method was called before executing the original method. You will be given a class with certain methods and a list of me...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert add_shims(Client, ['method1', 'method2']) is None\", \"assert client.method1() == None\", \"assert client.method2() == None\", \"assert client.method1() == None\", \"assert client.method2() == None\"]}" }
{ "split": "train", "index": 78007, "acecode_id": "oss_15448", "num_tests": 5 }
acecode
[ { "role": "user", "content": "Given a string, write a function that capitalizes the first character of the string and converts all other characters to lowercase. Your function should handle empty strings and return an empty string in such cases. Implement a function `capitalize_string(s: str) -> str` where ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert capitalize_string('hello') == 'Hello'\", \"assert capitalize_string('WORLD') == 'World'\", \"assert capitalize_string('pYTHON') == 'Python'\", \"assert capitalize_string('javaSCRIPT') == 'Javascript'\", \"assert capitalize_string('123abc') == '123abc'\", \"a...
{ "split": "train", "index": 78008, "acecode_id": "bigcode_python_fns_39700", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a set of keywords `words` and a string `S`, return a string where all appearances of the keywords in `S` are enclosed in bold tags (<b> and </b>). The tags should be used in a way that minimizes their number, and it should correctly handle overlapping and non-overlapping ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert boldWords([\\\"ab\\\", \\\"bc\\\", \\\"cd\\\"], \\\"aabcdcd\\\") == \\\"a<b>abcdcd</b>\\\"\", \"assert boldWords([], \\\"abc\\\") == \\\"abc\\\"\", \"assert boldWords([\\\"a\\\", \\\"b\\\", \\\"c\\\"], \\\"defghi\\\") == \\\"defghi\\\"\", \"assert boldWords(...
{ "split": "train", "index": 78009, "acecode_id": "evol_22074", "num_tests": 9 }
acecode
[ { "role": "user", "content": "You are given a list of strings containing keywords. Your task is to implement a function that evaluates the keywords based on their frequency of occurrence. Specifically, your function should return the keyword that appears most frequently in the list. If there is a tie, retur...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert most_frequent_keyword(['apple', 'banana', 'apple', 'orange', 'banana', 'banana']) == 'banana'\", \"assert most_frequent_keyword(['dog', 'cat', 'dog', 'dog', 'cat', 'cat']) == 'dog'\", \"assert most_frequent_keyword(['a', 'b', 'c', 'a', 'b', 'a']) == 'a'\", \...
{ "split": "train", "index": 78010, "acecode_id": "bigcode_python_fns_1801", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function `query(params: Dict[str, str], lang: str = 'en') -> Dict[str, Any]` that simulates a simplified API request. The function should take a dictionary of parameters and a language code (defaulting to 'en') and return a dictionary that contain...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert query({'action': 'query'}, 'en') == {'status': 'success', 'language': 'en', 'params': {'action': 'query'}}\", \"assert query({'action': 'query', 'format': 'json'}, 'fr') == {'status': 'success', 'language': 'fr', 'params': {'action': 'query', 'format': 'json...
{ "split": "train", "index": 78011, "acecode_id": "bigcode_python_fns_32564", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You want to schedule a list of jobs in `d` days with specific constraints on the maximum job difficulties allowed each day. Each job has a difficulty level represented in the array `jobDifficulty`. You need to ensure that you complete at least one job each day. The difficulty o...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert minDifficulty([9,9,9], 4, [9, 9, 9, 9]) == -1\", \"assert minDifficulty([1,1,1], 3, [1, 1, 1]) == 3\", \"assert minDifficulty([10,20,30], 3, [10, 20, 30]) == 60\", \"assert minDifficulty([5,5,5,5], 4, [5, 5, 5, 5]) == 20\", \"assert minDifficulty([10,10,10,1...
{ "split": "train", "index": 78012, "acecode_id": "evol_27286", "num_tests": 7 }
acecode
[ { "role": "user", "content": "Write a Python function that validates a credit card billing address. The billing address is provided as a single string with four lines, each containing specific details. The format for the billing address should be as follows: the first line contains the name (letters and spa...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert validate_billing_address('Alex Brown\\\\n#1234 Broadway\\\\nMetropolis, IL\\\\n55555') == True\", \"assert validate_billing_address('Tom Hanks\\\\nCottage 12\\\\nOldtown, NV\\\\n77777') == True\", \"assert validate_billing_address('Emma Watson\\\\nHouse 4\\\...
{ "split": "train", "index": 78013, "acecode_id": "evol_31543", "num_tests": 9 }
acecode
[ { "role": "user", "content": "Given a list of integers and a target integer, write a function that checks if the target integer is present in the list. The function should return True if the target is found, and False otherwise. You are required to implement a single function `contains_target(nums: List[int...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert contains_target([1, 2, 3, 4, 5], 3) == True\", \"assert contains_target([10, 20, 30, 40], 25) == False\", \"assert contains_target([-1, -2, -3, -4], -3) == True\", \"assert contains_target([], 1) == False\", \"assert contains_target([1], 1) == True\", \"asse...
{ "split": "train", "index": 78014, "acecode_id": "bigcode_python_fns_22840", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Implement a function that takes a string as input and returns a new string with each word reversed while maintaining the original order of the words. You should not use any built-in functions or slicing techniques in Python. A word is defined as a sequence of characters delimit...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert reverse_words_string('Hello World!') == 'olleH !dlroW'\", \"assert reverse_words_string('SingleWord') == 'droWelgniS'\", \"assert reverse_words_string('') == ''\", \"assert reverse_words_string(' ') == ''\", \"assert reverse_words_string('One') == 'enO'\",...
{ "split": "train", "index": 78015, "acecode_id": "evol_3822", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given two lists of positive integers, implement a function that combines both lists, sorts the resulting list in descending order, removes all duplicates, and filters the list such that only prime numbers with non-repeating digits are included. The function should return this f...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert filter_primes([10, 12, 14], [15, 17, 19]) == [19, 17]\", \"assert filter_primes([1, 4, 6], [8, 10, 12]) == []\", \"assert filter_primes([22, 23, 24], [25, 26, 27]) == [23]\", \"assert filter_primes([29, 10, 20], [3, 5, 7]) == [29, 7, 5, 3]\", \"assert filter...
{ "split": "train", "index": 78016, "acecode_id": "evol_3477", "num_tests": 12 }
acecode
[ { "role": "user", "content": "You are given a string `sequence` consisting of uppercase letters representing a DNA sequence. Your task is to implement a function that extracts a subsequence from this DNA sequence based on start and end indices provided as parameters. The function should return the extracted...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert extract_subsequence('ACGTAGCT', 0, 4) == 'ACGT'\", \"assert extract_subsequence('ACGTAGCT', 2, 5) == 'GTA'\", \"assert extract_subsequence('ACGTAGCT', 0, 8) == 'ACGTAGCT'\", \"assert extract_subsequence('ACGTAGCT', 3, 3) == ''\", \"assert extract_subsequence...
{ "split": "train", "index": 78017, "acecode_id": "bigcode_python_fns_910", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Implement a function `generate_unique_ids(n: int) -> List[str]` that generates a list of `n` unique identifiers. Each identifier should be a string representation of a universally unique identifier (UUID). The function should return a list of these UUIDs. If `n` is less than or...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert generate_unique_ids(0) == []\", \"assert len(generate_unique_ids(1)) == 1\", \"assert len(generate_unique_ids(5)) == 5\", \"assert len(generate_unique_ids(10)) == 10\", \"assert len(set(generate_unique_ids(10))) == 10\", \"assert len(set(generate_unique_ids(...
{ "split": "train", "index": 78018, "acecode_id": "bigcode_python_fns_8414", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a string of integers separated by commas, write a function that converts the string into a list of integers and randomly rearranges the elements in the list. The function should return the rearranged list. For example, given the input '1, 3, 5, 7, 9', the output should be...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert rearrange_numbers('1, 2, 3') != [1, 2, 3]\", \"assert sorted(rearrange_numbers('4, 5, 6')) == [4, 5, 6]\", \"assert len(rearrange_numbers('7, 8, 9, 10')) == 4\", \"assert rearrange_numbers('10, 20, 30') != [10, 20, 30]\", \"assert rearrange_numbers('1') == [...
{ "split": "train", "index": 78019, "acecode_id": "evol_22067", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with creating a Python function that counts the occurrences of different types of elements in a given mesh. The mesh is represented as a list of strings, where each string indicates the type of an element (either 'tri', 'quad', 'tetra', or 'hexa'). Your function ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert count_mesh_element_types(['tri', 'quad', 'tri', 'tetra', 'hexa', 'quad']) == {'tri': 2, 'quad': 2, 'tetra': 1, 'hexa': 1}\", \"assert count_mesh_element_types(['tri', 'tri', 'tri']) == {'tri': 3, 'quad': 0, 'tetra': 0, 'hexa': 0}\", \"assert count_mesh_eleme...
{ "split": "train", "index": 78020, "acecode_id": "oss_28899", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given an angle in gradians, write a function that converts the specified angle from gradians into degrees. The conversion formula is: degrees = gradians * 0.9. Implement the function `grad_to_deg(grad)` where `grad` is the angle in gradians. The function should return the equiv...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert grad_to_deg(0) == 0.0\", \"assert grad_to_deg(100) == 90.0\", \"assert grad_to_deg(200) == 180.0\", \"assert grad_to_deg(400) == 360.0\", \"assert grad_to_deg(50) == 45.0\", \"assert grad_to_deg(75) == 67.5\", \"assert grad_to_deg(300) == 270.0\", \"assert g...
{ "split": "train", "index": 78021, "acecode_id": "evol_6364", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Write a function `get_distance_to_location(lat1, lon1, lat2, lon2)` that calculates the distance between two geographical coordinates specified by latitude and longitude. The function should return the distance in miles. Use the Haversine formula to account for the curvature of...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_distance_to_location(34.0522, -118.2437, 34.0522, -118.2437) == 0.0\", \"assert get_distance_to_location(37.7749, -122.4194, 37.7749, -122.4194) == 0.0\", \"assert get_distance_to_location(-91.0, 0.0, 0.0, 0.0) == None\", \"assert get_distance_to_locatio...
{ "split": "train", "index": 78022, "acecode_id": "evol_34096", "num_tests": 8 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function that identifies potential Regular Expression Denial of Service (ReDoS) vulnerabilities in a given regular expression pattern. Your function should take a string input representing a JSON object, which contains a key 'pattern' whose value ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert handle_line_from_node('{\\\"pattern\\\": \\\"(a+|b+)*\\\"}') == 'Modified regex pattern to mitigate ReDoS vulnerability: *'\", \"assert handle_line_from_node('{\\\"pattern\\\": \\\"(a+|b+)?(c|d)*\\\"}') == 'Modified regex pattern to mitigate ReDoS vulnerabil...
{ "split": "train", "index": 78023, "acecode_id": "oss_22856", "num_tests": 9 }
acecode
[ { "role": "user", "content": "You are tasked with setting up a sensor platform for a gaming server. Your function should take in a list of sensor descriptions and return a list of sensor entity objects. Each sensor entity is represented as a dictionary with a 'name' and 'type'. The name is the original desc...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert setup_sensors(['CPU Usage', 'Memory Usage']) == [{'name': 'CPU Usage Sensor', 'type': 'GameSensor'}, {'name': 'Memory Usage Sensor', 'type': 'GameSensor'}]\", \"assert setup_sensors(['Player Count', 'Ping', 'Latency']) == [{'name': 'Player Count Sensor', 'ty...
{ "split": "train", "index": 78024, "acecode_id": "bigcode_python_fns_31315", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a list of words, write a function `find_palindrome(words, target)` that determines if the target word is both present in the list and a palindrome. A palindrome is a word that reads the same backward as forward. The function should return True if both conditions are satis...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert find_palindrome(['racecar', 'level', 'deed', 'swap', 'keel'], 'racecar') == True\", \"assert find_palindrome(['racecar', 'level', 'deed', 'swap', 'keel'], 'level') == True\", \"assert find_palindrome(['racecar', 'level', 'deed', 'swap', 'keel'], 'deed') == T...
{ "split": "train", "index": 78025, "acecode_id": "evol_31153", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Implement a function `upload_blob(bucket_name: str, source_file_name: str, destination_blob_name: str) -> str` that simulates uploading a file to a cloud storage bucket. The function should return a confirmation message indicating that the file has been uploaded. The parameters...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert upload_blob('my_bucket', 'sample.txt', 'destination_blob_name') == 'File sample.txt uploaded to destination_blob_name.'\", \"assert upload_blob('test_bucket', 'example.txt', 'example_blob') == 'File example.txt uploaded to example_blob.'\", \"assert upload_b...
{ "split": "train", "index": 78026, "acecode_id": "evol_28448", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given an array of strings `strarr` and two integers `n` and `k`. Write a function `find_longest_consecutive_string` that finds the longest string composed of `k` consecutive elements in the array, starting from index `i`, where `i` ranges from 0 to `n-k`. If `n` is 0, `...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert find_longest_consecutive_string([\\\"abc\\\", \\\"de\\\", \\\"fghi\\\", \\\"jklmno\\\", \\\"pqr\\\"], 5, 3) == \\\"fghijklmnopqr\\\"\", \"assert find_longest_consecutive_string([\\\"x\\\", \\\"y\\\", \\\"z\\\"], 3, 0) == \\\"\\\"\", \"assert find_longest_con...
{ "split": "train", "index": 78027, "acecode_id": "oss_33949", "num_tests": 10 }
acecode
[ { "role": "user", "content": "Write a function `generate_horizontal_line(lineLength: int, lineWidth: Optional[int] = None, lineCharacter: Optional[str] = None) -> str` that generates a horizontal line made up of a specified character. The line should have a length defined by `lineLength` and should repeat f...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert generate_horizontal_line(5) == '-----\\\\n'\", \"assert generate_horizontal_line(0) == '\\\\n'\", \"assert generate_horizontal_line(3, 1, '#') == '###\\\\n'\", \"assert generate_horizontal_line(4, 3, '*') == '****\\\\n****\\\\n****\\\\n'\", \"assert generate...
{ "split": "train", "index": 78028, "acecode_id": "bigcode_python_fns_48020", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with creating a Python function that simulates the loading and execution of predefined modules based on a given list of module names. Each module is represented as a dictionary where the key is the module name and the value is a function that returns a string mes...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert simulate_module_execution([{'module1': lambda: 'Hello from module1'}, {'module2': lambda: 'Hello from module2'}]) == {'module1': 'Hello from module1', 'module2': 'Hello from module2'}\", \"assert simulate_module_execution([{'module1': lambda: 'Hello from mod...
{ "split": "train", "index": 78029, "acecode_id": "oss_10020", "num_tests": 11 }
acecode
[ { "role": "user", "content": "You are tasked with updating records in a table based on given keys and values. Write a function that takes a list of dictionaries representing records, a list of keys that will be used to identify which records to update, and another list of values that should be updated. The ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert update_records([{'id': 1, 'name': 'Alice'}, {'id': 2, 'name': 'Bob'}], ['id'], ['name']) == 2\", \"assert update_records([{'id': 1, 'name': 'Alice'}, {'id': 2, 'name': 'Bob'}], ['id'], ['name', 'age']) == 2\", \"assert update_records([], ['id'], ['name']) ==...
{ "split": "train", "index": 78030, "acecode_id": "bigcode_python_fns_34960", "num_tests": 14 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function that manages a simple connection to a database. The function should take in two parameters: the host of the database and the database name. The function will simulate establishing a connection to the database and returning a success messa...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert manage_database_connection('localhost', 'test_db') == 'Connected to test_db at localhost.'\", \"assert manage_database_connection('localhost', '') == 'Error: Database name is missing.'\", \"assert manage_database_connection('', 'test_db') == 'Error: Host is ...
{ "split": "train", "index": 78031, "acecode_id": "oss_2389", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given a list of class names and a target class name. Write a function `instantiate_class(class_names: List[str], target_class: str) -> str` that checks if the target class name is present in the list of class names. If it is present, return the target class name; otherw...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert instantiate_class(['Coadd1d', 'Coadd2d', 'Reduce'], 'Coadd2d') == 'Coadd2d'\", \"assert instantiate_class(['ClassA', 'ClassB', 'ClassC'], 'ClassD') == 'Class not found'\", \"assert instantiate_class(['TestClass', 'ExampleClass'], 'ExampleClass') == 'ExampleC...
{ "split": "train", "index": 78032, "acecode_id": "bigcode_python_fns_29738", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function to extract titles from a given list of strings. The titles may be surrounded by double quotes or may simply be single words without quotes. If the title is surrounded by quotes, your function should return the title without the quotes...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert extract_titles(['\\\"The Great Gatsby\\\"', '1984', '\\\"Pride and Prejudice\\\"']) == ['The Great Gatsby', '1984', 'Pride and Prejudice']\", \"assert extract_titles(['\\\"Moby Dick\\\"', 'War and Peace', '\\\"To Kill a Mockingbird\\\"']) == ['Moby Dick', 'W...
{ "split": "train", "index": 78033, "acecode_id": "oss_4788", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given a string `html` that represents a simplified HTML document. Your task is to extract all unique hyperlinks (href attributes of <a> tags) from the document while ignoring any links that have a class attribute containing the word 'new'. The document may contain unord...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert extract_links('<ol><li><a href=\\\"link3.html\\\">Link 3</a></li><li><a href=\\\"link4.html\\\">Link 4</a></li></ol>') == ['link3.html', 'link4.html']\", \"assert extract_links('<ul><li><a href=\\\"link10.html\\\">Link 10</a></li></ul>') == ['link10.html']\"...
{ "split": "train", "index": 78034, "acecode_id": "bigcode_python_fns_43714", "num_tests": 8 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that simulates the deletion of specific records from a database. The database contains two types of records: 'Requests' and 'AntibodyHistories'. Each record type can be represented as a list of strings. Your function should take two l...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert delete_records(['req1', 'req2', 'req3'], ['ab1', 'ab2'], ['req1'], ['ab2']) == (['req2', 'req3'], ['ab1'])\", \"assert delete_records(['req1', 'req2'], ['ab1', 'ab2', 'ab3'], ['req2'], ['ab1', 'ab3']) == (['req1'], ['ab2'])\", \"assert delete_records([], [],...
{ "split": "train", "index": 78035, "acecode_id": "bigcode_python_fns_28818", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that processes two lists of integers, `list_a` and `list_b`. Your goal is to create a function that takes in these two lists and returns a dictionary where the keys are the unique integers from both lists, and the values are the count...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert count_common_elements([], [1, 2, 3]) == {}\", \"assert count_common_elements([1, 2, 3], []) == {}\", \"assert count_common_elements([5, 5, 5], [5, 5]) == {5: 5}\", \"assert count_common_elements([1, 2, 3], [4, 5, 6]) == {}\", \"assert count_common_elements([...
{ "split": "train", "index": 78036, "acecode_id": "oss_6140", "num_tests": 15 }
acecode
[ { "role": "user", "content": "You are tasked with creating a configuration management function that retrieves configuration settings from a dictionary. Implement a function named `get_setting_from_config` that accepts a dictionary of configuration settings and a string key, and returns the value associated ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_setting_from_config({'username': 'user123', 'password': 'secretpassword', 'server': 'example.com'}, 'username') == 'user123'\", \"assert get_setting_from_config({'username': 'user123', 'password': 'secretpassword', 'server': 'example.com'}, 'password') =...
{ "split": "train", "index": 78037, "acecode_id": "oss_4217", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a string that may contain trailing spaces, write a function that returns the last non-space character of the string. You can assume that the input string will have at least one non-space character. Implement a function `last_non_space_char(string: str) -> str` that takes ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert last_non_space_char('hello world ') == 'd'\", \"assert last_non_space_char('python programming ') == 'g'\", \"assert last_non_space_char(' leading spaces') == 's'\", \"assert last_non_space_char('trailing spaces ') == 's'\", \"assert last_non_space_ch...
{ "split": "train", "index": 78038, "acecode_id": "evol_3652", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given two distinct collections, groupA and groupB, implement a function that identifies the common elements between the two collections and returns a dictionary with the common elements as keys and their frequencies in both collections as values. The function should account for...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert find_common_elements_and_freq({'apple', 3.0, 5}, {'banana', 3, 5.0}) == {3: (1, 1), 5: (1, 1)}\", \"assert find_common_elements_and_freq({'hello', 1.0, 2}, {'hello', 2.0, '3'}) == {'hello': (1, 1), 2: (1, 1)}\", \"assert find_common_elements_and_freq({'cat',...
{ "split": "train", "index": 78039, "acecode_id": "evol_9517", "num_tests": 14 }
acecode
[ { "role": "user", "content": "Given a list of integers, implement a function called `sort_list` that sorts the list in ascending order and returns the sorted list. The input list may contain duplicate values.\nPlease reason step by step, then write a self-contained Python solution. Give your final program i...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert sort_list([30, 10, 70, 20, 50]) == [10, 20, 30, 50, 70]\", \"assert sort_list([5, 3, 8, 1, 2]) == [1, 2, 3, 5, 8]\", \"assert sort_list([1, 2, 3, 4, 5]) == [1, 2, 3, 4, 5]\", \"assert sort_list([5, 5, 5, 5]) == [5, 5, 5, 5]\", \"assert sort_list([-1, -2, -3,...
{ "split": "train", "index": 78040, "acecode_id": "evol_15270", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function called `process_nodes`. This function takes two parameters: a list of nodes (strings) and a success message (a string). The function should return a tuple containing a boolean value indicating whether the processing was successful and...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert process_nodes(['node1', 'node2'], 'Processing successful') == (True, 'Processing successful')\", \"assert process_nodes(['nodeA'], 'Success!') == (True, 'Success!')\", \"assert process_nodes([], 'Success!') == (False, 'No nodes to process')\", \"assert proce...
{ "split": "train", "index": 78041, "acecode_id": "oss_31196", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that processes a list of spice names and returns a list of the lengths of each spice name. However, the function should only include lengths of names that are less than 6 characters long. If a spice name has exactly 6 characters, it s...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_spice_lengths(['salt', 'pepper', 'cumin', 'turmeric']) == [4, 5]\", \"assert get_spice_lengths(['cardamom', 'cinnamon', 'vanilla']) == []\", \"assert get_spice_lengths(['paprika', 'mustard', 'dill']) == []\", \"assert get_spice_lengths(['tarragon', 'sage...
{ "split": "train", "index": 78042, "acecode_id": "oss_1660", "num_tests": 6 }
acecode
[ { "role": "user", "content": "You are tasked with developing an error handling function for a cloud infrastructure management tool. This function will take a fault type as input and return the associated error message. The fault types and their associated error messages are as follows: \n- 'Resource_Does_No...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert handle_error('Resource_Does_Not_Exist_Fault_Type') == 'Resource does not exist error'\", \"assert handle_error('Create_ResourceGroup_Fault_Type') == 'Resource group creation error'\", \"assert handle_error('Add_HelmRepo_Fault_Type') == 'Helm repository add e...
{ "split": "train", "index": 78043, "acecode_id": "oss_19298", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function to calculate the average color of a given image represented as a list of pixel values. Each pixel is defined as a tuple of three integers (R, G, B) where R, G, and B are in the range [0, 255]. Your function should compute the average ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert average_color([(255, 0, 0), (0, 255, 0), (0, 0, 255)]) == (85, 85, 85)\", \"assert average_color([(0, 0, 0), (255, 255, 255)]) == (127, 127, 127)\", \"assert average_color([(100, 150, 200), (100, 150, 200)]) == (100, 150, 200)\", \"assert average_color([(255...
{ "split": "train", "index": 78044, "acecode_id": "oss_1622", "num_tests": 14 }
acecode
[ { "role": "user", "content": "Given two 2D lists (matrices) T1 and T2 of the same dimensions, determine if they are balanced. Two matrices are considered balanced if the sets of non-negative integers in each corresponding row of T1 and T2 are identical, and the same condition holds for each corresponding co...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert is_row_and_col_balanced([[0, 1, -1], [-1, -1, -1]], [[0, 1, -1], [-1, -1, -1]]) == True\", \"assert is_row_and_col_balanced([[0, 1, -1], [-1, -1, -1]], [[0, 3, -1], [-1, -1, -1]]) == False\", \"assert is_row_and_col_balanced([[1, 2], [3, 4]], [[1, 2], [3, 4]...
{ "split": "train", "index": 78045, "acecode_id": "bigcode_python_fns_13756", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function that takes an integer `question_id` and returns the string 'Question {id} details retrieved successfully.' where `{id}` is replaced with the actual `question_id`. If `question_id` is less than 1, the function should return 'Invalid questi...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_question_details(1) == 'Question 1 details retrieved successfully.'\", \"assert get_question_details(5) == 'Question 5 details retrieved successfully.'\", \"assert get_question_details(10) == 'Question 10 details retrieved successfully.'\", \"assert get_...
{ "split": "train", "index": 78046, "acecode_id": "bigcode_python_fns_26747", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Write a function that replaces all whitespaces with an underscore and vice versa in a given string. Additionally, the function should reverse the order of the words in the string, ignoring any special characters and numbers. The function should also handle edge cases such as mu...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert replace_and_reverse('Hello World') == 'World_Hello'\", \"assert replace_and_reverse('Hello 123 World') == 'World_Hello'\", \"assert replace_and_reverse('Hello! World?') == 'World_Hello'\", \"assert replace_and_reverse('') == ''\", \"assert replace_and_revers...
{ "split": "train", "index": 78047, "acecode_id": "evol_12878", "num_tests": 5 }
acecode
[ { "role": "user", "content": "Given a list of integers, implement a function `double_array` that returns a new list where each element in the input list is doubled. The input list should not be modified. You must avoid using any loop constructs (such as 'for' or 'while').\nPlease reason step by step, then w...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert double_array([1, 2, 3]) == [2, 4, 6]\", \"assert double_array([0]) == [0]\", \"assert double_array([-1, -2, -3]) == [-2, -4, -6]\", \"assert double_array([5]) == [10]\", \"assert double_array([]) == []\", \"assert double_array([10, 20, 30]) == [20, 40, 60]\"...
{ "split": "train", "index": 78048, "acecode_id": "evol_27016", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given a list of geographic coordinates representing points on a map. Write a function `generate_map` that takes a list of tuples, where each tuple contains two float values representing the latitude and longitude of a point. The function should return a string represent...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert generate_map([(0, 0)]) == 'Total points: 1, Center point: (0.0, 0.0)'\", \"assert generate_map([(10.0, 20.0), (30.0, 40.0)]) == 'Total points: 2, Center point: (20.0, 30.0)'\", \"assert generate_map([]) == 'No points available.'\", \"assert generate_map([(1....
{ "split": "train", "index": 78049, "acecode_id": "bigcode_python_fns_965", "num_tests": 14 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that retrieves the value associated with a given timestamp from a predefined dictionary of time series data. The function `get_value(ts)` should take a string parameter `ts` representing the timestamp in the format 'YYYY-MM-DD HH:MM:S...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_value('2023-01-01 00:00:00') == 100\", \"assert get_value('2023-01-02 00:00:00') == 200\", \"assert get_value('2023-01-03 00:00:00') == 300\", \"assert get_value('2023-01-04 00:00:00') == 'Timestamp not found'\", \"assert get_value('2023-01-01 12:00:00')...
{ "split": "train", "index": 78050, "acecode_id": "oss_34734", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given a string s. Determine if the string is happy or not. A string is happy if its length is at least 3, each set of 3 sequential characters are unique, every distinct character occurs at least twice, no character appears three times in a row, and there is no number in...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert is_happy('a') == False\", \"assert is_happy('aa') == False\", \"assert is_happy('abcd') == False\", \"assert is_happy('aabb') == False\", \"assert is_happy('xyzz') == False\", \"assert is_happy('abcabc') == True\", \"assert is_happy('aaa') == False\", \"asse...
{ "split": "train", "index": 78051, "acecode_id": "evol_12647", "num_tests": 15 }
acecode
[ { "role": "user", "content": "You are given a dictionary representing team assignments for various components in a software project and a directory structure that maps directories to components. Your task is to implement a function `aggregate_components(components_dict: Dict[str, Set[str]], dir_dict: Dict[s...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert aggregate_components({'Component1': {'team1', 'team2'}, 'Component2': {'team3'}}, {'/path/to/dir1': 'Component1', '/path/to/dir2': 'Component2'}) == ({'Component1': {'team1', 'team2'}, 'Component2': {'team3'}}, {'/path/to/dir1': 'Component1', '/path/to/dir2'...
{ "split": "train", "index": 78052, "acecode_id": "bigcode_python_fns_42307", "num_tests": 15 }
acecode
[ { "role": "user", "content": "You are given a list of numbers and a string representing an operation. Your task is to implement a function that performs the specified operation on the list of numbers and returns the result. The operations you should support are 'sum', 'product', 'maximum', 'minimum', and 'a...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert process_data([1, 2, 3], 'sum') == 6\", \"assert process_data([1, 2, 3], 'product') == 6\", \"assert process_data([1, 2, 3], 'maximum') == 3\", \"assert process_data([1, 2, 3], 'minimum') == 1\", \"assert process_data([1, 2, 3], 'average') == 2.0\", \"assert ...
{ "split": "train", "index": 78053, "acecode_id": "oss_4275", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with writing a Python function that processes a list of strings and generates a formatted output. Your function should accept a list of strings as input and return a list of strings formatted in the following way: each element in the input list should be prefixed...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert format_arguments([]) == ['No arguments were given.']\", \"assert format_arguments(['apple', 'banana', 'cherry']) == ['Argument at index 0 is: apple', 'Argument at index 1 is: banana', 'Argument at index 2 is: cherry']\", \"assert format_arguments(['one']) ==...
{ "split": "train", "index": 78054, "acecode_id": "oss_11094", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given two positive integers 'start_num' and 'end_num', write a function 'count_primes_in_range' that returns the total number of prime numbers between these two numbers. The function should include a parameter named 'inclusive' which takes a boolean value; if true, the function...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert count_primes_in_range(10, 30, True) == 6\", \"assert count_primes_in_range(1, 10, True) == 4\", \"assert count_primes_in_range(20, 50, False) == 7\", \"assert count_primes_in_range(5, 5, True) == 1\", \"assert count_primes_in_range(5, 5, False) == 0\", \"ass...
{ "split": "train", "index": 78055, "acecode_id": "evol_14394", "num_tests": 15 }
acecode
[ { "role": "user", "content": "Write a function that takes a string and checks if it can be rearranged to form a palindrome. Return True if it can, and False otherwise. For example, 'carrace' should return True as it can be rearranged to 'racecar', a palindrome.\nPlease reason step by step, then write a self...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert is_anagram_of_palindrome('carrace') == True\", \"assert is_anagram_of_palindrome('aabb') == True\", \"assert is_anagram_of_palindrome('abc') == False\", \"assert is_anagram_of_palindrome('a') == True\", \"assert is_anagram_of_palindrome('') == True\", \"asse...
{ "split": "train", "index": 78056, "acecode_id": "evol_2967", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a string `s`, write a function that returns `True` if the string is empty, and `False` otherwise. An empty string is defined as a string with no characters, i.e., `''`. Your function should handle any string input, including whitespace strings. Implement the function `is_...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert is_empty_string('') == True\", \"assert is_empty_string(' ') == False\", \"assert is_empty_string('Hello') == False\", \"assert is_empty_string('World') == False\", \"assert is_empty_string(' ') == False\", \"assert is_empty_string(' Hello ') == False\...
{ "split": "train", "index": 78057, "acecode_id": "bigcode_python_fns_28125", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with creating a Python function that transforms a list of integers by applying a specific operation. The function should take a list of integers as input and return a new list where each integer is doubled and then increased by one. Write a function called `trans...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert transform_list([1, 2, 3]) == [3, 5, 7]\", \"assert transform_list([0]) == [1]\", \"assert transform_list([]) == []\", \"assert transform_list([5, 10, 15]) == [11, 21, 31]\", \"assert transform_list([-5, -10, -15]) == [-9, -19, -29]\", \"assert transform_list...
{ "split": "train", "index": 78058, "acecode_id": "oss_7304", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with processing a dictionary that contains astronomical data sources. Your function should iterate through the dictionary and return a list of keys that are present in the specific set of keys: ['name', 'sources', 'schema', 'photometry']. The function should igno...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert extract_important_keys({'name': 'Star', 'size': 10, 'sources': 'Telescope', 'color': 'blue'}) == ['name', 'sources']\", \"assert extract_important_keys({'photometry': 'data', 'type': 'galaxy', 'schema': 'schema_info'}) == ['photometry', 'schema']\", \"assert...
{ "split": "train", "index": 78059, "acecode_id": "oss_37021", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a string representing a technology name, return the capacity potential (in GW) for that technology. The accepted technology names are 'wind_onshore', 'wind_offshore', 'wind_floating', 'pv_utility', and 'pv_residential'. For each technology, the capacity potential is defin...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_capacity_potential('wind_onshore') == 15.0\", \"assert get_capacity_potential('wind_offshore') == 20.0\", \"assert get_capacity_potential('wind_floating') == 10.0\", \"assert get_capacity_potential('pv_utility') == 5.0\", \"assert get_capacity_potential(...
{ "split": "train", "index": 78060, "acecode_id": "bigcode_python_fns_36405", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Implement a function `isFull` that checks if a stack has reached its maximum capacity. The stack is initialized with a `ceiling_value` which indicates its maximum size. The stack can hold elements up to this limit. The function should return `True` if the stack is full, otherwi...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert Stack(3).isFull() == False\", \"assert Stack(5).isFull() == False\", \"assert Stack(1).isFull() == False\", \"assert Stack(0).isFull() == True\", \"assert Stack(2).isFull() == False\", \"assert Stack(10).isFull() == False\", \"assert Stack(4).isFull() == Fal...
{ "split": "train", "index": 78061, "acecode_id": "evol_20619", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given a 2D list representing a Sudoku grid, where empty cells are represented by zeros. Your task is to implement a function that extracts the digits from the Sudoku grid and returns them as a flat list. The function should ignore any empty cells. For example, given the...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert extract_digits_from_sudoku([[0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0]...
{ "split": "train", "index": 78062, "acecode_id": "oss_25122", "num_tests": 10 }
acecode
[ { "role": "user", "content": "Given a list of integers, write a function `smallest_prime(numbers)` that returns the smallest prime number from the list. If no prime number exists, return None. The input list will always contain exactly 8 integers.\nPlease reason step by step, then write a self-contained Pyt...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert smallest_prime([12, 27, 9, 11, 15, 3, 20, 5]) == 3\", \"assert smallest_prime([10, 15, 22, 34, 14, 28, 26, 30]) == None\", \"assert smallest_prime([2, 3, 5, 7, 11, 13, 17, 19]) == 2\", \"assert smallest_prime([4, 6, 8, 9, 10, 12, 14, 15]) == None\", \"assert...
{ "split": "train", "index": 78063, "acecode_id": "evol_12444", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given the coordinates of two points in a 2D plane represented as tuples of integers (x1, y1) and (x2, y2). Your task is to implement a function that calculates the Manhattan distance between these two points. The Manhattan distance is defined as the sum of the absolute ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert manhattan_distance((0, 0), (1, 1)) == 2\", \"assert manhattan_distance((1, 2), (4, 6)) == 7\", \"assert manhattan_distance((-1, -1), (1, 1)) == 4\", \"assert manhattan_distance((2, 3), (2, 3)) == 0\", \"assert manhattan_distance((5, 5), (5, 0)) == 5\", \"ass...
{ "split": "train", "index": 78064, "acecode_id": "bigcode_python_fns_7559", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given the coordinates of a starting point and a goal point on a 2D plane, implement a function `get_goal_sample_rate(start: Tuple[int, int], goal: Tuple[int, int]) -> float` that calculates the goal sample rate based on the distance between the starting point and the goal point...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert abs(get_goal_sample_rate((0, 0), (600, 600)) - 30) < 1e-5\", \"assert abs(get_goal_sample_rate((0, 0), (700, 700)) - 30) < 1e-5\", \"assert abs(get_goal_sample_rate((0, 0), (1000, 1000)) - 30) < 1e-5\", \"assert abs(get_goal_sample_rate((0, 0), (601, 601)) -...
{ "split": "train", "index": 78065, "acecode_id": "bigcode_python_fns_36122", "num_tests": 6 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a simple task management system using Python. Your goal is to create a function that simulates creating a specific type of task and returns a message indicating that the task has been created. The function should be named `create_specific_task` ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert create_specific_task() == 'Specific task created'\", \"assert create_specific_task() == 'Specific task created'\", \"assert create_specific_task() == 'Specific task created'\", \"assert create_specific_task() == 'Specific task created'\", \"assert create_spe...
{ "split": "train", "index": 78066, "acecode_id": "oss_37090", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a positive integer n, where gcd(n, 20) = 1, write a function `get_B(n)` that calculates the least value of k such that the number consisting entirely of twos, T(k), is divisible by n. T(k) is defined as the number formed by repeating the digit '2', k times. For example, T...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_B(7) == 6\", \"assert get_B(41) == 5\", \"assert get_B(91) == 6\", \"assert get_B(259) == 6\", \"assert get_B(451) == 10\", \"assert get_B(3) == 3\", \"assert get_B(11) == 2\", \"assert get_B(13) == 6\"]}" }
{ "split": "train", "index": 78067, "acecode_id": "evol_7862", "num_tests": 8 }
acecode
[ { "role": "user", "content": "You are given a string representing a stack identifier. Your task is to implement a function that checks if the stack identifier indicates that a stack was created or not. A stack is considered not created if the identifier contains the substring '[$LATEST]'. Your function shou...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert check_stack_identifier('my-stack-id') == 'Stack can be deleted'\", \"assert check_stack_identifier('my-stack-id[$LATEST]') == 'my-stack-id[$LATEST]'\", \"assert check_stack_identifier('another-stack-id') == 'Stack can be deleted'\", \"assert check_stack_iden...
{ "split": "train", "index": 78068, "acecode_id": "bigcode_python_fns_23014", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function `filter_messages(messages: List[str]) -> List[str]` that processes a list of email messages and filters out those that contain the phrase 'новый сотрудник'. The function should return a new list containing only the messages that include t...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert filter_messages([]) == []\", \"assert filter_messages(['hello', 'world']) == []\", \"assert filter_messages(['\\u043d\\u043e\\u0432\\u044b\\u0439 \\u0441\\u043e\\u0442\\u0440\\u0443\\u0434\\u043d\\u0438\\u043a is here']) == ['\\u043d\\u043e\\u0432\\u044b\\u0...
{ "split": "train", "index": 78069, "acecode_id": "bigcode_python_fns_47031", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that processes a list of strings, each representing a line of text. Your function should return a single string that concatenates all the lines together, separating them with a newline character ('\\n'). The input list may contain emp...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert concatenate_lines(['Hello', 'World']) == 'Hello\\\\nWorld'\", \"assert concatenate_lines(['This', '', 'is', 'a', 'test']) == 'This\\\\n\\\\nis\\\\na\\\\ntest'\", \"assert concatenate_lines(['Line 1', 'Line 2', 'Line 3']) == 'Line 1\\\\nLine 2\\\\nLine 3'\", ...
{ "split": "train", "index": 78070, "acecode_id": "bigcode_python_fns_34812", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given an array of integers and a window size. Implement a function `sliding_window_average(arr: List[int], window_size: int) -> List[float]` that computes the average of elements in a sliding window across the array. The window is centered around the current element, an...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert sliding_window_average([1, 2, 3, 4, 5], 3) == [1.5, 2.0, 3.0, 4.0, 4.5]\", \"assert sliding_window_average([1, 1, 1, 1, 1], 1) == [1.0, 1.0, 1.0, 1.0, 1.0]\", \"assert sliding_window_average([1, 3, 2, 4, 6], 1) == [1.0, 3.0, 2.0, 4.0, 6.0]\", \"assert slidin...
{ "split": "train", "index": 78071, "acecode_id": "bigcode_python_fns_29438", "num_tests": 8 }
acecode
[ { "role": "user", "content": "Implement a function that takes a list of integers and returns the list sorted in ascending order. The function should handle any list of integers, including negative numbers and duplicates.\nPlease reason step by step, then write a self-contained Python solution. Give your fin...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert bubble_sort([4, 2, 6, 1, 5, 3]) == [1, 2, 3, 4, 5, 6]\", \"assert bubble_sort([10, -1, 2, 0]) == [-1, 0, 2, 10]\", \"assert bubble_sort([1, 1, 1, 1]) == [1, 1, 1, 1]\", \"assert bubble_sort([]) == []\", \"assert bubble_sort([5]) == [5]\", \"assert bubble_sor...
{ "split": "train", "index": 78072, "acecode_id": "evol_30442", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Implement a function that computes the square root of a given non-negative numerical value using binary search methodology. The function should take a single argument, which is a non-negative float or integer, and return its square root. If the input is a negative number, the f...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert square_root(0) == 0\", \"assert square_root(1) == 1\", \"assert square_root(4) == 2\", \"assert square_root(16) == 4\", \"assert square_root(64) == 8\", \"assert square_root(-4) == None\"]}" }
{ "split": "train", "index": 78073, "acecode_id": "evol_14081", "num_tests": 6 }
acecode
[ { "role": "user", "content": "Given a list of integers, write a function `sum_of_squares(nums)` that returns the sum of the squares of all positive integers in the list. If the list is empty, return 0. The function should handle lists containing negative integers, zero, and positive integers. \n\n### Exampl...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert sum_of_squares([1, -2, 3, 4]) == 26\", \"assert sum_of_squares([-1, -2, -3]) == 0\", \"assert sum_of_squares([]) == 0\", \"assert sum_of_squares([0, 0, 0]) == 0\", \"assert sum_of_squares([5]) == 25\", \"assert sum_of_squares([-5, 5]) == 25\", \"assert sum_o...
{ "split": "train", "index": 78074, "acecode_id": "bigcode_python_fns_32446", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with creating a Python function that extracts the name of a package from a given string resembling a setup.py file content. The package name is typically defined using the `name` attribute within the `setup()` function call. Write a function `extract_package_name...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert extract_package_name('setup(name = \\\"MyPackage\\\", version = \\\"1.0\\\")') == 'MyPackage'\", \"assert extract_package_name('setup(name = \\\"TestPackage\\\", version = \\\"2.0\\\")') == 'TestPackage'\", \"assert extract_package_name('setup(name = \\\"Ano...
{ "split": "train", "index": 78075, "acecode_id": "oss_3815", "num_tests": 5 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function that checks the status of a referral in a company. Each referral is represented by an object that contains a `created_at` timestamp and a `status`. The `status` can be one of the following three values: 'PENDING', 'APPROVED', or 'REJECTED...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert check_referral_status(Referral('2023-01-01T10:00:00Z', Referral.Status.PENDING)) == True\", \"assert check_referral_status(Referral('2023-01-01T10:00:00Z', Referral.Status.APPROVED)) == False\", \"assert check_referral_status(Referral('2023-01-01T10:00:00Z',...
{ "split": "train", "index": 78076, "acecode_id": "oss_18622", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a program to analyze a given string of text and identify the frequency of each unique word. Your program should take a string of text as input and output a dictionary where the keys are the unique words in the text (case-insensitive) and the val...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert word_frequency('Hello world! Hello!') == {'hello': 2, 'world': 1}\", \"assert word_frequency('Python is great, and python is awesome!') == {'python': 2, 'is': 2, 'great': 1, 'and': 1, 'awesome': 1}\", \"assert word_frequency('Data Science is fun; data scienc...
{ "split": "train", "index": 78077, "acecode_id": "oss_37453", "num_tests": 15 }
acecode
[ { "role": "user", "content": "You are tasked with creating a Python function that validates module and package names according to the PEP 8 naming conventions. The PEP 8 guidelines specify that module and package names should be short, all-lowercase, and not contain underscores. Your task is to implement a ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert validate_module_name('math') == True\", \"assert validate_module_name('os') == True\", \"assert validate_module_name('numpy') == True\", \"assert validate_module_name('maths') == True\", \"assert validate_module_name('random') == True\", \"assert validate_mo...
{ "split": "train", "index": 78078, "acecode_id": "oss_35963", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function that generates a filename for saving a report based on a given participant ID and output directory. The function should take in two arguments: a string `output_dir` which represents the directory where the report will be saved, and a stri...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert generate_filename('reports', '12345') == 'reports/12345_report.html'\", \"assert generate_filename('reports/', '12345') == 'reports/12345_report.html'\", \"assert generate_filename('/path/to/reports', 'abcde') == '/path/to/reports/abcde_report.html'\", \"ass...
{ "split": "train", "index": 78079, "acecode_id": "bigcode_python_fns_46002", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Design an algorithm in Python to reverse a doubly linked list. A doubly linked list is a data structure where each node contains a reference to the next node and the previous node. Your task is to implement a function that reverses the doubly linked list in place, ensuring that...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert d.head.next.data == 2\", \"assert d.head.prev == None\", \"assert d.head.next.next.prev.data == 2\", \"assert d.head.next.next.next == None\", \"assert d.head.prev == None\", \"assert d.head.next.data == 2\", \"assert d.head.next.next.next == None\", \"asser...
{ "split": "train", "index": 78080, "acecode_id": "evol_19023", "num_tests": 12 }
acecode
[ { "role": "user", "content": "Given a two-dimensional array (matrix) of integers, implement a function that returns the count of negative values in the matrix. You must use a nested for loop to iterate over the elements of the matrix and include a conditional to check for negative values.\nPlease reason ste...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert count_negative_values([[1, -2, 3], [4, -5, 6], [-7, 8, -9]]) == 4\", \"assert count_negative_values([[0, 0], [0, 0]]) == 0\", \"assert count_negative_values([[-1, -2, -3], [-4, -5, -6]]) == 6\", \"assert count_negative_values([[1, 2, 3], [4, 5, 6]]) == 0\", ...
{ "split": "train", "index": 78081, "acecode_id": "evol_12031", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that takes a list of integers and returns a new list containing only the even numbers from the original list. The function should maintain the original order of the even numbers in the returned list. If there are no even numbers, retu...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert filter_even_numbers([1, 2, 3, 4, 5]) == [2, 4]\", \"assert filter_even_numbers([10, 15, 20, 25]) == [10, 20]\", \"assert filter_even_numbers([1, 3, 5, 7]) == []\", \"assert filter_even_numbers([]) == []\", \"assert filter_even_numbers([0, 1, 2, 3]) == [0, 2]...
{ "split": "train", "index": 78082, "acecode_id": "oss_8616", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given a list of tuples, where each tuple contains two elements: an index and a value. The index is an integer, and the value can either be a number (integer or float) or a string. You need to create a function that processes this list and returns a new list where each n...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert process_cells([(0, 10), (1, 'Hello'), (2, 5.5)], {(0, 10): 'red', (1, 'Hello'): 'blue', (2, 5.5): 'green'}) == ['\\\\cellcolor{red} 10', 'Hello', '\\\\cellcolor{green} 5.5']\", \"assert process_cells([(0, 20), (1, 'World'), (2, 3.2)], {(0, 20): 'yellow', (1,...
{ "split": "train", "index": 78083, "acecode_id": "bigcode_python_fns_22689", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that returns a dictionary containing details about a media device given its identifier and device name. The function should take in two parameters: a string `device_id` representing the identifier of the device and a string `device_na...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_device_details('123', 'Living Room TV') == {'identifier': '123', 'media_class': 'MEDIA_CLASS_DIRECTORY', 'media_content_type': 'MEDIA_TYPE_VIDEO', 'children_media_class': 'MEDIA_CLASS_VIDEO', 'title': 'Device: Living Room TV', 'can_play': False, 'can_exp...
{ "split": "train", "index": 78084, "acecode_id": "bigcode_python_fns_49667", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Write a function `optimize_svg_content(svg_content: str) -> str` that takes a string representation of an SVG file and optimizes it for faster loading on the web. The function should minimize the file size while ensuring that the quality of the SVG is not compromised. It should...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert optimize_svg_content('<svg><rect width=\\\"100\\\" height=\\\"100\\\" fill=\\\"red\\\"/></svg>') == '<svg><rect width=\\\"100\\\" height=\\\"100\\\" fill=\\\"red\\\"/></svg>'\", \"assert optimize_svg_content('<svg><circle cx=\\\"50\\\" cy=\\\"50\\\" r=\\\"40...
{ "split": "train", "index": 78085, "acecode_id": "evol_12882", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a string `s`, implement a function `tokenize(s)` that splits the string into a list of words. The words are defined as sequences of characters separated by spaces. Your function should handle multiple spaces between words as well as leading and trailing spaces. Return the...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert tokenize('Hello World') == ['Hello', 'World']\", \"assert tokenize(' Leading spaces') == ['Leading', 'spaces']\", \"assert tokenize('Trailing spaces ') == ['Trailing', 'spaces']\", \"assert tokenize(' Multiple spaces between words ') == ['Multiple'...
{ "split": "train", "index": 78086, "acecode_id": "bigcode_python_fns_6886", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a list of integers representing the number of parameters for different models, write a function `total_parameters_count(model_parameters: List[int]) -> int` that computes the total number of parameters across all models. The input will be a list of integers representing t...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert total_parameters_count([1, 2, 3]) == 6\", \"assert total_parameters_count([10, 20, 30, 40]) == 100\", \"assert total_parameters_count([0]) == 0\", \"assert total_parameters_count([1]) == 1\", \"assert total_parameters_count([100, 200, 300]) == 600\", \"asser...
{ "split": "train", "index": 78087, "acecode_id": "bigcode_python_fns_38317", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Implement a function `create_stack` that simulates a stack data structure with the operations `push`, `pop`, `peek`, and `is_empty`. The function should accept a maximum size of the stack and return a dictionary with the stack operations. Each operation should handle appropriat...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert stack['push'](1) == True\", \"assert stack['push'](2) == True\", \"assert stack['push'](3) == True\", \"assert stack['pop']() == None\", \"assert stack['is_empty']() == True\", \"assert stack['push'](5) == True\", \"assert stack['push'](6) == True\", \"asser...
{ "split": "train", "index": 78088, "acecode_id": "evol_10073", "num_tests": 9 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a simple game logic for an obstacle avoidance game. The game features a character that moves horizontally on the screen while avoiding obstacles that fall from the top. The character can move left or right based on user inputs. Your task is to i...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert game_logic(400, [(400, 300), (500, 300)]) == (400, False)\", \"assert game_logic(400, [(450, 300), (600, 300)]) == (400, False)\", \"assert game_logic(800, [(700, 300), (750, 300)]) == (750, False)\", \"assert game_logic(50, [(100, 300), (200, 300)]) == (50,...
{ "split": "train", "index": 78089, "acecode_id": "oss_3198", "num_tests": 10 }
acecode
[ { "role": "user", "content": "You are given a string `log` that represents the contents of an output log file. The log contains lines that may include file paths. Your task is to extract the names of files that are specified in two specific formats: lines containing '+ -o' followed by a tab character and li...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert extract_files_from_log('+ -o\\\\tresults/test1.txt\\\\n+++ TASK -> some task output=results/test2.txt\\\\n') == ['test1.txt', 'test2.txt']\", \"assert extract_files_from_log('+++ TASK -> some task output=results/test3.txt\\\\n+++ TASK -> some other task outp...
{ "split": "train", "index": 78090, "acecode_id": "bigcode_python_fns_6890", "num_tests": 11 }
acecode
[ { "role": "user", "content": "You are given a list of integers representing the weights of different items. Your task is to implement a function `max_weight(weights: List[int], limit: int) -> int` that returns the maximum total weight of items that can be carried without exceeding a given weight limit. The ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert max_weight([1, 2, 3, 4, 5], 5) == 5\", \"assert max_weight([5, 1, 2, 3, 4], 10) == 10\", \"assert max_weight([1, 2, 3, 4], 10) == 10\", \"assert max_weight([1, 2, 3, 4, 5], 15) == 15\", \"assert max_weight([1, 2, 3], 0) == 0\", \"assert max_weight([], 10) ==...
{ "split": "train", "index": 78091, "acecode_id": "oss_15393", "num_tests": 15 }
acecode
[ { "role": "user", "content": "Implement a function that takes a list of tuples as an argument, where each tuple contains a string representing the name of a person and an integer representing their age. The function should sort the list first by the integer in descending order and then by the string in alph...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert sort_tuples([('John', 23), ('Adam', 45), ('Zara', 45), ('Molly', 23)]) == [('Adam', 45), ('Zara', 45), ('John', 23), ('Molly', 23)]\", \"assert sort_tuples([('Alice', 30), ('Bob', 25), ('Charlie', 30)]) == [('Alice', 30), ('Charlie', 30), ('Bob', 25)]\", \"a...
{ "split": "train", "index": 78092, "acecode_id": "evol_4187", "num_tests": 13 }
acecode
[ { "role": "user", "content": "Implement a function `prepend_to_min_length(string: str, element: str, min_len: int) -> str` that takes a string and prepends a given character or string to it until the combined length of the string reaches a specified minimum length. If the original string is already of equal...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert prepend_to_min_length('test', '0', 8) == '0000test'\", \"assert prepend_to_min_length('abc', '#', 5) == '##abc'\", \"assert prepend_to_min_length('data', '!', 10) == '!!!!!!data'\", \"assert prepend_to_min_length('code', '1', 7) == '111code'\", \"assert prep...
{ "split": "train", "index": 78093, "acecode_id": "evol_9421", "num_tests": 7 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function that simulates moving a character on a 1D number line. The character starts at position 0 and can move left or right based on the given commands. Your function should take a list of commands where each command is either 'L' (move left) or...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert final_position(['L', 'L', 'L']) == -3\", \"assert final_position(['R', 'R', 'R']) == 3\", \"assert final_position(['L', 'R', 'R', 'L', 'L']) == -1\", \"assert final_position([]) == 0\", \"assert final_position(['L', 'L', 'R', 'R', 'R']) == 1\", \"assert fina...
{ "split": "train", "index": 78094, "acecode_id": "oss_5927", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a singly linked list represented by a series of nodes, determine whether the linked list is well-formed. A well-formed linked list consists of nodes where each node is an instance of the Node class, and it terminates with a None value. Each node has a 'value' and a 'next'...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert is_well_formed(Node(1, None)) == True\", \"assert is_well_formed(Node(1, Node(2, None))) == True\", \"assert is_well_formed(Node(1, Node(2, Node(3, None)))) == True\", \"assert is_well_formed(Node(1, Node(2, Node(3, Node(4, None))))) == True\", \"assert is_w...
{ "split": "train", "index": 78095, "acecode_id": "bigcode_python_fns_9302", "num_tests": 8 }
acecode
[ { "role": "user", "content": "You are given a list of DNA sequence identifiers formatted as strings. Each identifier contains an underscore character ('_') separating the identifier parts. Your task is to write a function that processes this list of identifiers and extracts the second part of each identifie...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert generate_temp_filenames(['seq_001', 'seq_002', 'seq_003']) == ['001.tmp', '002.tmp', '003.tmp']\", \"assert generate_temp_filenames(['id_123', 'data_456', 'info_789']) == ['123.tmp', '456.tmp', '789.tmp']\", \"assert generate_temp_filenames(['no_underscore']...
{ "split": "train", "index": 78096, "acecode_id": "oss_13135", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a Python function that generates a Fibonacci sequence up to a specified length. The function should take in the length of the sequence as its first argument, and the optional second and third arguments to specify the starting numbers of the sequ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert generate_fibonacci_sequence(0) == []\", \"assert generate_fibonacci_sequence(-1) == []\", \"assert generate_fibonacci_sequence(1) == [0]\", \"assert generate_fibonacci_sequence(2) == [0, 1]\", \"assert generate_fibonacci_sequence(3) == [0, 1, 1]\", \"assert ...
{ "split": "train", "index": 78097, "acecode_id": "oss_3050", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function that retrieves the latest version of a record based on a unique identifier. Each record has the following attributes: 'did' (document ID), 'rev' (revision), 'size' (size in bytes), 'form' (type of object), 'created_date' (creation timesta...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_latest_version('id4') == {}\", \"assert get_latest_version('id7') == {}\", \"assert get_latest_version('nonexistent_id') == {}\", \"assert get_latest_version('id15') == {}\", \"assert get_latest_version('id19') == {}\"]}" }
{ "split": "train", "index": 78098, "acecode_id": "bigcode_python_fns_25500", "num_tests": 5 }
acecode
[ { "role": "user", "content": "You are tasked with writing a function `has_permissions` that checks if a user has the specified permissions in a messaging application. The function should accept a variable number of keyword arguments representing permissions, where each permission is a boolean value indicati...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert has_permissions(manage_messages=True, send_messages=True) == True\", \"assert has_permissions(manage_messages=False, send_messages=True) == False\", \"assert has_permissions(manage_messages=True, send_messages=False) == False\", \"assert has_permissions(mana...
{ "split": "train", "index": 78099, "acecode_id": "bigcode_python_fns_6800", "num_tests": 14 }