Athena Python SDK for block development
Project description
athena-sdk
Python SDK for building blocks and workflows on the Athena ML orchestration platform.
Installation
pip install buildathena-sdk
Quick Start
Define a Block
from athena import block, BlockContext
@block(name="TrainModel", outputs=["checkpoint"])
async def train_model(ctx: BlockContext, epochs: int = 100):
for epoch in range(epochs):
loss = train_epoch()
await ctx.emit_metric("loss", loss, epoch=epoch)
ref = await ctx.artifacts.register("model.pt", schema_type="checkpoint")
return {"checkpoint": ref}
Use Credentials
Declare required secrets in the @block decorator and access via ctx.secrets:
from athena import block, BlockContext
@block(name="MyBlock", secrets=["OPENAI_API_KEY"])
async def my_block(ctx: BlockContext, config):
key = ctx.secrets["OPENAI_API_KEY"]
Features
- Block Decorator:
@blockfor defining workflow nodes - Handler Decorator:
@handlerfor custom URI scheme storage backends (s3://, gs://) - Inspector Backend:
@inspector_backendprotocol for interactive UI plugins - BlockContext: Emit metrics, progress, logs, and register artifacts
- Config System: YAML with
$include,$extends,${ref}substitution - Discovery: AST-based scanner for workspace block detection
- Credentials: Secure secret management with
@block(secrets=...)andctx.secrets
License
Proprietary - Copyright (c) 2026 Athena Technologies. All rights reserved.
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
buildathena_sdk-0.1.32.tar.gz
(69.3 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 buildathena_sdk-0.1.32.tar.gz.
File metadata
- Download URL: buildathena_sdk-0.1.32.tar.gz
- Upload date:
- Size: 69.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.8.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c9a49d42f5f7fc91a2acde1745d92d5c6212b7f7cef8657e497e1679b93bf57d
|
|
| MD5 |
f1a20e248de8f63bc2c6bac57523c730
|
|
| BLAKE2b-256 |
d525bfbd5fbe820bfdb779cf209a8b52aefeee53f9a4604d9f75a99f77234ff7
|
File details
Details for the file buildathena_sdk-0.1.32-py3-none-any.whl.
File metadata
- Download URL: buildathena_sdk-0.1.32-py3-none-any.whl
- Upload date:
- Size: 44.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.8.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5875925529330bd5eda06941d13d5178478a517a3f79def39677e2daf20c4de4
|
|
| MD5 |
b5c4370d2becb34629ffa2f9b2d064b7
|
|
| BLAKE2b-256 |
6c6977d4818a44b0588c66f8e26f2bb4eb42acbafb8ce2101d7822910e71e97d
|