EN ▾
Get API key

Qwen3.5 Roleplay with an Uncensored Text API

If you want long, in-character chat without the model stepping out to lecture you, a text API tuned to skip content refusals is the simplest route. This page shows how to wire one up for roleplay and what a session costs.

Updated

Stage with empty chairs and glowing speech bubbles, a metaphor for AI character roleplay

Key points

  • The API is OpenAI-compatible, so any roleplay frontend or script that accepts a custom base URL works with model ID uncensored.
  • A 100,000-token window holds a very long character history, but you pay for the history on every turn, so trim it.
  • A 30-turn session with a 500-token character profile costs about $0.033 at $0.15 and $0.50 per 1M tokens.
  • Fiction for lawful adult use only. Sexual content involving minors is blocked without exception.

The short answer for Qwen3.5 roleplay

People who search for qwen3.5 roleplay usually want one of two things: a model that stays in character for hundreds of messages, and one that does not break the scene with a refusal halfway through a story. This API covers the second need directly. It serves a single open-weight model, run by an independent provider and tuned to answer without content refusals for lawful adult use, behind the same /v1/chat/completions endpoint that every OpenAI client already speaks.

One point of honesty first. This service is not the official Qwen API and it is not a router that forwards to Qwen or any other vendor. You send requests to one model whose ID is uncensored. If you need a specific Qwen release by name, check the vendor's own platform. If what you need is a roleplay-friendly text model you can call from a script or a chat frontend, read on.

The setup takes three values: the base URL https://api.qwenimageapi.cc/v1, your key, and the model ID. Everything else in this article is about getting good results from that setup.

Why refusals ruin a roleplay session

Roleplay is a long game. A refusal in a one-shot question costs you a retry. A refusal at message 80 of a story costs you the mood, the pacing and sometimes the whole thread, because the model's next reply tends to inherit the cautious tone of the one before it. Writers who run fiction with villains, war, grief or romance between adult characters know the pattern: a disclaimer appears, the character goes flat, and you spend the next ten messages dragging the scene back.

A model tuned to answer without content refusals removes that failure mode for lawful adult fiction. It does not remove the need for good prompting. You still have to tell the model who the character is, what the setting is, and how long each reply should be. The difference is that the instructions you write are followed instead of second-guessed.

The hard limit is simple and not negotiable: no sexual content involving minors. That rule applies to every request, whatever the framing, and a story that depends on it will not work here.

What counts as a good use

  • Interactive fiction and tabletop-style campaigns with an AI game master.
  • Companion and character apps for adult users.
  • Dialogue drafting for writers who want a character to talk back in voice.
  • Testing a roleplay frontend of your own before you ship it.

A working character chat in Python

The script below keeps the whole conversation in a list and sends it with every call. That is how chat completions work: the API holds no memory between requests, so the history you send is the memory the character has.

from openai import OpenAI

client = OpenAI(
    base_url="https://api.qwenimageapi.cc/v1",
    api_key="YOUR_KEY",
)

SYSTEM = (
    "You are Mara, a weary river-boat captain in a fantasy delta town. "
    "Stay in character. Write in first person, past tense, 2 to 4 short paragraphs. "
    "Never speak for the user's character. End on something the user can react to."
)

history = [{"role": "system", "content": SYSTEM}]

def say(text):
    history.append({"role": "user", "content": text})
    stream = client.chat.completions.create(
        model="uncensored",
        messages=history,
        temperature=0.9,
        top_p=0.95,
        stream=True,
    )
    reply = ""
    for chunk in stream:
        if chunk.choices and chunk.choices[0].delta.content:
            piece = chunk.choices[0].delta.content
            reply += piece
            print(piece, end="", flush=True)
    print()
    history.append({"role": "assistant", "content": reply})

say("I step onto the dock at dawn and ask if she still takes passengers.")

Streaming matters for roleplay because a reply of several paragraphs takes a while to finish, and reading as it arrives feels like a person typing. A streamed request keeps its concurrency slot until the stream ends, which only becomes relevant if you run many chats at once.

Writing a system prompt that holds a character

Most roleplay quality comes from the system message. A paragraph of backstory is less useful than a short list of rules the model can check itself against. These four elements do the most work.

  1. Identity and voice. Name, role, how they talk. "Short sentences, dry humour, never uses the word please" beats "a grumpy person".
  2. Scene and stakes. Where the story is, what the character wants, what is in the way.
  3. Format rules. Length, person, tense, and whether actions go in asterisks. State them once and plainly.
  4. Boundaries of control. Tell the model not to write the user's actions or decisions. Without this, long sessions drift into the model narrating for you.

