EOSVC (Ersilia Version Control) is a Python-based tool designed to unify code versioning with data and result management by combining Git and S3 workflows around the main branch.
Project description
EOSVC (Ersilia Version Control)
EOSVC is a small CLI for syncing large artifacts to S3, while your code remains in Git.
EOSVC supports two repo types (detected from access.json):
- Standard repos: manage
data/andoutput/ - Model repos: manage
model/checkpoints/andmodel/fit/
EOSVC does not manage Git operations anymore (no clone/pull/push). Use git directly for code workflows.
What EOSVC stores where
EOSVC syncs artifacts under an S3 prefix equal to the repo name.
By default, the repo name is the local folder name (repo directory basename).
If your folder name differs from the remote repo/S3 prefix, set:
export EVC_REPO_NAME="my-actual-repo-name"
Standard repos
Managed roots:
data/output/
S3 mapping for repo ersilia-repo:
s3://<bucket>/ersilia-repo/data/...s3://<bucket>/ersilia-repo/output/...
Model repos
Managed roots:
model/checkpoints/model/fit/
Accepted path aliases for convenience:
checkpoints/...→model/checkpoints/...fit/...→model/fit/...
S3 mapping for repo my-model-repo:
s3://<bucket>/my-model-repo/model/checkpoints/...s3://<bucket>/my-model-repo/model/fit/...
In model repos, EOSVC refuses operations on data/ and output/.
Buckets and access
Buckets:
- Public bucket:
eosvc-public - Private bucket:
eosvc-private
Rules:
- Read from
eosvc-publicmay work without AWS credentials (unsigned S3 client). - Read from
eosvc-privaterequires AWS credentials. - Any upload requires AWS credentials, regardless of bucket.
Note: For unauthenticated reads to work, the
eosvc-publicbucket policy must allows3:GetObject. For unauthenticatedviewto work, it must also allows3:ListBucketconstrained to the relevant prefixes.
Installation
pip install -e .
eosvc --help
Credentials
EOSVC resolves credentials in this order:
-
Standard AWS resolution (environment variables and/or
~/.aws/*if present) -
.envfiles (loaded withpython-dotenv) from:~/.eosvc/.env<repo>/.env./.env
Option A: environment variables (standard AWS)
export AWS_ACCESS_KEY_ID="..."
export AWS_SECRET_ACCESS_KEY="..."
export AWS_SESSION_TOKEN="..." # optional
export AWS_REGION="eu-central-2" # optional
Option B: EOSVC config (writes ~/.eosvc/.env)
EOSVC provides a config command to store credentials in:
~/.eosvc/.env(permissions set to600when possible)
eosvc config \
--access-key-id "..." \
--secret-access-key "..." \
--session-token "..." \
--region "eu-central-2"
This is similar in spirit to aws configure, but EOSVC writes a .env file and loads it alongside other sources.
Option C: local .env files
Create .env in the repo (or current directory):
AWS_ACCESS_KEY_ID="..."
AWS_SECRET_ACCESS_KEY="..."
AWS_SESSION_TOKEN="..." # optional
AWS_REGION="eu-central-2" # optional
access.json (required)
EOSVC requires an access.json at the repo root.
EOSVC identifies the repo root by searching upward for access.json starting from the current directory.
Standard repo access.json
{
"data": "public",
"output": "private"
}
Model repo access.json
{
"checkpoints": "public",
"fit": "public"
}
Valid values are: "public" or "private".
Commands
config
Write AWS credentials to ~/.eosvc/.env:
eosvc config --access-key-id "..." --secret-access-key "..."
Optional flags:
eosvc config \
--access-key-id "..." \
--secret-access-key "..." \
--session-token "..." \
--region "eu-central-2" \
--default-region "eu-central-2"
view (S3 tree)
View the artifact layout in S3:
eosvc view
eosvc view --path data
eosvc view --path output
eosvc view --path model/checkpoints
eosvc view --path checkpoints
eosvc view --path fit
download
Download a file or folder from S3 into your repo:
eosvc download --path data/processed/file.csv
eosvc download --path output/
eosvc download --path model/checkpoints/
eosvc download --path checkpoints/
eosvc download --path fit/
upload
Upload a file or folder to S3 (requires credentials):
eosvc upload --path output/some_folder
eosvc upload --path data/test
eosvc upload --path model/checkpoints/test-run
eosvc upload --path checkpoints/test-run
eosvc upload --path fit/test-fit
Quick Test
From the project root:
cd tests
chmod +x test.sh
./test.sh
The test script:
- uses
git cloneto obtain test repos - runs
view,upload, anddownloadfor both model and standard repos
Access lock (no public/private migration)
EOSVC creates a local lock file:
.eosvc/access.lock.json
If you later change access.json (e.g., public → private), EOSVC will refuse to run.
To override (not recommended), delete the lock file manually:
rm .eosvc/access.lock.json
Common troubleshooting
“AccessDenied” when reading eosvc-public without creds
Your bucket policy probably does not allow anonymous access for the prefixes EOSVC uses.
If you want unauthenticated download to work:
- allow
s3:GetObjectonarn:aws:s3:::eosvc-public/*
If you want unauthenticated view to work:
- also allow
s3:ListBucketonarn:aws:s3:::eosvc-public - restrict with
s3:prefixconditions for your repo prefixes
“AWS credentials are missing or invalid”
Provide credentials via:
- env vars, or
eosvc config(writes~/.eosvc/.env), or- a
.envfile in the repo/current directory
About the Ersilia Open Source Initiative
The Ersilia Open Source Initiative is a tech-nonprofit organization fueling sustainable research in the Global South. Ersilia's main asset is the Ersilia Model Hub, an open-source repository of AI/ML models for antimicrobial drug discovery.
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
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 eosvc-0.1.3.tar.gz.
File metadata
- Download URL: eosvc-0.1.3.tar.gz
- Upload date:
- Size: 49.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.3.1 CPython/3.12.3 Linux/6.11.0-1018-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
04b705837f489b91d07113b836701607603358ca792c6750a3e6280b3859f3a4
|
|
| MD5 |
a780ad889ae496f0c9d1a5add495e718
|
|
| BLAKE2b-256 |
3f95e6f72b0e3d23883fdef696ada1ae4758a7225b0784717ff0d312768ef245
|
File details
Details for the file eosvc-0.1.3-py3-none-any.whl.
File metadata
- Download URL: eosvc-0.1.3-py3-none-any.whl
- Upload date:
- Size: 35.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.3.1 CPython/3.12.3 Linux/6.11.0-1018-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1e6a1fe8f103c9e63c26a61021ef9d6602157509115a0508b6ba8347205a6dbb
|
|
| MD5 |
3e7b882db3ea8241c6d811b7bc4ff04a
|
|
| BLAKE2b-256 |
a718099366ebd6938b5087d4a13a145ac7e5321b2b725ebb2b2ce7108fab9890
|