|
Download contracts/README.md from PYTHAI/mindXtrain: direct link, hf CLI and curl.
- Browser
- Download file 1.17 kB
-
https://huggingface.co/PYTHAI/mindXtrain/resolve/main/contracts/README.md
- Command line
-
hf download hf://PYTHAI/mindXtrain/contracts/README.md
-
curl -L -o README.md https://huggingface.co/PYTHAI/mindXtrain/resolve/main/contracts/README.md
1.17 kB
| # mindXtrain on-chain contracts | |
| Foundry workspace for the immutable, no-admin, no-proxy contracts that anchor | |
| mindXtrain run receipts and receive x402 settlement proofs. | |
| ## Contracts | |
| - `src/mindxtrain_registry.sol` — write-once anchoring of `(yamlHash, datasetCidHash, checkpointCidHash, evalReportHash)` per `runId`. | |
| - `src/x402_receiver.sol` — records x402 settlement proofs from a fixed facilitator address. | |
| Both follow the cypherpunk2048 standard: no upgradeable proxies, no `Ownable`, no admin keys, no pause function, no setters. Rotating any parameter requires a fresh deployment. | |
| ## Day-2 setup (on the MI300X droplet, where Foundry installs alongside the training stack) | |
| ```bash | |
| curl -L https://foundry.paradigm.xyz | bash && foundryup | |
| cd contracts | |
| forge install foundry-rs/forge-std --no-git | |
| forge build | |
| forge test --gas-report | |
| ``` | |
| ## Deploy | |
| ```bash | |
| export DEPLOYER_PRIVATE_KEY=0x... | |
| export X402_FACILITATOR=0x... # parsec-wallet or Coinbase facilitator | |
| export BASE_SEPOLIA_RPC_URL=https://sepolia.base.org | |
| forge script script/Deploy.s.sol --rpc-url base_sepolia --broadcast --verify | |
| ``` | |
| Day-3 deploy moves to `--rpc-url base` (mainnet). | |