tr ▾
Get API key

Hugging Face AbliteratedAPI Documentation

API Documentation

Get started with the uncensored LLM API in minutes. Use the openai compatible API standard to send text and receive unrestricted responses immediately.

Get API key

Base URL and Authentication

Connect to the API using our dedicated base URL and a single API key. The endpoint is https://api.huggingfaceabliteratedmodels.com/v1. You generate this key on the dashboard by clicking "Get API key". Use Google or an email password to sign in. The key appears instantly. Use it in the Authorization header as a Bearer token. No phone number is required for signup. The system tracks usage against this specific key.

  • Base URL: https://api.huggingfaceabliteratedmodels.com/v1
  • Auth Header: Authorization: Bearer YOUR_API_KEY

First Request

Send your first prompt to the uncensored model using a standard HTTP POST request. The model identifier is "uncensored". This abliterated model handles text generation without content refusals for lawful adult topics. It supports a 100,000 token context window for both prompt and completion combined. You can send up to 16,000 tokens in a single response. Errors and refusals do not consume your prepaid credit. Use curl to test connectivity and response format.

Here is a basic request example:

curl https://api.huggingfaceabliteratedmodels.com/v1/chat/completions \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "uncensored",
    "messages": [{"role": "user", "content": "What is the current version number of the latest release"}]
  }'

Python SDK Integration

Use the official OpenAI Python library to interact with the API seamlessly. Set the base URL and API key in the client configuration. This allows you to use familiar methods like chat.completions.create(). The library handles JSON serialization and streaming automatically. You can pass parameters like temperature and top_p directly. This approach works for both synchronous and asynchronous applications. It is the recommended way to integrate abliterated AI into your python projects.

Example Python code:

from openai import OpenAI

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

resp = client.chat.completions.create(
    model="uncensored",
    messages=[{"role": "user", "content": "Summarise this thread without softening it."}],
)
print(resp.choices[0].message.content)

Node SDK Integration

Integrate the API into your node.js applications using the standard openai node package. Configure the client with the custom base URL and your API key. This ensures compatibility with existing node libraries. You can make requests for text generation or function calling. The response structure matches the OpenAI API specification exactly. This makes switching from other providers or using multiple models easier. Use this method for server-side generation or edge functions.

Example Node.js code:

import OpenAI from "openai";

const client = new OpenAI({ baseURL: "https://api.huggingfaceabliteratedmodels.com/v1", apiKey: process.env.API_KEY });

const resp = await client.chat.completions.create({
  model: "uncensored",
  messages: [{ role: "user", content: "Draft a villain monologue for my game." }],
});
console.log(resp.choices[0].message.content);

Streaming Responses

Receive tokens in real-time using Server-Sent Events (SSE). Set stream: true in your request body. The API sends chunks as they are generated. This reduces perceived latency for end-users. Each chunk contains part of the response. The final chunk includes the full token usage statistics. This is ideal for chat interfaces or live text generation. You can parse these events in your frontend or backend. Streaming works with all standard parameters.

Example streaming code:

stream = client.chat.completions.create(
    model="uncensored",
    messages=[{"role": "user", "content": "Tell the story in second person."}],
    stream=True,
)
for chunk in stream:
    if chunk.choices and chunk.choices[0].delta.content:
        print(chunk.choices[0].delta.content, end="", flush=True)

Rate Limits and Errors

The API enforces strict limits to ensure stability. You are allowed 300 requests per minute per key. You can have 8 concurrent requests active at once. The maximum request body size is 8 MB. If you send an invalid key, you receive a 401 error. A 402 error means your prepaid credit is exhausted. Errors do not charge your balance. A 429 error indicates you have hit the rate limit. Wait a few seconds before retrying. Your credit never expires, so you can top up later.

01Hugging Face Abliterated

Frequently asked questions

What is the context window size for this abliterated LLM?

The model supports a 100,000 token context window. This limit includes both the prompt and the completion tokens combined. You can generate up to 16,000 tokens in a single response. This allows for long-form content generation without cutting off.

How do I handle rate limits with the abliterated API?

You are limited to 300 requests per minute and 8 concurrent connections. If you exceed this, you will receive a 429 status code. The system does not block your key permanently. You can simply wait and retry your requests. Each account has one active key that replaces the old one.

Is the hugging face abliterated models API openai compatible?

Yes, the API follows the OpenAI chat-completions standard. You can use the official OpenAI SDKs by changing the base URL. The endpoint is <code>/v1/chat/completions</code>. This ensures easy integration with existing tools and libraries that expect OpenAI responses.

Hugging Face Abliteratedhuggingfaceabliteratedmodels.com

Get your key now

Sign up, grab the key, update your base URL. That’s all there is.

Get API key