Documentation IndexFetch the complete documentation index at: /llms.txtUse this file to discover all available pages before exploring further.
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
export LUMAAI_API_KEY=***
lumaai
pip install -U lumaai
from agno.agent import Agent from agno.models.openai import OpenAIChat from agno.tools.lumalab import LumaLabTools luma_agent = Agent( name="Luma Video Agent", model=OpenAIChat(id="gpt-4o"), tools=[LumaLabTools()], # 使用我们创建的 LumaLab 工具 markdown=True, debug_mode=True, show_tool_calls=True, instructions=[ "你是一个用于使用 Luma AI API 生成视频的 Agent。", "你可以通过两种方式生成视频:", "1. 文本到视频生成:", "2. 图像到视频生成:", "根据用户提供的是图片 URL 还是仅提示词来选择合适的函数。", "视频将自动显示在你的响应下方的 UI 中,因此你无需在响应中显示视频 URL。", ], system_message=( "对于文本到视频请求使用 generate_video,对于基于图像的生成使用 image_to_video。" "除非特别要求,否则不要修改默认参数。 " "始终提供关于视频生成状态的清晰反馈。" ), ) luma_agent.run("Generate a video of a car in a sky")
api_key
str
None
generate_video
image_to_video