Sampling settings that suit fiction

A temperature around 0.8 to 1.0 with top_p near 0.95 gives varied prose. If a character starts looping on the same phrase, add a small frequency_penalty such as 0.3 to 0.6. The penalties are passed through to the model, so values behave the way they do in other OpenAI-compatible stacks. For reproducible testing while you tune a prompt, set seed and keep the other settings fixed, then change one thing at a time.

Use stop sequences if your frontend formats turns with a marker, for example stopping at a line that begins with the user's name. That prevents the model from continuing into your side of the dialogue.

Managing the 100,000-token window

The context window is 100,000 tokens, counting the prompt and the completion together. For a story that is a lot of room: a typical English page is a few hundred tokens, so a long campaign fits. The catch is cost and drift, not a hard wall. Every turn resends the whole history, so a session that has grown to 60,000 tokens charges you for 60,000 input tokens on the next message, and the model pays less attention to details buried in the middle.

Three habits keep long sessions sharp and cheap:

  • Pin the profile. Keep the system message at the top, unchanged, and put anything the character must never forget there.
  • Summarise old turns. Every 30 to 40 messages, ask the model for a bullet summary of what happened, then replace the oldest messages with that summary. You can use the same endpoint for the summary call.
  • Keep a window of recent turns. The last 20 or so messages in full, plus the summary, is enough for most scenes.

Because the completion can use whatever part of the window is left, max_tokens is optional. For roleplay it is still worth setting, for example 600, so one runaway reply cannot eat a large slice of your credit.

Using a roleplay frontend instead of code

You do not have to write a client. Frontends that let you add a custom OpenAI-compatible endpoint, SillyTavern among them, ask for the same three values: the base URL, the key and the model name. Pick the chat-completions style connection, paste https://api.qwenimageapi.cc/v1 as the URL, enter your key as the bearer token, and type uncensored as the model. If the frontend has a model picker that calls GET /v1/models, the list will contain that one ID.

Two settings to check in any frontend. First, the context size slider: set it at or below 100,000 and, for cost reasons, usually much lower. Second, the response length: a cap of 400 to 800 tokens keeps replies in the range most roleplay prefers. Frontends that support tool calling or JSON mode can use them as well, since both are supported on this API, but plain chat is all a character needs.

The quickstart in the docs lists the endpoints and headers, and the guide for media pipelines explains how the same text model can write prompts for image tools. This API itself returns text only.

What a roleplay session costs

Pricing is $0.15 per 1M input tokens and $0.50 per 1M output tokens, charged from prepaid credit. Here is a concrete session. The character profile is 500 tokens. Each turn, you write about 150 tokens and the character answers with about 250, so history grows by 400 tokens per turn. Over 30 turns:

  • Input per turn is 500 + 400 x (turn - 1) + 150. Summed over 30 turns that is 30 x 650 + 400 x 435 = 193,500 tokens.
  • Output is 30 x 250 = 7,500 tokens.
  • Input cost: 193,500 x $0.15 / 1M = $0.029025.
  • Output cost: 7,500 x $0.50 / 1M = $0.00375.
  • Total: about $0.033 for the whole session.

So $20, the smallest top-up, covers hundreds of sessions of that size. Failed or refused requests are not charged, and credit never expires, so an unused balance simply waits. Details on bonuses and amounts are on the pricing page, and a new account can claim $0.50 of trial credit with one click on the API key page. That trial is enough for the 30-turn example above with room to spare. The trial key allows 2 concurrent requests and 60 requests per minute, which is plenty for one person chatting.

Payment is by crypto only: USDT on TRC20 or USDC on Base.

Questions and answers

Is this the official Qwen API?

No. It is a hosted, OpenAI-compatible API for one open-weight model run by an independent provider. It is not the official API of Qwen or any other vendor, and it does not route between vendors.

Can the model keep a character for a very long story?

The window is 100,000 tokens, so a long history fits. For best results pin the character profile in the system message and summarise older turns instead of sending everything forever.

What content is not allowed?

Sexual content involving minors is blocked with no exceptions. Everything else is aimed at lawful adult use, including dark or mature fiction.

Can I use it with a roleplay frontend?

Yes. Any client that accepts a custom OpenAI-compatible endpoint works. Enter the base URL, your key and the model ID uncensored.

Are my chats used for training?

No. Prompts are not used for training.

Your key is one form away

Create an account, copy the key, change the base URL. That is the whole setup.