INNER CODE UNIT · Python

text_to_video

SamurAIGPT/Seedance-2.5-API · mcp_server.py:66

def text_to_video(prompt: str, aspect_ratio: str = "16:9", duration: int = 5, seed: Optional[int] = None) -> str:
    """Generate a standard 720p video from text."""
    return json.dumps(get_api().text_to_video(prompt, aspect_ratio, duration, seed), indent=2)


@mcp.tool()
def image_to_video(prompt: str, image_url: str, aspect_ratio: str = "16:9", duration: int = 5, seed: Optional[int] = None) -> str:
    """Animate one image into a standard 720p video."""
    return json.dumps(get_api().image_to_video(prompt, image_url, aspect_ratio, duration, seed), indent=2)


@mcp.tool()
def first_last_frame(prompt: str, images_list: List[str], aspect_ratio: str = "16:9", duration: int = 5, seed: Optional[int] = None) -> str:
    """Generate a standard 720p transition between two images."""
    return json.dumps(get_api().first_last_frame(prompt, images_list, aspect_ratio, duration, seed), indent=2)


@mcp.tool()

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…