# P-Image Edit > PrunaAI's sub-1-second multi-image editing model supporting up to 5 reference images with state-of-the-art quality ## Quick Reference - Model ID: p-image-edit - Creator: PrunaAI - Status: active - Base URL: https://api.lumenfall.ai/openai/v1 ## Specifications - Max Input Images: 5 - Input Modalities: text, image - Output Modalities: image - Supported Modes: Image Edit ## API Parameters The compiled parameter schema for this model is available via the API: `GET /v1/models/p-image-edit?schema=true`. ### Core Parameters - `prompt` (string) — REQUIRED: Edit instruction for the image - `seed` (integer): Random seed for reproducibility ### Size & Layout - `size` (string): Image dimensions as WxH pixels (e.g. "1024x1024") or aspect ratio (e.g. "16:9"). Values: auto, 1365x768, 768x1365, 1254x836, 836x1254, 887x1182, 1024x1024, 1183x887 - `aspect_ratio` (string): Aspect ratio of the output image (e.g. "16:9", "1:1"). Values: auto, 9:16, 2:3, 3:4, 1:1, 4:3, 3:2, 16:9 - `resolution` (string): Output resolution tier (e.g. "1K", "4K"). Values: auto, 1K ### Media Inputs - `image` (file) — REQUIRED: Input image(s) to edit ### Output & Format - `response_format` (string): How to return the image. Default: url. Values: url, b64_json - `output_format` (string): Output image format. Values: png, jpeg, gif, webp, avif - `output_compression` (integer): Compression level for lossy formats (JPEG, WebP, AVIF) - `n` (integer): Number of images to generate. Default: 1 ### Additional Parameters - `disable_safety_checker` (boolean): Disable safety checker for generated images.. Only available via replicate - `replicate_weights` (string): Task to perform with P-Edit.. Only available via replicate - `turbo` (boolean): If turned on, the model will run faster with additional optimizations. For complicated tasks, it is recommended to turn this off.. Only available via replicate ## Model Identifiers - Primary Slug: p-image-edit ## Tags image-editing, image-to-image ## Available Providers ### Replicate - Config Key: replicate/p-image-edit - Provider Model ID: prunaai/p-image-edit - Pricing: $0.010/image - Note: Sub-second multi-image editing model - Note: Supports up to 5 reference images - Source: https://replicate.com/prunaai/p-image-edit ## Performance Metrics Provider performance over the last 30 days. ### replicate - Median Generation Time (p50): 3043ms - 95th Percentile Generation Time (p95): 7170ms - Average Generation Time: 3528ms - Success Rate: 100.0% - Total Requests: 22 - Time to First Byte (p50): 2365ms - Time to First Byte (p95): 5376ms ## Image Gallery 2 images available for this model. Browse all at https://lumenfall.ai/models/prunaai/p-image-edit/gallery ### Curated Examples - [Add a plane to this beautiful sunset city](https://assets.lumenfall.ai/ODoCGCZ-f5B4uCuXhsSnSCJz9R2FzMYqo-PFA5svk6s/rs:fit:1500:1500/plain/gs://lumenfall-prod-assets/4urr6t0x1n17o42smjo6l25omqtf@jpeg) - [Add a capybara](https://assets.lumenfall.ai/-fv6LadGG2mDGuE8WS-HY6e8KoMsXPI9zeEQCrwngJI/rs:fit:1500:1500/plain/gs://lumenfall-prod-assets/le9laqd3ckogiuo8zanxt1ol0iwy@jpeg) ## Example Prompt The following prompt was used to generate an example image in our playground: Add a capybara ## Code Examples ### Image Edit (/v1/images/edits) #### cURL curl -X POST \ https://api.lumenfall.ai/openai/v1/images/edits \ -H "Authorization: Bearer $LUMENFALL_API_KEY" \ -F "model=p-image-edit" \ -F "image=@source.png" \ -F "prompt=Add a starry night sky to this image" \ -F "size=1024x1024" # Response: # { "created": 1234567890, "data": [{ "url": "https://...", "revised_prompt": "..." }] } #### JavaScript import OpenAI from 'openai'; import fs from 'fs'; const client = new OpenAI({ apiKey: 'YOUR_API_KEY', baseURL: 'https://api.lumenfall.ai/openai/v1' }); const response = await client.images.edit({ model: 'p-image-edit', image: fs.createReadStream('source.png'), prompt: 'Add a starry night sky to this image', size: '1024x1024' }); // { created: 1234567890, data: [{ url: "https://...", revised_prompt: "..." }] } console.log(response.data[0].url); #### Python from openai import OpenAI client = OpenAI( api_key="YOUR_API_KEY", base_url="https://api.lumenfall.ai/openai/v1" ) response = client.images.edit( model="p-image-edit", image=open("source.png", "rb"), prompt="Add a starry night sky to this image", size="1024x1024" ) # { created: 1234567890, data: [{ url: "https://...", revised_prompt: "..." }] } print(response.data[0].url) ## About ## Overview P-Image Edit is a high-speed image-to-image editing model developed by PrunaAI designed for near-instantaneous visual transformations. It stands out in the generative AI landscape by offering sub-second inference times while supporting up to five separate reference images for a single edit. This multi-reference capability allows the model to synthesize stylistic and structural elements from several sources simultaneously, maintaining high visual quality without typical performance bottlenecks. ## Strengths * **Latency Performance:** Achieves sub-one-second processing times, making it suitable for real-time interactive applications and high-throughput production pipelines. * **Multi-Reference Composition:** Supports inputting up to five reference images, allowing the model to bridge visual information across multiple context sources more effectively than single-image editing models. * **Temporal and Structural Consistency:** Maintains state-of-the-art visual quality during the editing process, ensuring that the output respects the core attributes of the primary input while integrating text-prompted changes. * **Flexibility in Modality:** Operates on a text-and-image input structure, providing granular control over how specific visual elements are modified or preserved. ## Limitations * **Inference Constraints:** While optimized for speed, the sub-second performance may vary depending on the resolution of the input images or the complexity of the specified edits. * **Context Management:** Balancing five different reference images requires precise prompting; the model may prioritize certain references over others depending on the visual weights of the input data. * **Limited Customization:** Being a specialized editing model, it may not perform as well in "text-to-image" only scenarios compared to general-purpose diffusion models like Stable Diffusion XL. ## Technical Background P-Image Edit is built by PrunaAI with a focus on optimization and efficient inference. While the specific architecture builds upon modern diffusion techniques, the primary technical innovation lies in its multi-reference processing layer and the underlying acceleration that enables sub-second execution. This allows the model to bypass the heavy computational overhead usually associated with high-fidelity image-to-image tasks. ## Best For * **Real-time Creative Tools:** Applications where users need immediate feedback while adjusting image styles or elements. * **Batch Media Processing:** Workflows that require applying consistent edits or branding across large sets of images quickly. * **Concept Blending:** Scenarios where a final image needs to combine the aesthetic of several different source inspirations into a cohesive new output. P-Image Edit is available for integration and testing through Lumenfall’s unified API and playground, providing a streamlined way to incorporate high-speed image editing into your stack. ## Frequently Asked Questions ### How much does P-Image Edit cost? P-Image Edit starts at $0.01 per image through Lumenfall. Pricing varies by provider. Lumenfall does not add any markup to provider pricing. ### How do I use P-Image Edit via API? You can use P-Image Edit through Lumenfall's OpenAI-compatible API. Send requests to the unified endpoint with model ID "p-image-edit". Code examples are available in Python, JavaScript, and cURL. ### Which providers offer P-Image Edit? P-Image Edit is available through Replicate on Lumenfall. Lumenfall automatically routes requests to the best available provider. ## Links - Model Page: https://lumenfall.ai/models/prunaai/p-image-edit - About: https://lumenfall.ai/models/prunaai/p-image-edit/about - Providers, Pricing & Performance: https://lumenfall.ai/models/prunaai/p-image-edit/providers - API Reference: https://lumenfall.ai/models/prunaai/p-image-edit/api - Benchmarks: https://lumenfall.ai/models/prunaai/p-image-edit/benchmarks - Use Cases: https://lumenfall.ai/models/prunaai/p-image-edit/use-cases - Gallery: https://lumenfall.ai/models/prunaai/p-image-edit/gallery - Playground: https://lumenfall.ai/playground?model=p-image-edit - API Documentation: https://docs.lumenfall.ai