Python SDK for BitLlama Protocol
Project description
BitLlama Python SDK
Official Python SDK for the BitLlama Protocol
Installation
pip install bitllama
Quick Start
from bitllama import BitLlama, MiningClient
import asyncio
async def main():
# Initialize client
client = BitLlama(
coordinator_url="https://api.bitllama.ai",
private_key="your_private_key",
network="base-mainnet"
)
# Create inference request
response = await client.i
nference.create(
model="llama3:70b",
prompt="Explain quantum computing",
max_tokens=500
)
print(response.text)
asyncio.run(main())
Mining
# Initialize mining client
miner = MiningClient(
client=client,
model_provider="ollama",
model_name="llama3:70b"
)
# Start mining
await miner.start()
# Check status
status = await miner.get_status()
print(f"Jobs completed: {status.jobs_completed}")
print(f"Earnings: {status.total_earnings} BLMA")
# Stop mining
await miner.stop()
Documentation
Full documentation available at https://docs.bitllama.ai/python-sdk
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
bitllama-1.0.0.tar.gz
(6.4 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file bitllama-1.0.0.tar.gz.
File metadata
- Download URL: bitllama-1.0.0.tar.gz
- Upload date:
- Size: 6.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.7.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d1318104be3f3435256de00715375c31acf821c19e4d322df3fa67b53634a586
|
|
| MD5 |
038936cc22c2a8b94772b0534eaaf8f9
|
|
| BLAKE2b-256 |
4260548bf3a65701f23b867cc937d8547a741cbf3d50524de8d825ca1e09f731
|
File details
Details for the file bitllama-1.0.0-py3-none-any.whl.
File metadata
- Download URL: bitllama-1.0.0-py3-none-any.whl
- Upload date:
- Size: 8.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.7.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
379a0a93183a8c7a2e35ab03961a0b26209e3895d7ff07f4506caa4e4a72419a
|
|
| MD5 |
83173adf022a1825c6fba95ba871c333
|
|
| BLAKE2b-256 |
f4b30a2000115fba209ea67a3b2f9487b53540877b383deb3cbd34ef90ff7f92
|