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": "Given two lists of integers, write a function `sum_pairs(list1, list2)` that takes two arguments: `list1` and `list2`. For each pair of integers formed by the elements at the same index from both lists, calculate their sum. If the sum is even, add it to a variable `even_sum`. I...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert sum_pairs([0, 0, 0], [1, 1, 1]) == (0, 3)\", \"assert sum_pairs([1, 1, 1], [0, 0, 0]) == (0, 3)\", \"assert sum_pairs([], []) == (0, 0)\", \"assert sum_pairs([10, 20], [30, 40]) == (100, 0)\", \"assert sum_pairs([10, 20, 30], [0, 0, 0]) == (60, 0)\", \"asser...
{ "split": "train", "index": 72500, "acecode_id": "evol_22596", "num_tests": 9 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that creates a loss function for a neural network training system based on a specified configuration. The function, `create_loss`, takes a configuration dictionary `config` that contains a key 'loss' which specifies the type of loss f...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert create_loss({'loss': 'L1'}) == 'L1 Loss'\", \"assert create_loss({'loss': 'L2'}) == 'L2 Loss'\", \"assert create_loss({'loss': 'L1'}) == 'L1 Loss'\", \"assert create_loss({'loss': 'L2'}) == 'L2 Loss'\", \"assert create_loss({'loss': 'L1'}) == 'L1 Loss'\", \"...
{ "split": "train", "index": 72501, "acecode_id": "oss_13304", "num_tests": 8 }
acecode
[ { "role": "user", "content": "Given a string `word`, write a function that reverses the string and returns the reversed version. You should implement the function such that it uses minimal extra space.\nPlease reason step by step, then write a self-contained Python solution. Give your final program in a sin...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert reverse_string('hello') == 'olleh'\", \"assert reverse_string('world') == 'dlrow'\", \"assert reverse_string('') == ''\", \"assert reverse_string('a') == 'a'\", \"assert reverse_string('abcde') == 'edcba'\", \"assert reverse_string('12345') == '54321'\", \"a...
{ "split": "train", "index": 72502, "acecode_id": "evol_10512", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function that simulates a simple caching mechanism for blockchain objects. The function should accept a list of object IDs and return a list of blockchain objects. If an object is requested multiple times, the function should return it from the ca...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_blockchain_objects(['12345', '12345', '67890']) == ['Blockchain object with ID 12345', 'Blockchain object with ID 12345', 'Blockchain object with ID 67890']\", \"assert get_blockchain_objects(['abc', 'def', 'abc']) == ['Blockchain object with ID abc', 'B...
{ "split": "train", "index": 72503, "acecode_id": "oss_33507", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given a list of strings representing items in a shopping cart. Your task is to write a function that takes this list as input and returns a new list containing only the items that start with the letter 'A'. The output list should maintain the order of the items as they ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert filter_items_starting_with_a(['Apple', 'Banana', 'Avocado', 'Cherry']) == ['Apple', 'Avocado']\", \"assert filter_items_starting_with_a(['Banana', 'Cherry', 'Mango']) == []\", \"assert filter_items_starting_with_a(['Aardvark', 'Ant', 'Bear', 'Alligator']) ==...
{ "split": "train", "index": 72504, "acecode_id": "oss_23289", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that filters and sorts a list of news articles based on specific criteria. Each news article is represented as a dictionary containing the keys 'title', 'category', and 'views'. Please implement the function `filter_news` that takes a...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert filter_news([{'title': 'Tech Innovation', 'category': 'Technology', 'views': 2000}, {'title': 'Health Advances', 'category': 'Health', 'views': 1500}]) == [{'title': 'Tech Innovation', 'category': 'Technology', 'views': 2000}]\", \"assert filter_news([{'titl...
{ "split": "train", "index": 72505, "acecode_id": "oss_31702", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Implement a function that takes an array of integers as input and returns a tuple containing two elements: a sorted list of unique integers and a dictionary that maps each integer to its count in the original array. The input array may contain duplicates, and the output should ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert count_and_sort([2, 8, 16, 2, 8, 8, 10, 3, 16, 10]) == ([2, 3, 8, 10, 16], {2: 2, 3: 1, 8: 3, 10: 2, 16: 2})\", \"assert count_and_sort([1, 1, 1, 1]) == ([1], {1: 4})\", \"assert count_and_sort([]) == ([], {})\", \"assert count_and_sort([5, 5, 5, 5, 5]) == ([...
{ "split": "train", "index": 72506, "acecode_id": "evol_33409", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given two points in a 2D space represented as tuples (x0, y0) and (x1, y1), write a function `draw_line(p0, p1)` that returns the coordinates of the line segment connecting these two points. The function should return a list of tuples representing each point along the line segm...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert draw_line((0, 0), (1, 1)) == [(0, 0), (1, 1)]\", \"assert draw_line((1, 1), (4, 4)) == [(1, 1), (2, 2), (3, 3), (4, 4)]\", \"assert draw_line((0, 0), (0, 0)) == [(0, 0)]\", \"assert draw_line((1, 2), (1, 2)) == [(1, 2)]\", \"assert draw_line((2, 2), (5, 5)) ...
{ "split": "train", "index": 72507, "acecode_id": "bigcode_python_fns_40603", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function that simulates the creation of database tables based on a given list of table names. The function `create_tables(table_names: List[str]) -> List[str]` should accept a list of strings where each string represents a table name. The function...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert create_tables(['users', 'products', 'orders']) == ['Table users created successfully.', 'Table products created successfully.', 'Table orders created successfully.']\", \"assert create_tables(['users', 'products', 'users']) == ['Table users created successfu...
{ "split": "train", "index": 72508, "acecode_id": "bigcode_python_fns_36896", "num_tests": 12 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a custom function that processes a list of integers representing sequences and returns the maximum value from each sequence. The input consists of a list of sequences, where each sequence is represented as a list of integers. Your function shoul...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert max_values([[1, 2, 3], [4, 5, 6], [7, 8, 9]]) == [3, 6, 9]\", \"assert max_values([[1, -1, 0], [0, 0, 0], [2, 2, 2]]) == [1, 0, 2]\", \"assert max_values([[], [1], [2, 3, 4]]) == [None, 1, 4]\", \"assert max_values([[10], [20, 15], [0]]) == [10, 20, 0]\", \"...
{ "split": "train", "index": 72509, "acecode_id": "oss_31835", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that selects the remaining titans from a list of available titans. The function should take in two parameters: `NUM_TITANS`, an integer representing the total number of titans, and `picked`, a list of integers representing the titans ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert select_remaining_titans(5, [1, 3]) == [0, 2, 4]\", \"assert select_remaining_titans(10, [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]) == []\", \"assert select_remaining_titans(5, []) == [0, 1, 2, 3, 4]\", \"assert select_remaining_titans(1, [0]) == []\", \"assert select_r...
{ "split": "train", "index": 72510, "acecode_id": "oss_25517", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with categorizing a list of modules based on their source directories. Each module name is represented as a string and may contain submodules separated by dots. Write a function `categorize_modules(module_names: List[str]) -> Dict[str, List[str]]` that takes a li...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert categorize_modules(['cloudflare']) == {'cloudflare': ['cloudflare']}\", \"assert categorize_modules(['debug_error']) == {'debug_error': ['debug_error']}\", \"assert categorize_modules(['django']) == {'django': ['django']}\", \"assert categorize_modules(['doc...
{ "split": "train", "index": 72511, "acecode_id": "oss_23914", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function to validate subcluster dependencies based on a given dictionary input. The function should take two parameters: `obj_dict`, a dictionary containing object information, and `db_conn`, an object that simulates a database connection. The...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert validate_subcluster_dep({'sub_cluster_refs': [{'uuid': '12345'}]}, MockDBConn()) == 100\", \"assert validate_subcluster_dep({'sub_cluster_refs': [{'uuid': '12346'}]}, MockDBConn()) == None\", \"assert validate_subcluster_dep({'sub_cluster_refs': []}, MockDBC...
{ "split": "train", "index": 72512, "acecode_id": "oss_13833", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that simulates the lazy instantiation of three different page objects in a web automation framework. The function `get_page` should accept a string input representing the page name ('home', 'payment', or 'flipkart') and return the cor...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_page('home') == 'HomePageFunctions Instance'\", \"assert get_page('payment') == 'PaymentPageFunctions Instance'\", \"assert get_page('flipkart') == 'FlipkartPageFunctions Instance'\", \"assert get_page('home') == 'HomePageFunctions Instance'\", \"assert ...
{ "split": "train", "index": 72513, "acecode_id": "oss_10732", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that parses information about a football draft pick from a given input dictionary. The function should take three parameters: an integer 'year', a string 'draft_type', and a dictionary 'row' that contains the following keys with assoc...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert parse_item(2021, 'NFL', {'draft_round': 1, 'draft_pick': 1, 'team': 'Team A', 'player': 'John Doe', 'position': 'QB', 'age': 22, 'all_pros_first_team': 1, 'pro_bowls': 2, 'career_av': 100, 'draft_av': 80, 'college': 'University A'}) == {'year': 2021, 'draft_...
{ "split": "train", "index": 72514, "acecode_id": "bigcode_python_fns_45783", "num_tests": 14 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function that takes a dictionary where the keys are file types (like 'image', 'document', etc.) and the values are lists of file extensions associated with those file types (like ['.jpg', '.png'] for 'image'). Your function should generate a new d...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert generate_file_extension_map({'image': ['.jpg', '.png'], 'document': ['.pdf', '.docx']}) == {'.jpg': 'image', '.png': 'image', '.pdf': 'document', '.docx': 'document'}\", \"assert generate_file_extension_map({'audio': ['.mp3', '.wav'], 'video': ['.mp4', '.avi...
{ "split": "train", "index": 72515, "acecode_id": "bigcode_python_fns_44570", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Implement a function that takes two lists as input: an operator_set containing basic arithmetic operations and an operand_set containing positive integers. The function should compute the result of applying the operators to the operands in the order they appear. The operator_se...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert compute_arithmetic_seq(['-', '+'], [10, 3, 2]) == 9\", \"assert compute_arithmetic_seq(['**', '+'], [2, 3, 1]) == 9\", \"assert compute_arithmetic_seq(['+', '*', '/'], [5, 3, 2, 1]) == 16\", \"assert compute_arithmetic_seq(['*', '-'], [4, 5, 2]) == 18\", \"a...
{ "split": "train", "index": 72516, "acecode_id": "evol_14512", "num_tests": 8 }
acecode
[ { "role": "user", "content": "Implement a function `factorial(n)` that calculates the factorial of a non-negative integer n. The function should return an appropriate error message for invalid inputs, such as negative numbers, decimal numbers, non-integer types, or numbers greater than 1000. The factorial o...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert factorial(0) == 1\", \"assert factorial(1) == 1\", \"assert factorial(5) == 120\", \"assert factorial(10) == 3628800\", \"assert factorial(20) == 2432902008176640000\", \"assert factorial(999) != 'Invalid input - input is too large'\", \"assert factorial(2) ...
{ "split": "train", "index": 72517, "acecode_id": "evol_15324", "num_tests": 9 }
acecode
[ { "role": "user", "content": "Given a list of options `opts` and a `default` value, write a function `getFirstValid(opts: List[Optional[Any]], default: Any) -> Any` that returns the first valid entry from `opts`. An entry is considered valid if it evaluates to `True`. If no valid entry is found, return the ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert getFirstValid([None, '', 0, 'valid', 5], 'default') == 'valid'\", \"assert getFirstValid([None, '', 0], 'default') == 'default'\", \"assert getFirstValid([False, '', [], 1, 2], 0) == 1\", \"assert getFirstValid(['', None, False, 10], -1) == 10\", \"assert ge...
{ "split": "train", "index": 72518, "acecode_id": "bigcode_python_fns_46477", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given a list of dictionaries where each dictionary represents a property with a 'term' and an 'id'. Your task is to implement a function that extracts the 'term' and 'id' from each property and returns a list of tuples, where each tuple contains the 'term' and 'id' of a...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert extract_properties([]) == []\", \"assert extract_properties([{ 'term': 'House', 'id': 1 }, { 'term': 'Apartment', 'id': 2 }]) == [('House', 1), ('Apartment', 2)]\", \"assert extract_properties([{ 'term': 'Villa', 'id': 3 }]) == [('Villa', 3)]\", \"assert ext...
{ "split": "train", "index": 72519, "acecode_id": "oss_5466", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that takes a string representing the title of a song and returns a message indicating the current song being played. The function should accept a single parameter, `song_title`, which is a string. The output should be a string formatt...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert current_song('Imagine by John Lennon') == 'Currently playing: Imagine by John Lennon'\", \"assert current_song('Bohemian Rhapsody') == 'Currently playing: Bohemian Rhapsody'\", \"assert current_song('') == 'Currently playing: No song currently playing.'\", \...
{ "split": "train", "index": 72520, "acecode_id": "bigcode_python_fns_9356", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given a string token that contains a command followed by its arguments separated by spaces. Your task is to implement a function `do_associate_latest_edit(token: str) -> Tuple[str, str]` that splits the token into two parts: the command and the first argument. If the to...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert do_associate_latest_edit('tag node') == ('tag', 'node')\", \"assert do_associate_latest_edit('command argument') == ('command', 'argument')\", \"assert do_associate_latest_edit('action item') == ('action', 'item')\", \"assert do_associate_latest_edit('hello ...
{ "split": "train", "index": 72521, "acecode_id": "bigcode_python_fns_753", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a Python function that calculates the percentage of occurrences of each unique element in a given list. The function should take a list of elements as input and return a dictionary where the keys are the unique elements from the input list, and ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert calculate_percentages([1, 2, 2, 3, 3, 3, 4, 4, 4, 4]) == {1: 10.0, 2: 20.0, 3: 30.0, 4: 40.0}\", \"assert calculate_percentages([1, 1, 1, 1]) == {1: 100.0}\", \"assert calculate_percentages([2, 3, 4, 5]) == {2: 25.0, 3: 25.0, 4: 25.0, 5: 25.0}\", \"assert ca...
{ "split": "train", "index": 72522, "acecode_id": "oss_20435", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a 2D array of positive integers, calculate the mean of each column and return the results as a 1D array. The mean should be rounded down to the nearest integer. The input will be a matrix of shape (m, n) where m is the number of rows and n is the number of columns. You ne...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert column_mean([[1, 2], [3, 4], [5, 6]]) == [3, 4]\", \"assert column_mean([[10, 20, 30], [40, 50, 60], [70, 80, 90]]) == [40, 50, 60]\", \"assert column_mean([[1, 1], [1, 1], [1, 1]]) == [1, 1]\", \"assert column_mean([[5]]) == [5]\", \"assert column_mean([[1,...
{ "split": "train", "index": 72523, "acecode_id": "bigcode_python_fns_5516", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with simulating the movement of a knight on a chessboard. The knight can move in an 'L' shape: two squares in one direction and then one square perpendicular, or one square in one direction and then two squares perpendicular. Write a function `knight_moves(start:...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert knight_moves((0, 0), [(2, 1), (1, 2), (2, 1)]) == [(0, 0), (2, 1), (3, 3), (5, 4)]\", \"assert knight_moves((5, 5), [(0, 0), (1, 1)]) == [(5, 5), (5, 5), (6, 6)]\", \"assert knight_moves((7, 0), [(0, 0), (2, 1)]) == [(7, 0), (7, 0), (7, 0)]\", \"assert knigh...
{ "split": "train", "index": 72524, "acecode_id": "bigcode_python_fns_4200", "num_tests": 8 }
acecode
[ { "role": "user", "content": "Implement a function `quick_sort(arr: List[int]) -> List[int]` that takes a list of integers and returns a new list containing the same integers sorted in ascending order using the Quicksort algorithm. The input list may contain duplicates and is guaranteed to have at least one...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert quick_sort([8, 5, 3, 9, 1]) == [1, 3, 5, 8, 9]\", \"assert quick_sort([3]) == [3]\", \"assert quick_sort([5, 5, 5]) == [5, 5, 5]\", \"assert quick_sort([2, 1]) == [1, 2]\", \"assert quick_sort([1, 2, 3, 4, 5]) == [1, 2, 3, 4, 5]\", \"assert quick_sort([5, 4,...
{ "split": "train", "index": 72525, "acecode_id": "evol_25958", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a floating-point or integer angle in degrees, implement a function that normalizes the angle to a value between 0 and 360 degrees. The function should handle both positive and negative angles, ensuring that the output is always a non-negative number less than 360. The nor...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert normalize_angle(370) == 10\", \"assert normalize_angle(-10) == 350\", \"assert normalize_angle(360) == 0\", \"assert normalize_angle(720) == 0\", \"assert normalize_angle(-360) == 0\", \"assert normalize_angle(450) == 90\", \"assert normalize_angle(-450) == ...
{ "split": "train", "index": 72526, "acecode_id": "bigcode_python_fns_22226", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given a list of records, where each record is represented as a dictionary. Each record contains a unique 'id' and potentially other fields. Your task is to filter out records that have a specific field 'ignore' set to 'yes', select a subset of records based on given ind...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_selected_records([{'id': 1, 'ignore': 'yes'}, {'id': 2, 'ignore': 'yes'}, {'id': 3, 'ignore': 'yes'}], [0], 1) == []\", \"assert get_selected_records([], [], 1) == []\", \"assert get_selected_records([{'id': 1, 'ignore': 'no'}], [0], 1) == [{'id': 1, 'ig...
{ "split": "train", "index": 72527, "acecode_id": "bigcode_python_fns_894", "num_tests": 6 }
acecode
[ { "role": "user", "content": "Implement a function that determines whether a given integer is odd or even. The function should return 'Even' if the number is even and 'Odd' if the number is odd. Your function should handle both positive and negative integers as well as zero. Write a single function named `i...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert is_odd_or_even(0) == 'Even'\", \"assert is_odd_or_even(1) == 'Odd'\", \"assert is_odd_or_even(-1) == 'Odd'\", \"assert is_odd_or_even(2) == 'Even'\", \"assert is_odd_or_even(-2) == 'Even'\", \"assert is_odd_or_even(3) == 'Odd'\", \"assert is_odd_or_even(-3) ...
{ "split": "train", "index": 72528, "acecode_id": "evol_11322", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Implement a function `reflect_string(input_str: str) -> str` that takes a string as input and returns its reflective counterpart, which is the string reversed. For example, if the input string is 'hello', the output should be 'olleh'.\nPlease reason step by step, then write a s...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert reflect_string('hello') == 'olleh'\", \"assert reflect_string('world') == 'dlrow'\", \"assert reflect_string('') == ''\", \"assert reflect_string('a') == 'a'\", \"assert reflect_string('abc') == 'cba'\", \"assert reflect_string('12345') == '54321'\", \"asser...
{ "split": "train", "index": 72529, "acecode_id": "evol_8707", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a media upload detail retrieval system for a social media platform. The system should allow users to retrieve details of their uploaded media by providing the identifier of the media entity. The media upload detail includes information such as t...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_media_upload_detail(1) == {'title': 'Nature.jpg', 'upload_date': '2022-05-15', 'file_type': 'image', 'size': 256789}\", \"assert get_media_upload_detail(2) == {'title': 'Vacation.mp4', 'upload_date': '2022-04-28', 'file_type': 'video', 'size': 1245789}\"...
{ "split": "train", "index": 72530, "acecode_id": "oss_6013", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with building a function that takes in a list of image builders and returns a list of their names and statuses. Each image builder is represented as a dictionary with various details including 'Name' and 'State'. Your function should handle the input as follows: ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert describe_image_builders([{'Name': 'Builder1', 'State': 'RUNNING'}, {'Name': 'Builder2', 'State': 'STOPPED'}]) == [('Builder1', 'RUNNING'), ('Builder2', 'STOPPED')]\", \"assert describe_image_builders([{'Name': 'BuilderA', 'State': 'PENDING'}, {'Name': 'Build...
{ "split": "train", "index": 72531, "acecode_id": "bigcode_python_fns_45612", "num_tests": 16 }
acecode
[ { "role": "user", "content": "In Python, write a function called 'custom_length()' that takes a single argument, which can be any iterable (like a string, list, or dictionary), and returns the number of elements in that iterable. If the input is not an iterable, the function should return None. Please ensur...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert custom_length('hello') == 5\", \"assert custom_length([1, 2, 3, 4, 5]) == 5\", \"assert custom_length({'a': 1, 'b': 2}) == 2\", \"assert custom_length([]) == 0\", \"assert custom_length({}) == 0\", \"assert custom_length('') == 0\", \"assert custom_length((1...
{ "split": "train", "index": 72532, "acecode_id": "evol_28728", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Design a function that receives a list of names, where each name is represented as a list containing three strings: first name, middle name, and last name. The function should format them in the following way: middle name + space + first letter of the first name + period + spac...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert format_names([['John', 'Alexander', 'Smith'], ['Timothy', 'Lee', 'Brown'], ['Jane', 'Alexandra', 'Doe']]) == ['Alexander J. Smith', 'Alexandra J. Doe', 'Lee T. Brown']\", \"assert format_names([['', 'Middle', 'Name']]) == 'No name was in the proper format. P...
{ "split": "train", "index": 72533, "acecode_id": "evol_17413", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that converts a nested structure containing either numerical tensors or statistical distributions into a simplified format. Each distribution should be converted to a dictionary that contains only its numerical parameters, while any t...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert convert_structure({'param': {'parameters': {'mean': 3.0, 'stddev': 1.0}}, 'tensor': 5}) == {'param': {'mean': 3.0, 'stddev': 1.0}, 'tensor': 5}\", \"assert convert_structure({'a': 10, 'b': {'parameters': {'mu': 0.5, 'sigma': 2.0}}, 'c': 20}) == {'a': 10, 'b'...
{ "split": "train", "index": 72534, "acecode_id": "bigcode_python_fns_3773", "num_tests": 13 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function to generate a future trajectory for a robot based on a list of future poses. The function `generate_future_trajectory` takes one parameter: `future_pose_list`, which is a list of tuples representing future positions of the robot in th...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert generate_future_trajectory([(1, 2, 3), (4, 5, 6)]) == ['Position: (1, 2, 3)', 'Position: (4, 5, 6)']\", \"assert generate_future_trajectory([(0, 0, 0)]) == ['Position: (0, 0, 0)']\", \"assert generate_future_trajectory([(10, 20, 30), (40, 50, 60), (70, 80, 9...
{ "split": "train", "index": 72535, "acecode_id": "oss_29883", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a list of lists of integers, implement a function that sorts the individual lists in descending order and then sorts the container list based upon the minimum element from each of the lists in descending order. Write a function called `sort_lists(lst)` that takes a list o...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert sort_lists([[10, 20], [5, 2, 1], [30]]) == [[30], [20, 10], [5, 2, 1]]\", \"assert sort_lists([[1], [2], [3], [4]]) == [[4], [3], [2], [1]]\", \"assert sort_lists([[0], [-1], [1], [2]]) == [[2], [1], [0], [-1]]\", \"assert sort_lists([[1], [1], [1]]) == [[1]...
{ "split": "train", "index": 72536, "acecode_id": "evol_28955", "num_tests": 11 }
acecode
[ { "role": "user", "content": "Given a positive integer n, return the n-th triangle number. Triangle numbers are derived from the summation of the first n natural numbers. The n-th triangle number can be calculated using the formula T(n) = n * (n + 1) / 2. Implement a function `triangle_number(n: int) -> int...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert triangle_number(1) == 1\", \"assert triangle_number(2) == 3\", \"assert triangle_number(3) == 6\", \"assert triangle_number(4) == 10\", \"assert triangle_number(5) == 15\", \"assert triangle_number(6) == 21\", \"assert triangle_number(7) == 28\", \"assert tr...
{ "split": "train", "index": 72537, "acecode_id": "evol_854", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with calculating an employee's new pay amount based on their current pay. Given an employee's current pay amount, implement a function called `calculate_new_pay` that returns the new pay amount after applying a multiplier. The function should work as follows: if ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert calculate_new_pay(45000) == 54000.0\", \"assert calculate_new_pay(50000) == 65000.0\", \"assert calculate_new_pay(60000) == 78000.0\", \"assert calculate_new_pay(0) == 0.0\", \"assert calculate_new_pay(-10000) == -12000.0\", \"assert calculate_new_pay(100000...
{ "split": "train", "index": 72538, "acecode_id": "oss_22080", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given a list of dictionaries where each dictionary contains a key 'name' with a string value representing a person's name. Your task is to implement a function `sort_names(name_list)` that returns a sorted list of unique names. The function should ensure that names appe...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert sort_names([{'name': 'John'}, {'name': 'Jane'}, {'name': 'Sue'}, {'name': 'Jane'}, {'name': 'Lucy'}, {'name': 'Omar'}, {'name': 'Brenda'}, {'name': 'Arthur'}, {'name': 'Zoe'}, {'name': 'Freda'}]) == ['Arthur', 'Brenda', 'Freda', 'Jane', 'John', 'Lucy', 'Omar...
{ "split": "train", "index": 72539, "acecode_id": "evol_13489", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a list of integers, implement a function `quick_sort` that sorts the list in non-decreasing order using the quick sort algorithm. The function should take a single parameter `seq`, which is a list of integers that can be empty or contain both positive and negative numbers...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert quick_sort([0, 5, 3, 2, 2]) == [0, 2, 2, 3, 5]\", \"assert quick_sort([]) == []\", \"assert quick_sort([-2, -5, -45]) == [-45, -5, -2]\", \"assert quick_sort([1, 2, 3, 4, 5]) == [1, 2, 3, 4, 5]\", \"assert quick_sort([5, 4, 3, 2, 1]) == [1, 2, 3, 4, 5]\", \"...
{ "split": "train", "index": 72540, "acecode_id": "bigcode_python_fns_46011", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a matrix of n*m size where each cell contains a string of a single character, implement a function that finds the one-dimensional index pair (i,j) such that matrix[i][j] is equal to a given character 'c'. Assume the given matrix is not empty and contains the character 'c'...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert find_char([['a', 'b', 'c'], ['d', 'e', 'f'], ['g', 'h', 'c']], 'c') == (0, 2)\", \"assert find_char([['x', 'y', 'z'], ['a', 'b', 'c'], ['d', 'e', 'f']], 'a') == (1, 0)\", \"assert find_char([['1', '2', '3'], ['4', '5', '6'], ['7', '8', '9']], '5') == (1, 1)\...
{ "split": "train", "index": 72541, "acecode_id": "evol_25762", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with calculating the dispersion measure (DM) of the intergalactic medium (IGM) based on a given redshift value. The relationship between the dispersion measure and redshift is defined by the equation: DM = slope * z, where 'slope' is a constant value provided as ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert calculate_dispersion_measure(0.5, 950, None, 'normal') == 475.0\", \"assert calculate_dispersion_measure(1.5, 800, None, 'log10normal') == 1200.0\", \"assert calculate_dispersion_measure(0.2, 600, None, 'normal') == 120.0\", \"assert calculate_dispersion_mea...
{ "split": "train", "index": 72542, "acecode_id": "bigcode_python_fns_40013", "num_tests": 8 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function that processes a list of Helm repository names and simulates the removal of these repositories. The function should take an array of repository names as input and return a dictionary containing the status code and a message indicating the...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert simulate_helm_repo_remove(['stable', 'local', 'nalkinscloud']) == {'status': 0, 'value': 'no errors found'}\", \"assert simulate_helm_repo_remove(['repo1', 'repo2', 'repo3']) == {'status': 0, 'value': 'no errors found'}\", \"assert simulate_helm_repo_remove(...
{ "split": "train", "index": 72543, "acecode_id": "bigcode_python_fns_47429", "num_tests": 13 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function that determines a value based on two inputs: `action` (a string representing a direction, either 'L' for left or 'R' for right) and `degrees` (an integer representing an angle). The function should return the following values based on the...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert determine_value('L', 0) == 1\", \"assert determine_value('R', 0) == -1\", \"assert determine_value('L', 180) == 1\", \"assert determine_value('R', 180) == -1\", \"assert determine_value('L', 270) == 1\", \"assert determine_value('R', 270) == -1\", \"assert d...
{ "split": "train", "index": 72544, "acecode_id": "oss_331", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Implement a function called `fibonacci_at_index` that takes a single integer `n` as its parameter and returns the `n`-th value in the Fibonacci sequence. The Fibonacci sequence is defined as follows: F(0) = 0, F(1) = 1, and F(n) = F(n-1) + F(n-2) for n >= 2. For example, if the...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert fibonacci_at_index(0) == 0\", \"assert fibonacci_at_index(1) == 1\", \"assert fibonacci_at_index(2) == 1\", \"assert fibonacci_at_index(3) == 2\", \"assert fibonacci_at_index(4) == 3\", \"assert fibonacci_at_index(5) == 5\", \"assert fibonacci_at_index(6) ==...
{ "split": "train", "index": 72545, "acecode_id": "evol_22814", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Write a function `calc_matrix_product(matrix)` that takes a bi-dimensional list (matrix) of integers as input and returns the product of all the elements in the matrix. The matrix will contain at least one element and can have any number of rows and columns.\nPlease reason step...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert calc_matrix_product([[1]]) == 1\", \"assert calc_matrix_product([[1, 2], [3, 4]]) == 24\", \"assert calc_matrix_product([[0]]) == 0\", \"assert calc_matrix_product([[1, 2, 3], [4, 5, 6]]) == 720\", \"assert calc_matrix_product([[7, 8], [9, 10], [11, 12]]) ==...
{ "split": "train", "index": 72546, "acecode_id": "evol_34794", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with creating a Python function that updates a dictionary based on the provided input. The function should take in two parameters: an existing dictionary and a dictionary of updates. You need to implement the `update_dictionary` function that performs the followi...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert update_dictionary({'a': 1, 'b': 2}, {'b': 3}) == {'a': 1, 'b': 3}\", \"assert update_dictionary({'a': 1, 'b': 2}, {'c': 3}) == {'a': 1, 'b': 2}\", \"assert update_dictionary({'a': 1, 'b': 2}, {}) == {'a': 1, 'b': 2}\", \"assert update_dictionary({'name': 'Al...
{ "split": "train", "index": 72547, "acecode_id": "oss_31804", "num_tests": 13 }
acecode
[ { "role": "user", "content": "Given a positive integer n, write a function to determine the smallest power of 2 that is greater than or equal to n. The function should return this power of 2. For example, if n = 5, the function should return 8, as 8 is the smallest power of 2 greater than 5.\nPlease reason ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert next_power_of_2(1) == 1\", \"assert next_power_of_2(2) == 2\", \"assert next_power_of_2(3) == 4\", \"assert next_power_of_2(4) == 4\", \"assert next_power_of_2(5) == 8\", \"assert next_power_of_2(6) == 8\", \"assert next_power_of_2(7) == 8\", \"assert next_p...
{ "split": "train", "index": 72548, "acecode_id": "bigcode_python_fns_43511", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Write a function `is_admin()` that checks if the current user has administrative privileges on a Windows system. The function should return `True` if the user is an administrator and `False` otherwise. You may assume that the function will only be run in a Windows environment.\...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert is_admin() == False\", \"assert is_admin() == False\", \"assert is_admin() == False\", \"assert is_admin() == False\", \"assert is_admin() == False\", \"assert is_admin() == False\", \"assert is_admin() == False\", \"assert is_admin() == False\", \"assert is...
{ "split": "train", "index": 72549, "acecode_id": "evol_7813", "num_tests": 10 }
acecode
[ { "role": "user", "content": "You are given a string representing a URL. Write a function `check_url` that verifies if the URL is valid. A valid URL must start with 'http' or 'https' and should be a non-empty string. If the URL is valid, return True; otherwise, return False. The function should handle cases...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert check_url('http://example.com') == True\", \"assert check_url('https://example.com') == True\", \"assert check_url('ftp://example.com') == False\", \"assert check_url('example.com') == False\", \"assert check_url('') == False\", \"assert check_url('http://')...
{ "split": "train", "index": 72550, "acecode_id": "bigcode_python_fns_5703", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given a 2D grid representing a height map where the value of each cell represents the height at that cell. Implement a function `calculateGradient` that takes the height map as input and returns a new 2D grid representing the gradient of the height at each cell. The gra...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert calculateGradient([[1,2,3],[4,5,6],[7,8,9]]) == [[3,3,3],[3,3,3],[3,3,3]]\", \"assert calculateGradient([[0,0,0],[0,0,0],[0,0,0]]) == [[0,0,0],[0,0,0],[0,0,0]]\", \"assert calculateGradient([[1]]) == [[0]]\", \"assert calculateGradient([[1,2],[3,4]]) == [[2,...
{ "split": "train", "index": 72551, "acecode_id": "oss_17461", "num_tests": 11 }
acecode
[ { "role": "user", "content": "You are tasked with writing a function that checks if a given number is a prime number. A prime number is a natural number greater than 1 that cannot be formed by multiplying two smaller natural numbers. Your function should return True if the number is prime and False otherwis...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert is_prime(2) == True\", \"assert is_prime(3) == True\", \"assert is_prime(4) == False\", \"assert is_prime(5) == True\", \"assert is_prime(6) == False\", \"assert is_prime(7) == True\", \"assert is_prime(8) == False\", \"assert is_prime(9) == False\", \"asser...
{ "split": "train", "index": 72552, "acecode_id": "oss_16738", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with adding a new field to an existing data model in a Django application. The model is part of an application named \"saef\". Write a migration code that adds a new field named 'description' of type CharField with a maximum length of 255 to the model 'Product'. ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert add_field_migration() == \\\"from django.db import migrations, models\\\\n\\\\nclass Migration(migrations.Migration):\\\\n dependencies = [\\\\n ('saef', '0025_auto_20210809_1555'),\\\\n ]\\\\n operations = [\\\\n migrations.AddField(\...
{ "split": "train", "index": 72553, "acecode_id": "oss_13125", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given a list of integers representing a series of measurements. Your task is to implement a function that takes this list and returns a new list containing only the unique measurements, preserving the order of their first occurrence. For example, given the input list [1...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert unique_measurements([1, 2, 2, 3, 4, 3, 5]) == [1, 2, 3, 4, 5]\", \"assert unique_measurements([5, 5, 5, 5]) == [5]\", \"assert unique_measurements([1, 2, 3, 4, 5]) == [1, 2, 3, 4, 5]\", \"assert unique_measurements([]) == []\", \"assert unique_measurements([...
{ "split": "train", "index": 72554, "acecode_id": "bigcode_python_fns_7262", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given a string containing a sequence of characters. Your task is to implement a function `is_valid_sequence(s: str) -> bool` that checks if the sequence is valid. A valid sequence must meet the following criteria: 1) It must not contain any digits. 2) It must not contai...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert is_valid_sequence('Hello world') == True\", \"assert is_valid_sequence('Hello, world.') == True\", \"assert is_valid_sequence('') == False\", \"assert is_valid_sequence('123') == False\", \"assert is_valid_sequence('Hello!') == False\", \"assert is_valid_seq...
{ "split": "train", "index": 72555, "acecode_id": "bigcode_python_fns_7694", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that checks if a user has permission to save a file to their library based on the file's owner and the user's identity. Given the owner's username, the user's username, and a flag indicating whether the user is allowed to save the fil...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert check_permission_and_save('alice', 'alice', True) == 'Successfully saved.'\", \"assert check_permission_and_save('charlie', 'charlie', True) == 'Successfully saved.'\", \"assert check_permission_and_save('hannah', 'hannah', True) == 'Successfully saved.'\", ...
{ "split": "train", "index": 72556, "acecode_id": "bigcode_python_fns_14712", "num_tests": 8 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that processes a list of integers and returns a new list containing only the even numbers from the original list, in the same order they appeared. The function should be named `filter_even_numbers`. Given a list of integers, the funct...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert filter_even_numbers([1, 2, 3, 4, 5, 6]) == [2, 4, 6]\", \"assert filter_even_numbers([7, 8, 9, 10]) == [8, 10]\", \"assert filter_even_numbers([1, 3, 5]) == []\", \"assert filter_even_numbers([0, 2, 4, 6, 8]) == [0, 2, 4, 6, 8]\", \"assert filter_even_number...
{ "split": "train", "index": 72557, "acecode_id": "oss_1060", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given a list of integers representing the pages of a book. Your task is to implement a function that returns a new list containing only the unique page numbers from the original list in ascending order. Write a function called `get_unique_pages(pages: List[int]) -> List...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_unique_pages([1, 2, 3, 4, 5]) == [1, 2, 3, 4, 5]\", \"assert get_unique_pages([5, 5, 5, 5]) == [5]\", \"assert get_unique_pages([3, 1, 2, 1, 3]) == [1, 2, 3]\", \"assert get_unique_pages([]) == []\", \"assert get_unique_pages([10, 9, 8, 7, 6]) == [6, 7, ...
{ "split": "train", "index": 72558, "acecode_id": "bigcode_python_fns_35063", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Implement a function `encode_cyclic(s: str, shift: int = 3) -> str` that encodes an input string using a Caesar Cipher. The shift varies based on the character's position in the string. Non-alphabetic characters should remain unchanged. The shift for each character is determine...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert encode_cyclic('123456', 3) == '123456'\", \"assert encode_cyclic('', 5) == ''\", \"assert encode_cyclic('A', 1) == 'A'\", \"assert encode_cyclic(' ', 3) == ' '\", \"assert encode_cyclic('!@#$%^&*()', 2) == '!@#$%^&*()'\"]}" }
{ "split": "train", "index": 72559, "acecode_id": "evol_26175", "num_tests": 5 }
acecode
[ { "role": "user", "content": "Given an integer x and a positive integer n, implement a function that calculates the sum of the series x^1 + x^2 + x^3 + ... + x^n. The function should take two parameters: an integer x and a positive integer n, and return the computed summation value.\nPlease reason step by s...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert func(2, 3) == 14\", \"assert func(3, 2) == 12\", \"assert func(1, 5) == 5\", \"assert func(0, 4) == 0\", \"assert func(5, 1) == 5\", \"assert func(10, 0) == 0\", \"assert func(4, 2) == 20\", \"assert func(7, 1) == 7\", \"assert func(2, 0) == 0\", \"assert fu...
{ "split": "train", "index": 72560, "acecode_id": "evol_16600", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Write a function that counts the occurrences of all consonants in a given sentence and returns them in descending order. The function should be case-insensitive and should ignore special characters and spaces. If the input is not a string, return an error message indicating inv...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert count_consonants('') == []\", \"assert count_consonants('12345!!!') == []\", \"assert count_consonants('Hello World!') == [('l', 3), ('h', 1), ('w', 1), ('r', 1), ('d', 1)]\", \"assert count_consonants('Invalid input!') == [('n', 2), ('v', 1), ('l', 1), ('d'...
{ "split": "train", "index": 72561, "acecode_id": "evol_787", "num_tests": 5 }
acecode
[ { "role": "user", "content": "You are given a list of integers representing the power states of nodes in a cluster. Each node can either be 'on' (represented by 1) or 'off' (represented by 0). Your task is to implement a function `powercycle_nodes(states: List[int]) -> List[int]` that returns a new list whe...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert powercycle_nodes([1, 0, 1, 1]) == [0, 1, 0, 0]\", \"assert powercycle_nodes([0, 0, 0, 0]) == [1, 1, 1, 1]\", \"assert powercycle_nodes([1]) == [0]\", \"assert powercycle_nodes([0]) == [1]\", \"assert powercycle_nodes([0, 1]) == [1, 0]\", \"assert powercycle_...
{ "split": "train", "index": 72562, "acecode_id": "bigcode_python_fns_27114", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a list of elements and a specific entity, implement a function that removes all instances of that entity from the list and returns the modified list. The input list can contain elements of any type. Your function should maintain the order of the remaining elements.\nPleas...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert expunge_entity([1, 2, 3, 2, 4], 2) == [1, 3, 4]\", \"assert expunge_entity(['a', 'b', 'c', 'b', 'd'], 'b') == ['a', 'c', 'd']\", \"assert expunge_entity([], 1) == []\", \"assert expunge_entity([1, 1, 1], 1) == []\", \"assert expunge_entity([1, 2, 3], 4) == [...
{ "split": "train", "index": 72563, "acecode_id": "evol_23242", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that simulates the basic behavior of an osmotic ensemble under fixed parameters. Your function should take four parameters: N_A (the number of particles of type A), mu_B (the chemical potential of particles of type B), P (the pressure...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert osmotic_ensemble_simulation(100, 10.0, 1.0, 300) == {'num_particles': 200, 'pressure': 1.0, 'temperature': 300}\", \"assert osmotic_ensemble_simulation(0, 10.0, 1.0, 300) == {'num_particles': 0, 'pressure': 1.0, 'temperature': 300}\", \"assert osmotic_ensemb...
{ "split": "train", "index": 72564, "acecode_id": "oss_31198", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that processes and formats data from a 3D array into a specific string format. The function takes in three parameters: `header` (a string representing the header of the data), `data` (a 3D array containing the data to be processed), a...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert process_data('Sample Data', [[[1, 2, 3], [4, 5, 6]], [[7, 8, 9], [10, 11, 12]]], (2, 2, 3)) == ['Sample Data', '1 2 3', '4 5 6', '7 8 9', '10 11 12']\", \"assert process_data('Header', [[[1], [2]], [[3], [4]]], (2, 2, 1)) == ['Header', '1', '2', '3', '4']\",...
{ "split": "train", "index": 72565, "acecode_id": "oss_26243", "num_tests": 15 }
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 integers from the original list, preserving their order. Implement a function `filter_even_numbers(nums: List[int]) -> List[int]` where `nums` is the input ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert filter_even_numbers([1, 2, 3, 4, 5, 6]) == [2, 4, 6]\", \"assert filter_even_numbers([10, 15, 20, 25, 30]) == [10, 20, 30]\", \"assert filter_even_numbers([-2, -1, 0, 1, 2]) == [-2, 0, 2]\", \"assert filter_even_numbers([]) == []\", \"assert filter_even_numb...
{ "split": "train", "index": 72566, "acecode_id": "oss_9794", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with managing a list of software projects. Each project has an identifier, a learning technology, a primary technology, and a list of tools used in the project. Write a function `add_project` that takes a list of projects and a new project as input. The function ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert add_project([], {'id': '1', 'learning': 'Python', 'tech': 'Flask', 'tools': 'SQLAlchemy'}) == [{'id': '1', 'learning': 'Python', 'tech': 'Flask', 'tools': 'SQLAlchemy'}]\", \"assert add_project([{'id': '1', 'learning': 'Python', 'tech': 'Flask', 'tools': 'SQ...
{ "split": "train", "index": 72567, "acecode_id": "oss_6362", "num_tests": 15 }
acecode
[ { "role": "user", "content": "Given a list of non-empty strings, implement a function `get_first_characters(strings)` that returns a list containing the first character of each string in the input list. If the input list is empty, the function should return an empty list. It is guaranteed that no string in ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_first_characters(['apple', 'banana', 'cherry']) == ['a', 'b', 'c']\", \"assert get_first_characters(['dog', 'cat', 'mouse']) == ['d', 'c', 'm']\", \"assert get_first_characters(['python', 'java', 'c++']) == ['p', 'j', 'c']\", \"assert get_first_character...
{ "split": "train", "index": 72568, "acecode_id": "bigcode_python_fns_27109", "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 integers from the original list. Your function should maintain the order of the even integers as they appeared in the input list. Implement a function calle...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert filter_even_numbers([1, 2, 3, 4, 5]) == [2, 4]\", \"assert filter_even_numbers([2, 4, 6, 8]) == [2, 4, 6, 8]\", \"assert filter_even_numbers([1, 3, 5, 7]) == []\", \"assert filter_even_numbers([]) == []\", \"assert filter_even_numbers([-2, -1, 0, 1, 2]) == [...
{ "split": "train", "index": 72569, "acecode_id": "oss_21092", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function that simulates the creation of a ResNet model, specifically a ResNet 101 architecture. The function, `wide_resnet101`, takes in the following parameters: `input_shape` (a tuple representing the shape of the input data), `num_classes` ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert wide_resnet101((224, 224, 3), 10, False, False) == 'ResNet 101: input_shape=(224, 224, 3), num_classes=10, dense_classifier=False, pretrained=False'\", \"assert wide_resnet101((224, 224, 3), 10, True, False) == 'ResNet 101: input_shape=(224, 224, 3), num_cla...
{ "split": "train", "index": 72570, "acecode_id": "bigcode_python_fns_18495", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given a list of news articles, where each article is represented as a dictionary with a 'title' and a 'publication_status'. Your task is to implement a function called `get_published_articles` that takes a list of articles and returns a new list containing only the arti...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_published_articles([{'title': 'Article 1', 'publication_status': 'published'}, {'title': 'Article 2', 'publication_status': 'draft'}]) == [{'title': 'Article 1', 'publication_status': 'published'}]\", \"assert get_published_articles([{'title': 'Article 3...
{ "split": "train", "index": 72571, "acecode_id": "oss_28308", "num_tests": 15 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function that generates a URL-friendly slug from a given title. The slug should be a lowercase version of the title, with spaces replaced by hyphens and any special characters removed. Your function should take a single string input representing t...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert generate_slug('Hello World') == 'hello-world'\", \"assert generate_slug('Python is Awesome!') == 'python-is-awesome'\", \"assert generate_slug('SingleWord') == 'singleword'\", \"assert generate_slug('Uppercase Letters') == 'uppercase-letters'\", \"assert gen...
{ "split": "train", "index": 72572, "acecode_id": "oss_16545", "num_tests": 11 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function that simulates sending a POST request to a given URL with a set of parameters. Your function should take a URL as a string and any number of keyword arguments representing the data to be sent in the POST request. The function should retur...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert simulate_post_request('http://example.com', param1='value1', param2='value2') == {'url': 'http://example.com', 'data': {'param1': 'value1', 'param2': 'value2'}}\", \"assert simulate_post_request('http://test.com') == {'url': 'http://test.com', 'data': {}}\",...
{ "split": "train", "index": 72573, "acecode_id": "bigcode_python_fns_8350", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are given a dictionary of software versions and their corresponding package names. Your task is to update the package name for a specific version if it exists in the dictionary. If the version is not found in the dictionary, you should not make any updates. Write a function...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert update_package_name({'1.0': 'package1', '1.1': 'package2'}, '1.0', 'new_package1') == {'1.0': 'new_package1', '1.1': 'package2'}\", \"assert update_package_name({'1.0': 'package1', '1.1': 'package2'}, '1.1', 'new_package2') == {'1.0': 'package1', '1.1': 'new...
{ "split": "train", "index": 72574, "acecode_id": "bigcode_python_fns_8544", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a logging system for a software application. The application has multiple modules, and each module requires its own logger with a specific name. Your goal is to write a function `get_module_logger(module_name)` that takes a `module_name` as inpu...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_module_logger('interface').name == 'BLUSE.interface'\", \"assert get_module_logger('database').name == 'BLUSE.database'\", \"assert get_module_logger('api').name == 'BLUSE.api'\", \"assert get_module_logger('auth').name == 'BLUSE.auth'\", \"assert get_mo...
{ "split": "train", "index": 72575, "acecode_id": "oss_14647", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with creating a simple function that initializes a text-to-speech (TTS) engine based on a given engine name. The function should accept a string input representing the name of the TTS engine and return a corresponding initialization message. If the engine name is...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert initialize_tts('IBM') == 'IBM TTS Initialized'\", \"assert initialize_tts('pytts') == 'pytts TTS Initialized'\", \"assert initialize_tts('google') == 'Unknown TTS Engine'\", \"assert initialize_tts('microsoft') == 'Unknown TTS Engine'\", \"assert initialize_...
{ "split": "train", "index": 72576, "acecode_id": "bigcode_python_fns_23079", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Implement a function `validate_phone_number(input_number: str) -> bool` that validates a given telephone number based on the conventional format used in the United States. The valid format for a telephone number is '(XXX) XXX-XXXX', where 'X' is a digit from 0 to 9. The functio...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert validate_phone_number('(123) 456-7890') == True\", \"assert validate_phone_number('(987) 654-3210') == True\", \"assert validate_phone_number('(000) 000-0000') == True\", \"assert validate_phone_number('(123) 123-1234') == True\", \"assert validate_phone_num...
{ "split": "train", "index": 72577, "acecode_id": "evol_23959", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function that generates a list of permissions for a given list of database table names. Each permission should follow the format 'Can SELECT from {table_name} table'. The function should take a list of table names as input and return a list of cor...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert generate_permissions(['users', 'products', 'orders']) == ['Can SELECT from users table', 'Can SELECT from products table', 'Can SELECT from orders table']\", \"assert generate_permissions(['customers', 'invoices']) == ['Can SELECT from customers table', 'Can...
{ "split": "train", "index": 72578, "acecode_id": "bigcode_python_fns_572", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given an array of integers, implement a function that calculates the sum of the cubes of all its elements. For every third element in the array (considering a 1-based index), instead of adding its cube to the total sum, subtract that cube from the total sum. Return the final co...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert sum_of_cubes([0, 0, 0]) == 0\", \"assert sum_of_cubes([3]) == 27\", \"assert sum_of_cubes([1, 2]) == 9\", \"assert sum_of_cubes([-1, -2]) == -9\", \"assert sum_of_cubes([]) == 0\"]}" }
{ "split": "train", "index": 72579, "acecode_id": "evol_29227", "num_tests": 5 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a URL routing system for a web application. You need to define a list of URL patterns that map specific paths to their corresponding view functions. Each URL pattern is defined as a tuple containing the URL path as a string, the view function as...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert add_contact_url([]) == [('contact/', 'contact_view', 'contact')]\", \"assert add_contact_url([('home/', 'home_view', 'home')]) == [('home/', 'home_view', 'home'), ('contact/', 'contact_view', 'contact')]\", \"assert add_contact_url([('about/', 'about_view', ...
{ "split": "train", "index": 72580, "acecode_id": "oss_31447", "num_tests": 10 }
acecode
[ { "role": "user", "content": "Create a function `greetings_generator` in Python that takes two arguments: a string `message` and an integer `n`. The function should return a new string consisting of the input message concatenated n times. Each concatenation should have a newline character in between.\nPleas...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert greetings_generator('Hello, World!', 3) == 'Hello, World!\\\\nHello, World!\\\\nHello, World!\\\\n'\", \"assert greetings_generator('Python is great!', 1) == 'Python is great!\\\\n'\", \"assert greetings_generator('Test message', 0) == ''\", \"assert greetin...
{ "split": "train", "index": 72581, "acecode_id": "evol_30162", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Write a function `validate_mac_address(mac_address: str) -> bool` that checks if the given string `mac_address` is a valid MAC (Media Access Control) address. A valid MAC address follows the format of six groups of two hexadecimal digits, separated by either a colon (:) or a hy...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert validate_mac_address('00:1A:2B:3C:4D:5E') == True\", \"assert validate_mac_address('00-1A-2B-3C-4D-5E') == True\", \"assert validate_mac_address('00:1A:2B:3C:4D:5G') == False\", \"assert validate_mac_address('00:1A:2B:3C:4D') == False\", \"assert validate_ma...
{ "split": "train", "index": 72582, "acecode_id": "evol_9291", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a string `s`, implement a function that counts the total number of uninterrupted sub-segments within the string where each character in the sub-segment is lexicographically greater than or equal to the previous character. The function should return the total count of such...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert count_subsegments('abcde') == 15\", \"assert count_subsegments('zyx') == 3\", \"assert count_subsegments('aaa') == 6\", \"assert count_subsegments('a') == 1\", \"assert count_subsegments('abca') == 7\", \"assert count_subsegments('abcdefg') == 28\", \"assert...
{ "split": "train", "index": 72583, "acecode_id": "evol_16702", "num_tests": 9 }
acecode
[ { "role": "user", "content": "You are given a nested dictionary structure that contains information about interconnectors and their associated offer collections. Write a function `get_offer_index(data)` that takes a dictionary `data` as input and returns a list of tuples. Each tuple should contain two eleme...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_offer_index({'NEMSPDCaseFile': {'NemSpdInputs': {'PeriodCollection': {'Period': {'InterconnectorPeriodCollection': {'InterconnectorPeriod': [{'@InterconnectorID': 'E', 'MNSPOfferCollection': None}, {'@InterconnectorID': 'F', 'MNSPOfferCollection': None}]...
{ "split": "train", "index": 72584, "acecode_id": "bigcode_python_fns_30637", "num_tests": 9 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function that simulates a sensor kit query for different device types. Each sensor kit has attributes: device_type, architecture, sensor_type, and version. Your function should take a list of sensor kits and return a list of dictionaries, where ea...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert simulate_sensor_query([('LINUX', '64', 'SUSE', '1.2.3.4')]) == [{'sensor_type': {'device_type': 'LINUX', 'architecture': '64', 'type': 'SUSE', 'version': '1.2.3.4'}, 'sensor_url': 'https://SensorURL0', 'sensor_config_url': 'https://SensorConfigURL0', 'error_...
{ "split": "train", "index": 72585, "acecode_id": "bigcode_python_fns_38104", "num_tests": 12 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function `get_default_builder()` that determines the default builder plugin name based on certain conditions. The function should check the provided configuration dictionary for the following keys: 'builder' in 'gitconfig' and 'builder' in 'bu...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_default_builder({'gitconfig': {'builder': 'CustomBuilder'}, 'build': {}}) == 'CustomBuilder'\", \"assert get_default_builder({'gitconfig': {}, 'build': {'builder': 'BuildTool'}}) == 'BuildTool'\", \"assert get_default_builder({'gitconfig': {}, 'build': {...
{ "split": "train", "index": 72586, "acecode_id": "bigcode_python_fns_41400", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Implement a function `verify_email(email: str) -> bool` that checks if a given email address is valid based on the following criteria: The email must contain an '@' symbol, followed by a domain name that includes a top-level domain (e.g., .com, .net). The username can consist o...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert verify_email('test@example.com') == True\", \"assert verify_email('user@domain.co') == True\", \"assert verify_email('user@sub.domain.com') == True\", \"assert verify_email('user@domain.com') == True\", \"assert verify_email('test@com') == False\", \"assert ...
{ "split": "train", "index": 72587, "acecode_id": "evol_14386", "num_tests": 13 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a function to calculate the height of a label widget in a graphical user interface (GUI) application. The label widget's vertical alignment is set to 'Center', and its width is fixed to match the width of a line edit widget. Your task is to impl...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert calculateLabelHeight(30) == 30\", \"assert calculateLabelHeight(40) == 40\", \"assert calculateLabelHeight(25) == 25\", \"assert calculateLabelHeight(50) == 50\", \"assert calculateLabelHeight(15) == 15\", \"assert calculateLabelHeight(20) == 20\", \"assert ...
{ "split": "train", "index": 72588, "acecode_id": "oss_8315", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given an array of numerical elements, implement a function that returns a new array where each element at index `i` is the sum of all elements from the original array up to and including index `i`. For example, for the input array [1, 2, 3, 4], the output should be [1, 3, 6, 10...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert calc_summation([1, 2, 3, 4]) == [1, 3, 6, 10]\", \"assert calc_summation([0, 0, 0, 0]) == [0, 0, 0, 0]\", \"assert calc_summation([-1, -2, -3, -4]) == [-1, -3, -6, -10]\", \"assert calc_summation([10]) == [10]\", \"assert calc_summation([]) == []\", \"assert...
{ "split": "train", "index": 72589, "acecode_id": "evol_36234", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Write a function that receives an array of integers, which may not be in order and might contain negative values and zeros. This function should return a new array that retains the first occurrence of each integer, discards any repeated occurrences, and maintains the original o...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert unique_in_order([1, 2, 3, 4, 5, -1, 0, 5, 1, 2, -3, 0, 3]) == [1, 2, 3, 4, 5, -1, 0, -3]\", \"assert unique_in_order([1, 1, 1, 1, 1]) == [1]\", \"assert unique_in_order([-1, -2, -2, -3, -1, 0]) == [-1, -2, -3, 0]\", \"assert unique_in_order([0, 0, 0, 0, 0]) ...
{ "split": "train", "index": 72590, "acecode_id": "evol_22933", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function `clear_rat_request(clearing_protocol: str, username: str, request_name: str, antibody1: str, antibody2: str, clearing_batch_number: int, time_pbs_wash1: str, pbs_wash1_notes: str) -> str`. This function simulates the clearing of a rat req...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert clear_rat_request('iDISCO abbreviated clearing (rat)', 'admin_test', 'Admin_rat_request', 'AntibodyA', 'AntibodyB', 2, '2023-10-01T12:00', 'notes for admin') == 'Request for Admin_rat_request by admin_test has been cleared using iDISCO abbreviated clearing (...
{ "split": "train", "index": 72591, "acecode_id": "bigcode_python_fns_25778", "num_tests": 11 }
acecode
[ { "role": "user", "content": "You are given a list of genetic variant strings, where each string represents a genetic variant with specific attributes. Each variant string is formatted as 'Type: {VariantType}; INFO=DP={Depth}; ...'. Your task is to implement a function that counts the occurrences of two typ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert count_variants(['Type: SNP; INFO=DP=10;', 'Type: INDEL; INFO=DP=5;']) == {'SNP': 1, 'INDEL': 1}\", \"assert count_variants(['Type: SNP; INFO=DP=15;', 'Type: SNP; INFO=DP=12;', 'Type: INDEL; INFO=DP=7;']) == {'SNP': 2, 'INDEL': 1}\", \"assert count_variants([...
{ "split": "train", "index": 72592, "acecode_id": "bigcode_python_fns_1153", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Given a two-dimensional matrix composed of whole numbers, implement a function that calculates the difference between the maximum and minimum integer present within each row of the matrix. The function should return a list of these differences for all rows. For example, if the ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert find_disparity([[3, 10, 2], [6, 4, 8, 1]]) == [8, 7]\", \"assert find_disparity([[1, 2, 3], [4, 5, 6]]) == [2, 2]\", \"assert find_disparity([[5, 5, 5], [1, 1, 1]]) == [0, 0]\", \"assert find_disparity([[10, 20, 30], [5, 15, 25]]) == [20, 20]\", \"assert fin...
{ "split": "train", "index": 72593, "acecode_id": "evol_23087", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You have a list of banners, each represented by a dictionary containing their properties. Each banner can have various statuses like 'active', 'expired', or 'disabled'. Your goal is to implement a function `get_active_banners(banners: List[Dict[str, str]]) -> List[Dict[str, str...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_active_banners([{'status': 'active', 'id': '1'}, {'status': 'expired', 'id': '2'}, {'status': 'disabled', 'id': '3'}]) == [{'status': 'active', 'id': '1'}]\", \"assert get_active_banners([{'status': 'disabled', 'id': '1'}, {'status': 'disabled', 'id': '2...
{ "split": "train", "index": 72594, "acecode_id": "bigcode_python_fns_48390", "num_tests": 16 }
acecode
[ { "role": "user", "content": "You are tasked with implementing a train scheduling system for a railway company. The company operates a network of trains that travel between various stations. Each train has a unique identifier and a schedule that includes the departure and arrival times for each station alon...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert find_conflicts([('Station A', '09:00', '09:30'), ('Station B', '09:30', '10:00')]) == []\", \"assert find_conflicts([('Station A', '12:00', '12:15'), ('Station B', '12:15', '12:30')]) == []\", \"assert find_conflicts([('Station A', '08:00', '08:30'), ('Stati...
{ "split": "train", "index": 72595, "acecode_id": "oss_12756", "num_tests": 7 }
acecode
[ { "role": "user", "content": "Given two lists of unique integers, X and Y, write a function `intersect(X, Y)` that returns a list of integers that are present in both lists. The function should handle large input sizes efficiently. The output list should contain the intersection of the two lists, and the or...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert intersect([1, 2, 3], [2, 3, 4]) == [2, 3]\", \"assert intersect([5, 6, 7], [1, 2, 8]) == []\", \"assert intersect([], [1, 2, 3]) == []\", \"assert intersect([1, 2, 3], []) == []\", \"assert intersect([0], [0]) == [0]\", \"assert intersect([1, 2, 3], [3, 4, 5...
{ "split": "train", "index": 72596, "acecode_id": "evol_20381", "num_tests": 16 }
acecode
[ { "role": "user", "content": "Implement a function `greeting_based_on_timezone(timezone_str: str) -> str` that takes a timezone string as input and returns a greeting message based on the current hour in that timezone. The greeting should be: 'Good evening or night! Sleep tight' if the hour is between 8 PM ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert greeting_based_on_timezone('America/New_York') == 'Good evening or night! Sleep tight'\", \"assert greeting_based_on_timezone('Australia/Sydney') == 'Good evening or night! Sleep tight'\", \"assert greeting_based_on_timezone('America/Los_Angeles') == 'Good e...
{ "split": "train", "index": 72597, "acecode_id": "evol_17291", "num_tests": 8 }
acecode
[ { "role": "user", "content": "You are given a list of tuples, where each tuple contains two lists: the first list represents Mach numbers and the second list represents reduced frequencies. Your task is to process these tuples and return a new list of tuples where each tuple contains the same data but split...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert process_mkaero1([([1.0, 2.0, 3.0], [0.1, 0.2, 0.3])]) == [([1.0, 2.0, 3.0], [0.1, 0.2, 0.3])]\", \"assert process_mkaero1([([1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0], [0.1, 0.2, 0.3])]) == [([1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0], [0.1, 0.2, 0.3])]\", \"ass...
{ "split": "train", "index": 72598, "acecode_id": "bigcode_python_fns_18326", "num_tests": 5 }
acecode
[ { "role": "user", "content": "You are tasked with creating a function that takes no arguments and returns a specific JSON response as a Python dictionary. The function should return the following dictionary: {\"message\": \"Hello, World!\"}. Your solution should include only one function and should not requ...
code
{ "style": "rule", "ground_truth": "{\"tests\": [\"assert get_hello_message() == {'message': 'Hello, World!'}\", \"assert get_hello_message() == {'message': 'Hello, World!'}\", \"assert get_hello_message() == {'message': 'Hello, World!'}\", \"assert get_hello_message() == {'message': 'Hello, World!'}\", \"assert ge...
{ "split": "train", "index": 72599, "acecode_id": "oss_35277", "num_tests": 16 }