from swift.llm.template import split_str_parts_by def test_split_str_parts_by(): print(split_str_parts_by('aaaAction:bb\nbAction Inputs:\nabbb', ['Action:', 'Action Inputs:'], regex_mode=False)) print(split_str_parts_by('aaaAction:bb\nbAction Inputs:\nabbb', ['Action:', 'Action Inputs:'], regex_mode=True)) print(split_str_parts_by('aaabbbccc', ['.+?'], regex_mode=True)) print(split_str_parts_by('aaa\nbb\nb