Metadata-Version: 2.4
Name: lisa-artifacts
Version: 0.3.0
Summary: A library for managing object storage artifacts
License-Expression: Apache-2.0
Project-URL: Homepage, https://github.com/lisa-sgs/artifacts
Project-URL: Source, https://github.com/lisa-sgs/artifacts
Project-URL: Issues, https://github.com/lisa-sgs/artifacts/issues
Project-URL: Documentation, https://lisa-sgs.github.io/artifacts/
Project-URL: Changelog, https://github.com/lisa-sgs/artifacts/blob/main/CHANGELOG.md
Requires-Python: >=3.11
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: boto3
Requires-Dist: pydantic
Requires-Dist: types-boto3[s3]
Dynamic: license-file

# LISA Artifacts

[![PyPI](https://img.shields.io/pypi/v/lisa-artifacts)](https://pypi.org/project/lisa-artifacts/)
[![CI](https://github.com/lisa-sgs/artifacts/actions/workflows/ci.yml/badge.svg)](https://github.com/lisa-sgs/artifacts/actions/workflows/ci.yml)
[![License](https://img.shields.io/github/license/lisa-sgs/artifacts)](https://github.com/lisa-sgs/artifacts/blob/main/LICENSE)
[![Docs](https://img.shields.io/badge/docs-latest-blue)](https://lisa-sgs.github.io/artifacts/)

A Python library for uploading and downloading artifacts to/from object storages using manifests.

## Installation

Install using uv:

```bash
uv add lisa-artifacts
```

## Quick Start

Set environment variables:

```bash
export ARTIFACTS_BUCKET=my-bucket
export ARTIFACTS_REMOTE_PREFIX=artifacts/ # optional
export ARTIFACTS_LOCAL_PREFIX=./local/ # optional
```

Create and use a manifest:

```python
from lisa.artifacts import Artifact, Manifest

artifacts = [
    Artifact(name="model.pkl", path="models/model.pkl"),
    Artifact(name="data.csv", path="data/data.csv"),
]

manifest = Manifest.from_env(artifacts)
manifest.get()  # Download artifacts
manifest.store()  # Upload artifacts
```
