Library for accessing the anthropic API
Project description
Anthropic Python SDK
This python repo provides access to Anthropic's safety-first language model APIs.
For more information on our APIs, please check out Anthropic's documentation.
How to use
Install the package with:
pip install anthropic
Then write code with:
import anthropic
client = anthropic.Client(api_key=<insert token here>)
client.XXX # look to examples/ directory for code demonstrations
How to develop and run the examples in this repo
pip install .
export ANTHROPIC_API_KEY=<insert token here>
python examples/basic_sync.py
python examples/basic_stream.py
python examples/count_tokens.py
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
anthropic-0.2.8.tar.gz
(5.7 kB
view hashes)
Built Distribution
Close
Hashes for anthropic-0.2.8-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7a11da8a3d8cb52835912e73d42e9245e7949155f4afb7093496f100a9bf610b |
|
MD5 | b8f565880af886f7d32e4fb9273a36d5 |
|
BLAKE2b-256 | 29823693786bdf81557cf458d9365795b6f00904ccad9c51e47e7d9d15182db2 |