Spellbok Serve Python Client
Project description
Spellbook Serve
The Spellbook Serve Python library provides a convenient way of interfacing with a
spellbook-serve
endpoint running on
Scale Spellbook Serve or on your own infrastructure.
Get Started
Install
pip install spellbook-serve-client
Usage
If you are using Scale Spellbook Serve, you can get your API key from
https://spellbook.scale.com/settings.
Set the SCALE_API_KEY
environment variable to your API key.
If you are using your own infrastructure, you can set the
SPELLBOOK_SERVE_BASE_PATH
environment variable to the base URL of your
self-hosted spellbook-serve
endpoint.
from spellbook_serve_client import Completion
response = Completion.create(
model_name="llama-7b",
prompt="Hello, my name is",
max_new_tokens=10,
temperature=0.2,
)
print(response.outputs[0].text)
Documentation
Documentation is available at https://scaleapi.github.io/spellbook-serve/.
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
Built Distribution
Close
Hashes for spellbook_serve_client-0.0.0a1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 80e942634c47cab071d11e2437add99c94de29c74080d99015f341b1ff3f25a5 |
|
MD5 | ac4058ceb61b3bb86dad4e8f3892f85a |
|
BLAKE2b-256 | 3a8619cb358d9dec3bf5f2e969df6aa3c4d9bafa2c083e934afc677effe87d59 |
Close
Hashes for spellbook_serve_client-0.0.0a1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0b71b0c3922d5d50dd8b76506e4fb4faf9b256c831342694ee17ef46881f0455 |
|
MD5 | 7eab81dff036c87ad8281978edb7dea7 |
|
BLAKE2b-256 | bdbebf1067f4d61b093f210ef0a322d25f843ebe3f365b5724afcc6c24172bd6 |