Storage Configuration¶
Job store¶
The job store backend is selected automatically based on DATABASE_URL.
SQLite (default)
Used when DATABASE_URL is not set. Stored at app/instance/jobs.db. Created automatically on first run.
Postgres
Schema is created automatically on first startup. Uses asyncpg connection pool (min 1, max 10).
Warning
If DATABASE_URL is set but Postgres is unreachable at startup, the engine logs an error and falls back to SQLite. This is not safe in production.
Artifact storage¶
Artifacts are loaded by build_pipeline() functions using a loader.
Local (default)
from app.domain.loading.local_loader import LocalModelLoader
loader = LocalModelLoader(root="model_artifacts")
path = loader.load("my_model", "v1")
# → Path("model_artifacts/my_model/v1/")
S3
from app.domain.loading.s3_loader import S3ModelLoader
loader = S3ModelLoader(bucket="my-bucket", prefix="models")
path = loader.load("my_model", "v1")
# downloads s3://my-bucket/models/my_model/v1/* → local temp dir
Requires: pip install boto3

