Skip to main content

Official python library for the Uncensored AI (uncensored.com) API

Project description

Uncensored AI Python Package

A lightweight Python client for the Uncensored AI API

Features

  • Chat completions - with streaming support
  • Fine-tuning
  • Model listing
  • Image generation
  • CLI for easy account management
  • Both global and client-based usage patterns

Installation

pip install uncensored

Usage

import uncensored

# Global usage
uncensored.api_key = "YOUR-KEY-HERE"

response = uncensored.ChatCompletion.create(
    model="model-t",
    messages=[{"role": "user", "content": "Say wasa"}],
    stream=True,
)

for chunk in response:
    print(chunk)

# OR using an optional client-like usage
client = uncensored.Client(api_key="YOUR-KEY-HERE")
models = client.list_models()
print(models)

CLI

# Log in (fetch/store API key)
uncensored login

# Check your usage/balance
uncensored balance

# List available models
uncensored list-models

contact: devs@uncensored.com

by uncensored.com

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

uncensored-0.0.1.tar.gz (7.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

uncensored-0.0.1-py3-none-any.whl (10.6 kB view details)

Uploaded Python 3

File details

Details for the file uncensored-0.0.1.tar.gz.

File metadata

  • Download URL: uncensored-0.0.1.tar.gz
  • Upload date:
  • Size: 7.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.6

File hashes

Hashes for uncensored-0.0.1.tar.gz
Algorithm Hash digest
SHA256 a239b648fbe37cabc54c8415629b6c80dd2178f65282dd083740f49adb397f4e
MD5 20fbbd827399ed373a318aad3924850b
BLAKE2b-256 a486226673536f7b83b473c46a56b70fec6855fcdca7b9e1fe3fb423db00a014

See more details on using hashes here.

File details

Details for the file uncensored-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: uncensored-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 10.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.6

File hashes

Hashes for uncensored-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 09849bfb12f8f85378563f59884e5dd2f07d554c4fb725cdf3cfe6e42d7c1556
MD5 f84949010b1f3bd71e6520960edd4c52
BLAKE2b-256 2d48875abec7a24ca2bb45ff7f81471b294de56d962ed2ee3155955179c8d984

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page