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.10.tar.gz
(5.7 kB
view hashes)
Built Distribution
Close
Hashes for anthropic-0.2.10-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a007496207fd186b0bcb9592b00ca130069d2a427f3d6f602a61dbbd1ac6316e |
|
MD5 | b0293ba7f7fabe6e97c706fec877b6bf |
|
BLAKE2b-256 | 0b3a6e609e7162833ed87762656f902f2fe1009ad93f794a1c5b270bea0fb039 |