lithium-cli
CLI miner and operations tool for Litium (LI) on the Bostrom blockchain.
Mines LI tokens by solving UniversalHash proof-of-work challenges and submitting proofs on-chain. Also provides commands for querying contract state, managing staking, referrals, and transfers.
Install
Or build from source:
# binary at target/release/lithium
Quick Start
# Create a wallet
# Check mining window status
# Start mining (uses all CPU cores, auto difficulty)
# Start mining with specific settings
Commands
Mining
lithium mine [OPTIONS]
Continuous mining loop: generates random challenges, solves them locally using the UniversalHash algorithm, and submits valid proofs to the litium-mine contract.
| Flag | Default | Description |
|---|---|---|
--mine-contract |
mainnet address | litium-mine contract |
-d, --difficulty |
0 (contract min) |
Leading zero bits |
-t, --threads |
all cores | CPU worker threads |
--batch-size |
4096 |
Hashes per batch |
--max-batches |
0 (unlimited) |
Max batches per challenge |
--max-proofs |
0 (unlimited) |
Stop after N proofs |
--referrer |
none | Referrer address (first proof only) |
--gas-limit |
2000000 |
Gas per proof TX |
Wallet
Queries
Transactions
Manual Proof Submission
Global Options
| Flag | Default | Description |
|---|---|---|
--rpc |
https://rpc.bostrom.cybernode.ai |
Tendermint RPC endpoint |
--lcd |
https://lcd.bostrom.cybernode.ai |
LCD/REST endpoint |
--chain-id |
bostrom |
Chain ID |
--fee |
0 |
Fee in uboot (Bostrom supports zero-fee) |
--wallet |
~/.uhash/wallet.json |
Wallet keystore path |
--json |
off | Machine-readable JSON output |
JSON Output
All commands support --json for scripting. Mining emits newline-delimited JSON events:
Architecture
Single binary crate with four modules:
main.rs-- CLI argument parsing and command dispatchrpc.rs-- Bostrom LCD client (queries, TX signing, broadcast)contract_types.rs-- Serde types for all modular litium contractsdeployments.rs-- Mainnet contract addresses from embedded TOML
Queries and transactions are routed to the correct modular contract automatically:
| Contract | CLI Commands |
|---|---|
| litium-core | burn-stats, transfer |
| litium-mine | status, stats, emission, mine, send |
| litium-stake | stake-info, claim-staking, claim-unbonding |
| litium-refer | referral, claim-referral |
Mining uses uhash-prover for the UniversalHash CPU solver and uhash-cli for wallet management.
Contracts
| Contract | Role |
|---|---|
| litium-core | CW-20 token, transfer burn accounting |
| litium-mine | Proof verification, reward calculation, difficulty adjustment, emission |
| litium-stake | LI staking, unbonding, reward distribution |
| litium-refer | Referral tracking and rewards |
| litium-wrap | CW-20 to native TokenFactory bridge |
Mainnet addresses are embedded in deployments/bostrom-mainnet.toml and used as CLI defaults.
License
Apache-2.0