# AI Character Reference Bank — Consistent Characters (`dami_studio/ai-character-reference-bank`) Actor

Describe one character and get a matching reference set. You get a portrait, three-quarter, full body, side profile and expression sheets. It also writes a character-bible prompt you can reuse. That keeps the face, hair, outfit and colors the same in every shot. $0.15 per character, flat.

- **URL**: https://apify.com/dami\_studio/ai-character-reference-bank.md
- **Developed by:** [Dami's Studio](https://apify.com/dami_studio) (community)
- **Categories:** AI, Videos, Social media
- **Stats:** 5 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: 5.00 out of 5 stars

## Pricing

from $150.00 / 1,000 character banks

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

## AI Character Reference Bank

Give it a one-line character description and it generates a matching set of reference images (portrait, three-quarter, full body, side profile, and expression sheets) plus a reusable "character bible" prompt you can paste into later jobs. It's built for people who need the same character to show up identically across many shots: comics, faceless videos, game concepts, storyboards.

### How it works

For each character it writes a character-bible prompt from your description and shared style, then sends that same bible to OpenAI's gpt-image-1 once per requested view, appending the view instruction (front portrait, 3/4 angle, full body, side, or an expression). Reusing one locked description per view is what keeps the face, hair, clothing, and colors consistent across the set.

### Input

You bring your own OpenAI key. Nothing is strictly required by the schema. Run it without a key and it returns one clearly-labeled SAMPLE record showing the output shape instead of real images — that row is billed like any other (see Pricing).

| Field | Required | Notes |
|-------|----------|-------|
| `characters` | yes (in practice) | Array of descriptions. Plain strings, or objects `{ name, description }`. The name becomes the file slug. |
| `views` | no | Which views/expressions to render. Any of `portrait`, `threequarter`, `fullbody`, `side`, `happy`, `angry`, `sad`, `surprised`. Defaults to `portrait`, `threequarter`, `fullbody`. |
| `style` | no | Shared art style applied to every character so the whole set matches. Defaults to a clean studio-portrait style. |
| `aspectRatio` | no | `1:1`, `9:16`, or `16:9`. Defaults to `1:1`. |
| `quality` | no | gpt-image-1 quality: `low`, `medium`, `high`. Lower is cheaper and faster. Defaults to `high`. |
| `openaiApiKey` | yes (in practice) | Your OpenAI key with gpt-image-1 access. Stored as a secret. |
| `baseUrl` | no | Override for an OpenAI-compatible endpoint. Defaults to `https://api.openai.com/v1`. |

### Output

Each character is one dataset record. The PNG files land in the run's key-value store, and the record links to them. Key fields per record: `name`, `slug`, `description`, `characterBible` (the reusable prompt), and `references`, an array of `{ view, imageKey, imageUrl }`. If a particular view fails, that entry carries an `error` instead of an image and the rest still run — the character's record is written either way, and the charge is per record.

### Example

```json
{
  "characters": [
    { "name": "Milo", "description": "a small brave fox cub with a red scarf and bright green eyes, cartoon style" }
  ],
  "views": ["portrait", "threequarter", "fullbody", "happy", "angry"],
  "style": "consistent character design, clean studio background, soft even lighting",
  "aspectRatio": "1:1",
  "quality": "high",
  "openaiApiKey": "sk-..."
}
```

### Pricing

**$0.15 per dataset row**.

One character is one row, so three characters cost $0.45 no matter how many views you ask for: the view count drives your OpenAI bill, not the Apify one. Two cases are worth knowing, because the charge is per row rather than per usable result:

- a keyless run writes one labelled SAMPLE row and costs $0.15, so the preview is not free;
- a character whose views all failed still gets a row (with `error` entries under `references`) and is still charged $0.15.

Pay per result, no subscription. OpenAI image costs are billed separately to your own key.

### Notes

The character bible reduces drift but doesn't eliminate it. Across many views you'll still see small inconsistencies, so treat the set as strong references rather than a guarantee, and reuse the `characterBible` string verbatim in downstream prompts to stay on model.

# Actor input Schema

## `characters` (type: `array`):

Array of character descriptions — plain strings, or objects { name, description }.

## `views` (type: `array`):

Which views/expressions to render: portrait, threequarter, fullbody, side, happy, angry, sad, surprised.

## `style` (type: `string`):

Shared art style for the character set.

## `aspectRatio` (type: `string`):

Image shape.

## `quality` (type: `string`):

gpt-image-1 quality.

## `openaiApiKey` (type: `string`):

Your OpenAI key (gpt-image-1). Kept private.

## `baseUrl` (type: `string`):

OpenAI-compatible base URL. Default https://api.openai.com/v1.

## Actor input object example

```json
{
  "characters": [
    {
      "name": "Milo",
      "description": "a small brave fox cub with a red scarf and bright green eyes, cartoon style"
    }
  ],
  "views": [
    "portrait",
    "threequarter",
    "fullbody",
    "happy",
    "angry"
  ],
  "style": "consistent character design, clean studio background, highly detailed, soft even lighting",
  "aspectRatio": "1:1",
  "quality": "high"
}
```

# Actor output Schema

## `results` (type: `string`):

Result rows / metadata are stored in the default dataset (one row per item).

## `files` (type: `string`):

Generated media/files (video, audio, images, captions) are stored in the default key-value store.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "characters": [
        {
            "name": "Milo",
            "description": "a small brave fox cub with a red scarf and bright green eyes, cartoon style"
        }
    ],
    "views": [
        "portrait",
        "threequarter",
        "fullbody",
        "happy",
        "angry"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("dami_studio/ai-character-reference-bank").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "characters": [{
            "name": "Milo",
            "description": "a small brave fox cub with a red scarf and bright green eyes, cartoon style",
        }],
    "views": [
        "portrait",
        "threequarter",
        "fullbody",
        "happy",
        "angry",
    ],
}

# Run the Actor and wait for it to finish
run = client.actor("dami_studio/ai-character-reference-bank").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "characters": [
    {
      "name": "Milo",
      "description": "a small brave fox cub with a red scarf and bright green eyes, cartoon style"
    }
  ],
  "views": [
    "portrait",
    "threequarter",
    "fullbody",
    "happy",
    "angry"
  ]
}' |
apify call dami_studio/ai-character-reference-bank --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,dami_studio/ai-character-reference-bank"
        }
    }
}

```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/dxBbCpOHkUfLAZ5ir/builds/2AIIYoxevj6RerAqK/openapi.json
