Create Stunning Surreal Images with the Aramintak Mooniverse Cognitive Actions

The Aramintak Mooniverse API offers a powerful set of Cognitive Actions designed for developers looking to enhance their applications with innovative image generation capabilities. One standout action, "Generate Surreal Style Images," allows you to create visually captivating images characterized by natural textures and muted tones. This action is perfect for developers aiming to integrate artistic elements into their applications, whether for marketing, entertainment, or creative projects.
Prerequisites
Before diving into the integration of the Cognitive Actions, ensure you have the following:
- An API key for the Aramintak Mooniverse platform to authenticate your requests.
- Basic knowledge of making API calls and handling JSON data in your preferred programming language.
For authentication, pass your API key in the headers of your requests, enabling secure access to the Cognitive Actions.
Cognitive Actions Overview
Generate Surreal Style Images
The Generate Surreal Style Images action creates images with a distinctive surreal aesthetic, focusing on East Asian portraits and stylized representations. With a variety of customizable parameters, this action empowers developers to generate unique artistic outputs.
Input
The input for this action requires a JSON object with the following fields:
- prompt (string, required): A text prompt that guides the image generation. Example:
"A four image grid of a woman making different facial expressions, cyborg, blonde, gray eyes, swedish, happy sad angry silly, surreal style". - mainLoraScale (number, optional): Controls the intensity of the main LoRA application (default: 1).
- inferenceModel (string, optional): Selects the model for inference (default:
"dev"). - numberOfOutputs (integer, optional): Defines how many images to generate (default: 1, max: 4).
- promptIntensity (number, optional): Adjusts the prompt's influence on the output (default: 0.8).
- imageAspectRatio (string, optional): Sets the desired aspect ratio for the output image (default:
"1:1"). - imageOutputFormat (string, optional): Specifies the file format for saving images (default:
"webp"). - imageOutputQuality (integer, optional): Quality of the output image (default: 80).
- additionalLoraScale (number, optional): Intensity of additional LoRA application (default: 1).
- diffusionGuidanceScale (number, optional): Adjusts the guidance strength during diffusion (default: 3).
- numberOfInferenceSteps (integer, optional): Total number of denoising iterations (default: 28).
Example Input
{
"prompt": "A four image grid of a woman making different facial expressions, cyborg, blonde, gray eyes, swedish, happy sad angry silly, surreal style",
"mainLoraScale": 0.99,
"inferenceModel": "dev",
"numberOfOutputs": 4,
"promptIntensity": 0.8,
"imageAspectRatio": "1:1",
"imageOutputFormat": "png",
"imageOutputQuality": 90,
"additionalLoraScale": 1,
"diffusionGuidanceScale": 3.5,
"numberOfInferenceSteps": 28
}
Output
The output of this action will be a list of URLs pointing to the generated images. For example:
[
"https://assets.cognitiveactions.com/invocations/cd8b9bd9-8cf4-49c4-a841-e43d832ee555/755829d4-62d3-470c-9cce-58c02227e26c.png",
"https://assets.cognitiveactions.com/invocations/cd8b9bd9-8cf4-49c4-a841-e43d832ee555/9d099196-a75c-43cd-ac9b-a12350f8cc84.png",
"https://assets.cognitiveactions.com/invocations/cd8b9bd9-8cf4-49c4-a841-e43d832ee555/c656559d-fdb5-447c-a215-8341dd1d4037.png",
"https://assets.cognitiveactions.com/invocations/cd8b9bd9-8cf4-49c4-a841-e43d832ee555/7391a4e3-b4e8-4c39-8e9c-beb40afb228f.png"
]
Conceptual Usage Example (Python)
Here’s a conceptual example of how a developer might call the Generate Surreal Style Images action using Python:
import requests
import json
# Replace with your Aramintak Mooniverse API key and endpoint
COGNITIVE_ACTIONS_API_KEY = "YOUR_COGNITIVE_ACTIONS_API_KEY"
COGNITIVE_ACTIONS_EXECUTE_URL = "https://api.cognitiveactions.com/actions/execute" # Hypothetical endpoint
action_id = "0e6870ec-1124-4edd-b336-842b1d47aa2f" # Action ID for Generate Surreal Style Images
# Construct the input payload based on the action's requirements
payload = {
"prompt": "A four image grid of a woman making different facial expressions, cyborg, blonde, gray eyes, swedish, happy sad angry silly, surreal style",
"mainLoraScale": 0.99,
"inferenceModel": "dev",
"numberOfOutputs": 4,
"promptIntensity": 0.8,
"imageAspectRatio": "1:1",
"imageOutputFormat": "png",
"imageOutputQuality": 90,
"additionalLoraScale": 1,
"diffusionGuidanceScale": 3.5,
"numberOfInferenceSteps": 28
}
headers = {
"Authorization": f"Bearer {COGNITIVE_ACTIONS_API_KEY}",
"Content-Type": "application/json"
}
try:
response = requests.post(
COGNITIVE_ACTIONS_EXECUTE_URL,
headers=headers,
json={"action_id": action_id, "inputs": payload} # Hypothetical structure
)
response.raise_for_status() # Raise an exception for bad status codes (4xx or 5xx)
result = response.json()
print("Action executed successfully:")
print(json.dumps(result, indent=2))
except requests.exceptions.RequestException as e:
print(f"Error executing action {action_id}: {e}")
if e.response is not None:
print(f"Response status: {e.response.status_code}")
try:
print(f"Response body: {e.response.json()}")
except json.JSONDecodeError:
print(f"Response body: {e.response.text}")
In this code snippet, replace YOUR_COGNITIVE_ACTIONS_API_KEY with your actual API key. The input payload is structured according to the requirements of the action, allowing you to generate stunning surreal images.
Conclusion
The Generate Surreal Style Images action from the Aramintak Mooniverse provides a unique opportunity for developers to integrate advanced image generation capabilities into their applications. By utilizing the customizable parameters available, you can create a wide array of artistic images suited for various use cases. Explore this action and unleash your creativity with the power of the Mooniverse!