Tiiny SDK for edge computing power box communication
Project description
Tiiny SDK
A Python SDK for communicating with Tiiny edge computing power boxes via USB-C connection.
Overview
The Tiiny SDK provides a simple, OpenAI-like interface for interacting with Tiiny edge computing devices. The workflow involves:
- Detecting if the device is connected to the host computer
- Authenticating with the device
- Sending chat completions requests to the edge computing device
Installation
pip install tiiny-sdk
Quick Start
import tiiny
# Initialize the client
client = tiiny.TiinyClient()
# Check if device is connected
if client.is_device_connected():
# Authenticate with the device
client.login(api_key="your-api-key")
# Send a chat completion request
response = client.chat.completions.create(
model="tiiny-edge",
messages=[
{"role": "user", "content": "Hello, edge device!"}
]
)
print(response.choices[0].message.content)
else:
print("No Tiiny device found. Please check your USB connection.")
Features
- Device Detection: Automatically detect connected Tiiny devices
- Authentication: Secure login with API keys
- Chat Completions: OpenAI-compatible chat interface
- Error Handling: Comprehensive error handling and logging
- Type Hints: Full type annotation support
Requirements
- Python 3.8+
- USB-C connection to Tiiny edge computing device
- Valid API key for authentication
Development
Install development dependencies:
pip install -e ".[dev]"
Run tests:
pytest
License
MIT License - see LICENSE file for details.
Project details
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
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 tiiny_sdk-0.1.0.tar.gz.
File metadata
- Download URL: tiiny_sdk-0.1.0.tar.gz
- Upload date:
- Size: 11.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3b0798e3ef138b247ec7734a752e997939bd9890ac81ba0d1a77e81a961be129
|
|
| MD5 |
c58c7989329245bf2c38c756eea00fde
|
|
| BLAKE2b-256 |
a6ef16289f394d919a152c726dc0d2c433a19dd7b6b485c868bc91473b6f8500
|
File details
Details for the file tiiny_sdk-0.1.0-py3-none-any.whl.
File metadata
- Download URL: tiiny_sdk-0.1.0-py3-none-any.whl
- Upload date:
- Size: 9.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
62e820e74a9d559fc73e24e1afa5b212ca0d3f5a09b1c89187217bea277d9acf
|
|
| MD5 |
b2edf976e25fb86bc21b047e2a2e652d
|
|
| BLAKE2b-256 |
523ad76f94e95a49536cf1dd2784b738c38b94328faa49bcc14ebe7cff316375
|