def METHOD_NAME(text, frame=0, max_frames=0):
    """
    splits the prompt based on deforum webui implementation, moved from generate.py 
    """
    math_parser = re.compile("(?P<weight>(`[\S\s]*?`))", re.VERBOSE)
    parsed_prompt = re.sub(math_parser, lambda m: str(parse_weight(m, frame)), text)
    negative_prompts = []
    positive_prompts = []
    prompt_split = parsed_prompt.split("--neg")
    if len(prompt_split) > 1:
        positive_prompts, negative_prompts = parsed_prompt.split("--neg")  # TODO: add --neg to vanilla Deforum for compat
    else:
        positive_prompts = prompt_split[0]
        negative_prompts = ""
    return positive_prompts, negative_prompts