> ## Documentation Index
> Fetch the complete documentation index at: https://docs.bitrune.org/llms.txt
> Use this file to discover all available pages before exploring further.

# BITRUNE Mining

> Stake LP-Rune tokens to earn BITRUNE rewards.

Bitrune offers a **liquidity mining** program where users stake their LP-Rune tokens into mining pools to earn **BITRUNE** rewards. Rewards are distributed per-block based on the proportion of staked shares.

## Overview

```
LP-Rune tokens → Stake into mining pool → Earn BITRUNE per block → Claim rewards
```

* **Stake**: Transfer LP-Rune tokens from your deposit address to the mining pool's stake address via MuSig2 cooperative signing.
* **Earn**: BITRUNE rewards accrue per-block, proportional to your share of total staked tokens.
* **Unstake**: Withdraw LP-Rune tokens back to your deposit address at any time (platform-signed, no MuSig2 needed).
* **Claim**: Collect accumulated BITRUNE rewards via MuSig2 cooperative signing.

## Staking

<Steps>
  <Step title="Ensure you have LP-Rune tokens">
    Provide liquidity to a pool that has an etched LP-Rune. Your LP shares will be represented as LP-Rune tokens held in your deposit address.
  </Step>

  <Step title="Prepare the stake">
    Specify the number of LP shares to stake and the mining pool (if multiple exist). The platform constructs a transaction that moves your LP-Rune UTXO to the mining pool's stake address and presents MuSig2 sighashes.
  </Step>

  <Step title="Sign and finalize">
    Sign the sighashes with your passkey (MuSig2 partial signatures) and submit. The platform aggregates signatures and broadcasts the staking transaction.
  </Step>
</Steps>

## Unstaking

Unstaking is **platform-signed** — no user signature is required. The LP-Rune tokens are transferred from the stake pool back to your deposit address.

<Steps>
  <Step title="Request unstake">
    Specify the number of shares to unstake.
  </Step>

  <Step title="Receive LP-Rune tokens">
    The platform signs and broadcasts the transaction. Your LP-Rune tokens are returned to your deposit address.
  </Step>
</Steps>

<Note>
  Unstaking also triggers a reward snapshot. Your accumulated pending reward is preserved and can be claimed separately.
</Note>

## Claiming Rewards

BITRUNE rewards are transferred from the reward pool to your deposit address via an on-chain Rune transfer.

<Steps>
  <Step title="Prepare the claim">
    The platform calculates your accumulated BITRUNE rewards and constructs a claim transaction. MuSig2 sighashes are returned for user signing.
  </Step>

  <Step title="Sign and finalize">
    Sign the sighashes with your passkey and submit. The platform aggregates and broadcasts the claim transaction.
  </Step>

  <Step title="Receive BITRUNE">
    BITRUNE tokens arrive at your deposit address as a Rune UTXO.
  </Step>
</Steps>

## Emission Schedule

BITRUNE mining follows a **5-phase progressive emission schedule**. The per-block reward increases across phases to incentivize long-term participation:

| Phase | BITRUNE per Block | Duration  |
| ----- | ----------------- | --------- |
| 1     | 50                | 365 days  |
| 2     | 100               | 365 days  |
| 3     | 200               | 365 days  |
| 4     | 300               | 365 days  |
| 5     | 400               | Until end |

Rewards accrue continuously as new Bitcoin blocks are mined. You can claim at any time — there is no vesting or lock-up period.

## Reward Calculation

Rewards are calculated per-block using a **reward-per-share** accumulator:

```
reward_per_share += bitrune_per_block / total_staked_shares
pending_reward = staked_shares * reward_per_share - reward_debt
```

* **bitrune\_per\_block**: The current phase's emission rate (see schedule above).
* **total\_staked\_shares**: Sum of all LP-Rune tokens staked in the pool.
* **reward\_debt**: Tracks the user's last-claimed position to prevent double-counting.
