Skip to main content

edi-maas-sdk

MaaS Platform Python SDK — HTTP client for model and dataset management.

Install

pip install edi-maas-sdk

Quick Start

from edi_maas_sdk import DatasetCategory, DatasetFormat, DatasetSplit, EdiApi

api = EdiApi(endpoint="https://maas.example.com/maas-service", api_key="edik-...")

# List models
repos = api.list_repos("models")
for r in repos:
    print(r.name, r.status)

# Create a model (display_name required; name is auto-generated)
result = api.create_repo("models", display_name="My Model", description="A fine-tuned model")

# Create a dataset (display_name required, name auto-generated; optional enums)
result = api.create_repo(
    "datasets",
    display_name="My Dataset",
    dataset_category=DatasetCategory.TEXT_CORPUS,
    format=DatasetFormat.PARQUET,
    split=DatasetSplit.TRAIN,
    tags=["nlp"],
)

# List versions
refs = api.list_repo_refs("models", org_id="acme", name=result.name)
for ref in refs:
    print(ref.id, ref.version_name)

# Browse files
files = api.list_repo_tree("models", org_id="acme", name=result.name, version=refs[0].version_name, recursive=True)
for f in files:
    print(f.type, f.path, f.size)

# Download (returns presigned URL; optional expires in seconds, max 3600)
info = api.file_download("models", org_id="acme", name=result.name, version=refs[0].version_name, path="pytorch_model.bin", expires=1800)
print(info.url, info.expires_in)

# Upload
api.upload_file("models", org_id="acme", name=result.name, file_path="./weights.bin")

# Upload a whole folder (filename = path relative to folder)
api.upload_folder("models", org_id="acme", name=result.name, local_dir="./artifacts")

Configuration

Environment Variable Description Default
MAAS_ENDPOINT MaaS service base URL http://localhost:8000/maas-service
MAAS_SDK_API_KEY SDK API key (required)

API Reference

EdiApi(endpoint=None, api_key=None)

Create a client. Reads MAAS_ENDPOINT and MAAS_SDK_API_KEY from environment if not provided.

Methods

Method Description
create_repo(repo_type, display_name, model_category?, dataset_category?, format?, split?, tags?) Create a model or dataset (name is auto-generated)
list_repos(repo_type, keyword?, page_no?, page_size?) List repos
list_repo_refs(repo_type, *, org_id, name) List versions
list_repo_tree(repo_type, *, org_id, name, version, path?, recursive?) Browse files
file_download(repo_type, *, org_id, name, version, path, expires?) Get presigned download URL (expires in seconds, max 3600)
upload_file(repo_type, *, org_id, name, file_path, relative_path?) Upload a file (optional explicit relative path)
upload_folder(repo_type, *, org_id, name, local_dir) Upload a whole folder (relative paths preserved)

Enums

create_repo accepts typed enums for category / format / split fields. The server validates these and rejects unknown values with HTTP 422.

Enum Values
ModelCategory llm, embedding, image, vision, audio, rerank, video
DatasetCategory text_corpus, instruction_tuning, image_caption, image_generation, lora_training, object_detection, image_classification, image_segmentation, other
DatasetFormat parquet, jsonl, csv, arrow, image_folder, text_folder, custom
DatasetSplit train, validation, test, train+validation, all, custom

License

MIT

Release files for edi-maas-sdk 0.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for edi-maas-sdk 0.1.2
File Size Uploaded
edi_maas_sdk-0.1.2.tar.gz 6.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for edi-maas-sdk 0.1.2
File Interpreter ABI Platform
edi_maas_sdk-0.1.2-py3-none-any.whl Python 3 none any Details

Total release size: 13.1 kB

Release files / edi_maas_sdk-0.1.2.tar.gz

Download URL edi_maas_sdk-0.1.2.tar.gz
Size 6.3 kB
Tags Source
SHA-256 checksum
How to use checksums
6554efddc685873a36672fab0768527a981259b79acaf5a6d4414e3d767a3879
BLAKE2b-256 checksum
How to use checksums
fe9dc7a3afedca223f39e86a37ac54a1e88c0d1d3e076525c65736999f9a35d8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.6.13

Release files / edi_maas_sdk-0.1.2-py3-none-any.whl

Download URL edi_maas_sdk-0.1.2-py3-none-any.whl
Size 6.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
712e158dd285ca3f829c5e0f4accc7cae2004984bf23826980eba48848df2e51
BLAKE2b-256 checksum
How to use checksums
673e76d701334055b6b74677b82e1a124cbcc84c14e86c4a1bf4c8e398801a71
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.6.13

Release history Release notifications | RSS feed

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

This release

0.1.2 This release

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page