Skip to main content
WriftAI Banner

WriftAI Python Client

Docs · Issues

CI PyPI - Version License

The WriftAI Python Client provides convenient access to WriftAI's services. The library includes type definitions for all request params and response fields, and offers both synchronous and asynchronous clients powered by httpx.

Documentation

https://wrift.ai/docs/clients/python

Requirements

  • Python 3.10+

Installation

pip install wriftai

Basic Usage

import os

from wriftai import Client

# Instantiate the WriftAI client
wriftai = Client(
    # This is the default and can be omitted
    access_token=os.environ.get("WRIFTAI_ACCESS_TOKEN"),
)

# Create a prediction against deepseek-ai/deepseek-r1 and wait for it to complete
prediction = wriftai.predictions.create(
    model="deepseek-ai/deepseek-r1",
    input={
        "prompt": "Summarize quantum computing.",
    },
    wait=True,
)

print(prediction.output)
# Quantum computing uses quantum bits to solve problems...

Using AsyncIO

The WriftAI Python client includes asyncio support powered by httpx. For convenience, every method also has an async_ prefixed variant.

Contributing

Contributions are very welcome. To learn more, see the Contributor Guide.

License

Copyright (c) Sych Inc. All rights reserved.

Distributed under the terms of the Apache 2.0 license.

Release files for wriftai 0.32.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for wriftai 0.32.0
File Size Uploaded
wriftai-0.32.0.tar.gz 268.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for wriftai 0.32.0
File Interpreter ABI Platform
wriftai-0.32.0-py3-none-any.whl Python 3 none any Details

Total release size: 303.2 kB

Release files / wriftai-0.32.0.tar.gz

Download URL wriftai-0.32.0.tar.gz
Size 268.4 kB
Tags Source
SHA-256 checksum
How to use checksums
3b43ed785c5bd21ca7d89c60977b524758c5c23e59107acd0ae5e67c4426b642
BLAKE2b-256 checksum
How to use checksums
881a8923b0f4601282f3781f382ead259dd81cec001c0e0a85d61009c2f1ae06
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.6.14

Release files / wriftai-0.32.0-py3-none-any.whl

Download URL wriftai-0.32.0-py3-none-any.whl
Size 34.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
36915b5626e4244980aed9a49f22324f8b3733623190b94927cf0fab2ea65e6d
BLAKE2b-256 checksum
How to use checksums
3e010763505e098d7520084335b895ad0e83fc75505ff823e5988c73bcf502db
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.6.14
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page