Skip to main content

IO adapter registry and format backends for the Jarvis ecosystem

Project description

Jarvis-Portal

Jarvis-Portal is the standalone IO adapter and registry package for the Jarvis ecosystem.

It provides format-specific read/write behavior for scientific file formats used by Jarvis-HEP and related tools, including JSON, plain files, SLHA, xSLHA, and future HEP calculator formats.

Jarvis-Portal is intended to serve YAML-driven Jarvis workflows through Jarvis-HEP. It does not own Jarvis-HEP YAML parsing or runtime workflow semantics.

Scope

Jarvis-Portal owns:

  • format adapter registration and lookup
  • JSON nested entry reads/writes
  • plain file adapter helpers
  • optional SLHA/xSLHA record handling
  • future adapters for ROOT, HepMC, LHE, YODA, SPheno, MadGraph cards, and related HEP formats

Jarvis-HEP owns:

  • YAML IO block parsing
  • runtime path markers such as &J, @PackID, @SampleID, and @Sdir
  • expression evaluation
  • sample/runtime context
  • save/copy/archive policy
  • logger and IO manager integration
  • deciding which variables are written or read

Quick Install

pip install Jarvis-HEP-Portal

Optional format extras:

pip install "Jarvis-HEP-Portal[slha]"
pip install "Jarvis-HEP-Portal[xslha]"
pip install "Jarvis-HEP-Portal[all]"

Development

python -m pip install -e ".[dev,all]"
python -m pytest
ruff check .
python -m build

Basic Usage

CLI:

jportal input.yaml
jportal input.yaml --json
jportal --formats
jportal --version

By default, jportal input.yaml parses the YAML file and prints the resulting Python dictionary to the terminal. It does not execute Jarvis-HEP workflow semantics.

Python:

from jarvis_portal import IOContext, create_default_registry

registry = create_default_registry()
adapter = registry.get("JSON", "input")

context = IOContext()
await adapter.write_input(
    context,
    {
        "name": "params",
        "path": "input.json",
        "type": "JSON",
        "actions": [
            {
                "type": "Dump",
                "variables": [
                    {"name": "x"},
                    {"name": "nested", "entry": "config.value", "value": 2.0},
                ],
            },
        ],
    },
    {"x": 1.0},
)

Documentation

Status

This package is in alpha development. Runtime behavior should stay small and adapter-focused so Jarvis-HEP can remain the owner of workflow semantics.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

jarvis_hep_portal-1.0.0.tar.gz (31.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

jarvis_hep_portal-1.0.0-py3-none-any.whl (13.5 kB view details)

Uploaded Python 3

File details

Details for the file jarvis_hep_portal-1.0.0.tar.gz.

File metadata

  • Download URL: jarvis_hep_portal-1.0.0.tar.gz
  • Upload date:
  • Size: 31.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.13

File hashes

Hashes for jarvis_hep_portal-1.0.0.tar.gz
Algorithm Hash digest
SHA256 d7009c402b5b85d7c716a1839b874a6ef71a915589bc9fe6bfbbbea2f8ffece3
MD5 3a817041c3988ac714e3c6fea773f8a0
BLAKE2b-256 571ff25ffd771ffccd14204942cafdf429d5333e7fdfb38d3b8dd511861999c3

See more details on using hashes here.

File details

Details for the file jarvis_hep_portal-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for jarvis_hep_portal-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ae51a4a3702fa500eb783f42ad9bb0aa441d3b6df242fd9b758689ea64b7b6a7
MD5 efe5302799b9ea817c572ce14b38285e
BLAKE2b-256 e4a55eb48600a8257b8516b73f3495b54969a1a3f3c214a1d063b7b9eb570ebb

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page