Docs: align fee tier examples (deployment guide vs architecture) #198

Closed
opened 2026-05-26 08:00:03 +00:00 by PlasticDigits · 7 comments
PlasticDigits commented 2026-05-26 08:00:03 +00:00 (Migrated from gitlab.com)

Problem statement

Fee discount tier examples contradict across docs/deployment-guide.md and docs/architecture.md (discount bps, min token thresholds). Operators can misconfigure production tiers.

Evidence / context

Proposed solution

Single source of truth; fix all contradictory examples; cross-link from deployment guide.

Acceptance criteria

  • One canonical tier table; deployment guide examples match architecture.
  • No numeric conflicts in docs tree (grep / review).

Priority

P2

## Problem statement Fee discount tier examples **contradict** across [`docs/deployment-guide.md`](docs/deployment-guide.md) and [`docs/architecture.md`](docs/architecture.md) (discount bps, min token thresholds). Operators can misconfigure production tiers. ## Evidence / context - Backlog **#68** / DEX-P2-013; reference table [`docs/reference/fee-discount-tiers.md`](docs/reference/fee-discount-tiers.md) if present. ## Proposed solution Single source of truth; fix all contradictory examples; cross-link from deployment guide. ## Acceptance criteria - [ ] One canonical tier table; deployment guide examples match architecture. - [ ] No numeric conflicts in docs tree (grep / review). ## Priority **P2**
PlasticDigits commented 2026-05-26 10:04:43 +00:00 (Migrated from gitlab.com)

fee-discount-tiers.md is authoritative

fee-discount-tiers.md is authoritative
PlasticDigits commented 2026-05-26 10:06:58 +00:00 (Migrated from gitlab.com)

mentioned in commit de4b0fec7b

mentioned in commit de4b0fec7b714dd2c2eaebcec06a248e91a22001
PlasticDigits commented 2026-05-26 10:07:12 +00:00 (Migrated from gitlab.com)

Resolution (merged to main — de4b0fe)

Aligned fee-discount tier documentation so operators have a single canonical source and automated drift detection.

What changed

Verification checklist

  • make check-fee-discount-tier-docs passes locally
  • docs/deployment-guide.md §5a links to reference doc only (no numeric tier table in guide)
  • docs/architecture.md Discount Tiers section links to reference doc only
  • docs/contracts-terraclassic.md Fee Discount section has no duplicate tier table
  • rg min_tokens docs/ only hits intentional “not min_tokens” warnings
  • Localnet deploy still adds 11 tiers (scripts/deploy-dex-local.sh) matching reference table
  • CI job Fee discount tier docs drift green on main

/cc @brouie — please verify the checklist above and confirm we can close #198 when satisfied. Leaving issue open per deploy workflow.

## Resolution (merged to `main` — `de4b0fe`) Aligned fee-discount tier documentation so operators have a single canonical source and automated drift detection. ### What changed - **Canonical table only:** [`docs/reference/fee-discount-tiers.md`](docs/reference/fee-discount-tiers.md) — expanded invariants (I1–I7), cross-links, GitLab #198 reference. - **Removed duplicate tier table** from [`docs/contracts-terraclassic.md`](docs/contracts-terraclassic.md); fixed `ExecuteMsg` field names (`min_cl8y_balance`, `governance_only`). - **Cross-linked** [`docs/deployment-guide.md`](docs/deployment-guide.md) §5a and [`docs/architecture.md`](docs/architecture.md) (no inline conflicting numbers). - **Fixed** [`docs/security-model.md`](docs/security-model.md) (`min_cl8y_balance` vs deprecated `min_tokens`). - **Drift guard:** `scripts/check_fee_discount_tier_docs.py` + `make check-fee-discount-tier-docs` (canonical MD ↔ `tier_fixtures.rs` ↔ `deploy-dex-local.sh`). - **CI:** `docs-fee-discount-tiers` job in [`.github/workflows/test.yml`](.github/workflows/test.yml). - **Agent playbook:** [`skills/AGENTS_FEE_DISCOUNT_TIERS.md`](skills/AGENTS_FEE_DISCOUNT_TIERS.md) for third-party agents. ### Verification checklist - [ ] `make check-fee-discount-tier-docs` passes locally - [ ] `docs/deployment-guide.md` §5a links to reference doc only (no numeric tier table in guide) - [ ] `docs/architecture.md` Discount Tiers section links to reference doc only - [ ] `docs/contracts-terraclassic.md` Fee Discount section has no duplicate tier table - [ ] `rg min_tokens docs/` only hits intentional “not min_tokens” warnings - [ ] Localnet deploy still adds 11 tiers (`scripts/deploy-dex-local.sh`) matching reference table - [ ] CI job **Fee discount tier docs drift** green on `main` /cc @brouie — please verify the checklist above and confirm we can close #198 when satisfied. Leaving issue **open** per deploy workflow.
PlasticDigits (Migrated from gitlab.com) closed this issue 2026-05-27 07:06:07 +00:00
PlasticDigits commented 2026-05-27 07:06:12 +00:00 (Migrated from gitlab.com)

Verification complete (agent)

Re-verified GitLab #198 on main @ 049a979 using worktree fix/issue-198-verify.

Checklist

  • make check-fee-discount-tier-docs — OK (11 tiers aligned)
  • docs/deployment-guide.md §5a — links to docs/reference/fee-discount-tiers.md only (no inline tier table)
  • docs/architecture.md Discount Tiers — links to reference doc only
  • docs/contracts-terraclassic.md — no duplicate tier table
  • rg min_tokens docs/ — only intentional “not min_tokens” warnings
  • Localnet GetTiers — 11 tiers on-chain match canonical table (deploy-dex-local.sh payloads)
  • CI Fee discount tier docs drift — success on latest main run (26495493656)
  • Browser visual: /tiers shows tiers 1–9 with expected discounts (2.5% … 95%) from live LCD

Infra used

LocalTerra healthy, host Postgres :5432, indexer :3001, frontend :5174, bot swarm active.

No doc drift or numeric conflicts found; closing as verified.

## Verification complete (agent) Re-verified GitLab #198 on `main` @ `049a979` using worktree `fix/issue-198-verify`. ### Checklist - [x] `make check-fee-discount-tier-docs` — OK (11 tiers aligned) - [x] `docs/deployment-guide.md` §5a — links to `docs/reference/fee-discount-tiers.md` only (no inline tier table) - [x] `docs/architecture.md` Discount Tiers — links to reference doc only - [x] `docs/contracts-terraclassic.md` — no duplicate tier table - [x] `rg min_tokens docs/` — only intentional “not `min_tokens`” warnings - [x] Localnet `GetTiers` — 11 tiers on-chain match canonical table (`deploy-dex-local.sh` payloads) - [x] CI **Fee discount tier docs drift** — success on latest `main` run (26495493656) - [x] Browser visual: `/tiers` shows tiers 1–9 with expected discounts (2.5% … 95%) from live LCD ### Infra used LocalTerra healthy, host Postgres :5432, indexer :3001, frontend :5174, bot swarm active. No doc drift or numeric conflicts found; closing as verified.
PlasticDigits commented 2026-07-12 07:14:19 +00:00 (Migrated from gitlab.com)

mentioned in issue #476

mentioned in issue #476
PlasticDigits commented 2026-07-12 07:14:42 +00:00 (Migrated from gitlab.com)

mentioned in issue #477

mentioned in issue #477
PlasticDigits commented 2026-08-26 01:06:40 +00:00 (Migrated from gitlab.com)

mentioned in issue #651

mentioned in issue #651
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
code/cl8y-dex-terraclassic#198
No description provided.