MCP server for generating AI images and videos using Luma API
The server exposes 2 tools with well-structured parameter schemas and moderately detailed descriptions. Both tools follow the verb_noun naming convention (create_image, create_video), which is correct. However, the descriptions are verbose with embedded implementation guidance rather than concise LLM-optimized summaries. Parameter schemas are explicitly declared with types and defaults, but lack granular per-parameter descriptions in the tool registration layer, they rely on the docstring which LLMs may not parse consistently. Output schemas are documented in prose but not in structured JSON Schema format. Error handling is present (try-catch blocks return formatted errors) but lacks categorization (retryable vs fatal) and recovery guidance. The tools score above average due to comprehensive parameter coverage and reasonable naming, but fall short of A-grade due to missing per-param descriptions in the schema layer and lack of structured error taxonomy.
Generates AI images using Luma API based on the provided parameters. [Generation Notes] - When generating an image prompt, be detailed and enhance the prompt as necessary. - You can add additional stylistic details to the prompt if the user desires. - Use the defintions specified in [PARAMETERS] to guide the generation. [Parameters] prompt: Detailed text description of the image to generate. Be specific about subject, setting, lighting, mood, style, and composition. aspect_ratio: Image dimensions - "1:1" (square) - Best for portraits, icons, or symmetrical compositions - "16:9" (landscape) - Ideal for scenic views, cinematic shots (DEFAULT) - "9:16" (portrait) - Perfect for mobile wallpapers or vertical compositions - "4:3" - Standard display format for many devices - "3:4" - Alternative portrait orientation - "21:9" - Ultra-wide cinematic format - "9:21" - Ultra-tall format for specialized vertical content model: - "photon-1" - Higher quality with more detailed rendering (DEFAULT) - "photon-flash-1" - Faster generation with slightly reduced detail reference_options: - image_ref: Up to 8 reference images with weights (0.1-1.0) to influence overall generation - style_ref: Single reference image with weight to influence artistic style only - character_ref: Up to 4 character references to maintain consistent character appearance - modify_image_ref: Single source image to enhance or modify while preserving core elements [Usage Guidelines] 1. ALWAYS use character_ref when user requests specific characters or consistent character appearance. 2. Use style_ref when user wants to match a particular artistic style but not copy specific content. 3. Use image_ref when user wants to influence both content and style of generation. 4. Use modify_image_ref when enhancing or altering an existing image while maintaining its core elements. 5. For best results, encourage detailed prompts with specific visual descriptions. 6. When appropriate, enhance user prompts with additional details about lighting, composition, and atmosphere. 7. As required based on what is user asking for, you can also use multiple reference images at once. [Returns] List containing triplets of [image_data, image_url, generation_id] for each image: - image_data: Image object that can be displayed directly in the MCP interface - image_url: String with URL to the generated image on Luma CDN - generation_id: Unique ID that can be used for referencing in future operations
Parameter descriptions missing from tool registration schema. While the docstring includes detailed parameter guidance ('aspect_ratio: Image dimensions...'), the MCP protocol schema (via @mcp.tool() decorator) does not attach descriptions to individual input parameters, only to the tool itself. LLMs may not consistently parse docstrings and will rely on the schema definition. Per pattern:tool-description baseline: 100% of A+ tools have descriptions for every parameter in the schema layer.
Output schema is documented in prose within the docstring but not as a formal JSON Schema structure. Pattern:tool requires documented return types. LLMs need structured output definitions to plan multi-step workflows, 'List containing triplets of [image_data, image_url, generation_id]' is informal. Without a schema, LLMs may misinterpret the structure of returned objects (e.g., whether image_data is a URL string, a base64 blob, or an object with properties).
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-22 | D | 58 | 2026-07-28+ | v2 |
| 2026-03-09 | F | 47 | - | v1 |
Generates AI videos using Luma API based on the provided parameters. [Generation Notes] - When generating a video prompt, be detailed and enhance the prompt as necessary. - You can add additional stylistic details to the prompt if the user desires. - Use the defintions specified in [PARAMETERS] to guide the generation. - If the user asks for 10s video or a longer video, default to 9s. [Parameters] prompt: Text description of the video to generate aspect_ratio: Video dimensions - "1:1" (square), "16:9" (landscape), "9:16" (portrait), "4:3", "3:4", "21:9", "9:21" (default: "16:9") model: AI model to use - "ray-2" (standard), "ray-flash-2" (faster), "ray-1-6" (legacy) (default: "ray-2") loop: Whether the video should loop seamlessly (default: False) resolution: Video quality - "4k", "1080p", "720p", "540p" (default: "720p") duration: Video length - "5s" or "9s" (default: "5s") frame0_image: URL of image to use as first frame (optional) frame1_image: URL of image to use as last frame (optional) frame0_id: Generation ID for first frame (UUID v4) (optional) frame1_id: Generation ID for last frame (UUID v4) (optional) [Returns] List containing quartets of [thumbnail_image, video_url, image_url, generation_id] for each video: - thumbnail_image: Image object that can be displayed directly in the MCP interface - video_url: String with URL to the generated video on Luma CDN - image_url: String with URL to the thumbnail image on Luma CDN - generation_id: Unique ID that can be used for referencing in future operations
Error handling is generic and non-actionable. Both tools catch exceptions and return a formatted string with stack traces ('error in create_image: {str(e)}\n\nStack trace:\n{stack_trace_str}'). Per pattern:recovery-guide, error responses must guide the agent: 'What to do next?' A stack trace tells the agent nothing. No categorization of errors as retryable, user-fixable, or fatal.
Tool descriptions are overly verbose (500+ chars, exceeding the 200-char p90 baseline) and include implementation guidance ('When generating an image prompt, be detailed and enhance the prompt as necessary.') that belongs in system prompts, not tool definitions. Descriptions should concisely answer: What does it do? When to use it? What does it return? Verbose descriptions waste tokens and dilute signal.
No input validation or constraint enforcement visible in tool code. Parameters like aspect_ratio accept string but allow any value, should validate against enum ['1:1', '16:9', '9:16', '4:3', '3:4', '21:9', '9:21']. Similarly, model, resolution, duration accept unbounded strings. Per pattern:constrained-input, free-form strings invite hallucinated values. Validation should happen early with actionable error messages ('Invalid aspect_ratio: got "1:2", must be one of: 1:1, 16:9, ...').