Create perfect anime characters with GPT-4o and SDXL
Tags: sdxl, chatgpt, aiagent, ai
Published: 2024-07-16 19:49:47

GPT-4o writes character details and text-to-image prompts. SDXL generates images.

## AI Agent Flow

The initial prompt is as simple as this: “Generate a random anime character. You can pick any topic. Write a background story specific to the character, including mood, physical appearance, and superpowers.”

Then we chain it using [http://aiflowly.com](http://aiflowly.com):

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3bpom45hnvlf0dib2o0b.png)

## Character Details and Specifications

The first four GPT-4o will generate different AI characters. Their system image is as follows:

> “Write a detailed specification for an anime character.”

**An example output (long text):**

“Character Specification: Aiko Takahashi — The Elemental Guardian Background Story: In a small, ancient village nestled within the untamed forests of Japan, there exists a legend of a powerful guardian who wields the elemental forces of nature to protect the world from dark entities. That guardian is Aiko Takahashi, a seemingly ordinary 16-year-old high school student, living a dual life between modern convenience and ancient duty. Born into a lineage of elemental guardians, Aiko was trained from a young age by her grandmother, the previous guardian. Her village, isolated from the hustle and bustle of the cities, preserved a strong connection to nature and its mystical energies. Aiko’s life was a blend of rigorous training sessions and typical teenage experiences, although she felt the weight of her responsibility constantly tugging at her. Aiko’s peaceful village life was disrupted when she turned 15, and the balance of nature began to falter due to a resurgence of dark forces. The once-understood mantle was passed down to her, and she became the chief protector against these malevolent supernatural beings threatening not just her village, but the entire world. Mood: The mood surrounding Aiko Takahashi is a mix of serene nature harmonies and looming tension. Her story oscillates between the tranquil beauty of her village’s lush forests and the intense battles against dark forces. The ambiance often shifts from the comforting, warm lights of traditional paper lanterns to the eerie, suspenseful darkness of encroaching night. Aiko is a hopeful yet burdened character, struggling with the balance between her personal desires and her duty. This duality flavors her story with both light-hearted moments of teenage life and the somber, weighty responsibilities she carries as a guardian. Physical Appearance: Aiko Takahashi embodies the ethereal beauty and intensity of a hero tied to nature. Here are the details of her appearance: Hair: Long, jet-black hair that flows down to her waist, often tied up in intricate styles with traditional hairpins and floral adornments during ceremonies. In battle, she wears it in a high ponytail for practicality. Eyes: Her eyes are a striking emerald green, reflecting the elemental power she channels. They glow faintly when she uses her abilities, adding a mystical air to her presence. Height: Average height for her age, around 5’4” (162 cm), giving her a balanced, agile frame. Build: She has a lithe, athletic build from years of training, yet retains an air of grace and poise. Attire: Normally, Aiko wears her school uniform — a typical sailor-style outfit with a green bow tie. However, during her guardian duties, she dons a traditional miko (shrine maiden) attire, which is white and crimson with flowing sleeves and intricate designs that symbolize the elements she controls. Superpowers: Aiko possesses the rare ability to manipulate the four classical elements — Earth, Water, Fire, and Air. Her training allows her to wield these powers with precision and creativity: Earth: Aiko can summon and control earth in various forms, from creating barriers out of rock to growing plants for attack or defense. She can also sense vibrations through the ground, giving her a tactical advantage during battles. Water: Aiko can manipulate water, shaping it into various forms such as weapons or healing mists. She can also purify tainted water and summon rain. Fire: With fire, Aiko can generate intense flames, enhance her physical attacks with fire aura, and even create fire-based constructs like phoenixes. Her control allows her to extinguish fires too, preventing collateral damage. Air: Aiko’s air manipulation enables her to create powerful gusts of wind, form protective air barriers, and enhance her agility. She can also use air currents to glide or leap across large distances. Aiko’s elemental powers are tied to her emotions and her training has taught her to maintain a balance within herself to ensure precise and effective use of her abilities. As the newest guardian, Aiko’s journey is about mastering her powers, understanding the ancient knowledge passed down to her, and uniting with her allies to protect the world from encroaching darkness. Brimming with potential and the wisdom of her ancestral lineage, Aiko Takahashi is on a path that will challenge her resolve, reveal her true strength, and ultimately allow her to embrace her destiny as the Elemental Guardian.”

## Automate text-to-image prompt

Then, we ask another GPT-4o instance to write a text-to-image prompt for each of these images. The system instruction is:

> “You are an AI assistant writing in-depth prompts for another AI model. Your output must always be a detailed prompt without additional text. You must write a detailed prompt with the parameters and features of an image for a given user input. Write prompts as detailed as possible. It must be related to the topic of the user’s input. Pay attention to describing style and everything in the image.”

## Example Anime Characters


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/v14zftm9d7xmun5krxcl.png)

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/m28hztud45pjeytfjuvm.png)

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/k0rqxas0iio9u3uwxzqv.png)

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/bfp53hhvdknmstb3p3n5.png)

## Create Anime Characters with GPT-4o and SDXL

You can use this agent via:

https://www.aiflowly.com/.../AID-01J2YFMMFFD26H2QTFQARQV61N