diff --git a/AGENTS.md b/AGENTS.md index d8bd9ba..74cd184 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -1,4 +1,4 @@ - + # Agent Brief: Harb Stack ## What is KRAIKEN? diff --git a/formulas/AGENTS.md b/formulas/AGENTS.md index 8547fbd..67a135c 100644 --- a/formulas/AGENTS.md +++ b/formulas/AGENTS.md @@ -1,4 +1,4 @@ - + # Agent Brief: Formulas Formulas are TOML files that declare automated pipeline jobs for the harb evaluator. diff --git a/kraiken-lib/AGENTS.md b/kraiken-lib/AGENTS.md index 7206aae..6733b81 100644 --- a/kraiken-lib/AGENTS.md +++ b/kraiken-lib/AGENTS.md @@ -1,4 +1,4 @@ - + # Kraiken Library - Agent Guide Shared TypeScript helpers used by the landing app, txnBot, and other services to talk to KRAIKEN contracts and the Ponder GraphQL API. diff --git a/landing/AGENTS.md b/landing/AGENTS.md index affe88b..1b6b74a 100644 --- a/landing/AGENTS.md +++ b/landing/AGENTS.md @@ -1,4 +1,4 @@ - + # Landing Interface - Agent Guide Vue 3 + Vite application that delivers the public marketing site and forthcoming staking UI. @@ -14,6 +14,7 @@ Vue 3 + Vite application that delivers the public marketing site and forthcoming ## Key Views & Components - `HomeView.vue` - Launch countdown, feature overview, and staking CTA - `DocsView.vue` - Documentation portal with responsive navigation and generated table of contents +- `SecurityInfo.vue` - Displays unaudited badge (planned Q3 2026), KRAIKEN Token and Stake contract addresses with copy-to-clipboard, BaseScan and source links (#147) - Layout components (`KNavbar.vue`, `KFooter.vue`, `LeftRightComponent.vue`) manage shared chrome - UI components (`KButton.vue`, `Countdown.vue`, `SocialButton.vue`, icon set) supply reusable primitives diff --git a/onchain/AGENTS.md b/onchain/AGENTS.md index ce39d4b..a3ea7f1 100644 --- a/onchain/AGENTS.md +++ b/onchain/AGENTS.md @@ -1,4 +1,4 @@ - + # Agent Brief: Kraiken Protocol ## Protocol Philosophy & Business Logic @@ -43,7 +43,7 @@ The staking system traces a triangle in (staking%, avgTax) space: ## System Snapshot - Kraiken ERC20 with mint/burn via LiquidityManager. VERSION=2. - LiquidityManager.sol: ANCHOR + DISCOVERY + FLOOR positions with asymmetric slippage. -- VWAPTracker.sol: squared price in X96, compression, directional recording (price-fall / ETH-outflow events only — buy-only cycles must NOT update VWAP or the floor tracks the inflated price, crystallising IL; see issue #543). +- VWAPTracker.sol: squared price in X96, compression, directional recording (price-fall / ETH-outflow events only — buy-only cycles must NOT update VWAP or the floor tracks the inflated price, crystallising IL; see issue #543). Uses `_hasRecenterTick` boolean guard to decouple bootstrap detection from VWAP recording — prevents tick-0 ambiguity when `lastRecenterTick==0` after bootstrap (#609). - OptimizerV3.sol: UUPS upgradeable, direct 2D binary mapping. - Stake.sol: self-assessed tax, snatching auctions, discrete brackets, UBI redistribution. @@ -71,3 +71,6 @@ The staking system traces a triangle in (staking%, avgTax) space: - Outstanding supply excludes LM position balances and KRK held by `feeDestination` (only when `feeDestination != address(0) && feeDestination != address(this)`) and `stakingPool` (only when `stakingPoolAddr != address(0) && stakingPoolAddr != feeDestination`). - `recenterAccess` is removed — `recenter()` always enforces cooldown and TWAP stability. No bypass path exists. - `feeDestinationLocked` prevents CREATE2 bypass: once `feeDestination` is set to a contract address, it cannot be changed. `setFeeDestination` checks `.code.length > 0` to detect contract addresses. +- Optimizer input slots 0-7 all require `<= 1e18` — the overflow guard previously only applied to slot 0 (`percentageStaked`); slots 1-7 (including `averageTaxRate`) are now also validated (#997). +- Floor Ratchet attack (buy→stake→recenter oscillation) is defeated — evidence in `evidence/red-team/2026-03-22-floor-ratchet-oscillation.json` shows floor holds under 2000-trade oscillation (#1067). +- Fee-income delta_bps calculation is documented in `evidence/README.md`; `LmTotalEth.s.sol` now captures the auditable snapshot methodology (#1084). diff --git a/scripts/harb-evaluator/AGENTS.md b/scripts/harb-evaluator/AGENTS.md index 20f9d8b..2542f61 100644 --- a/scripts/harb-evaluator/AGENTS.md +++ b/scripts/harb-evaluator/AGENTS.md @@ -1,4 +1,4 @@ - + # Agent Brief: harb-evaluator The evaluator runtime executes formula-defined pipelines. Scripts in this diff --git a/services/ponder/AGENTS.md b/services/ponder/AGENTS.md index 16e5218..ff93fab 100644 --- a/services/ponder/AGENTS.md +++ b/services/ponder/AGENTS.md @@ -1,4 +1,4 @@ - + # Ponder Indexer - Agent Guide Ponder-based indexer that records Kraiken protocol activity and exposes the GraphQL API consumed by the app and automation bot. diff --git a/services/txnBot/AGENTS.md b/services/txnBot/AGENTS.md index 8d36219..5f835fc 100644 --- a/services/txnBot/AGENTS.md +++ b/services/txnBot/AGENTS.md @@ -1,4 +1,4 @@ - + # Transaction Bot - Agent Guide Automation service that maintains liquidity alignment and tax enforcement for the KRAIKEN protocol. diff --git a/web-app/AGENTS.md b/web-app/AGENTS.md index 5327649..9da207c 100644 --- a/web-app/AGENTS.md +++ b/web-app/AGENTS.md @@ -1,4 +1,4 @@ - + # Web App - Agent Guide Vue 3 + TypeScript staking interface for KRAIKEN, enabling users to stake tokens, manage positions, and interact with Harberger-tax mechanics.