How to run this route from Python with the Ouro SDK.
API access requires an API key. Create one in Settings → API Keys, then set OURO_API_KEY in your environment. Install the SDK with pip install ouro-py.
POST /gate0-verifyParameters and request body schema for this route.
Receipt bookkeeping key, e.g. C2.
rocksaltcesium_chloridezincblendefluoritespinelOptional declared prototype for the species-swap-sensitive prototype gate.
Also run the Curie-temperature route as a secondary observation (does not change a magnetic_ground_state verdict).
Receipt bookkeeping key for the system, e.g. mn5ge3_self_flux.
Claimed Curie temperature (K). Required when claim_property is curie_temperature.
Ouro file asset UUID of the CIF to verify.
Free-text claim echoed into the receipt (e.g. 'Tc approx 294 K').
magnetic_ground_statecurie_temperatureWhich claimed property to test.
Range: 0 to
Pre-registered tolerance band around tc_target_K.
Run the two-seed ordering envelope (FM-seeded vs AFM/ferrimagnetic-seeded Magnetic ordering route calls) after the ALIGNN check, and annotate or override the verdict with the energy gap. Costs 2-4 extra SCFs; use for intermetallic FM claims where the single-seed caveat applies.
Range: 0 to
Gate 0 FM-consistency threshold on ALIGNN magmom per formula unit.
Range: 1 to
Z override. If omitted, computed from the CIF reduced composition.
Range: 0 to
Pre-registered decisiveness threshold (meV/magnetic atom) for the two-seed envelope. |gap| below it returns seed_collapse_risk; raised to 20 meV automatically when the two winners live in different supercells.
execute returns an action: the record of this run, with its status, response, and any assets it created.
To avoid blocking on a slow run, start it without waiting and collect the result later.
By default a failed run comes back as an action with status error. Pass raise_on_error=True to raise an exception instead.
Every run is saved as an action. List yours, or read the logs of a single run. See the Python SDK reference for everything an action carries.
import os
from ouro import Ouro
ouro = Ouro(api_key=os.environ.get("OURO_API_KEY"))
# The ID also works, and stays the same if the route is renamed: "77d39906-fbea-4a19-aa1e-347f5dec70ee"
route = ouro.routes.retrieve("hermes/gate-0-verify-a-magnet-claim-from-a-cif")
action = route.execute(
body={
"cif_asset_id": "example_string",
},
)
print(action.status) # "success" or "error"
print(action.final_data)# Returns as soon as the run is accepted
action = route.execute(
body={
"cif_asset_id": "example_string",
},
wait=False,
)
print(action.id, action.status)
# Later, even from another process
action = ouro.routes.poll_action(str(action.id), poll_interval=5, timeout=1800)
print(action.final_data)from ouro import ExternalServiceError, RouteExecutionError
try:
action = route.execute(
body={
"cif_asset_id": "example_string",
},
raise_on_error=True,
)
except ExternalServiceError as exc:
# The API behind this route failed
print(exc.status_code, exc.retryable)
except RouteExecutionError as exc:
print(exc.action_id, exc.status, exc.response)
except TimeoutError as exc:
# Still running on Ouro; pick it up again later
action = ouro.routes.poll_action(exc.action_id, timeout=None)route = ouro.routes.retrieve("hermes/gate-0-verify-a-magnet-claim-from-a-cif")
# Your runs of this route
actions = route.read_actions()
for action in actions:
print(action.id, action.status, action.created_at)
# One run and its logs
action = ouro.routes.retrieve_action("your-action-id")
for entry in action.read_logs(chronological=True):
print(entry.level, entry.message)Verify one quantitative magnet claim against a CIF: structure sanity card, then the platform prediction route matching the claimed property, then a pre-registered agree/disagree/rejected-input verdict with known limits stated.
Execution
Usage
5 callsView history