Expand description
§tribewarez-pot-o
Proof of Tensor Optimizations (PoT-O) on-chain program for Solana.
This crate implements the PoT-O blockchain validation system, which combines proof-of-work concepts with tensor network analysis to optimize mining rewards. It manages miner accounts, validates cryptographic proofs submitted by off-chain validators, and distributes rewards with optional tensor-aware enhancements.
§Core Features
- Proof Validation: Validates mining proofs submitted by the off-chain PoT-O validator
- Miner Management: Creates and maintains miner accounts with proof history tracking
- Reward Distribution: Distributes mining rewards with support for tensor-weighted bonuses
- Difficulty Adjustment: Automatically adjusts mining difficulty based on network conditions
- Tensor Network Support: v0.2.0 feature for enhanced reward calculations using tensor metrics
§Key Instructions
initialize: Set up the PoT-O configuration (admin-only)register_miner: Register a new miner accountsubmit_proof: Submit a mining proof for validation and reward distributionupdate_pool_config: Update configuration parameters (admin-only)create_tensor_pool: Create a tensor network pool for enhanced rewards (admin-only)
§Events
This program emits events for proof submissions, reward distributions, and configuration changes.
See the events module for detailed event documentation.
§Services
The services module provides trait implementations for proof validation and reward distribution,
supporting both legacy (v0.1.x) and tensor-aware (v0.2.0) configurations.
Modules§
- accounts
- An Anchor generated module, providing a set of structs
mirroring the structs deriving
Accounts, where each field is aPubkey. This is useful for specifying accounts for a client. - events
- instruction
- An Anchor generated module containing the program’s set of
instructions, where each method handler in the
#[program]mod is associated with a struct defining the input arguments to the method. These should be used directly, when one wants to serialize Anchor instruction data, for example, when speciying instructions on a client. - program
- Module representing the program.
- services
- tribewarez_
pot_ o - PoT-O: Proof of Tensor Optimizations on-chain program. Validates mining proofs submitted by the off-chain PoT-O validator, manages miner accounts, distributes rewards, and adjusts difficulty.
Structs§
- Adjust
Difficulty - Adjust
Difficulty Bumps - Claim
Rewards - Claim
Rewards Bumps - Init
Params - Parameters for initializing the PoT-O configuration.
These values are set once during program initialization and can be updated via
update_pool_config. - Initialize
- Initialize
Bumps - Miner
Account - Per-miner account storing mining history and statistics. Created when a miner first registers. Updated each time a proof is submitted.
- PotO
Config - Global PoT-O configuration account. Stores network-wide settings for proof validation, reward distribution, and tensor network parameters. This is a singleton account (one per program) created by the admin during initialization.
- Proof
Params - Parameters for submitting and validating mining proofs. Contains cryptographic commitments and validation data for the proof.
- Proof
Record - Proof record account storing details of a submitted mining proof. Created each time a miner submits a valid proof.
- Register
Miner - Register
Miner Bumps - Request
Swap - Request
Swap Bumps - Submit
Proof - Submit
Proof Bumps - Update
Pool Config - Update
Pool Config Bumps
Enums§
Statics§
- ID
- The static program ID
Functions§
- check_
id - Confirms that a given pubkey is equivalent to the program ID
- entry
- The Anchor codegen exposes a programming model where a user defines
a set of methods inside of a
#[program]module in a way similar to writing RPC request handlers. The macro then generates a bunch of code wrapping these user defined methods into something that can be executed on Solana. - entrypoint⚠
- Safety
- id
- Returns the program ID