Create Stunning Images Effortlessly with Ariyakuti

26 Apr 2025
Create Stunning Images Effortlessly with Ariyakuti

Ariyakuti is an innovative image generation service that empowers developers to create high-quality images using advanced AI techniques. With its Cognitive Actions, Ariyakuti simplifies the process of generating images by providing flexible options for model selection, customizable dimensions, and various output qualities and formats. Whether you're looking to create detailed illustrations or quick visual outputs, Ariyakuti caters to your needs with features like image-to-image generation and inpainting modes.

Common use cases for Ariyakuti include creating personalized illustrations for marketing materials, generating unique artwork for games or applications, and enhancing visual content for social media. The ability to customize prompts and image characteristics allows developers to easily integrate rich visual content into their projects, saving time and resources while enhancing user engagement.

Prerequisites

To start using Ariyakuti's Cognitive Actions, you will need an API key and some basic knowledge of making API calls.

Generate Image Using AriYakuti

The "Generate Image Using AriYakuti" action allows you to create images using the AriYakuti method. This action supports various options such as model selection for detailed or quick outputs, and it offers capabilities for image-to-image transformations and inpainting. You can customize the dimensions, quality, and format of the generated images, making it a versatile tool for developers.

Input Requirements

The input for this action is a structured object that includes several properties:

  • prompt: A descriptive string that guides the image generation.
  • aspectRatio: Specifies the desired aspect ratio for the image.
  • outputFormat: The desired file format for the output image (webp, jpg, png).
  • guidanceScale: A numerical value that influences the adherence to the prompt during image generation.
  • outputQuality: Controls the quality of the saved output image.
  • inferenceModel: Allows you to choose between 'dev' for detailed outputs or 'schnell' for faster results.

For example, a typical input might look like this:

{
  "prompt": "Create a 3D cartoon-style illustration of AriYakuti, a 3-year-old boy with soft, light brown hair.",
  "aspectRatio": "1:1",
  "outputFormat": "png",
  "guidanceScale": 3.5,
  "outputQuality": 90,
  "inferenceModel": "dev"
}

Expected Output

The output is a URL linking to the generated image, which can be directly used in applications or shared across platforms. The generated image will reflect the characteristics defined in the input prompt, resulting in a unique visual representation.

For example, an expected output might be:

[
  "https://assets.cognitiveactions.com/invocations/0267dfc1-6e7e-4b67-8af5-dbdd74134d1d/e0550749-208a-4150-9447-2ee4fc423661.png"
]

Use Cases for this Specific Action

  • Personalized Illustrations: Create customized graphics for children's books or educational materials that capture specific characters or scenes.
  • Marketing Content: Generate unique visuals for advertising campaigns, social media posts, or blog illustrations that stand out and engage the audience.
  • Game Development: Use the action to produce character designs or backgrounds that align with the game's theme and style, enhancing the overall player experience.
import requests
import json

# Replace with your actual Cognitive Actions API key and endpoint
# Ensure your environment securely handles the API key
COGNITIVE_ACTIONS_API_KEY = "YOUR_COGNITIVE_ACTIONS_API_KEY"
# This endpoint URL is hypothetical and should be documented for users
COGNITIVE_ACTIONS_EXECUTE_URL = "https://api.cognitiveactions.com/actions/execute"

action_id = "a35d55fc-d787-4e32-9de5-3b2fc611e993" # Action ID for: Generate Image Using AriYakuti

# Construct the exact input payload based on the action's requirements
# This example uses the predefined example_input for this action:
payload = {
  "prompt": "Create a 3D cartoon-style illustration of AriYakuti, a 3-year-old boy. Ari has soft, light brown hair styled with a side-swept fringe that gives him a polished yet playful look. His expressive brown eyes convey curiosity and thoughtfulness. For this scene, show Ari in mid-action, kicking a soccer ball with great enthusiasm. His face should be lit up with joy. The background should be a whimsical, colorful version of Karmiel city, with buildings slightly curved and exaggerated. Use a dynamic, slightly tilted camera angle to capture the energy of the moment. Add magical, colorful streaks following the ball's path.\n",
  "aspectRatio": "1:1",
  "outputFormat": "png",
  "guidanceScale": 3.5,
  "outputQuality": 90,
  "extraLoraScale": 1,
  "inferenceModel": "dev",
  "promptStrength": 0.8,
  "numberOfOutputs": 1,
  "primaryLoraScale": 1,
  "numberOfInferenceSteps": 28
}

headers = {
    "Authorization": f"Bearer {COGNITIVE_ACTIONS_API_KEY}",
    "Content-Type": "application/json",
    # Add any other required headers for the Cognitive Actions API
}

# Prepare the request body for the hypothetical execution endpoint
request_body = {
    "action_id": action_id,
    "inputs": payload
}

print(f"--- Calling Cognitive Action: {action.name or action_id} ---")
print(f"Endpoint: {COGNITIVE_ACTIONS_EXECUTE_URL}")
print(f"Action ID: {action_id}")
print("Payload being sent:")
print(json.dumps(request_body, indent=2))
print("------------------------------------------------")

try:
    response = requests.post(
        COGNITIVE_ACTIONS_EXECUTE_URL,
        headers=headers,
        json=request_body
    )
    response.raise_for_status() # Raise an exception for bad status codes (4xx or 5xx)

    result = response.json()
    print("Action executed successfully. Result:")
    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 (non-JSON): {e.response.text}")
    print("------------------------------------------------")

Conclusion

Ariyakuti's image generation capabilities provide developers with a powerful tool to create stunning visuals quickly and efficiently. With customizable options and various output formats, this service is ideal for a range of applications, from marketing to game development. By integrating Ariyakuti into your projects, you can enhance user engagement with unique and appealing visual content. Start exploring the possibilities today and elevate your creative projects to new heights!