Commonbase Python SDK
Project description
Commonbase Python SDK
Commonbase allows developers to integrate with any popular LLM API provider without needing to change any code. The SDK helps with collecting data and feedback from the users and helps you fine-tune models for your specific use case.
Installation
pip install commonbase
Usage
A Project ID and API Key are required for all Commonbase requests. You can find your project ID and generate an API key in the Commonbase Dashboard.
To create a completion, provide your Project ID, API Key, and prompt to Completion.create
.
import commonbase
result = commonbase.Completion.create(
api_key="YOUR_API_KEY",
project_id="YOUR_PROJECT_ID",
prompt="Hello!"
)
print(result.best_result)
To stream a completion as it is generated, use Completion.stream
.
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
commonbase-0.2.2.tar.gz
(23.2 MB
view hashes)
Built Distribution
Close
Hashes for commonbase-0.2.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1e7fe4668762671711e992be7b6101626f0d7fe483584bd94c1c6f7ff40c2046 |
|
MD5 | 21a93a4e9cf2282a9c908d72e0a974e8 |
|
BLAKE2b-256 | 90d6d0d864afa41f0053ab8f6ee12b5084a36bad09531e00ffd46ef5ee9d080c |