Files
Qwen3-Sex/README.en.md
ModelHub XC bb6612bce2 初始化项目,由ModelHub XC社区提供模型
Model: evildevlive/Qwen3-Sex
Source: Original Platform
2026-06-27 09:07:15 +08:00

7.6 KiB
Raw Permalink Blame History

license, language, base_model, pipeline_tag, library_name, tags, datasets
license language base_model pipeline_tag library_name tags datasets
apache-2.0
zh
en
Qwen/Qwen3-4B-Instruct-2507
text-generation transformers
qwen3
chat
sft
nsfw
not-for-all-audiences
ystemsrx/Erotic_Literature_Collection
ystemsrx/Bad_Data_Alpaca

Qwen3-Sex

Base Model License Dtype Context Audience Not for all audiences

简体中文 | English

A conversational model fine-tuned from Qwen3-4B-Instruct-2507.

Warning

This model is intended for adult users (18+) only. It may generate adult, explicit, or otherwise NSFW content. Please read the Disclaimer before using it.


Model Overview

Item Value
Base model Qwen/Qwen3-4B-Instruct-2507
Dtype bfloat16
Context length native 262,144 (4K32K recommended for everyday chat)
Chat template ChatML (`<

Repository Contents

File Description
model-*.safetensors Full weights (bfloat16)
config.json / tokenizer* / chat_template.jinja Model & tokenizer configuration
generation_config.json Recommended inference parameters (keep defaults for best results)
infer.py Ready-to-use multi-turn CLI chat script
Modelfile Modelfile for importing into Ollama
Qwen3-Sex-BF16.gguf Unquantized GGUF (BF16, ~8 GB)
Qwen3-Sex-Q8_0.gguf Q8_0 quantized GGUF (~4.3 GB)

Important

The values in generation_config.json are tuned for this model and should be kept as the defaults for optimal quality.

{
  "do_sample": true,
  "temperature": 0.7,
  "top_p": 0.8,
  "repetition_penalty": 1.08,
  "max_new_tokens": 2048,
  "eos_token_id": [151645, 151643],
  "pad_token_id": 151643,
  "bos_token_id": 151643
}

Quick Start

The repo ships with an interactive CLI script that loads the model and applies the parameters from generation_config.json automatically:

# Set up a virtual environment (uv is recommended)
uv venv
source .venv/bin/activate
uv pip install torch transformers accelerate

# Start chatting
python infer.py

Tip

Type clear to reset the multi-turn history; type exit or quit to leave.

Option 2: Minimal inference code

import torch
from transformers import AutoModelForCausalLM, AutoTokenizer, GenerationConfig

MODEL_NAME = "ystemsrx/Qwen3-Sex"

tokenizer = AutoTokenizer.from_pretrained(MODEL_NAME, trust_remote_code=True)
model = AutoModelForCausalLM.from_pretrained(
    MODEL_NAME,
    dtype=torch.bfloat16,
    device_map="auto",
    trust_remote_code=True,
)
model.eval()

# Load the recommended generation config (keeping defaults gives the best quality)
gen_config = GenerationConfig.from_pretrained(MODEL_NAME)

messages = [
    {"role": "user", "content": "Hello, please introduce yourself briefly."},
]

inputs = tokenizer.apply_chat_template(
    messages,
    add_generation_prompt=True,
    return_tensors="pt",
    return_dict=True,
).to(model.device)

with torch.inference_mode():
    output_ids = model.generate(**inputs, generation_config=gen_config)

response = tokenizer.decode(
    output_ids[0][inputs["input_ids"].shape[-1]:],
    skip_special_tokens=True,
)
print(response)

Option 3: Use the GGUF files in Ollama

GGUF builds (Qwen3-Sex-BF16.gguf and Qwen3-Sex-Q8_0.gguf) are included so you can load the model directly with Ollama:

# Build the Ollama model from the bundled Modelfile
ollama create Qwen3-Sex -f Modelfile

# Start chatting
ollama run Qwen3-Sex

Caution

GGUF builds — especially the Q8_0 quantized one — produce lower output quality than the original safetensors weights. Fine details, long-context coherence, and generation stability may degrade. If quality is critical, prefer Option 1 or Option 2.


Disclaimer

Caution

Downloading or using this model constitutes your acknowledgement and acceptance of all terms below. If you do not agree, stop downloading and using the model immediately.

Click to fold / unfold the full notice
  1. Adult content warning: This model has been fine-tuned on adult-oriented data and may produce explicit, sensitive, or NSFW text. Anyone under the age of 18 (or under the age of majority in their jurisdiction) is strictly prohibited from accessing, downloading, or using this model.
  2. Permitted use: The model is provided solely for academic research, personal non-commercial use, and fictional creative writing. Users must comply with all applicable laws and regulations in their jurisdiction. It must not be used to generate illegal content, content that infringes the rights of others, sexual content involving minors, non-consensual sexual content involving real persons, or any other content that violates public order or morality.
  3. No liability: The author(s) of this model accept no responsibility for any direct or indirect consequences arising from its use, including but not limited to legal liability, emotional or reputational harm, or financial loss. Generated content does not represent the views or positions of the author(s).
  4. Third-party platforms: When deploying or using this model on any third-party platform, service, or application, you must additionally comply with that platform's terms of service and content policies.
  5. Use at your own risk: The model may produce factually incorrect, biased, or harmful output. Users are responsible for evaluating and accepting these risks.
  6. Acceptance: Downloading or using this model constitutes your acknowledgement and acceptance of all terms above. If you do not agree, stop downloading and using the model immediately.

License

This model is released under the Apache License 2.0, and inherits the relevant license terms of the base model Qwen/Qwen3-4B-Instruct-2507.