disconnected
docs/protocol/self-deprecation

Self-Deprecation and Reactivation

NAKA implements a sustainable deflation cycle, not a one-way shutoff. The hook contract uses a single boolean state flag, selfDeprecated, that flips between two values based on circulating supply. When circulating crosses the upper threshold via buys, minting pauses; when sells push circulating back under the lower threshold, minting auto-resumes. The flag has no admin override, no governance vote, no off-chain trigger — it is read-only state derived from on-chain balances.

Triggers

Both triggers operate on circulating supply, defined as NAKA.totalSupply() − NAKA.balanceOf(0x...dEaD). This is the supply that participates in the curve, with permanently-burned tokens excluded.

DirectionThresholdConstantSource eventWhen it fires
Pausecirculating ≥ 99% × KSELF_DEPRECATE_PCT = 99SelfDeprecated(finalSupply)Inside _commitBuy, after a buy that pushes circulating across the line
Resumecirculating < 95% × KREACTIVATE_PCT = 95Reactivated(circulatingAtReactivation, deadBalance)Inside _executeSell, only when the flag was already set, after the sell has settled

K = 21,000,000. So the upper trigger fires at 20,790,000 circulating and the lower at 19,950,000 circulating. The 4-percentage-point gap is the deprecation cycle band.

Effects of selfDeprecated == true

While the flag is set:

  • buyNaka reverts with SelfDeprecatedNoBuys(). New issuance is paused.
  • Sells continue normally. Token holders can redeem through the curve at the prevailing rate. Reserves keep paying out.
  • Burn-on-fee continues. The 0.30% fee on every sell still goes to 0xdEaD. Cumulative DEAD balance keeps growing.
  • The 1-block anti-flip cooldown still applies to sells from accounts that recently bought (this is per-EOA via tx.origin).

Reactivation Mechanics

Sells reduce circulating by exactly tokensIn per trade — the redeemed portion is burned outright, the fee portion is moved to DEAD. After the sell has settled and totalMintedFair has been decremented, the hook checks circulating again. If it has fallen below 95% × K, the flag is cleared and Reactivated is emitted in the same transaction.

The next buy after reactivation works normally and reads the curve at the new (lower) totalMintedFair. There is no cooldown between deprecation and reactivation, no minimum dwell time, and no on-chain confirmation required beyond the sell that crosses the threshold.

Why a Cycle Instead of a One-Way Halt

A pure one-way deprecation creates two failure modes:

  1. Death spiral. A panic sell after deprecation pushes price toward the floor. With no buy demand allowed, the curve has no symmetric mechanism to absorb pressure.
  2. Stuck reserves. Even if circulating later collapses to near zero, the curve can't accept new ETH. Late entrants lose access to the deflation primitive.

The reactivation cycle eliminates both. Whenever sells outpace the deprecation pressure, buys are auto-enabled at the lower circulating level, restoring two-sided liquidity. As DEAD accumulates over time (every swap contributes 0.30%), the absolute number of tokens that can re-enter circulation before deprecation re-fires shrinks. The system asymptotically grinds itself toward higher floor coverage without ever blocking access to the curve.

Burn Headroom

A useful intuition: the difference between 99% × K and current circulating is the headroom — how many tokens can still be minted before the next deprecation. Because burns shrink circulating but not K, headroom regenerates over time independent of buys, just from the fee component of each trade.

After many cycles, total supply can vastly exceed K, but circulating can never cross 99% × K for long. The protocol's effective ceiling on simultaneously-circulating supply is roughly 0.99 × K. The total over the lifetime is unbounded, all of the excess being permanently locked.

Detection

Frontends should treat the boolean selfDeprecated() view function as the source of truth for "is the buy path open right now?". The status pip in the header at naka.exchange flips between active and deprecated based on this read. Indexers should listen for both SelfDeprecated and Reactivated events to reconstruct the cycle history.

What Self-Deprecation Is Not

  • It is not a sunset. The protocol keeps running indefinitely. Sells, transfers, integrations, and reactivation all continue.
  • It is not a governance event. No proposal, no vote, no operator action. The triggers are pure on-chain math checks against circulating supply.
  • It is not irreversible. The flag flips both directions automatically based on supply. The deflation it produces (DEAD accumulation) is irreversible, but the buy path is not.