Runway Image Generator
Runway Image Generator lets you create new images or transform existing ones by sending requests to the Runway AI platform. You can describe what you want in plain text, choose a model, and let the system generate up to four images in a single run.
How it Works
When you run the component, it takes the values you entered (or mapped from other components) and builds a request to the Runway API. The API processes the prompt or the input image with the selected model and returns one or more image files. The component then stores those files in Nappai’s data store so you can use them later in your workflow or pass them to another tool.
Inputs
Mapping Mode
This component has a special mode called Mapping Mode. When you enable this mode using the toggle switch, an additional input called Mapping Data is activated, and each input field offers you three different ways to provide data:
- Fixed: You type the value directly into the field.
- Mapped: You connect the output of another component to use its result as the value.
- Javascript: You write Javascript code to dynamically calculate the value.
This flexibility allows you to create more dynamic and connected workflows.
Input Fields
The following fields are available to configure this component. Each field may be visible in different operations:
- Image Files: The list of image files (URL or File Id) to use for image generation.
- Aspect Ratio: The aspect ratio of the generated image.
- Generation Mode: Mode of Image generation. (text_to_image or image_to_image)
- Height: Height of the generated image in pixels.
- Mapping Mode: Enable mapping mode to process multiple data records in batch.
- Image Model: The Runway ML model to use for image generation.
- Negative Prompt: What you don’t want in the image.
- Number of Images: The number of images to generate (1-4).
- Prompt: A text description of the desired image(s). The maximum length is 1000 characters.
- Seed: Random seed for reproducible results. Leave empty for random.
- Width: Width of the generated image in pixels.
- Tool Name: The name of the tool that will be used when this component is connected as a tool. This name will be displayed to the agent when it selects tools to use.
- Tool Description: A detailed description of what this tool does. This description will help the agent understand when and how to use this tool effectively.
- Tools arguments metadata: Defines the arguments metadata for the tools.
Credential
This component requires a Runway API credential.
- Go to the Credentials section of Nappai and add a new credential of type Runway API.
- Enter your Runway ML API Key (you can get it from the Runway Developer Portal).
- In the component, select the credential you just created from the Credential dropdown.
Outputs
- Image: A data object containing the generated image file(s).
- Tool: A tool object that can be used by the agent to invoke this component programmatically.
Usage Example
- Add the component to your workflow.
- Configure the inputs:
- Set Prompt to “A futuristic city skyline at sunset”.
- Choose an Image Model like “stable-diffusion-v1”.
- Set Number of Images to 2.
- Leave Seed empty for random results.
- Select a Runway API credential as described above.
- Run the workflow. The component will return two image files that you can then feed into a gallery component or send to a user.
Related Components
- Runway Video Generator – Create videos from prompts or images.
- Runway Text-to-Image – A simplified version that only supports text prompts.
- Image Resizer – Adjust the size of images produced by this component.
Tips and Best Practices
- Keep prompts concise; longer prompts can increase API usage and cost.
- Use Negative Prompt to avoid unwanted elements (e.g., “no text, no watermark”).
- If you need the same image for multiple records, enable Mapping Mode and map the prompt or image file from a previous component.
- Test with a single image first to fine‑tune the prompt before generating multiple images.
Security Considerations
- The Runway API key is stored securely in Nappai’s credential store.
- Do not expose the key in any public workflow or share the credential with untrusted users.
- The component only sends the data you provide; no additional personal data is transmitted unless included in the prompt or image files.