chore: checkpoint working tree — shell Tier-B retirement + accumulated WIP
Snapshot of accumulated work-in-progress on top of the baseline commit. This session — retire Tier B from the wallet shell (single-tier model, glossary "Tiers & trust"): - SendFlow.tsx: BCH-only; removed the non-functional Tier-B send path, the D-4/D-5 raw-BCH co-display, and the ADR-0013 friction ladder. - ArtemisionScreen.tsx: Create wizard collapsed to a single 5-step on-chain genesis flow; tier-selection step + Tier-B branch (prepareTierBImport) deleted. - QuickActions.tsx / SettingsScreen.tsx: receive note reworded; "Send friction thresholds" + "Tier explainer" rows removed; registry-trust note reworded. - Verified: tsc clean, vitest 74/74, full preview walkthrough, no console errors. Pre-existing uncommitted work also folded in: - USDm -> FIATm family rename/reorg (Parameters/FIATm/, design records) - ~130 chipnet + sim-fiatm scripts (catalytic-converter, hyperinflation backtests) - snapshots 0153-0168; wiki updates (glossary, decisions, index); ADR-0044/0045 - mockups + additional shell screens (Agora, Apps, MainScreen, AssetDetail, ...) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
e7f867f263
commit
599202a721
225 changed files with 52676 additions and 1518 deletions
26372
.calibration-sweep.json
Normal file
26372
.calibration-sweep.json
Normal file
File diff suppressed because it is too large
Load diff
6767
.catalytic-sweep.json
Normal file
6767
.catalytic-sweep.json
Normal file
File diff suppressed because it is too large
Load diff
6
.gitignore
vendored
6
.gitignore
vendored
|
|
@ -47,6 +47,8 @@ shells/app/src/devWallets.ts
|
|||
# per-file entries above — these are testnet-only, regenerated by scripts,
|
||||
# and may hold WIF private keys. Never commit.
|
||||
.chipnet-*.json
|
||||
# Chipnet test-state JSONs (moved by scripts/migrate-chipnet-tests.mjs).
|
||||
ChipnetTests/
|
||||
|
||||
# Third-party design template screenshots (Figma/Behance kits) downloaded for
|
||||
# the CosmoGenesis comparison round — reference-only, not project assets.
|
||||
|
|
@ -60,8 +62,10 @@ KnowledgeBase/RAW/
|
|||
Knowledgebase/RAW/
|
||||
|
||||
# Claude session transcript dumps (multi-MB JSONL) — logs, not source, and a
|
||||
# secret-prone surface. Kept on disk, never committed.
|
||||
# secret-prone surface. Kept on disk, never committed. Both legacy root location
|
||||
# and the FIATm-scoped subfolder are excluded.
|
||||
transcripts/
|
||||
Parameters/FIATm/transcripts/
|
||||
|
||||
# Local scratch / temp files.
|
||||
.tmp-*
|
||||
|
|
|
|||
|
|
@ -206,15 +206,42 @@ When the institutional, technical, economic, and rhetorical forces all point in
|
|||
|
||||
<h3>The diminishing-bribe-value calculation — why this is <em>substantially stronger</em> than KYC at scale</h3>
|
||||
|
||||
<p>A KYC bribe yields one verified identity per bribe — linear cost, deterministic effect. A social-proof bribe yields admission only if the bribe survives two subsequent sortition lotteries — geometric cost, probabilistic and rapidly vanishing effect.</p>
|
||||
<div class="callout">
|
||||
<div class="callout-title">Math correction (2026-06-15)</div>
|
||||
<p>An earlier version of this subsection (and the corresponding wiki/voting-systems.md section) presented a <strong>"~870 bribes per identity"</strong> figure with a <strong>"three orders of magnitude vs KYC"</strong> claim. Both were wrong. The error: conflating one-time pool-corruption <em>capability investment</em> with per-identity <em>stochastic burn</em>, and treating ~52 % of the pool as reliable capture when the hypergeometric distribution actually gives only ~50 % per-attempt success at that bribed fraction. The corrected analysis below uses the Vector A / Vector B framing from the <a href="#"><code>athenae_protocol_technical_spec_v0_1.md</code></a> §9 — costs combine <em>multiplicatively across independent attack surfaces</em>, not linearly per identity.</p>
|
||||
</div>
|
||||
|
||||
<p><strong>KYC bribery:</strong> Cost is <code>c · n</code> for <code>n</code> forged identities. Effect probability per bribe: <code>1.0</code>.</p>
|
||||
<p>A KYC bribe yields one verified identity per bribe — linear cost, deterministic effect. A social-proof bribe must defeat <em>three independent layers</em>, and the <em>shape</em> of cost differs between them.</p>
|
||||
|
||||
<p><strong>Social-proof bribery (mature network, <code>M = 1500</code> Citizens, <code>M_d = 150</code> Delegated):</strong> To admit one bribed identity, the attacker must (1) bribe 15 Citizens for the pre-gate; (2) bribe enough Citizens that ~15 of them land in the sortitioned 29 (≈ <code>52 % of M = 780 Citizens</code>); (3) bribe enough Delegated similarly (≈ <code>52 % of M_d = 78 Delegated</code>). Total: <strong>≈ 870 distinct bribes per admitted identity</strong>, versus 1 for KYC.</p>
|
||||
<p><strong>KYC bribery — linear and deterministic.</strong> Cost <code>c · n</code> for <code>n</code> forged identities; effect probability per bribe = <code>1.0</code>. Detectability: low (the issuer doesn't publish a "I attested these identities" bundle).</p>
|
||||
|
||||
<p><strong>Social-proof bribery — two cost categories that compose differently:</strong></p>
|
||||
|
||||
<table>
|
||||
<thead><tr><th>Cost category</th><th>Shape</th><th>When paid</th></tr></thead>
|
||||
<tbody>
|
||||
<tr><td><strong>One-time capture-capability investment</strong></td><td>Bribe ~60 % of each sortitioned pool (Citizens for Stage 1, Delegated for Stage 2). Paid <em>once</em> for the capability, not per identity.</td><td>At infiltration setup</td></tr>
|
||||
<tr><td><strong>Per-identity pre-gate cost</strong></td><td>15 endorsement bribes. Amortises across identities <em>only if</em> uniqueness defenses are absent; with rate-limit + adaptive uniqueness active, marginal cost scales back with <code>N</code>.</td><td>Per identity</td></tr>
|
||||
<tr><td><strong>Per-identity stochastic burn</strong></td><td>Escrow burn × <code>(1 / P_success_per_attempt)</code>. At 60 % pool corruption, hypergeometric <code>P(≥15 of 29 bribed)</code> ≈ 85 % per stage, ≈ 72 % combined — so ~1.4 expected attempts per successful admission.</td><td>Per identity attempt</td></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<p><strong>Why the sortitioned stages don't have a "stable bloc" attack.</strong> Sortition specifically destroys the attack model where a small bribed group reliably votes the attacker's way. An attacker cannot bribe a specific 15 Citizens and have them be the ones sortitioned — the chain draws randomly from <code>M</code>. So the attacker must either bribe a <em>large fraction</em> of the entire pool and accept probabilistic per-attempt capture, or accept that bribing a fixed small group is essentially useless. There is no middle path.</p>
|
||||
|
||||
<p><strong>Vector A — concrete cost at mature scale</strong> (from the Athenae spec):</p>
|
||||
|
||||
<ul>
|
||||
<li><strong>Single-sybil admission:</strong> $75K–$750K bribery + months-to-years + sortition luck.</li>
|
||||
<li><strong>Single-sybil influence at N = 1500:</strong> ~0.067 % — catastrophically bad cost-to-effect ratio for the attacker.</li>
|
||||
<li><strong>Majority capture (~751 admissions):</strong> <strong>$50M–$500M+ over 5–10 years</strong>, with rollback risk if pattern analysis flags the cluster.</li>
|
||||
<li><strong>Comparable token-DAO capture:</strong> $51M to capture a $100M-FDV token-weighted DAO <em>in days</em>, with no rollback risk.</li>
|
||||
<li><strong>Cost ratio: 10–100× worse for the attacker.</strong></li>
|
||||
<li><strong>Time horizon: 100–1000× longer.</strong></li>
|
||||
</ul>
|
||||
|
||||
<div class="callout">
|
||||
<div class="callout-title">The bribery cost is multiplicative across layers, not linear</div>
|
||||
<p>At mature scale the cost asymmetry between KYC-attack and social-proof-attack is roughly <strong>three orders of magnitude</strong> — and the social-proof attack is auditable post-hoc (every endorser's pkh is on a publicly verifiable bundle), while the KYC attack is not. This is not just "different from KYC" — at scale it is substantially stronger, because the cost of forgery grows linearly with network size while the cost of legitimate admission stays bounded.</p>
|
||||
<div class="callout-title">The honest asymmetry</div>
|
||||
<p>The earlier "three orders of magnitude per identity" framing was wrong. The honest version is: <strong>a 10–100× cost ratio combined with a 100–1000× time horizon</strong>, where the <em>product</em> is large but the cost and time have different shapes. The asymmetry comes from <em>multiplicative composition of independent attack surfaces</em> — capital AND social-network penetration AND time AND no-detection-by-Elders must all succeed simultaneously — not from linear per-identity bribery.</p>
|
||||
</div>
|
||||
|
||||
<h3>The pre-gate is ON-CHAIN — <code>EndorsementCovenant</code></h3>
|
||||
|
|
|
|||
85
Parameters/Athenae Politeia/README.md
Normal file
85
Parameters/Athenae Politeia/README.md
Normal file
|
|
@ -0,0 +1,85 @@
|
|||
# Athenae Politeia — Reference Folder
|
||||
|
||||
This subfolder holds all reference material for the **Athenae Politeia** governance / voting protocol — the separate dApp built on the same BCH substrate as the Deviant wallet but with its own covenant stack and its own spec.
|
||||
|
||||
If you're a new session picking this up: **start with [`athenae_protocol_technical_spec_v0_1.md`](athenae_protocol_technical_spec_v0_1.md) §1 (Overview) + §5 (Bicameral Sortition Design)** — that's the authoritative implementation spec, with status markers (✅ chipnet-validated / 🔧 specified-not-implemented / ❓ open question) on every line.
|
||||
|
||||
---
|
||||
|
||||
## What's in here
|
||||
|
||||
| File | What it is | Use it when |
|
||||
|---|---|---|
|
||||
| **`athenae_protocol_technical_spec_v0_1.md`** | The authoritative implementation-only technical spec. Greek brand layer, status markers, capture analysis, 8-layer founder mitigation, adaptive schedule, open questions A-1 through A-8. | You need the canonical mechanism reference. *Start here.* |
|
||||
| **`deviant_voting_counterfeight_whyonchain.md`** | Session summary covering: 8 refinements to the design, Vector A / Vector B attack analysis, Elder confirmation adaptive scaling, on-chain-only philosophy crystallization, active-rejection framing (bank-counterfeit analogy). | You need the decision history and *why* certain choices were made. |
|
||||
| **`deviant_athenae.html`** | Public-facing Athenae overview (web format). | Marketing / public-reference context. |
|
||||
| **`deviant_voting-system-update_FOR-design-record.html`** | Records all session refinements as a diff to the base voting-systems doc. 12 sections. | You need the design-diff against earlier versions. |
|
||||
|
||||
---
|
||||
|
||||
## Companion docs (live elsewhere — referenced from here)
|
||||
|
||||
| File | Location | What it is |
|
||||
|---|---|---|
|
||||
| `wiki/voting-systems.md` | `wiki/` | Full corpus design doc — historical lineage, comparison to other systems, full capture-cost economics (the public corpus the Athenae spec defers to for those topics). |
|
||||
| `wiki/decisions.md` ADR-0040 + addenda 1–6 | `wiki/` | The decision record for the voting framework. |
|
||||
| `wiki/voting-systems-bootstrap-playbook.md` | `wiki/` | Operational playbook for launching: founder cohort selection, Phase 0 discipline, transition to Phase 1, Elder emergence. |
|
||||
| `Knowledgebase/03_historical_and_political_economic/deviant_voting-systems_FOR-sophisticated-readers-and-political-economic-analysts.html` | `Knowledgebase/` | The public political-economy reference doc — for analysts evaluating the design. |
|
||||
|
||||
---
|
||||
|
||||
## Status snapshot (as of 2026-06-06 / project snapshot 0127)
|
||||
|
||||
- **Phases A–F + EndorsementCovenant** — all ✅ chipnet-validated. Per-rank CitizenToken / adaptive RegistryState / bicameral ApplicationCovenant / cap+fail-fast / paid-regardless escrow / commit-reveal ballot / Elder freeze / rising-cost complaint / on-chain pre-gate.
|
||||
- **Phase G** — 🔧 in progress: D-1 canonical templates (G.1 ✅ done — voting contracts registered in `src/verify/canonical.ts` + `src/verify/voting-labels.ts` with ADR-0008 trust labels); G.2 (TypeScript dApp SDK) / G.3 (dApp UI) / G.4 (regulatory pass) pending.
|
||||
- **Architecture decision** — Athenae is built as a **separate dApp**, NOT as a wallet feature. The wallet's role is to be a good signing partner (per ADR-0008 verifier-not-authority). See decision discussion 2026-06-06.
|
||||
|
||||
---
|
||||
|
||||
## Deferred decision — Greek-primary contract naming (parked 2026-06-06)
|
||||
|
||||
**Decision:** when Athenae work resumes, rename the auto-generated descriptive contract identifiers to **Greek-primary names** matching the classical reconstruction. Keep the English meaning + role in each contract's header comment so the codebase stays legible to readers without classical vocabulary.
|
||||
|
||||
**Mapping table** (full version in [`athenae_protocol_technical_spec_v0_1.md`](athenae_protocol_technical_spec_v0_1.md) §5.6):
|
||||
|
||||
| Current (auto-generated) | New (Greek-primary) | English meaning |
|
||||
|---|---|---|
|
||||
| `CitizenToken` | `Pinakion` | Citizen ID ticket used in the kleroterion for sortition |
|
||||
| `EndorsementCovenant` | `Dokimasia` | Pre-admission scrutiny |
|
||||
| `ApplicationCovenant` (A→E) | `Engraphe` | Enrolment of a citizen onto the deme roll |
|
||||
| `RegistryState` | `Katalogos` | The official citizen roll |
|
||||
| `BallotCovenant` | `Psephos` | The voting pebble |
|
||||
| `PollCovenant` | `Ekklesia` | The citizen Assembly that convened the vote |
|
||||
| `TallyState` | `Diapsephisis` | The taking & counting of the vote |
|
||||
| `ComplaintCovenant` | `Euthynai` | Mandatory accountability audit |
|
||||
| `ElderFreezeAction` | `Graphe Paranomon` | Suit against an unconstitutional decree |
|
||||
| *(sortition draw)* | `Kleroterion` | The allotment machine |
|
||||
| *(demotion outcome)* | `Ostracism` | Removal by community vote |
|
||||
|
||||
**Tier names** (use Greek-primary throughout):
|
||||
|
||||
| Functional | Greek |
|
||||
|---|---|
|
||||
| Base non-voting / Metics | `Metoikoi` |
|
||||
| Citizen | `Polites` |
|
||||
| Delegated Member | `Bouleutai` |
|
||||
| Elder | `Themis` (Themidae) |
|
||||
| Founder | `Nomothetes` |
|
||||
|
||||
**Companion deliverable:** project-level Greek↔English glossary doc (`wiki/athenae-glossary.md`, future) so the polity layer stays legible as it grows.
|
||||
|
||||
**Scope guidance:**
|
||||
- **Athenae Politeia dApp** — adopt Greek-primary names from inception. Header comments retain English meaning.
|
||||
- **P2P market dispute-court slice** — has not yet started; can adopt the new names from inception (does not need to retrofit because nothing has been built against them yet).
|
||||
- **Anything already built against the old names** — do NOT retrofit; the rename is forward-only.
|
||||
|
||||
---
|
||||
|
||||
## When you open this folder in a new session
|
||||
|
||||
1. Read `athenae_protocol_technical_spec_v0_1.md` § 1–6 to get the mechanism in mind.
|
||||
2. Read this README's "Deferred decision" section.
|
||||
3. Cross-check `wiki/voting-systems.md` §6.15 for the implementation phasing status (which will reference back here).
|
||||
4. Pick up wherever Phase G stands.
|
||||
|
||||
The Athenae stack is feature-complete on chipnet through Phase F + on-chain pre-gate. What remains is **the dApp itself** (SDK + UI + regulatory pass + canonical template promotion already done in G.1 + treasury wiring + lazy-voter instrumentation). All those are scoped in §11–§12 of the spec.
|
||||
60
Parameters/FIATm/README.md
Normal file
60
Parameters/FIATm/README.md
Normal file
|
|
@ -0,0 +1,60 @@
|
|||
# Parameters / FIATm
|
||||
|
||||
Design-record artefacts for the **FIATm family** — sound-money notes for state currencies,
|
||||
on-chain, backed by base-layer BCH. `m` = MBA. USDm is the worked example; **EURm, GBPm, JPYm,
|
||||
INRm, ARSm, TRYm** are the other six chipnet-validated instances on the same
|
||||
`DeviantOracleMBA` template (snapshots 0136 USDm / 0137 EURm + cross-asset / 0138 6-asset
|
||||
market / 0144 GBPm+JPYm+INRm + merchant POS / 0160 ARSm+TRYm).
|
||||
|
||||
## What lives here
|
||||
|
||||
| File | Role |
|
||||
|------|------|
|
||||
| [`fiatm_synthesis_FOR-reading-first.md`](fiatm_synthesis_FOR-reading-first.md) | **Single-source FIATm overview — start here.** Self-contained synthesis pulling the design record, the catalytic-converter hypothesis, the wallet-UI architectural naming, and the structural elaborations developed through snapshot 0163 into one reader-first document. ~700 lines. Cross-references the canonical sources rather than duplicating them. Written for a technically-engaged reader who wants the full picture in one pass. |
|
||||
| [`fiatm_complete-design_FOR-design-record.md`](fiatm_complete-design_FOR-design-record.md) | **The canonical FIATm design record.** Family intro (§0.5), three-values / Greek-coinage framing (§7a), Artemision lineage / art-of-emission / universal-substrate / why-the-lag-exists (§7a.1), 180° reversal (§7), holder experience + global scale + lag-as-opportunity (§7b), magical reversal + institutional-action asymmetry (§8 / §8.1), five-layer §12 controller, oracle integrity stack (§14) + composed-oracle for non-USD FIATm (§14a), TVL / governance / maturity ladder, implementation status, calibration program (§22), historical back-test §20a, BCH/USD volatility appendix B. Renamed from `usdm_…` to `fiatm_…` in snapshot 0155. |
|
||||
| [`usdm_sound-money-note_FOR-design-record.md`](usdm_sound-money-note_FOR-design-record.md) | The original USDm-only conceptual note. **Absorbed** by the FIATm record above; retained as a historical artefact for the early framing. |
|
||||
| [`usdm-and-market_diagram-report.html`](usdm-and-market_diagram-report.html) | USDm / market-integration diagram report (HTML render). |
|
||||
| [`catalytic-converter-hypothesis_FOR-testing.md`](catalytic-converter-hypothesis_FOR-testing.md) | **HYPOTHESIS-STAGE** (NOT yet a canonical design claim). Conjecture that the §12 rate-correction lag functions as a *catalytic converter for speculative noise* — absorbing synthetic-market volatility while arbitrage closes the gap with real BCH settlement. Testable predictions named; sim infrastructure path written. Promoted to a §12e or ADR only if simulation confirms. |
|
||||
| [`transcripts/`](transcripts/) | **Untracked by git** (`.gitignore` excludes the path). Verbatim session logs + companion narrative for the design lineage. Files: `2026-05-27_session_usdm-family-and-controller.jsonl` (raw 4.2 MB verbatim, 1,553 records, the original "stablecoin-mechanism / USDm-family-and-controller" session); `design-journey.md` (narrative — *why* and *how* decisions were made); `framings-and-rejected-paths.md` (quick-ref — pithy phrasings + rejected-path register + voice notes). Kept on disk, never committed (logs, not source). |
|
||||
|
||||
## What's adjacent but NOT in this folder
|
||||
|
||||
- **Snapshots** that describe FIATm work live under `../../snapshots/` (append-only history; do
|
||||
not move):
|
||||
- `0136` USDm round-trip · `0137` EURm cross-asset · `0138` 6-asset market · `0144` GBPm+JPYm+INRm + merchant POS
|
||||
- `0147` five-layer controller + simulator · `0148` 9-year back-test · `0149` doc updates with back-test · `0150` session synthesis
|
||||
- `0155` FIATm-level promotion · `0157` multi-redeem chipnet · `0158` §22 calibration sweep · `0159` hyperinflating back-test · `0160` ARSm+TRYm chipnet live + §7b/§14a
|
||||
- **Public-facing primer**: `../../wiki/sound-money-primer.md` (renamed BCHm → FIATm; pairs
|
||||
with the design record's §7 / §7a / §7b).
|
||||
- **Simulators + chipnet test scripts** for FIATm live under `../../scripts/`:
|
||||
- `sim-usdm-controller.mjs` · `sim-usdm-historical-bch.mjs` · `sim-usdm-calibration-sweep.mjs`
|
||||
(USDm-baseline)
|
||||
- `sim-fiatm-historical.mjs` · `sim-fiatm-trajectory.mjs` (multi-currency)
|
||||
- `chipnet-multicurrency-mba-test.mjs` (GBPm+JPYm+INRm genesis)
|
||||
- `chipnet-fiatm-multi-redeem.mjs` (multi-FIATm atomic burn proof)
|
||||
- `chipnet-fiatm-hyperinflation-test.mjs` (ARSm+TRYm genesis)
|
||||
- `merchant-pos-checkout-demo.mjs`
|
||||
- **Merchant POS module**: `../../src/merchant-pos/` (FIATm-family POS primitives).
|
||||
- **ADRs touching FIATm**: `../../wiki/decisions.md` — ADR-0028 / ADR-0033 (token-vs-asset
|
||||
taxonomy); ADR-0039 (MBA divisibility); the §14a composed-oracle decision lives in the
|
||||
design record itself, not as a standalone ADR yet.
|
||||
- **Different-but-adjacent designs** kept in the parent `Parameters/` folder:
|
||||
- `../MBA_Shares/mba-shares_complete-design_FOR-design-record.md` (MBA Shares — ADR-0042; same MBA
|
||||
family but an equity↔debt instrument, not a fiat sound-money note).
|
||||
- `../deviant_flow-and-bch-impact-model.md` (broader BCH-impact economic model; references
|
||||
FIATm flow but isn't FIATm-specific).
|
||||
- `../deviant_technical_spec_v2_8.md` (project-wide spec; FIATm appears as one of many
|
||||
asset families).
|
||||
|
||||
## Cross-references inside this folder
|
||||
|
||||
Both files in this folder reference each other and the diagram report by bare filename
|
||||
(sibling references) — moving them to or from this folder requires no path edits as long as
|
||||
they stay siblings.
|
||||
|
||||
## Naming convention reminder
|
||||
|
||||
Every fiat-backed FIATm instance carries an `m` suffix. Current: USDm / EURm / GBPm / JPYm /
|
||||
INRm / ARSm / TRYm. Future: any state currency on the same template (VESm / ZWLm / NGNm /
|
||||
EGPm / PKRm / IRRm / LBPm / … — VESm and ZWLm specifically need a piecewise sim treatment
|
||||
for the redenominations during the window, deferred per snapshot 0159).
|
||||
428
Parameters/FIATm/catalytic-converter-hypothesis_FOR-testing.md
Normal file
428
Parameters/FIATm/catalytic-converter-hypothesis_FOR-testing.md
Normal file
|
|
@ -0,0 +1,428 @@
|
|||
# Catalytic-converter hypothesis — the §12 rate-correction lag as speculation absorber
|
||||
|
||||
> **Status: STAGE-1 TESTED, SURVIVES (2026-06-14, snapshot 0161).** Mini test + scale-test
|
||||
> sweep across 192 parameter combinations both confirm the mechanism under stated
|
||||
> assumptions. 3 of 5 predictions DIRECTLY CONFIRMED, 1 indirectly, 1 deferred. **No
|
||||
> prediction refuted.** Mean catalytic strength across the sweep: **+16.2 pp recovery vs
|
||||
> null** (75% of cases >1pp, 63% >10pp, best 49.9pp, worst −6.0pp at undersized-reservoir
|
||||
> failure mode).
|
||||
>
|
||||
> Still labeled HYPOTHESIS-STAGE — not yet promoted to a canonical §12e design claim.
|
||||
> Promotion requires Stage 2 (robustness): varied §22 calibration, historical-path overlay,
|
||||
> multi-currency competition, varied transactional-adoption, P4 latency test. See *Path to
|
||||
> canonization* below for the full ladder. Per the corpus discipline (*"enthusiasm attaches
|
||||
> to the math model, not predicted market outcomes"*), this stays in this directory until
|
||||
> Stage 2 also passes.
|
||||
>
|
||||
> **Origin:** user-articulated, session ending 2026-06-14 (snapshot 0160 follow-up).
|
||||
> The same session opened the §7b "rate-correction lag is a catch-up opportunity for late
|
||||
> entrants" framing; this hypothesis extends that finding to a *systemic* claim about how
|
||||
> the FIATm controller interacts with synthetic-market noise.
|
||||
>
|
||||
> **Stage 1 test artefacts:**
|
||||
> - `scripts/sim-fiatm-catalytic-mini.mjs` — single-case validation (chipnet-scale, 0.2 BCH).
|
||||
> - `scripts/sim-fiatm-catalytic-scale.mjs` — 192-case parameter sweep.
|
||||
> - `.catalytic-sweep.json` — full sweep output.
|
||||
> - `snapshots/0161-catalytic-converter-mini-scale-tests-hyp.md` — findings synthesis,
|
||||
> prediction-by-prediction resolution, surprises, design caveat (reservoir sizing).
|
||||
>
|
||||
> **Notable design caveat surfaced by Stage 1:** the mechanism INVERTS when offchain
|
||||
> crash volume exceeds ~5× the FIATm reservoir capacity (partial absorption + slow BCH
|
||||
> price recovery underperforms the null's natural recovery). **Reservoir sizing at
|
||||
> deployment must anticipate the speculative depth it will face** — an under-sized FIATm
|
||||
> currency is net harmful to the substrate during a deep crash, not beneficial. This is
|
||||
> the strongest design constraint to carry into any §12e draft.
|
||||
|
||||
## The hypothesis in one sentence
|
||||
|
||||
**The §12 controller's rate-correction lag absorbs the high-frequency volatility produced by
|
||||
synthetic / leveraged / fractional markets, while real-settlement arbitrage closes the gap —
|
||||
together converting counterfeit volatility into real BCH demand.**
|
||||
|
||||
## The definitions this rests on
|
||||
|
||||
- **Speculation** (in this hypothesis): synthetic markets, 100× leverage, perpetual futures,
|
||||
fractional-reserve systems — any mechanism that *amplifies a price signal beyond the real
|
||||
on-chain settlement that would back it*. By the On-Chain-Only Philosophy's framing these
|
||||
are *counterfeit until a real transaction settles and validates*. The market-level effect
|
||||
is high-frequency noise around the spot oracle that does not correspond to real
|
||||
settlement.
|
||||
- **Arbitrage** (in this hypothesis): the much larger population of market participants who
|
||||
close price gaps between observed venues for *real* profit, with *real* settlement
|
||||
capital. By construction, arbitrage requires real BCH (to mint FIATm at the lagged rate
|
||||
and offload at the spot rate); the act of arbitraging *converts* the gap into real on-chain
|
||||
flow.
|
||||
- **Catalytic converter** (the metaphor): a passive filter on an exhaust stream that converts
|
||||
one molecule (toxic, fast) into another (harmless, settled) without itself being consumed.
|
||||
The §12 controller is passive (genesis-fixed parameters, no discretion); the speculation
|
||||
noise is the toxic input; the real BCH settlement that arbitrage produces is the converted
|
||||
output.
|
||||
|
||||
## The mechanism the hypothesis claims
|
||||
|
||||
1. Synthetic-market speculation drives the BCH/X spot oracle through high-frequency moves
|
||||
that do not correspond to real on-chain settlement.
|
||||
2. The §12 controller, by design (deadband + cadence + damping + cap, §12a–§12c), **does not
|
||||
propagate** those moves into the FIATm mint rate at full speed. The lag is a feature.
|
||||
3. Each lag window is a **price gap** between the controller rate (lagged) and the oracle
|
||||
target (current). Arbitrage discovers this gap as soon as the difference exceeds
|
||||
transaction costs.
|
||||
4. **The closure path requires real BCH.** Minting FIATm at the lagged rate locks real BCH;
|
||||
offloading FIATm into the local-currency market converts the lagged price into real
|
||||
capital flow. There is no synthetic shortcut — the contract verifies a real reservoir
|
||||
deplete + real BCH backing.
|
||||
5. The volume of arbitrage scales with the *gap depth × adoption*. Larger gaps → more
|
||||
arbitrage volume → more real BCH locked. Larger adoption (transactional use of FIATm) →
|
||||
more arbitrage seats → faster gap closure → larger conversion volume.
|
||||
6. **Net effect:** synthetic volatility goes in; real BCH demand and real FIATm settlement
|
||||
come out. The controller is the passive catalyst; arbitrage is the reaction.
|
||||
|
||||
## What this would predict that other mechanisms wouldn't
|
||||
|
||||
A hypothesis is only worth testing if it predicts something the null model doesn't. This one
|
||||
predicts:
|
||||
|
||||
| Prediction | Null (controller is just damping) | Catalytic-converter |
|
||||
|---|---|---|
|
||||
| Volume of FIATm minted during high-volatility periods | proportional to spot volume | **disproportionately larger** — arbitrage piles in during gap windows |
|
||||
| Realized BCH locked per unit of *implied* synthetic volume | small | **large multiplier** — synthetic volume catalyses real settlement |
|
||||
| Correlation between speculation spikes and FIATm mint events | random | **strong positive lag** — mints follow speculation spikes by ~the controller cadence |
|
||||
| Effect of adoption growth on volatility absorption | none | **superlinear** — more adoption seats expand the arbitrage market that closes gaps |
|
||||
| Direction of BCH price-support during synthetic bear attacks | ambiguous (oracle reflects the attack) | **net buying pressure on BCH** — arbitrageurs mint, locking BCH, generalising §12b to fiat-side too |
|
||||
|
||||
The directional predictions are testable in the existing simulator with modest extensions.
|
||||
|
||||
## Testable predictions for simulation
|
||||
|
||||
These are stated in the form `if(condition) then expect(outcome)`. The simulator
|
||||
(`scripts/sim-fiatm-trajectory.mjs` extended; or a new `sim-fiatm-catalytic.mjs`) should
|
||||
either reproduce these or refute them.
|
||||
|
||||
### Prediction 1 — Arbitrage volume scales with gap depth
|
||||
|
||||
> **In a scenario where the oracle injects synthetic noise (a Gaussian or fat-tailed
|
||||
> high-frequency oscillation overlaid on the underlying BCH/X drift), the cumulative
|
||||
> arbitrage-driven mint volume during the simulation should grow superlinearly with the
|
||||
> RMS amplitude of the synthetic noise.**
|
||||
|
||||
Test: parameterise the simulator with a `noiseAmplitude` knob (0%, 1%, 5%, 10% of spot RMS).
|
||||
Run all 5 stress scenarios at each amplitude. Compute cumulative mint volume attributable
|
||||
to lag-window minting. If the relationship is sub-linear or flat, the catalytic claim is
|
||||
weaker than the null.
|
||||
|
||||
### Prediction 2 — BCH price support during synthetic crashes
|
||||
|
||||
> **In a scenario where synthetic markets crash BCH price by 30% in days (compressed flash
|
||||
> bear, oracle-side), the implied arbitrage-driven mint volume should produce a net
|
||||
> buying-pressure signal that is non-trivial vs the crash magnitude.**
|
||||
|
||||
Test: add a "synthetic_crash" scenario — sharp spot drop + recover within 7-14 days, no
|
||||
underlying fundamental change. Compute the cumulative BCH locked via arbitrage mints during
|
||||
the drop. Compare to the spot move's implied selling volume. The §12b mechanism (BCH-crash
|
||||
buying pressure) should generalise; magnitude is the question.
|
||||
|
||||
### Prediction 3 — Adoption-conditional catalysis
|
||||
|
||||
> **At low FIATm adoption the catalysis is weak (small arbitrage market); at high
|
||||
> adoption it scales above linear (deeper arbitrage market closes gaps faster and at
|
||||
> larger volume).**
|
||||
|
||||
Test: parameterise an `adoptionMultiplier` on mint demand (0.1×, 1×, 5×, 20× the baseline
|
||||
phase curve). Re-run the noise scenarios. If catalysis is real, the cumulative absorbed-noise
|
||||
volume should grow super-proportionally with adoption.
|
||||
|
||||
### Prediction 4 — Gap-closure latency is bounded by cadence, not amplitude
|
||||
|
||||
> **The time-to-close a gap depends primarily on the §12 controller's cadence × damping,
|
||||
> not on the gap's absolute size — i.e. arbitrage closes gaps to the deadband regardless of
|
||||
> how deep they were.**
|
||||
|
||||
Test: simulate gaps of varying initial size (1%, 5%, 20%, 50%) and measure mean blocks until
|
||||
gap returns to within the deadband. If the time is roughly invariant with gap size (within
|
||||
the CAP_BPS limit), arbitrage is the speed-limiter; the controller's pace is not.
|
||||
|
||||
### Prediction 5 — Non-arbitrageable speculation is destructive
|
||||
|
||||
> **If the simulator is run *without* an arbitrage model (mints only happen via the
|
||||
> baseline phase curve, no gap-responsive minting), the lag windows accumulate and the
|
||||
> long-run holder outcomes degrade.**
|
||||
|
||||
Test: this is the null comparison. Disable gap-responsive minting; run all 5 scenarios.
|
||||
Compare final holder outcomes to the gap-responsive run. If the catalytic claim holds, the
|
||||
gap-responsive run should produce better holder outcomes AND lower BCH-price drawdowns.
|
||||
If the runs are indistinguishable, the lag is a passive damping — not a converter.
|
||||
|
||||
## What the simulator needs that it doesn't yet have
|
||||
|
||||
The current `sim-fiatm-trajectory.mjs` runs the controller against a deterministic price
|
||||
path and a phase-based adoption curve. To test the catalytic-converter hypothesis it needs:
|
||||
|
||||
1. **A synthetic-noise overlay on the oracle price path** — a Gaussian or fat-tailed
|
||||
high-frequency oscillator above the underlying drift, parameterisable by amplitude and
|
||||
spectral density. Defaults: zero (current behaviour) so the existing runs are
|
||||
unaffected.
|
||||
2. **A gap-responsive mint model** — at each block, in addition to the baseline phase mint,
|
||||
add `f(gap%)` extra mints proportional to the controller-vs-oracle gap (capped by an
|
||||
`adoptionMultiplier × maxArbitragePerBlock` ceiling). The functional form `f` is itself
|
||||
a hypothesis — sigmoid? linear with floor? — test multiple shapes.
|
||||
3. **A cumulative-arbitrage-volume metric** — distinguish "phase mints" from
|
||||
"gap-responsive mints" in the per-month report; output a summary attributing volume to
|
||||
each source.
|
||||
4. **An "absorbed noise" metric** — sum of `|spot − controller|` over windows where the
|
||||
spot diverged from the trend; compare to sum over windows where it didn't. Yardstick:
|
||||
what fraction of synthetic-noise oracle volatility was *not* propagated to the
|
||||
controller rate.
|
||||
5. **Adversarial scenarios** — synthetic flash crash (Prediction 2), synthetic flash rally,
|
||||
"pump and dump" attempted via oracle (does the deadband + cap absorb it?), and
|
||||
coordinated-majority oracle attack (the §15 worst case — does arbitrage still close
|
||||
gaps if the oracle is compromised?).
|
||||
|
||||
None of these are large additions; the existing simulator structure absorbs them with one
|
||||
new module (e.g. `scripts/lib/noise-and-arbitrage.mjs`) and a few parameter knobs.
|
||||
|
||||
## What the hypothesis does NOT claim
|
||||
|
||||
- It does **not** claim the controller "prevents" synthetic-market price discovery from
|
||||
affecting BCH. The oracle still reads spot; the controller still moves toward oracle
|
||||
targets eventually. The claim is about the *path* from spot move to FIATm rate and
|
||||
the *volume* of real settlement that flows along that path.
|
||||
- It does **not** claim arbitrage will *always* close gaps. Closure requires
|
||||
(a) a counterparty for the FIATm offload (transactional adoption) and (b) capital
|
||||
willing to lock real BCH. If either is absent, the gap persists and the catalysis is
|
||||
weak — Prediction 3 makes that explicit.
|
||||
- It does **not** alter the §16 "oracle failure is benign" property. Redemption is still
|
||||
P2PKH-only.
|
||||
- It does **not** require any contract change. The mechanism, if real, is emergent from
|
||||
the §12 controller already designed and the §3 atomic-swap path already built.
|
||||
- It does **not** claim FIATm "stabilises" BCH or local fiat. Stabilisation is the
|
||||
*behaviour* speculation predicts but cannot deliver; the claim here is about *real
|
||||
settlement volume* converting noise into demand. Whether that visibly damps BCH spot
|
||||
volatility depends on the size of the FIATm market relative to BCH spot.
|
||||
|
||||
## Structural elaboration — the two-counterweight model + expose mechanism + invisible-bootstrap + Chilonic anchor
|
||||
|
||||
This section consolidates the structural elaboration developed in the snapshot 0163 session
|
||||
(user-driven). It does **not** introduce new mechanism beyond the original hypothesis above; it
|
||||
names *why* the mechanism's preconditions hold (in particular, the previously-pinned-ON
|
||||
*transactional adoption* assumption), and *what enforces* the disjointness between real and
|
||||
synthetic markets at substrate level. The elaboration earns canonization (or rejection) at the
|
||||
same time as the core hypothesis — Stage 2.
|
||||
|
||||
### Two counterweights, applied simultaneously
|
||||
|
||||
The original hypothesis describes *one* counterweight to speculation: arbitrage, closing
|
||||
lag-window gaps with real BCH settlement. That counterweight requires a profitable exit, which
|
||||
the simulation pinned ON via the *transactional adoption* assumption. The structural elaboration
|
||||
makes the implicit exit explicit:
|
||||
|
||||
1. **Counterweight A — arbitrage.** The catalytic-converter as written. Lag opens; arbitrageur
|
||||
buys cheap BCH from offchain; mints FIATm at the lagged rate; real BCH gets locked inside
|
||||
FIATm UTXOs. Stage-1 mini + scale tests (snapshots 0161 / 0162 / 0163) confirm the mechanism
|
||||
under stated assumptions.
|
||||
2. **Counterweight B — real economy.** The transactional-adoption layer. Merchants accepting
|
||||
FIATm for goods; people paying rent / wages / invoices in FIATm; real-world settlement at
|
||||
face value. This is what *creates the arbitrageur's exit market at face value*. Without it,
|
||||
arbitrage has no profit; with it, the converter runs. **The real economy IS the previously-
|
||||
pinned-ON assumption, named structurally** — it is not arbitrary; it is what an on-substrate
|
||||
transactional layer *is*.
|
||||
|
||||
The two are not sequential; they are simultaneous. Counterweight B pays the arbitrageur, who
|
||||
closes the gap, which keeps the lag healthy as a catch-up mechanism for *more* Counterweight B
|
||||
participants. **The two counterweights reinforce each other**, and both run on the same
|
||||
substrate at the same time.
|
||||
|
||||
### Why this asymmetry is structural (the substrate enablers, named)
|
||||
|
||||
Synthetic markets produce *paper supply* — leverage multiplies a position without requiring
|
||||
proportional BCH to settle it. The FIATm system answers paper supply with *two real demands*:
|
||||
Counterweight A demands real BCH to mint FIATm; Counterweight B demands real FIATm to settle
|
||||
goods. Both demands settle on-chain, in real UTXOs, with **no synthetic counterpart possible
|
||||
within the substrate**.
|
||||
|
||||
The structural enablers, all pre-existing in the corpus, all carrying their architectural
|
||||
names from `Parameters/MBA_Shares/naming-and-branding_FOR-design-record.md`:
|
||||
|
||||
- **ASM** (Atomic Swap Market) — every position is a real UTXO; no synthetic counterpart
|
||||
possible inside the substrate. Surfaced architecturally via the *Poseidon* metaphor: *"an
|
||||
ocean, not a pool"*.
|
||||
- **MBA** (Mintable Backed Asset family — `DeviantOracleMBA` covenant) — real BCH locked per
|
||||
unit, not in a shared reservoir; no fractional reserve possible by covenant construction.
|
||||
- **BCH base layer** — hard-capped 21M, censorship-resistant consensus, no synthetic BCH
|
||||
supply venue within the substrate.
|
||||
|
||||
Together they make the substrate **structurally pro-real**: it is not neutral between real
|
||||
and synthetic; it *does not permit* synthetic supply to enter the on-chain mechanism. A
|
||||
stablecoin issuer cannot run a fractional reserve here because the substrate does not permit
|
||||
one. A speculator cannot run synthetic FIATm here because minting requires real BCH lock.
|
||||
|
||||
### The expose mechanism (Akone) — the elenchic property
|
||||
|
||||
The substrate's verification gate is **Akone** — *ἀκόνη*, the touchstone, the assay surface in
|
||||
the wallet UI (`wiki/glossary.md`, `Parameters/MBA_Shares/naming-and-branding_FOR-design-record.md`). Akone
|
||||
is not a marketing surface; it is the substrate's structural rejection of unverified claims.
|
||||
Every economic action attempting to participate in the on-chain mechanism passes through it,
|
||||
and Akone's pass/fail rule is binary: either the claim has real backing (in which case it
|
||||
becomes real and ceases to be a synthetic claim), or it has none (in which case it stays
|
||||
off-substrate forever).
|
||||
|
||||
This produces the **expose mechanism** as an emergent property of the substrate, not a
|
||||
designed addition. Every centralized counterparty interacting with the FIATm catalytic process
|
||||
declares its character through its behaviour:
|
||||
|
||||
- An honest CEX settles real BCH outflows — *visible on chain.*
|
||||
- A dishonest CEX halts withdrawals when arbitrage pressure builds — *also visible.*
|
||||
- An arbitrageur who profits from a lag window by locking real BCH — *visible as
|
||||
substrate-strengthening.*
|
||||
- A speculator who tries to extract value without settling — *unable to do so on-substrate*,
|
||||
must move to off-substrate venues which are themselves their own declaration of intent.
|
||||
|
||||
**Akone does not have to accuse anyone. The substrate does no work to reject synthetics; it
|
||||
simply does not invite them in, and they declare themselves by going elsewhere.** This is the
|
||||
elenchic property — proof through self-revelation under situation — in its operational form.
|
||||
|
||||
### Epigraph for Akone (per the naming-and-branding doc)
|
||||
|
||||
The Chilonic couplet, attributed to Chilon of Lacedaemon (one of the Seven Sages of ancient
|
||||
Greece) per traditional ascription:
|
||||
|
||||
> Ἐν λιθίναις ἀκόναις ὁ χρυσὸς ἐξετάζεται διδοὺς βάσανον φανεράν.
|
||||
> Ἐν δὲ χρυσῷ ἀνδρῶν ἀγαθῶν τε κακῶν τε νοῦς ἔδωκ' ἔλεγχον.
|
||||
|
||||
> "Gold is tested on the 'touchstone' (grinding stone) to verify its authenticity. With Gold
|
||||
> being an examination, mans true character bad or good is being tested and surfaced
|
||||
> (revealed) by means of consciousness (logic). (whether he is truly virtuous or not)."
|
||||
|
||||
The couplet's structure pairs two tests: a substance tested by a stone (the touchstone's
|
||||
*basanos*) and persons tested by gold (consciousness's *elenchus*). The FIATm substrate runs
|
||||
both tests at once: BCH backing is tested by the on-chain verification surface (Akone as
|
||||
*basanos*); economic actors are tested by their behaviour toward that surface (Akone as
|
||||
*elenchus*). The aphorism's reading carries unchanged into the substrate — the situation does
|
||||
the work; the actors disclose themselves.
|
||||
|
||||
### The institutional-action asymmetry (the magical reversal at full strength)
|
||||
|
||||
The two-counterweight model + the Akone expose mechanism + the substrate enablers produce, in
|
||||
combination, the institutional-action asymmetry now named in **§8.1 of the design record**:
|
||||
every direction of institutional action available against FIATm either strengthens the
|
||||
substrate or has no effect on it. The full matrix is in §8.1; the structural moats stack three
|
||||
deep (pre-launch invisibility, post-launch immunity, in-category exclusivity).
|
||||
|
||||
For the catalytic-converter hypothesis specifically, this resolves an open question from the
|
||||
Stage-1 cross-substrate test (snapshot 0162, corrected in 0163): the original simulation
|
||||
modelled synthetic supply as if it could compete with real arbitrage in the on-chain face-value
|
||||
market. That modelling was structurally impossible — Akone enforces market disjointness. The
|
||||
test as it stands validly demonstrates a **substrate-design counterfactual** (had FIATm been
|
||||
built on a substrate that permitted internal fractional reserve, the converter mechanism would
|
||||
not survive); it does **not** speak to external-market coexistence (institutions printing
|
||||
paper-FIATm products in their own category does not affect the on-chain catalytic mechanism,
|
||||
because the gate keeps the two markets disjoint).
|
||||
|
||||
### What Stage 2 needs to test, given the elaboration
|
||||
|
||||
The structural elaboration sharpens four Stage-2 candidates:
|
||||
|
||||
1. **The varied-transactional-adoption test now has explicit semantics.** The "adoption %"
|
||||
sweep models the *size of Counterweight B*. Predictions: arbitrage volume should track
|
||||
adoption (since adoption sets the exit-market capacity); the converter should reduce to zero
|
||||
strength as adoption → 0 (no exit → no arb).
|
||||
2. **A synthetic-attack scenario.** Inject a coordinated synthetic-market sell-off in BCH
|
||||
(leverage cascade), measure Counterweight A response (arb mint volume) AND Counterweight B
|
||||
persistence (real-economy demand stays constant). Does the combined demand absorb the
|
||||
synthetic sell pressure faster than either alone?
|
||||
3. **Supply-driven maturation re-test** (still open). Replace the hardcoded mature controller
|
||||
settings (`N_down = 144`, `d_down = 5%`) with the §12a.2 catalyst-driven evolution
|
||||
(`N_down`, `d_down`, `N_up`, `d_up` advance per 210k cumulative mints). Re-run mini + scale.
|
||||
Replaces the Stage-1 "scale invariance" finding with a *supply-history-conditional* catalytic
|
||||
strength curve.
|
||||
4. **Cross-substrate test ⇒ correctly framed.** Snapshot 0163 corrects 0162's findings #4 / #5
|
||||
to reflect that the test addresses a *substrate-design counterfactual*, not an
|
||||
external-market coexistence question. Akone enforces disjointness; institutional synthetics
|
||||
are irrelevant to the real catalytic mechanism by structural design.
|
||||
|
||||
### Honest limits to the elaboration
|
||||
|
||||
- The two-counterweight claim does **not** predict FIATm "wins" against speculation in any
|
||||
short-term price sense. Speculators move spot prices in either direction; the claim is about
|
||||
the *conversion path* and the *substrate composition*, not the price level.
|
||||
- The claim does **not** assert Counterweight B is automatic. Real-economy adoption is
|
||||
voluntary, path-dependent, and a function of factors outside the design (on-ramps,
|
||||
regulatory posture, merchant tooling, wallet UX). The model says *if* Counterweight B exists,
|
||||
*then* the substrate amplifies it via Counterweight A — not that B will materialise on its
|
||||
own.
|
||||
- The claim does **not** assert ASM + MBA permanently exclude synthetics from all venues.
|
||||
Synthetic FIATm could exist on other chains or off-chain exchanges (a CEX could list a "paper
|
||||
USDm" perpetual). The substrate-level pro-real bias holds *within* the FIATm substrate;
|
||||
bridges to less-disciplined venues reintroduce the synthetic question *in those venues*,
|
||||
without affecting the on-substrate mechanism.
|
||||
- The Akone enforcement is structural at the covenant level; its operational consistency
|
||||
depends on the §14 oracle integrity stack and the §17 issuance-scale confirmation. The
|
||||
Akone-as-elenchus framing is a *reading* of what the substrate does, not a separately
|
||||
designed enforcement layer.
|
||||
|
||||
### Simulator-vs-design reconciliation (outstanding)
|
||||
|
||||
Stage-1 simulations (snapshots 0161 / 0162) used `N_CEILING = 144` (from `sim-usdm-
|
||||
controller.mjs`) as the asymptotic mature value. The §12a.2 catalyst table in the design record
|
||||
shows `N_down = 21` as the suggested asymptotic value after 20+ catalysts. The discrepancy
|
||||
between simulator and design record (7×) propagates through the catalytic-strength calculations
|
||||
in 0161 and 0162 — the mature-state catch-up-window estimates were based on `N_down = 144`, not
|
||||
on the design's suggested 21. Reconciliation is a Stage-2 prerequisite: confirm which value
|
||||
the design intends as canonical, update either the simulator or the design record accordingly,
|
||||
then re-run the Stage-1 tests on the reconciled baseline.
|
||||
|
||||
Additionally, the simulator's DART time-trigger does **not** implement the path-dependence rule
|
||||
specified in §12a.1 (*"full magnitude when signal agrees with trajectory; half magnitude when
|
||||
opposing"*). This is another simulator-vs-design gap to close before further catalytic-converter
|
||||
modeling. Task: see snapshot 0163's *pending* section.
|
||||
|
||||
## Related corpus material (lineage)
|
||||
|
||||
- **§7b** of the design record (added 2026-06-14, snapshot 0160) — *"Rate-correction lag is
|
||||
a catch-up opportunity for late entrants."* This hypothesis extends the catch-up framing
|
||||
one level up: from "individual late entrants benefit from lag" to "the lag systemically
|
||||
converts speculative noise into real demand at the population scale."
|
||||
- **§12b** of the design record — *"Bargain windows during BCH crashes drive BCH buying
|
||||
pressure during the worst drawdowns."* This is the existing claim for BCH-side. The
|
||||
hypothesis generalises §12b to fiat-side too, and quantifies the conversion mechanism.
|
||||
- **On-Chain-Only Philosophy** (`Parameters/webfiles/the_on-chain-only_design_philosophy_FOR-reference.html`)
|
||||
— *"Synthetic markets are counterfeit until real settlement validates them."* The
|
||||
catalytic converter is the *mechanism* by which counterfeit volume gets converted to
|
||||
real settlement through the FIATm path.
|
||||
- **Snapshot 0148 / §20a** — the 9-year back-test already shows §12b's BCH-price-support
|
||||
feedback was a real consequence of the design. Extending it to fiat-side and to
|
||||
synthetic-market noise is a step further along the same arc.
|
||||
- **`transcripts/design-journey.md`** — the design-journey context for the controller's
|
||||
emergence.
|
||||
|
||||
## Path to canonization (if simulation confirms)
|
||||
|
||||
1. **Stage 1 — refutation attempt.** Run Predictions 1–5 in the simulator with multiple
|
||||
noise models + multiple arbitrage-response functions. If any prediction fails badly,
|
||||
the hypothesis is wounded; honest acknowledgement here + a `framings-and-rejected-paths`
|
||||
entry.
|
||||
2. **Stage 2 — robustness.** If Stage 1 passes, run it again with the §22 calibration
|
||||
sweep parameters varied, with the historical back-test path overlaid with noise, and
|
||||
per-currency. Stable findings under parameter variation = robust mechanism.
|
||||
3. **Stage 3 — write-up.** Publish an analysis doc (this file becomes the prelude). Identify
|
||||
*what improves* the converter: deadband choices, damping per direction, oracle stack
|
||||
layering, transactional-adoption sensitivity.
|
||||
4. **Stage 4 — promotion.** Add **§12e — *Catalytic converter for synthetic-market
|
||||
volatility*** to the FIATm design record. Author the ADR that captures the operational
|
||||
choices the analysis identifies (which parameters the converter is sensitive to;
|
||||
adoption-conditional weighting; oracle-stack interaction).
|
||||
5. **Stage 5 — primer integration.** The hypothesis, if true, is one of the most marketable
|
||||
claims in the FIATm corpus: *"the design that makes speculation accidentally productive
|
||||
for the substrate."* Add to `wiki/sound-money-primer.md`.
|
||||
|
||||
## What to do next (concrete)
|
||||
|
||||
- **Next session, opening move:** extend `scripts/sim-fiatm-trajectory.mjs` (or write
|
||||
`scripts/sim-fiatm-catalytic.mjs`) with the 5 simulator additions above.
|
||||
- Run Predictions 1–5 across USDm + ARSm + TRYm (the existing 3 currency profiles).
|
||||
- Capture: per-prediction metric + plain narrative. Snapshot the result.
|
||||
- Decision tree: confirm → analysis write-up + §12e draft. Refute → write the rejection
|
||||
honestly + move this file to a `_REJECTED_` prefix and link from
|
||||
`transcripts/framings-and-rejected-paths.md`.
|
||||
|
||||
Either outcome is a real contribution; the hypothesis is small enough to test cheaply and
|
||||
significant enough to deserve testing now.
|
||||
202
Parameters/FIATm/fiatm-adaptive-layer-principle_FOR-testing.md
Normal file
202
Parameters/FIATm/fiatm-adaptive-layer-principle_FOR-testing.md
Normal file
|
|
@ -0,0 +1,202 @@
|
|||
# FIATμ adaptive response layer — design principle
|
||||
|
||||
**Status: HYPOTHESIS-STAGE** — proposed §12d/e addendum to the canonical
|
||||
design record. Sim validation, parameter pinning, and ADR drafting all
|
||||
pending. Companion to `catalytic-converter-hypothesis_FOR-testing.md`.
|
||||
|
||||
## The proposal in one line
|
||||
|
||||
Add a sub-trigger inside DART (Layer 2) that modulates effective cadence
|
||||
per block based on **price direction × flow direction**, with the goal of
|
||||
asymmetrically supporting growth and resisting sell pressure.
|
||||
|
||||
## The 4-condition matrix
|
||||
|
||||
| Price direction | Flow direction | Adaptive response | Why |
|
||||
|---|---|---|---|
|
||||
| Downtrend | Mints > Redeems (active accumulation) | **Slow down** rate adjustment | Wider bargain window → more buyers commit BCH → §12b feedback amplified |
|
||||
| Uptrend | Redeems > Mints (active exit) | **Speed up** rate adjustment | Premium window closes → no sustained sell pressure extraction AND newcomers get fair entry pricing |
|
||||
| Downtrend | Mints < Redeems (no accumulation) | **Speed up** rate adjustment | No ghost window in dead market → rate normalizes to current reality |
|
||||
| Uptrend | Mints > Redeems (hodlers stay) | **Slow down** rate adjustment | Premium preserved for those with conviction |
|
||||
|
||||
## User's framings (both required for the full picture)
|
||||
|
||||
Two framings — both preserve verbatim:
|
||||
|
||||
1. *"the whole logic is to allow price growth support and empower it, and
|
||||
to limit the window for sell pressures"* (primary mission)
|
||||
2. *"new coming people will want to buy at fair rate, keeping the window
|
||||
where the rate remains high, the cost will be high for newcomers"*
|
||||
(the rally-side speed-up serves newcomer fairness too, not just
|
||||
sell-pressure resistance)
|
||||
|
||||
Stated intent: *"I am trying to balance the system"* — the adaptive
|
||||
layer is balancing multiple legitimate user groups, not picking winners.
|
||||
|
||||
## The full user-group analysis
|
||||
|
||||
The matrix serves three legitimate user groups and structurally suppresses
|
||||
the fourth (extractors) without exclusion — just by closing the structural
|
||||
opportunity their behavior requires.
|
||||
|
||||
| User group | What they want | How the matrix serves them |
|
||||
|---|---|---|
|
||||
| Existing holders (long-term) | Stability + value preservation | Asymmetric pro-hold bias from §12 catalyst lattice (untouched) |
|
||||
| Counter-cyclical buyers (vintage hunters) | Wider window during crashes | Down + active mints → slow down → wider commitment window |
|
||||
| New entrants (accessibility) | Fair entry pricing, not excluded by stale rates | Up + active redeems → speed up → rate normalizes → fair entry |
|
||||
| Sell-pressure extractors | Sustained inflated premium to dump into | Up + active redeems → speed up → window closes → extraction self-limits |
|
||||
|
||||
The rally-side speed-up serves BOTH the system (limits extraction) AND
|
||||
newcomers (restores fair entry pricing). A slow rally-side response
|
||||
without the adaptive layer would tax new entrants the same way it lets
|
||||
extractors extract.
|
||||
|
||||
## Why "manipulation" is not a vulnerability
|
||||
|
||||
The matrix converts any attempt at rate manipulation into one of two
|
||||
outcomes, both of which serve the system:
|
||||
|
||||
1. **Buy-side "manipulation"** → attacker commits real BCH → that IS demand →
|
||||
system absorbs BCH and rewards the action with a persistent rate window.
|
||||
Whether the "manipulator" is a whale, a coordinated group, or just an
|
||||
actual buyer is irrelevant — they all provide real economic value.
|
||||
|
||||
2. **Sell-side "manipulation"** → attacker triggers faster rate adjustment →
|
||||
premium window collapses before attack can scale → attack self-limits.
|
||||
Cannot extract sustained value from a closing window.
|
||||
|
||||
So manipulation IS the conversion mechanism — there is no clean attack
|
||||
against the rate that doesn't either subsidize demand or self-defeat.
|
||||
|
||||
User's exact framing (preserve): *"let them manipulate, it just proves
|
||||
there is a demand, and that someone values the asset… If they start
|
||||
redeeming the rate will get adjusted faster, closing the opportunity for
|
||||
pressure sells."*
|
||||
|
||||
## What the system "wants" at each market state
|
||||
|
||||
The matrix is structurally encoding the system's preferences at every
|
||||
moment:
|
||||
|
||||
| Market state | System wants | Adaptive layer enforces |
|
||||
|---|---|---|
|
||||
| Crash + fearful buyers | More committed buyers | Slow → window stays open longer |
|
||||
| Crash + dead market | Don't preserve ghost opportunity | Fast → normalize |
|
||||
| Rally + hodlers staying | Reward conviction | Slow → premium preserved |
|
||||
| Rally + active sellers | Don't let sellers extract sustained premium | Fast → fair conversion only |
|
||||
|
||||
Aligned behavior is fast-tracked. Misaligned behavior is allowed (no ban,
|
||||
no gating) but doesn't get amplification.
|
||||
|
||||
## Structural shape: pure overlay
|
||||
|
||||
The adaptive layer is a **pure overlay** on top of the existing §12 stack:
|
||||
|
||||
```
|
||||
For each block:
|
||||
1. Existing §12 stack computes its decision (always)
|
||||
2. Adaptive layer evaluates: do I have clear signals?
|
||||
- If yes: modulate effective cadence within bounded multiplier
|
||||
- If no: pass through unchanged (baseline §12 wins)
|
||||
```
|
||||
|
||||
The adaptive layer can ONLY tighten or loosen cadence within bounded
|
||||
ranges. It cannot:
|
||||
- Override Layer 1 (block floor)
|
||||
- Change damping (Layer 4)
|
||||
- Fire catalysts (Layer 2 main, which stays strictly on cumulative-minted)
|
||||
- Affect time-doublings (Layer 3)
|
||||
|
||||
This keeps code surface small, attack surface small, and §12 character
|
||||
intact at every layer below.
|
||||
|
||||
## How it integrates with §12
|
||||
|
||||
```
|
||||
Layer 1: Block-rate floor (10 min absolute)
|
||||
Layer 2: DART
|
||||
├─ 2-week time trigger (existing)
|
||||
├─ 210k mint catalyst (existing — permanent bias ratchet)
|
||||
└─ ADAPTIVE PRICE × FLOW response (PROPOSED — transient modulation)
|
||||
Layer 3: Time-doubling (210k blocks ≈ 4 years per epoch)
|
||||
Layer 4: Damping
|
||||
Layer 5: Inner guards (deadband, cap)
|
||||
```
|
||||
|
||||
The catalyst lattice still ratchets at 210k crossings. The adaptive
|
||||
sub-trigger only modulates EFFECTIVE cadence per block within bounded
|
||||
ranges. Long-term asymmetric character is unchanged.
|
||||
|
||||
## Resolved design questions (user-confirmed)
|
||||
|
||||
1. **Cold-start** (EWMA history too short to be meaningful):
|
||||
adaptive layer dormant. Existing §12 stack (2-week DART timer,
|
||||
catalyst lattice, deadband/cap/damping) governs as normal. No special
|
||||
bootstrap logic needed.
|
||||
2. **Sideways markets** (no clear price direction):
|
||||
no signal → stay at baseline cadence.
|
||||
3. **Oracle gap detection**:
|
||||
sign of `(oracle_target - controller_rate)` IS the trend signal,
|
||||
already computed every block by existing controller. Adaptive layer
|
||||
reads it; no new detection mechanism needed.
|
||||
|
||||
## Open design questions (remaining — need sim + ADR)
|
||||
|
||||
1. **Cadence multiplier bounds** — max slowdown × baseline (2×? 4×?
|
||||
8×?), max tightening vs Layer 1 floor (always bounded by 1 block)
|
||||
2. **EWMA half-life** for mint/redeem velocity (1 day = 144 blocks?
|
||||
1 week = 1008 blocks?)
|
||||
3. **Activity threshold** for "active" vs "low" — ratio relative to EWMA
|
||||
baseline (1.5× mint:redeem? 2×? 3×?)
|
||||
|
||||
## Sim validation so far
|
||||
|
||||
`scripts/sim-fiatm-adaptive-comparison.mjs` runs two scenarios on a
|
||||
fresh-launched currency (3 catalysts in):
|
||||
|
||||
### Scenario A: crash + active mints
|
||||
- Adaptive widens gap from −10% to −14% at peak
|
||||
- Bargain window holds open ~2× longer (recovery to within 1% by hour 72
|
||||
vs hour 36 baseline)
|
||||
- Validates the "wider bargain window with productive activity" property
|
||||
|
||||
### Scenario B: rally + active redeems
|
||||
- At fresh-launch maturity (N_up=1 already at floor), adaptive has no
|
||||
further compression room
|
||||
- Effect emerges only post time-doubling (when N_up = 2^epoch blocks)
|
||||
- This is a *finding*, not a bug — establishes that adaptive value on
|
||||
the rally side accrues with maturity
|
||||
|
||||
## Where things live
|
||||
|
||||
- This file: `Parameters/FIATm/fiatm-adaptive-layer-principle_FOR-testing.md`
|
||||
- Comparison sim: `scripts/sim-fiatm-adaptive-comparison.mjs`
|
||||
- Snapshot recording the session: `snapshots/0168-fiatm-exchange-demo-and-adaptive-layer-design.md`
|
||||
- Memory: `fiatm-adaptive-layer-principle.md` (cross-session surface)
|
||||
|
||||
## When to invoke
|
||||
|
||||
- User asks about manipulation, attack vectors, or whale games against
|
||||
FIATm — point them at the manipulation reframe section
|
||||
- Designing or evaluating adaptive response mechanisms anywhere in the
|
||||
project
|
||||
- Discussing the philosophical principle behind §12 asymmetry — the
|
||||
three-user-groups analysis is the cleanest articulation
|
||||
- Anyone says "the slow crash response is a bug" — it's the design's
|
||||
whole architectural commitment, and the adaptive layer makes it
|
||||
explicit
|
||||
- Considering whether to weaken the asymmetric character — don't. The
|
||||
asymmetry IS the system, not a side effect.
|
||||
|
||||
## Promotion criteria
|
||||
|
||||
This file moves from `_FOR-testing.md` to a `_FOR-design-record.md`
|
||||
section (likely §12d or §12e) when:
|
||||
|
||||
1. Sim across multiple maturity states confirms the matrix produces the
|
||||
intended behavior in all four conditions
|
||||
2. Three parameters (cadence multiplier bounds, EWMA half-life, activity
|
||||
threshold) are calibrated and stable across price-regime scenarios
|
||||
3. Edge cases (rapid oscillation, gaming via wash mints, parameter
|
||||
sensitivity) are documented and bounded
|
||||
4. ADR drafted for the addition to §12
|
||||
149
Parameters/FIATm/fiatm-conventions_FOR-design-record.md
Normal file
149
Parameters/FIATm/fiatm-conventions_FOR-design-record.md
Normal file
|
|
@ -0,0 +1,149 @@
|
|||
# FIATμ conventions — naming and UX
|
||||
|
||||
Two user-agreed conventions that govern how FIATm/FIATμ is presented
|
||||
across code, copy, and user-facing surfaces. Both should be honored when
|
||||
writing new docs, designing UI, or contributing changes.
|
||||
|
||||
---
|
||||
|
||||
## 1. Dual-tier naming: `FIATm`/`USDm` in code, `FIATμ`/`USDμ` in brand
|
||||
|
||||
### The rule
|
||||
|
||||
| Context | Use | Examples |
|
||||
|---|---|---|
|
||||
| JS/TS identifiers, contract names | Latin `m` | `USDm`, `DeviantOracleMBA`, `state.fromSym` |
|
||||
| File paths, folder names | Latin `m` | `Parameters/FIATm/`, `fiatm-exchange_demo.html` |
|
||||
| Snapshots, ADRs, memory files, design records | Latin `m` | `bchm-five-layer-controller.md` |
|
||||
| Currency tickers in app UI | Latin `m` (like BTC/ETH ticker) | "USDm 420.50 in sidebar" |
|
||||
| App brand title / headlines | Greek `μ` | "FIATμ Exchange" |
|
||||
| Marketing copy, landing page | Greek `μ` | "Sound money for any fiat — FIATμ" |
|
||||
| Public-facing design record headers | Greek `μ` (optional ceremonial) | "§0 FIATμ family overview" |
|
||||
|
||||
Same pattern as Bitcoin's `₿` (sacred symbol) vs `BTC` (typeable ticker).
|
||||
|
||||
### Why μ — three simultaneous readings
|
||||
|
||||
User's exact framing (preserve): *"μ reads both μικρο and μαθηματικα
|
||||
simultaneously"* — plus a third reading worth holding alongside:
|
||||
**μέτρον** (ancient Greek "measure" / standardized unit of exchange,
|
||||
Pheidon's reformed weights, Solonian measures).
|
||||
|
||||
Together:
|
||||
- **μικρο** (micro) — each unit is the *smallest sound* fractional unit
|
||||
of fiat; matches the BCHμ notation for sats
|
||||
- **μαθηματικά** (mathematics) — the §12 controller is pure math; no
|
||||
governance, no discretion
|
||||
- **μέτρον** (measure) — Greek concept of standardized unit of exchange
|
||||
|
||||
Fits the project's existing Greek motif: Artemision, Salamis (multi-
|
||||
currency family as defense), Thermopylae (onchain settlement as narrow
|
||||
pass), Aristarchus.
|
||||
|
||||
### Migration policy
|
||||
|
||||
**Do NOT migrate existing artifacts.** Gradual brand-side adoption only.
|
||||
Latin versions remain canonical for code; Greek versions are additive
|
||||
for brand moments. Both refer to the same thing; no confusion if the
|
||||
rule above is held.
|
||||
|
||||
### Anti-patterns
|
||||
|
||||
- "Let's just pick one consistently" — the dual-tier resolution is
|
||||
intentional, not indecision. Point disagreement here.
|
||||
- Renaming `Parameters/FIATm/` to `Parameters/FIATμ/` — no. Latin is
|
||||
the file path convention. Greek would break tooling and grep.
|
||||
- Using `USDμ` as a JS variable name — no. Code uses Latin.
|
||||
- Using `USDm` in marketing copy — fine for now (existing docs use it),
|
||||
but new public-facing copy should adopt `USDμ`.
|
||||
|
||||
---
|
||||
|
||||
## 2. UX rule: "Swap" replaces mint/redeem in user-facing copy
|
||||
|
||||
### The rule
|
||||
|
||||
In every user-facing surface of FIATμ Exchange (and by extension Agora /
|
||||
Orbital Swap), all conversion operations are labeled **"Swap"** regardless
|
||||
of whether they're technically a mint, a redeem, or a cross-currency
|
||||
conversion.
|
||||
|
||||
Mint and redeem remain valid as **code terms** (variable names, function
|
||||
names, contract methods, internal diagnostic logs, ADRs, design records)
|
||||
— but they MUST NOT appear in:
|
||||
|
||||
- Button labels
|
||||
- Receipt / confirmation text
|
||||
- Activity log entries
|
||||
- Banner / status messages
|
||||
- Modal titles
|
||||
- Help text or tooltips visible to end users
|
||||
|
||||
### Why
|
||||
|
||||
User's exact framing (preserve): *"Users don't need to know weather they
|
||||
mint or redeem, they just swap assets. Let the mint redeem only for
|
||||
programming language"*
|
||||
|
||||
The mental model for users is uniform: **I have asset A, I want asset B,
|
||||
I swap.** The underlying mechanism (mint a new token vs burn an existing
|
||||
token vs route via BCH) is implementation detail that adds cognitive
|
||||
load without value at the UX layer.
|
||||
|
||||
Same way users don't see "creating UTXO" vs "spending UTXO" — they just
|
||||
see "send" and "receive". Same principle, applied to mint/redeem.
|
||||
|
||||
### How to apply
|
||||
|
||||
| Layer | Term |
|
||||
|---|---|
|
||||
| End-user UI (buttons, receipts, banners, activity log) | **"Swap"** universally |
|
||||
| JS variable names, internal logic | `isMint`, `isRedeem`, `tryMintUSDm`, `runDemoSwap` — code-only, keep |
|
||||
| Diagnostic / debug logs visible only in Phase 2 modal | Mint/redeem allowed (dev surfaces, not consumer) |
|
||||
| Contract method names | `claim()`, `redeem()` etc. (covenant-level, code-only) |
|
||||
| ADRs, design records, snapshots | Use precise technical terms (mint, redeem, claim) |
|
||||
| Memory files | Use precise technical terms freely |
|
||||
|
||||
### Applied in FIATμ Exchange demo
|
||||
|
||||
Snapshot date 2026-06-16. In `fiatm-exchange_demo.html`:
|
||||
|
||||
- Activity log: always `Swap FROM → TO`, never `Mint X` or `Redeem X`
|
||||
- Receipt operation field: always shows `Swap` (not "Mint / Redeem / Swap")
|
||||
- Crash window banner: "Swapping in now locks a richer vintage" / "Rich
|
||||
vintage window arbitrage opportunity" (was "Minting now locks…")
|
||||
- Vintage note: "you locked a richer vintage" (was "you minted…")
|
||||
- Phase 2 button: "Try real swap on chipnet" (was "Try real mint on chipnet")
|
||||
- Phase 2 modal title: "Real chipnet swap — confirm" (was "Real chipnet
|
||||
mint — confirm")
|
||||
- Phase 2 amount field: "Amount to receive" (was "Amount to mint")
|
||||
|
||||
### Anti-patterns
|
||||
|
||||
- Adding a "mint" or "redeem" button to the wallet UI — no, just "swap"
|
||||
- "Mint USDm with BCH" in tooltip text — write "Swap BCH → USDm"
|
||||
- Showing "Redeem 100 USDm for BCH" in receipt — write "Swap 100 USDm → BCH"
|
||||
- Showing whether a swap is a mint or a redeem in any user-visible
|
||||
diagnostic — no, that's implementation detail
|
||||
|
||||
---
|
||||
|
||||
## When to invoke this document
|
||||
|
||||
- Writing any new user-facing copy for FIATμ / Agora / Orbital Swap
|
||||
surfaces — check the "just say Swap" rule
|
||||
- Designing app branding, splash screens, ceremonial document headers —
|
||||
check the dual-tier naming rule
|
||||
- Reviewing UI text in `shells/app/` or any wallet integration
|
||||
- Considering renaming any existing artifact — default: don't
|
||||
- Anyone proposes "let's pick one consistently" or "show mint/redeem
|
||||
for transparency" — point them here, the conventions are intentional
|
||||
|
||||
## Where things live
|
||||
|
||||
- This file: `Parameters/FIATm/fiatm-conventions_FOR-design-record.md`
|
||||
- Memory (cross-session): `fiatm-dual-tier-naming.md` and
|
||||
`fiatm-ux-just-swap.md`
|
||||
- Demo HTML applying both: `Parameters/FIATm/fiatm-exchange_demo.html`
|
||||
- Snapshot recording the decisions:
|
||||
`snapshots/0168-fiatm-exchange-demo-and-adaptive-layer-design.md`
|
||||
1974
Parameters/FIATm/fiatm-exchange_demo.html
Normal file
1974
Parameters/FIATm/fiatm-exchange_demo.html
Normal file
File diff suppressed because it is too large
Load diff
|
|
@ -1,8 +1,15 @@
|
|||
# USDm — Complete Design Record
|
||||
# FIATm — Complete Design Record
|
||||
|
||||
**USDm = USD MBA** (a USD-denominated Mathematically Backed Asset).
|
||||
**FIATm** is the family of **Fiat MBAs** — sound-money notes for state currencies, on-chain, backed
|
||||
by base-layer BCH. The `m` is the **MBA template**: one universal contract (`DeviantOracleMBA`)
|
||||
parameterized by a price oracle and a denomination, so new currencies are added by configuration,
|
||||
not by writing new covenant code. **USDm** (the USD MBA) is the worked example throughout this
|
||||
record; **EURm, GBPm, JPYm, INRm** are the other four currently chipnet-validated instances. The
|
||||
mechanism, the controller, the oracle stack, the maturity ladder — all of it is currency-agnostic.
|
||||
|
||||
**Date:** 2026-06-07 · **Status:** asset core chipnet-validated (snapshots 0136–0138);
|
||||
**Date:** 2026-06-13 (FIATm-level promotion) · originally drafted 2026-06-07 (USDm-specific).
|
||||
**Status:** asset core chipnet-validated across **5 FIATm currencies** (snapshots 0136 USDm round-trip;
|
||||
0137 EURm + atomic cross-asset swap; 0138 6-asset market 111 swaps; 0144 GBPm+JPYm+INRm + merchant POS);
|
||||
price-adjustment + oracle-integrity layers designed here, not yet built. **Supersedes**
|
||||
`usdm_sound-money-note_FOR-design-record.md` (absorbed below) and adds the full price-adjustment /
|
||||
oracle-integrity design.
|
||||
|
|
@ -10,12 +17,18 @@ oracle-integrity design.
|
|||
**Discipline (corpus standard):** documented facts + mechanism; strong claims labeled; honest
|
||||
counterweights kept; *enthusiasm attaches to the math model, not predicted market outcomes.*
|
||||
**Terminology:** **asset** = on-chain backed (MBA family); **token** = unbacked / off-chain claim
|
||||
(NBA family). USDm is an **asset**; USDT/USDC/DAI are **tokens**.
|
||||
(NBA family). A FIATm unit is an **asset**; USDT/USDC/DAI are **tokens**.
|
||||
|
||||
---
|
||||
|
||||
# PART I — WHAT USDm IS
|
||||
|
||||
> **Scope of Part I.** The headline and the chapters below describe **USDm** because USDm is the
|
||||
> worked example carried through the record. The same statement holds verbatim for every other
|
||||
> FIATm currency (EURm, GBPm, JPYm, INRm, or any future state currency on the same template) —
|
||||
> the §0.5 family intro and the framing flags at Part II make that explicit. Reading "USDm" as
|
||||
> "the FIATm worked example" preserves the meaning end-to-end.
|
||||
|
||||
## 0. Headline
|
||||
> **USDm is the only stablecoin that can't break its peg — because it never made one — and the
|
||||
> only one whose redemption is strongest in a crisis.** A dollar-denominated note with a **hard BCH
|
||||
|
|
@ -23,6 +36,51 @@ counterweights kept; *enthusiasm attaches to the math model, not predicted marke
|
|||
> liquidation or insolvency. This is structurally possible, on-chain-verifiable, and has no
|
||||
> precedent in the stablecoin category — what the market does with it is an open experiment.
|
||||
|
||||
## 0.5. The FIATm family — universal model, USDm as worked example
|
||||
|
||||
The model is **not USD-specific**. USD is the worked example because it is the largest, most
|
||||
widely-priced state currency and BCH/USD has the deepest oracle coverage — but FIATm is a *family*:
|
||||
**any state currency** can be issued as a FIATm with a different oracle and a different denomination.
|
||||
The contract code does not change.
|
||||
|
||||
| FIATm instance | Status | Oracle (BCH/X) | Genesis snapshot |
|
||||
|---|---|---|---|
|
||||
| **USDm** | chipnet-validated · worked example throughout | BCH/USD | 0136 |
|
||||
| **EURm** | chipnet-validated · atomic cross-asset swap with USDm | BCH/EUR | 0137 |
|
||||
| **GBPm** | chipnet-validated | BCH/GBP | 0144 |
|
||||
| **JPYm** | chipnet-validated | BCH/JPY | 0144 |
|
||||
| **INRm** | chipnet-validated | BCH/INR | 0144 |
|
||||
| *(any future state currency)* | — | BCH/X | — |
|
||||
|
||||
**The defining properties of FIATm (one statement of the model):**
|
||||
|
||||
1. **State-currency-agnostic** — any sovereign or supra-sovereign unit (USD, EUR, GBP, JPY, INR,
|
||||
ARS, …) can be minted as a FIATm; the contract does not encode the currency, only the oracle's
|
||||
public key and the denomination granularity.
|
||||
2. **Base-layer backed** — every unit holds real BCH inside its own UTXO. There is **no shared
|
||||
reservoir**, **no fractional pool**, **no off-chain reserve attestation**. Strip the
|
||||
surroundings and the unit still works.
|
||||
3. **Atomically swappable** — between FIATm currencies (USDm ↔ EURm at oracle ratios) and back to
|
||||
BCH at any time, in a single covenant spend, with no counterparty consent required for the
|
||||
exit. Snapshot 0137 demonstrates this end-to-end.
|
||||
4. **Dynamic Rate Asset with correction mechanisms** — the mint-time rate floats with the oracle
|
||||
inside a five-layer adaptive controller (§12) that bounds volatility, dampens noise, and
|
||||
ratchets asymmetric pro-hold bias through real adoption rather than at genesis.
|
||||
5. **No liquidation trigger** *(unlike CDPs)* — a FIATm unit is settled at mint, not an open
|
||||
debt. Nothing can liquidate it. No price drop in BCH can take your BCH away. §6 details the
|
||||
contrast with DAI / ParyonUSD / any CDP.
|
||||
6. **No over-collateralization** *(unlike CDPs)* — 100% capital-efficient: $1 of BCH locked
|
||||
mints $1-equivalent of FIATm. CDPs require 110–200% collateral to absorb their liquidation
|
||||
tail; FIATm has no tail to absorb, so it doesn't need the over-collateralization.
|
||||
|
||||
**The philosophical claim.** Electronic fiat morphed into sound money — the reverse path. Sound
|
||||
money was hollowed into fiat over centuries (Croesus → Roman silver dilution → bank notes → gold
|
||||
standard → Bretton Woods → 1971 Nixon shock). FIATm runs that arc **backwards, in one covenant**:
|
||||
the dollar (or any state currency) returns to substance, not because the state restored a peg, but
|
||||
because a base-layer-backed bearer instrument can carry the dollar denomination *without* the
|
||||
fractional reserve and *without* the political commitment underneath it. §7 develops the reversal
|
||||
in full; §7a maps it onto the three-values framing of ancient Greek coinage.
|
||||
|
||||
## 1. Sound-money note, not a stablecoin
|
||||
"Stablecoin" is the wrong genus — *stable* names the peg USDm discards. It is a **sound-money note**:
|
||||
a bearer claim on hard money (BCH), dollar-labeled for accounting, behaving like the **opposite of
|
||||
|
|
@ -32,6 +90,107 @@ in fiat; trustless to redeem, with no institution in the path.** It is **functio
|
|||
mechanical-$1** — ~$1 in calm BCH, drifts *above* $1 in a bull (the upside), confidence-above-a-real-
|
||||
floor in a hard bear.
|
||||
|
||||
## 1a. The inversion — surface fiat, underneath sound
|
||||
|
||||
§1 establishes the *negative* claim — stablecoin is the wrong genus. This subsection establishes
|
||||
the *positive* claim: FIATm is the **inverted-fiat genus**. Historically, fiat currency was *backed
|
||||
by* sound money (gold/silver) — the substance was real, the face was the political wrapping. The
|
||||
1914–1971 arc severed the substance from the face, leaving the face alone as the modern unit-of-
|
||||
account. **FIATm reverses the relationship**: it returns the substance and *re-couples it through
|
||||
the same fiat face value*. The result is **fiat's face value backed by sound money** — the exact
|
||||
inversion of the historical fiat-backed-by-sound arrangement.
|
||||
|
||||
The inverted relationship, made explicit:
|
||||
|
||||
| Layer | Historical fiat (post-1971) | USDT / USDC / DAI (paper stablecoin) | FIATm (inverted fiat) |
|
||||
|---|---|---|---|
|
||||
| **Surface** — denomination, what the user thinks in | Dollar / euro / peso / lira face value | Same fiat face value | Same fiat face value |
|
||||
| **Underneath** — what backs the surface | Nothing — political fiat alone | Off-chain reserves (paper IOU claim on the fiat) | **Real BCH locked in the unit's UTXO** |
|
||||
| **Surface↔underneath relationship** | Surface *is* the unit (no underneath) | Surface *claims* the underneath (off-chain paper) | Surface *carries* the underneath (sound-money substrate wearing the fiat label) |
|
||||
|
||||
The naive observer reads FIATm as "a fiat-denominated stablecoin" — same face, same denomination,
|
||||
same accounting unit. **The actual structure is the inverted relationship**: the fiat face is not
|
||||
the substance; it is the *labeling convention* used to deliver real BCH backing to a population
|
||||
that thinks in their local currency. It looks irrational because in every other category the fiat
|
||||
face is the primary thing and the backing is the derived thing (when present at all). FIATm flips
|
||||
this: **the BCH is the primary thing, and the fiat face is the delivery vehicle.**
|
||||
|
||||
### Three structural consequences
|
||||
|
||||
This inversion is what produces the asymmetries §7 (reverse trajectory), §8 (magical reversal),
|
||||
and §8.1 (institutional-action asymmetry) describe operationally. Three structural consequences
|
||||
fall out:
|
||||
|
||||
1. **The denomination is not a threat surface.** Institutions cannot identify FIATm as adversarial
|
||||
through its denomination because FIATm is denominated in *their* currency. A USDm holder
|
||||
transacts in "dollars," prices in "dollars," files taxes in "dollars." An ARSm holder transacts
|
||||
in "pesos." A TRYm holder in "lira." The substrate is invisible to a denomination-level audit
|
||||
in every fiat the family covers.
|
||||
2. **The primary monetary tool — printing — strengthens FIATm.** Every new unit of fiat issued
|
||||
debases all units of that fiat (including the paper stablecoins denominated in it), but **a
|
||||
FIATm holder's BCH appreciates in their fiat's terms in proportion to the debasement**. The
|
||||
tool the issuing central bank uses to defend its currency instead recruits new BCH demand. This
|
||||
is the §8.1 *"print more fiat → strengthens"* cell at its structural root, and it operates
|
||||
across the FIATm family — Federal Reserve action strengthens USDm; ECB action strengthens
|
||||
EURm; Central Bank of Argentina action strengthens ARSm; Central Bank of Turkey action
|
||||
strengthens TRYm. **One mechanism, applied independently to every fiat the family covers.**
|
||||
3. **The cognitive on-ramp is zero.** The user does not have to migrate their cognitive frame to
|
||||
migrate their store of value. They keep their denomination; they just change what backs it.
|
||||
The "invisible bootstrap" property of §8.1 *operationally means* exactly this: the substrate
|
||||
borrows the institution's own UI (denomination) so the on-ramp friction is zero at the
|
||||
cognitive layer. **This is what makes FIATm a global-scale instrument**: every fiat-using
|
||||
population — ~2-3 billion people in hyperinflating regimes plus everyone in stable-fiat
|
||||
regimes — already thinks in the unit the substrate uses to deliver the substance.
|
||||
|
||||
### Global scope — not a USD instrument
|
||||
|
||||
The inversion is **not specific to USDm**. It applies *independently and identically* to every
|
||||
FIATm currency the family covers (USDm, EURm, GBPm, JPYm, INRm, ARSm, TRYm — and every future
|
||||
state currency on the same template). Each FIATm wears its local fiat denomination on the
|
||||
surface; each carries BCH underneath; each presents the inverted relationship to its respective
|
||||
issuing central bank. **The family addresses the global fiat economy, not the dollar economy.**
|
||||
A central bank facing FIATm in its own denomination faces the same structural inversion as every
|
||||
other central bank, on the same substrate, simultaneously. There is no jurisdiction where the
|
||||
inversion does not apply.
|
||||
|
||||
### The structural reading of "Keynesian capture"
|
||||
|
||||
Keynesian monetary policy depends on the central bank controlling the value of the
|
||||
unit-of-account by controlling supply. If the unit-of-account is preserved (the fiat face stays
|
||||
$1, ₹1, ₺1, $1 ARS) but the value-setting is now done by a hard-capped substrate (BCH), **the
|
||||
central bank still controls the unit-of-account but no longer controls what that unit is worth
|
||||
in real terms for FIATm holders**. The denomination is now a label without a lever. Keynesian
|
||||
tools still operate, but they operate on a population that has structurally exited their domain
|
||||
*while remaining inside their accounting frame*. The §8.1 institutional-action asymmetry is the
|
||||
operational consequence of this structural reading: every institutional action available (print,
|
||||
refuse to list, regulate, ignore) is an action *inside the accounting frame* — and the substrate
|
||||
sits outside the accounting frame while wearing it. The frame remains; the substrate doesn't
|
||||
need to leave the frame to occupy a category outside it.
|
||||
|
||||
### Bridges forward
|
||||
|
||||
- The historical mirror is in **§7** (reverse trajectory: gold→fiat arc walked backwards). The
|
||||
inversion described here is the *visible structural form* of that reversal: not "we return to
|
||||
the gold standard" but "we wear the modern fiat surface, with the ancient substance underneath."
|
||||
- The denomination-as-bridge insight is in **§7a / §7a.1** (the three values: metallic / nominal
|
||||
/ commercial). The inversion preserves the *nominal* layer across the gold→fiat→FIATm arc;
|
||||
it returns the *metallic* layer; the *commercial* drift remains the value-discovery mechanism
|
||||
it always was.
|
||||
- The mechanism producing real BCH demand from inverted-fiat circulation is in **§8** (magical
|
||||
reversal). The inversion described here names *why this works at population scale*: the demand
|
||||
never has to recognise itself as demand for BCH; it can continue to identify as demand for
|
||||
dollars / euros / pesos, with the substrate doing the conversion invisibly.
|
||||
- The asymmetric checkmate is in **§8.1**. The inversion is the *structural root* of why the
|
||||
checkmate has the shape it has: the institution's own primary capture mechanism (denomination)
|
||||
is the substrate's own primary recruitment mechanism, and the institution cannot route around
|
||||
what it cannot identify as adversarial.
|
||||
|
||||
The public-facing primer (`wiki/sound-money-primer.md`) is allowed to project this into
|
||||
trajectory language — *"a trap for Keynesian economics and the fiat financial system"* — where
|
||||
the discipline permits projection. Within this design record, the structural form is what's
|
||||
recorded: **the inverted fiat is the genus, the denomination is the delivery vehicle, the
|
||||
substance is BCH, and the global fiat economy is the addressable population by construction.**
|
||||
|
||||
## 2. The on-chain-only line — token vs asset
|
||||
> The **USDT token's** truth lives off-chain (reserves); the on-chain token is a pointer to a
|
||||
> promise. The **USDm asset's** truth lives on-chain (locked BCH); the asset *is* the backing.
|
||||
|
|
@ -84,12 +243,21 @@ note is its own BCH; nothing to run on.
|
|||
USDm are **identical**, and USDm carried zero liquidation risk. CDP = leveraged consumption; USDm
|
||||
trades the leverage win for removal of the catastrophe.
|
||||
|
||||
## 7. The reverse trajectory — fiat decays, USDm hardens
|
||||
Gold→fiat removed backing step by step: fixed peg → devalue → float → **sever**. USDm runs it in
|
||||
reverse: floating DRA → tighten → **freeze the BCH rate** → USDm becomes the reference. The mirror is
|
||||
**structurally enforced** because the gold→fiat decay needed two things USDm removes:
|
||||
## 7. The reverse trajectory — fiat decays, USDm hardens (the 180° reversal)
|
||||
|
||||
| drove the decay | USDm's answer |
|
||||
**USDm is a 180° reversal of the historical arc.** Sound money was hollowed into fiat over
|
||||
**centuries** — coin clipping under Rome; bills of exchange; bank notes redeemable for specie;
|
||||
classical gold standard; Bretton Woods; the 1971 closing of the gold window; pure fiat. Each step
|
||||
removed one tether between the nominal note and the substance it claimed. The arc has a name —
|
||||
**the gold→fiat trajectory** — and it ran in one direction: *more discretion, less backing.*
|
||||
|
||||
USDm reverses it in a single covenant. **The same arc, walked backwards, on-chain.** Where
|
||||
gold→fiat moved through fixed peg → devalue → float → **sever**, USDm moves through floating DRA
|
||||
→ tighten → **freeze the BCH rate** → USDm becomes the reference. The reversal is
|
||||
**structurally enforced** — not a policy choice that can be revoked — because the two engines that
|
||||
drove the historical decay are the two things USDm removes:
|
||||
|
||||
| drove the historical decay | USDm's answer |
|
||||
|---|---|
|
||||
| **discretionary issuer** (chose each step) | **automated, genesis-fixed schedule** — no ongoing discretion |
|
||||
| **inflatable base** (print / sever) | **hard-capped BCH** — nothing to inflate or sever |
|
||||
|
|
@ -100,6 +268,330 @@ loss since 1913) gives a long-run **bias** toward appreciation — a bias, *not*
|
|||
peg" must mean **freeze the BCH rate**, never peg-to-live-$1 (which would reimpose the ceiling + a
|
||||
fractional pool).
|
||||
|
||||
**Why one covenant, not centuries.** The historical decay needed centuries because each step
|
||||
required political consensus, market acceptance of the next degradation, and time for memory of
|
||||
the prior tether to fade. The reversal needs none of that: a single deployment of a covenant that
|
||||
*is* the discipline. The discipline isn't a promise to be kept — it's the script the network
|
||||
enforces on the bytes themselves.
|
||||
|
||||
## 7a. Three values, ancient Greek coinage — the metallic / nominal / commercial framing
|
||||
|
||||
Ancient Greek coins had **three values** simultaneously: a **metallic value** (the worth of the
|
||||
metal in the coin — gold > silver > copper, in roughly that ratio), a **nominal value** (the face
|
||||
denomination stamped on the coin), and a **commercial value** (what it actually traded for in the
|
||||
market, which could float above or below either of the other two). The initial gold-silver ratio
|
||||
was 1:12; by 400 BC coins were the predominant means of exchange across the Greek world, without
|
||||
any single currency being imposed — regional preference emerged on its own, and the **Attic
|
||||
Tetradrachm (17 grams)** came to prevail with subdivisions (1/6 drachma = 1 obol) and multiples
|
||||
(decadrachma), while Sicilian colonies used the *liter* coin. Coins were struck with hammer and
|
||||
anvil, so the shape was rarely perfectly round and the image rarely perfect, but the metallic
|
||||
content was real and the denomination was honest.
|
||||
|
||||
**FIATm wears the same three values, made legible:**
|
||||
|
||||
| Greek coin | FIATm note | What it is on-chain |
|
||||
|---|---|---|
|
||||
| **Metallic value** (gold / silver / copper content) | **Backing value** | The actual BCH satoshis locked inside the note's UTXO. Verifiable on chain at any moment. |
|
||||
| **Nominal value** (the face stamp) | **Denomination** | "$1" / "€1" / "₹1" — the unit the user thinks in. A label, not a guarantee. |
|
||||
| **Commercial value** (market trade price) | **Market value** | What someone will give you for it now. Floats around — usually above — the nominal, depending on BCH price action. |
|
||||
|
||||
The historical claim FIATm makes — and the reason the Greek analogy is the right one — is that
|
||||
**the metallic value is no longer hidden**. A USDT holder knows the nominal value but the metallic
|
||||
value (reserves) is asserted off-chain, in private, by a counterparty; the commercial value
|
||||
(market price) sometimes diverges *downward* (USDC at $0.88 during SVB; Tether mini-runs) and the
|
||||
metallic value is unauditable in real time. A FIATm holder reads all three off chain: nominal from
|
||||
the genesis configuration, metallic from the satoshis in their own UTXO, commercial from whatever
|
||||
market thinks BCH × oracle-rate produces today. **All three values are public, simultaneous, and
|
||||
inspectable by anyone.**
|
||||
|
||||
The Greeks understood that a coin with three values is not a *defect*; it's a richer instrument
|
||||
than one with only a face number. Metal content was *the* anti-fraud mechanism (you can melt it
|
||||
and weigh it). Nominal denomination was the unit of account (you can use it for prices). Commercial
|
||||
value was the market's continuous re-evaluation against both. The combination produced 800 years
|
||||
of broadly stable monetary practice across a fragmented political geography — exactly the property
|
||||
modern fiat sacrificed when it discarded the metallic layer.
|
||||
|
||||
**FIATm restores the metallic layer in software, in the form that survives — not by re-pegging to
|
||||
gold, but by writing the substance into each unit's UTXO.** The denomination is preserved (you
|
||||
still think in dollars, euros, rupees); the metallic layer returns (BCH, hard-capped, in your own
|
||||
wallet); the commercial layer remains what it always was (market discovery). The three values are
|
||||
back; the coin is whole again.
|
||||
|
||||
**"Sound version of fiat money, interchangeable infrastructure."** The Greek coinage analogy is not
|
||||
just illustrative — it is the architectural statement. One template, many denominations, regional
|
||||
preference rather than political imposition. Whichever FIATm you choose to hold, the metal is the
|
||||
same metal underneath.
|
||||
|
||||
## 7a.1. The Artemision lineage — art of emission, universal substrate, and why the lag exists
|
||||
|
||||
§7a names *what* FIATm's three values are. This subsection names *where they come from*
|
||||
historically, *what makes the family architecture possible structurally*, and *why the §12
|
||||
controller's correction lag is the recognition of an ancient truth rather than a modern
|
||||
compromise*. The four registers — historical site, architectural craft, structural substrate,
|
||||
controller mechanism — turn out to be the same idea told four times.
|
||||
|
||||
### The historical site
|
||||
|
||||
Coinage as a category begins archaeologically at the **Artemision** — the Temple of Artemis at
|
||||
Ephesus, in ancient Ionia (western Anatolian coast). The temple's foundation deposits yielded the
|
||||
*Artemision hoard*: among the earliest electrum coins known to the historical record, contemporary
|
||||
with the Lydian invention of struck coinage under Alyattes and Croesus (~7th–6th c. BCE). The
|
||||
category was born at a sanctuary, in electrum (a natural gold-silver alloy), struck by hand into
|
||||
figured discs whose substance and image were unified at the moment of striking. **The wallet UI
|
||||
surface where new FIATm currencies are minted carries this name**: *Artemision* is the
|
||||
create/genesis surface in the shell (`shells/app/src/screens/ArtemisionScreen.tsx`,
|
||||
`design/mockups/artemision-tab.html`, `wiki/glossary.md`, and the rationale in
|
||||
`Parameters/MBA_Shares/naming-and-branding_FOR-design-record.md`). The genesis act in code carries the name of
|
||||
the genesis act in history.
|
||||
|
||||
### Art OF Emission — the *technē* reading
|
||||
|
||||
The wallet UI name carries a deliberate wordplay: **"Art Emission"** as the *technē* of emission —
|
||||
the *skilled practice* of bringing trustworthy value into being. In the Greek frame, *technē*
|
||||
(τέχνη) was the category of disciplined craft — sculptors, vase-painters, navigators, healers, and
|
||||
master die-cutters and minters belonged together in it. Coinage was a craft on par with the highest
|
||||
crafts of the period because the *practice* of emission was the load-bearing thing: who struck the
|
||||
die, with what discipline, on what substance, in what sanctuary. **The wordplay is structurally
|
||||
encoded into the asset taxonomy itself**: the first MBA class in the design is **DEA — *Direct
|
||||
Emission Asset***, which carries the *Emission* reading explicitly. The wallet surface and the
|
||||
canonical asset class name agree that emission is a practice with discipline, not a passive act.
|
||||
|
||||
### Ionia → Magna Graecia — plausible cultural lineage, *not* asserted etymology
|
||||
|
||||
The Greek poleis of Ionia (Ephesus, Miletus, Smyrna, Phocaea) were colonising founders of much of
|
||||
*Magna Graecia* — the Greek-speaking belt of southern Italy and Sicily (Cumae, Tarentum, Sybaris,
|
||||
Croton, Rhegium, Locri). The cultural influence of Greek-speaking southern Italy on early Rome is
|
||||
documented from at least the 6th–5th c. BCE: religious absorption via *interpretatio romana*
|
||||
(Artemis → Diana, Athena → Minerva), the alphabet reaching Rome through Greek-via-Etruscan, and
|
||||
minting practices in Magna Graecia predating and influencing Roman coinage. The Ionian *technē* of
|
||||
coinage — born at Artemision — travelled into the same cultural sphere that became Latin-speaking.
|
||||
|
||||
This is a **conceptual lineage**, plausible as cultural transmission. It is **not asserted as the
|
||||
formal etymological derivation** of Latin *ē-mittere*, which standard etymological dictionaries
|
||||
trace directly to PIE \*meit- without a Greek intermediary. The carrier wave of the *concept* is
|
||||
real; the *root* travelled separately. The Artemision↔Art-Emission resonance lives in the concept,
|
||||
not in the philology.
|
||||
|
||||
### Metal as universal substrate — and the FIATm equivalent
|
||||
|
||||
The Ancient Greek monetary system worked across a fragmented political geography *because the metal
|
||||
was a universal substrate*. An Athenian tetradrachm and a Corinthian stater had different art
|
||||
(Athena's owl, Pegasus, different cultural figures) but **the silver underneath was the same
|
||||
silver, judged by the same touchstone, traded at the same weight**. The art was the regional
|
||||
identity layer; the metal was the universal interchange medium; the gold-silver 1:12 ratio was the
|
||||
cross-rate between metals. You could trade any coin for any coin because there was a substrate
|
||||
underneath them that everyone agreed on. **The system did not need a central authority to enforce
|
||||
interchange because the metal itself enforced it.**
|
||||
|
||||
FIATm + ASM reconstructs this architecture directly:
|
||||
|
||||
| Ancient Greek coinage | FIATm + on-chain substrate |
|
||||
|---|---|
|
||||
| The metal (electrum/gold/silver/copper) — universal interchange medium under regional art | **BCH** — universal interchange medium under per-currency mark |
|
||||
| Regional gods/animals/figures stamped on each city's coinage — the cultural identity layer | **Per-currency category mark** (USDm / EURm / GBPm / JPYm / INRm / ARSm / TRYm) — the denomination identity layer |
|
||||
| The touchstone (whetstone, *ἀκόνη*) — the test that proves metal purity at the moment of trade | **Akone** — the verify surface in the wallet UI, where backing claims are tested on-chain (`wiki/glossary.md`, `Parameters/MBA_Shares/naming-and-branding_FOR-design-record.md`) |
|
||||
| The merchant — counterparty who validates each exchange | The **ASM** (atomic-swap market) — counterparty-less swap on the substrate; *"an ocean, not a pool"* (the *Poseidon* metaphor from the naming-and-branding doc) |
|
||||
| Regional preference without imposed currency | Per-currency preference without imposed FIATm |
|
||||
|
||||
The architecture's Greek-pantheon naming is not decorative. **Artemision** (where coinage is
|
||||
struck), **Akone** (where claims are tested), **Poseidon** (the substrate-ocean that carries
|
||||
exchange) directly maps the ancient practice onto the on-chain substrate. The wallet UI makes the
|
||||
historical genealogy a navigable surface; the design record makes the historical genealogy a
|
||||
structural statement.
|
||||
|
||||
### Why the §12 correction lag exists — the three-values derivation
|
||||
|
||||
The §7a three values — metallic, nominal, commercial — were never identical in ancient practice,
|
||||
and that was the design property, not a defect. The *metallic* value (silver content) was fixed at
|
||||
striking; the *nominal* value (face stamp) was set by the issuing city; the *commercial* value
|
||||
(market trade price) drifted continuously according to wear, debasement, regional demand, and
|
||||
merchant assessment. **The drift between the three values was the value-discovery mechanism.** A
|
||||
worn-down tetradrachm traded below face; a coin from a debased mint traded below its weight; a
|
||||
Sicilian decadrachma might command a premium where it was prized. The market read the drift and
|
||||
priced it. Debasement worked precisely by trying to break the lock between metallic and nominal
|
||||
value, which the market caught via commercial value drifting away.
|
||||
|
||||
**The §12 controller's correction lag exists for the same structural reason.** §4 fixes the
|
||||
metallic value at mint (locked BCH per unit, exact, never adjusted afterward); the denomination
|
||||
label preserves the nominal value (the unit still says "1 USDm" on its face); the commercial value
|
||||
is allowed to drift; and the §12 controller adjusts the *mint-time relationship* between metallic
|
||||
and nominal only when sustained, multi-signal evidence justifies it (the DART three-signal
|
||||
calculation + the 210k-mint catalyst + the §12b damping + the inner-guard layer). **The lag is not
|
||||
a damping artefact. It is the structural recognition that the three values were always in motion in
|
||||
ancient coinage, and any system that tries to freeze them either fails or breaks the
|
||||
value-discovery layer.** A system without lag would attempt to collapse all three values into one
|
||||
continuously — which is exactly the move debasement uses, and exactly the move that historically
|
||||
destroys monetary trust.
|
||||
|
||||
This derivation has two consequences carried into the rest of the record:
|
||||
|
||||
1. **The lag is *deliberate* (§7b) — not a trade-off accepted for simplicity, not a side-effect of
|
||||
damping.** It is the active mechanism the design imports from ancient practice.
|
||||
2. **The strength of the lag *scales with adoption* (§12a.2 catalyst, §17 issuance-scale).** Same
|
||||
principle as *"bias earned through adoption, not given at genesis"*: a brand-new FIATm currency
|
||||
has a small lag (immature symmetric controller); a currency that has earned many catalysts
|
||||
carries a stronger lag, structurally proportional to what its participants have contributed.
|
||||
The lag is *always on*, scaling continuously with cumulative-mint supply — there is no on/off
|
||||
switch.
|
||||
|
||||
### The continuous arc
|
||||
|
||||
§7a establishes the historical framing (three values, regional preference, hammer-and-anvil
|
||||
honesty); §7a.1 names the architectural lineage (Artemision birth-site, *technē* of emission,
|
||||
universal-metal-substrate, three-values→§12 lag derivation); §12 implements the lag mechanism
|
||||
(DART, catalyst, damping, time-doubling, inner guards); the wallet UI surfaces the operational
|
||||
vocabulary (Artemision for genesis, Akone for verify, Poseidon for liquidity, *Asterae Planitae*
|
||||
for the loading-screen star-birth metaphor). **The four registers are the same idea twenty-six
|
||||
centuries apart** — at the Artemision in ~7th c. BCE, in a public sanctuary, the *technē* of
|
||||
emission struck figured discs whose substance was real and whose art was honest; in the FIATm
|
||||
substrate in 2026 CE, the same act runs as on-chain code, with Akone as the touchstone, ASM as
|
||||
Poseidon's ocean, and the lag as the recognition that the three values were always in motion. The
|
||||
substrate is the touchstone; the art is the denomination; the substance is BCH; the *technē* of
|
||||
emission is the practice we now call **FIATm**.
|
||||
|
||||
## 7b. What this does for the holder — and the global scale of the population it matters to
|
||||
|
||||
The §0.5 / §7 / §7a framing is *structural* — what FIATm is. This section is *experiential* —
|
||||
what holding it does for a person, day by day, in their own local denomination. The structural
|
||||
machinery delivers a holder experience that is most dramatic in the regions where fiat is failing
|
||||
fastest.
|
||||
|
||||
### The holder's view in their own denomination
|
||||
|
||||
A person who holds a FIATm voucher in their local-currency denomination sees something they have
|
||||
never been able to see before in that denomination: the *face value* of the unit appreciating —
|
||||
not in some other currency they don't transact in, but **in the very money they pay rent and buy
|
||||
groceries with**. The mechanism is exactly the §0.5 properties, but read from the holder's chair
|
||||
rather than the architect's:
|
||||
|
||||
- The denomination on their unit ("100 ARSm" / "100 TRYm" / "100 USDm") **is the unit they think
|
||||
in** — their wallet, their invoices, their tax accounting, their grocery bill. The cognitive
|
||||
cost of holding is zero: it is *their* money, in their face value.
|
||||
- The backing is BCH — *not their local currency, not their banking system, not their state's
|
||||
treasury*. So the unit's commercial value (§7a's third value) **decouples from the local
|
||||
currency** the moment the local currency begins to depreciate.
|
||||
- They watch the decoupling on their own statement. The unit still says "100 ARSm" on its face,
|
||||
but **what 100 ARSm trades for, today, is what 100 ARS *would have* traded for at a stronger
|
||||
point in the currency's history** — the locked BCH carries the value forward through the fiat
|
||||
collapse.
|
||||
|
||||
This is the experience the §20a / §22 back-tests quantify. The 9-year USDm holder ended with
|
||||
$207 of purchasing power (mild). The 9-year **ARSm** holder ended with **15,804 ARS of commercial
|
||||
value vs 100 ARS in cash** (`scripts/sim-fiatm-historical.mjs`) — a 158× spread on the cash baseline.
|
||||
The TRYm holder: **24.8× cash**. The structural machinery is the same in every case; the holder
|
||||
*experience* scales with how badly the underlying fiat collapsed.
|
||||
|
||||
### Decoupling is observable on the holder's own device
|
||||
|
||||
The holder does not need to read a design record to see what is happening. A wallet that surfaces
|
||||
the §7a three values together — *face* (denomination), *real* (BCH × current oracle rate, in the
|
||||
local currency), and the *spread* between them — converts the entire reverse-trajectory thesis
|
||||
into a number that updates on screen as the local currency depreciates. **The visible inflation
|
||||
gauge.** The face value stays at 100 by definition; the real value rises; the spread is the
|
||||
empirical demonstration of §7 happening to *this user*.
|
||||
|
||||
### The rate-correction lag — what it IS and what it IS NOT
|
||||
|
||||
The rate-correction lag is a **deliberate design choice**, derived from the §7a / §7a.1 three-
|
||||
values architecture. It is **not a trade-off** accepted for controller simplicity, and it is
|
||||
**not a side-effect** of damping. The lag is the active mechanism by which **the FIATm system
|
||||
becomes more powerful as more people use it for payments** — empowering both the individual
|
||||
holder and the wider ecosystem. §7a.1 derives why the lag exists at all (the three values were
|
||||
always in motion in ancient coinage; any system that forces them to align instantaneously
|
||||
breaks the value-discovery layer); this subsection names what the lag delivers in operation.
|
||||
|
||||
**The mechanism.** The §12 controller's per-direction cadence + damping keep the on-chain mint
|
||||
rate *behind* sudden oracle shifts. During the lag window the controller rate is **better than
|
||||
the new equilibrium** — a new minter locks *more BCH per face-unit* than the oracle target
|
||||
implies. §12b's "BCH-crash bargain window for buyers" is the BCH-side case; against fiat
|
||||
collapse the same lag plays out on the fiat side, with the same deliberate effect.
|
||||
|
||||
**What this delivers:**
|
||||
|
||||
- **For the holder.** Every entry point in the FIATm life-cycle is empowered. The 2017
|
||||
vintage holder watches their voucher appreciate (§20a). The 2024 late entrant gets a
|
||||
*better-than-equilibrium* mint rate during a lag window. The hyperinflating-fiat user who
|
||||
only discovers FIATm after their currency lost most of its purchasing power **is not
|
||||
punished for arriving late** — the next lag window is structurally available to them.
|
||||
There is no "missed the boat" failure mode by design.
|
||||
- **For the ecosystem.** Synthetic-market noise (leverage, futures, fractional venues —
|
||||
everything the On-Chain-Only Philosophy calls *counterfeit until settled*) decomposes
|
||||
into gap windows the controller refuses to chase. The gap windows attract arbitrage;
|
||||
arbitrage demands real BCH to mint at the lagged rate; the real BCH demand strengthens
|
||||
the substrate. *Volatility becomes settlement.* This is the catalytic-converter mechanism
|
||||
developed as a labelled hypothesis in
|
||||
`Parameters/FIATm/catalytic-converter-hypothesis_FOR-testing.md` — Stage 1 simulation
|
||||
results in snapshots 0161/0162/0163, with corrections noted.
|
||||
- **For adoption.** Transactional use of FIATm by real merchants and consumers expands the
|
||||
arbitrage market that closes lag-window gaps. **The more people use FIATm for payments,
|
||||
the more powerful the lag-as-converter becomes.** The system does not require adoption
|
||||
to function; it rewards adoption with stronger systemic properties.
|
||||
|
||||
**Strength scales continuously with cumulative-mint supply via §12a.2's catalyst mechanism.**
|
||||
The lag is small at launch (immature symmetric controller, `N_up = N_down = 1`, `d = 10%` —
|
||||
the §12a.2 genesis row) and grows monotonically with each 210,000-cumulative-minted catalyst
|
||||
event. The mechanism is **always on**, scaled to what adoption has earned — there is no on/off
|
||||
switch; the strength curve is the same *"bias earned through adoption, not given at genesis"*
|
||||
principle as §12a.2 applied to the lag itself. A brand-new FIATm has a small lag-window
|
||||
appropriate to its small adoption history; a mature FIATm carries a structurally deeper lag
|
||||
appropriate to its accumulated participation. The §20a 9-year back-test shows this scaling
|
||||
through real cycles; chipnet-scale honest immature-state results are in snapshot 0163.
|
||||
|
||||
**The recurring bargain-window evidence.** `scripts/sim-fiatm-trajectory.mjs` walks the 9-year
|
||||
window month-by-month and flags every checkpoint where the controller is lagging the oracle by
|
||||
more than 5%. Across USDm, TRYm, ARSm the bargain frequency is **~25-30% of months** — the lag
|
||||
opens roughly every 2-4 months and lasts a few weeks at a time. **The catch-up window is
|
||||
recurring, not one-shot.** A user who hears about ARSm in Aug 2024 and joins during the Milei-
|
||||
aftermath lag (Aug 2024: −12.0% gap) is not "too late"; they got a mint that locked 12% more
|
||||
sats per ARS than the equilibrium implied, on top of all the future BCH appreciation against
|
||||
the still-collapsing peso.
|
||||
|
||||
**This is why FIATm is a population-scale instrument, not an early-adopter prize.** The
|
||||
controller's lag protects late entrants by structurally giving them a better entry rate during
|
||||
the same shocks that scared them into looking for alternatives in the first place — and the
|
||||
strength of that protection grows with how many *other* people are using the system.
|
||||
|
||||
### The global scale this matters to
|
||||
|
||||
The structural argument above is identical for every fiat. The *population* it serves is mostly
|
||||
the people whose fiat is currently misbehaving. Approximate, rough-order figures, the kind of
|
||||
sketch a design record can offer (not a market study):
|
||||
|
||||
- **Argentina** — ARS lost ~98.7% of USD-purchasing-power 2017→2026 (sim baseline). ~45 million.
|
||||
- **Turkey** — TRY lost ~91.7%. ~85 million.
|
||||
- **Egypt** — EGP lost ~80%+. ~110 million.
|
||||
- **Pakistan** — PKR lost ~65%+. ~240 million.
|
||||
- **Nigeria** — NGN lost ~80%+. ~225 million.
|
||||
- **Venezuela** — VES lost effectively all purchasing power (>99.99…%). ~28 million.
|
||||
- **Lebanon** — LBP lost >98%. ~5 million.
|
||||
- **Iran** — IRR lost ~85%+. ~88 million.
|
||||
- **Sudan, Ethiopia, Ghana, Sri Lanka, Zimbabwe, Myanmar, Laos, …** — each adds 10–110 million.
|
||||
|
||||
**On the order of 2–3 billion people live under currencies that are losing double-digit annual
|
||||
purchasing power.** For all of them, the cash they hold in their pocket *is* the depreciating asset
|
||||
in §7's table. FIATm is not a hedge against an abstract risk — it is the *direct fix* for the
|
||||
problem the local-currency user already lives with.
|
||||
|
||||
A face-value of "100" that *gains commercial value while the local currency falls* is not a
|
||||
financial product; it is a **monetary reform**, executed not by the state but by the holder, one
|
||||
mint at a time. That is the global story §7 implies and this section makes explicit.
|
||||
|
||||
### Honest limits to this framing
|
||||
|
||||
- Adoption is voluntary, never automatic. State-currency users may not have BCH on hand at the
|
||||
moment of mint — they need to acquire it first (an on-ramp problem, not a FIATm problem).
|
||||
- FIATm's denomination is a *labelling* convenience; the holder still has full BCH exposure (§3 /
|
||||
§10). For someone whose subsistence requires bounded local-currency-denominated spending in
|
||||
the next 30 days, holding FIATm carries the same volatility risk as holding BCH — *the
|
||||
appreciation is not free of variance*. The honest pitch is "preservation against multi-year
|
||||
collapse," not "stable for tomorrow's groceries."
|
||||
- The catch-up windows exist but are not signalled to the holder by the on-chain rate itself
|
||||
(they have to read the oracle target separately). A wallet UI that surfaces the gap as a
|
||||
"good time to mint" signal closes that loop, but is a wallet feature, not a contract property.
|
||||
- The §22 calibration of the controller's cadence + damping (snapshots 0158 + this session's
|
||||
follow-ups) determines *how long and how deep* the catch-up windows are. The 25–30% bargain
|
||||
frequency is a function of the suggested defaults; per-currency calibration will shift it.
|
||||
|
||||
## 8. The magical reversal
|
||||
> **USDm converts dollar-denominated demand into demand for real, on-chain BCH** (you must lock real
|
||||
> coins to mint it). **USDT converts dollar demand into demand for paper** (off-chain IOUs).
|
||||
|
|
@ -108,6 +600,64 @@ The stablecoin category — today the largest engine of *counterfeit* on-chain v
|
|||
engine of *real* on-chain settlement. This is "use is the solvent" (Block Size Wars thesis): USDm
|
||||
makes BCH spendable as a dollar-denominated medium without converting it to a paper claim.
|
||||
|
||||
### 8.1. The institutional-action asymmetry — the magical reversal at full structural strength
|
||||
|
||||
§8 names the magical reversal in its simplest form: dollar-demand → demand for real BCH. This
|
||||
subsection names what that reversal looks like at full structural strength — once §7 (reverse
|
||||
trajectory), §9 (trust surface), §12 (controller), §16 (oracle failure benign), §17 (issuance
|
||||
scale), and §19 (freeze) are read together. The reading is **not** a trajectory prediction (per
|
||||
the corpus discipline, *"enthusiasm attaches to the math model, not predicted market
|
||||
outcomes"*). It is a *structural claim* about which directions of institutional action can move
|
||||
the FIATm substrate — and the structural answer is: **none of the available directions move it
|
||||
adversely.** The substrate is unidirectional. Every column of the matrix below reads
|
||||
*strengthens* or *no effect* — never *weakens*.
|
||||
|
||||
| Institutional action | Why it cannot affect real FIATm | What it does to the real substrate |
|
||||
|---|---|---|
|
||||
| Refuse to list FIATm on CEXes | ASM provides on-chain what listings provide off-chain (price discovery, liquidity, cross-asset trade); adoption needs no institutional permission | **No effect** — bootstrap proceeds invisibly (the *invisible-bootstrap* property) |
|
||||
| Print more fiat (USD, EUR, JPY, ...) | Substrate covenant unchanged; oracle tracks the new fiat price directly | **Strengthens** — fiat debasement raises BCH/fiat; existing FIATm holders' BCH appreciates in fiat terms (the §7 reverse trajectory's empirical engine, confirmed in the §20a 9-year back-test) |
|
||||
| Print more synthetic stablecoins (USDT-style) | Akone verification gate keeps them in their own category; the on-chain real-economy market and the off-chain synthetic-speculator market are *disjoint* by structural design | **Strengthens** — visible paper proliferation makes the real-vs-synthetic distinction more legible to the broad population |
|
||||
| Print "synthetic-USDm" perpetuals on CEXes | Cannot enter the on-chain mechanism without becoming real (the verification gate is binary — pass the touchstone or stay off-substrate); synthetic-USDm is structurally equivalent to USDT/USDC/DAI in the existing paper-stablecoin category | **Strengthens** — adds to the visible-paper category alongside USDT; accelerates migration of users seeking real value |
|
||||
| Regulatory action against on-chain BCH | Cannot disable BCH consensus; covenant code does not exist within any jurisdiction's exclusive reach (the §9 trust-surface property) | **Strengthens** — confirms the substrate's resistance to capture |
|
||||
| Inaction | Nothing | **Strengthens** — adoption grows; controller matures via §12a.2 catalysts; catalytic-converter mechanism strengthens with cumulative-mint supply |
|
||||
|
||||
**The structural moats stack three deep:**
|
||||
|
||||
1. **Pre-launch invisibility** — no listing gates adoption (ASM replaces what listings provide).
|
||||
2. **Post-launch immunity** — institutions can copy the FIATm name but not the substrate
|
||||
property. Akone is the operational enforcer: any claim attempting to participate in the
|
||||
on-chain mechanism must pass the touchstone, and the only way to pass it is to be real.
|
||||
3. **In-category exclusivity** — only on-substrate FIATm exhibits §4 redemption, §16
|
||||
oracle-failure-benign, §7b lag-as-catch-up, and the catalytic-converter mechanism.
|
||||
Synthetic competitors operate in the existing paper-stablecoin category alongside
|
||||
USDT/USDC/DAI; **they cannot enter the new on-chain-backed category that FIATm occupies
|
||||
alone**, because the substrate gate is structural, not market-share-driven.
|
||||
|
||||
**The historical mirror.** The gold→fiat arc over 1914–1971 was itself an asymmetric process
|
||||
*in the opposite direction*: every institutional action available to states pushed toward
|
||||
unbacking the currency, and inaction also tended toward unbacking (specie reserves drained
|
||||
naturally as fiat printing exceeded gold inflow). Once the system was structurally configured
|
||||
to favor debasement, every direction of state action moved it further toward synthetic.
|
||||
Nothing the public could do reversed it — the structural property of the system was
|
||||
unidirectional toward fiat. **FIATm is the same shape, inverted.** Every direction of
|
||||
institutional action on a hard-capped substrate with a verification gate moves the system
|
||||
toward real backing — because the substrate's verification gate (Akone) is the structural
|
||||
inverse of the central-bank-printing seam that drove the historical decay. **The §7
|
||||
reverse-trajectory thesis carries this institutional asymmetry as its terminal implication.**
|
||||
State action drove the descent; substrate action — which includes *everyone using it*, not
|
||||
just an issuer — drives the ascent.
|
||||
|
||||
**Discipline boundary.** The asymmetric checkmate is a *structural claim*, partially confirmed
|
||||
by simulation (catalytic-converter cross-substrate test, snapshot 0162 with corrections in
|
||||
0163; supply-driven maturation, snapshot 0163; 9-year historical back-test, §20a) and
|
||||
partially open empirically (adoption growth at population scale is still subject to the test
|
||||
of history, not of the design). The structural claim is what §8 implies when read at full
|
||||
strength; **whether** the trajectory it makes possible actually realises depends on adoption,
|
||||
on-ramps, broad population awareness, the visible-inflation gauge of §7a doing its work, and
|
||||
factors entirely outside the design. The design has done its job by removing the failure modes
|
||||
that could have made the outcome contingent on institutional permission. *Whether* the outcome
|
||||
arrives, and *how fast*, is not a design property — and is not a prediction this record makes.
|
||||
|
||||
## 9. Trust surface
|
||||
> Counterparty and institutional trust are **gone**. What remains — a far smaller surface — is **BCH
|
||||
> consensus**, the **immutable covenant code** (D-1/D-2 verifiable), and a **price oracle at mint
|
||||
|
|
@ -130,6 +680,13 @@ ownership, transfer) is fully on-chain; the oracle only corrects/adjusts the pri
|
|||
|
||||
# PART II — THE PRICE-ADJUSTMENT MECHANISM
|
||||
|
||||
> **Currency-agnostic.** The price-adjustment mechanism (oracle stack, five-layer controller, TVL
|
||||
> correction, maturity ladder, oracle-set governance) is the same for every FIATm currency. The
|
||||
> per-currency configuration is just (a) the oracle's public key (BCH/USD vs BCH/EUR vs …), (b) the
|
||||
> denomination granularity, and (c) the calibration of §22's parameters against that currency's
|
||||
> volatility profile. The worked example throughout uses USDm (BCH/USD); the prose says "BCH/USD"
|
||||
> for readability. Read it as "BCH/X" where X is the FIATm's denomination currency.
|
||||
|
||||
## 11. The problem
|
||||
Mint pricing needs a BCH/USD rate that is (a) reasonably current, (b) **capture-resistant**, and (c)
|
||||
adjusted **only when warranted** (not chasing noise). Redemption never needs it. The design is a
|
||||
|
|
@ -545,6 +1102,93 @@ humans do coarse legitimacy adjudication with external knowledge.* The human que
|
|||
("which cluster matches reality?"), which is why it's reliable; humans don't out-measure the oracles,
|
||||
they catch gross capture.
|
||||
|
||||
## 14a. Composed oracle for non-USD FIATm — BCH/USD × USD/X
|
||||
|
||||
§14 above describes the integrity stack for *a single* BCH/X price feed. For USDm the assumption
|
||||
is benign: BCH/USD has the deepest, most-liquid spot markets, and a competent BCH/USD oracle is
|
||||
a known engineering problem. For **non-USD FIATm** (EURm chipnet-validated; GBPm/JPYm/INRm
|
||||
chipnet-validated; **ARSm/TRYm and most-of-the-world FIATm prospective**) the assumption breaks:
|
||||
there is no deep BCH/ARS or BCH/TRY spot market. The oracle has to be *composed* from a BCH/USD
|
||||
spot feed and a USD/X foreign-exchange feed.
|
||||
|
||||
This section names three composition options and the trust-surface trade-off between them. None
|
||||
require changes to the §14 integrity stack — that stack applies to each feed independently.
|
||||
|
||||
### Option A — single-feed, off-chain composition (status quo today)
|
||||
|
||||
The oracle operator fetches BCH/USD and USD/X separately, multiplies them, signs the product as
|
||||
the BCH/X price, and publishes a normal §14 message. The on-chain contract verifies one signature.
|
||||
|
||||
- **Pros:** The simplest option. Zero contract changes. The covenant already deployed for
|
||||
USDm/EURm/GBPm/JPYm/INRm handles ARSm/TRYm immediately — only the off-chain composition logic
|
||||
in the oracle operator changes. Today's `DeviantOracleMBA` contract is in this regime.
|
||||
- **Cons:** The composition is *opaque on chain*. If the oracle operator misreports USD/X (lies
|
||||
about the FX rate while reporting BCH/USD honestly), no on-chain observation can catch them.
|
||||
The §14 multi-oracle cluster check helps — if multiple operators report different BCH/X,
|
||||
cluster integrity catches the divergence — but the *intermediate inputs* are not auditable.
|
||||
- **When to use:** Bootstrap phase. The §14 layered defence over a small set of independent
|
||||
composing operators is adequate; honest operators with public methodology + a sortition
|
||||
reputation layer is the §19 launch posture.
|
||||
|
||||
### Option B — two-feed, on-chain composition
|
||||
|
||||
The mint transaction includes **two** signed messages — one from a BCH/USD oracle and one from a
|
||||
USD/X (FX) oracle — and the covenant verifies both signatures and computes the product on chain.
|
||||
The price field used to compute backing sats is `floor(satsPerUsd × fxRate / 10⁴)` or similar
|
||||
(decimal handling tbd). One additional `checkDataSig` per mint; one additional 16-byte data
|
||||
field per mint.
|
||||
|
||||
- **Pros:** Composition is *transparent on chain*. The BCH/USD oracle can be *one* well-known
|
||||
high-integrity oracle set serving every non-USD FIATm — large pool of competent operators,
|
||||
shared diligence cost. The FX oracle can be smaller and specialised per currency; a USD/ARS
|
||||
oracle is a smaller market with smaller pools but it doesn't need to also know BCH price. The
|
||||
attack surface is *partitioned*: corrupting BCH/X requires corrupting both pools, and each pool
|
||||
is the §14 stack independently.
|
||||
- **Pros:** A user can independently audit either feed against external sources after the fact
|
||||
(the signed messages are on chain).
|
||||
- **Cons:** A new covenant variant (`DeviantOracleMBA_Composed.cash`) — one more compiled
|
||||
artifact to register, verify, and ship. Higher per-mint transaction size and CPU. Two oracle
|
||||
sets to operate.
|
||||
- **When to use:** Once chipnet has demonstrated the §14 stack at scale; mainnet launch of
|
||||
non-USD FIATm should default to Option B. Option A remains available for currencies where the
|
||||
FX feed is genuinely a single shared infrastructure (e.g. EUR/USD has deep markets too).
|
||||
|
||||
### Option C — single-feed, multi-source attested
|
||||
|
||||
The oracle operator publishes a *24-byte* message — `(timestamp, sequence, contentSequence,
|
||||
satsPerUsd, fxRate, satsPerLocalUnit)` — instead of the standard 16-byte. The chain verifies one
|
||||
signature but the three intermediate values are *all on chain*; verifiers can independently check
|
||||
that `satsPerLocalUnit == satsPerUsd / fxRate × 10⁴`.
|
||||
|
||||
- **Pros:** Composition is on-chain auditable *without* requiring two signatures. Tx cost is
|
||||
marginal (8 extra bytes per oracle message). Same covenant template as today — just an
|
||||
alternative message format.
|
||||
- **Cons:** Same operator still signs both values, so corruption is single-key. The audit catches
|
||||
*math errors and inconsistencies*, not *lying operators*. Less defended than Option B.
|
||||
- **When to use:** A useful intermediate during the bootstrap phase — better than Option A in
|
||||
forensic auditability, lower complexity than Option B.
|
||||
|
||||
### Recommendation
|
||||
|
||||
- **Now (chipnet) → Option A**: existing `DeviantOracleMBA` template handles ARSm/TRYm without
|
||||
contract changes. Tx-level proof is the immediate need (verifying the family-property claim).
|
||||
- **Pre-mainnet → Option B**: ship `DeviantOracleMBA_Composed.cash`, deploy the BCH/USD oracle
|
||||
pool as shared infrastructure for the non-USD FIATm family, deploy per-currency FX oracle
|
||||
pools.
|
||||
- **Option C** is documented as a forensic-audit improvement available for any non-Option-B
|
||||
deployment that wants the §14 cluster check to extend to intermediates.
|
||||
|
||||
### What §14a does NOT change
|
||||
|
||||
- **The §14 integrity stack** (median + spread + cluster + continuity + persistence + bounds +
|
||||
sortition + freeze) applies *to each feed* in Option B. Composition does not create a new
|
||||
failure mode beyond the existing stack — it just means the stack is applied twice.
|
||||
- **The §16 oracle-failure-is-benign property** holds regardless of composition option. Redemption
|
||||
is still P2PKH-only; the holder still recovers their locked BCH whether the oracle is alive or
|
||||
dead, single-feed or composed.
|
||||
- **The §19 freeze** retires the oracle entirely; in the end-state the composition question
|
||||
becomes irrelevant.
|
||||
|
||||
## 15. Coordinated-majority defense (how the layers compose)
|
||||
A coordinated, stable, false majority forms the largest tight cluster — no pure aggregation rule sees
|
||||
through it. It is defeated by the *combination*: **continuity + cap** forbid the jump (reduce it to a
|
||||
|
|
@ -724,12 +1368,22 @@ outside diversity only later, from protocol revenue, if the operator set proves
|
|||
- EURm + **atomic cross-asset swap** (snapshot 0137).
|
||||
- 6-asset market, **111 swaps** (snapshot 0138).
|
||||
- `PegState` (single-layer epoch recalibration) — compiled; `SortitionBeacon` — proven (0133).
|
||||
- Multi-currency chipnet validation: USDm, EURm, **GBPm + JPYm + INRm** (5 BCHm currencies live on one template, snapshot 0144).
|
||||
- **Merchant POS dApp module** (`src/merchant-pos/`) — accepts any BCHm voucher, settles in any merchant fiat, surfaces face-vs-real spread as visible inflation gauge (snapshot 0144).
|
||||
- Multi-currency chipnet validation: USDm, EURm, **GBPm + JPYm + INRm** (5 FIATm currencies live on one template, snapshot 0144).
|
||||
- **Merchant POS dApp module** (`src/merchant-pos/`) — accepts any FIATm voucher, settles in any merchant fiat, surfaces face-vs-real spread as visible inflation gauge (snapshot 0144).
|
||||
- **Five-layer controller simulator** (`scripts/sim-usdm-controller.mjs`) — five scenarios (calm growth / rally / crash / flash event / adoption boom) confirming the per-direction dynamics designed in §12 (snapshot 0147).
|
||||
- **9-year historical back-test** (`scripts/sim-usdm-historical-bch.mjs`) — applies the five-layer controller to approximate BCH/USD prices from Aug 2017 BCH fork through Jun 2026 with a phase-based adoption curve; see §20a for findings (snapshot 0148).
|
||||
|
||||
## 20a. Historical back-test findings (Aug 2017 → Jun 2026)
|
||||
## 20a. Historical back-test findings — USDm worked example (Aug 2017 → Jun 2026)
|
||||
|
||||
> **Scope of this section.** The back-test is **USDm-specific**: it uses approximate BCH/USD prices
|
||||
> from the Aug 2017 BCH fork through Jun 2026, with a plausible adoption curve for *that*
|
||||
> instance. The **method** generalizes to any FIATm — replay the controller against
|
||||
> BCH/EUR / BCH/GBP / BCH/JPY / BCH/INR (or any state currency with sufficient historical price
|
||||
> data) and the same machinery produces the equivalent table. **High-inflation currencies (ARS,
|
||||
> TRY, VES, ZWL, …) are an especially interesting per-currency back-test**: against a hyperinflating
|
||||
> fiat, FIATm's bias toward appreciation compounds with the *fiat's* loss of purchasing power, so
|
||||
> the holder-outcome table should look qualitatively different from USDm's. That work is open
|
||||
> (snapshot 0150, Open items: per-currency back-tests).
|
||||
|
||||
The §12 five-layer controller applied to ~9 years of approximate historical BCH prices, with a
|
||||
plausible adoption curve, reaches the asymmetric pro-hold/buy end-state organically through real
|
||||
|
|
@ -860,7 +1514,14 @@ covenant** = a DIY decentralized oracle on BCH, plus the novel human-adjudicatio
|
|||
|
||||
---
|
||||
|
||||
# APPENDIX B — BCH/USD volatility & first-pass calibration
|
||||
# APPENDIX B — BCH/USD volatility & first-pass calibration (USDm worked example)
|
||||
|
||||
> **Per-currency note.** The volatility analysis below uses **BCH/USD** because that pair has the
|
||||
> deepest, most-liquid historical data. The *method* is identical for any FIATm — re-run
|
||||
> `scripts/analyze-bch-volatility.mjs` against BCH/EUR / BCH/GBP / BCH/JPY / BCH/INR / BCH/ARS / …
|
||||
> to produce per-currency calibration tables. Currencies with materially different volatility
|
||||
> profiles (notably the high-inflation set) will yield different deadband / persistence-K / cap
|
||||
> settings at genesis — that's expected and is exactly what §22's calibration program is for.
|
||||
|
||||
Empirical input for the genesis-fixed parameters (§12), so they're chosen, not guessed. Source:
|
||||
Binance BCH/USDT — **1000 daily candles (~2.7 years)** + intraday 5-min resampled to 10-min. Script:
|
||||
|
|
@ -910,8 +1571,14 @@ the constants. The numbers above are the right shape, not the final values.
|
|||
### Cross-references
|
||||
- `the_on-chain-only_design_philosophy_FOR-reference.html` (token-vs-asset / counterfeit-vs-real).
|
||||
- `blocksize-war_…` (use-is-the-solvent).
|
||||
- Contracts: `DeviantOracleMBA` · `DeviantOracleMBAFloor` · `PegState` · `SortitionBeacon` ·
|
||||
`CitizenToken` · `DeviantOpenMintFT`.
|
||||
- Snapshots 0133 (sortition beacon), 0136 (USDm round-trip), 0137 (EURm + atomic cross), 0138 (market
|
||||
+ 111 swaps). ADR-0028 / ADR-0033 (*secured ≠ backed* → CDP stablecoins are tokens).
|
||||
- Contracts: `DeviantOracleMBA` (universal FIATm template) · `DeviantOracleMBAFloor` · `PegState` ·
|
||||
`SortitionBeacon` · `CitizenToken` · `DeviantOpenMintFT`.
|
||||
- Snapshots 0133 (sortition beacon), 0136 (USDm round-trip), 0137 (EURm + atomic cross-asset swap),
|
||||
0138 (6-asset market, 111 swaps), 0144 (GBPm+JPYm+INRm + merchant POS dApp across the family),
|
||||
0147 (five-layer controller + simulator), 0148 (USDm 9-year back-test). ADR-0028 / ADR-0033
|
||||
(*secured ≠ backed* → CDP stablecoins are tokens).
|
||||
- Modules: `src/merchant-pos/` (FIATm-agnostic POS), `scripts/sim-usdm-controller.mjs`,
|
||||
`scripts/sim-usdm-historical-bch.mjs`, `scripts/chipnet-multicurrency-mba-test.mjs`.
|
||||
- Diagram report: `usdm-and-market_diagram-report.html`.
|
||||
- Per-currency overlay (open): per-FIATm calibration of §22's parameters; per-FIATm 9-year
|
||||
back-test analogue of §20a (USDm done; EURm/GBPm/JPYm/INRm and the high-inflation set open).
|
||||
867
Parameters/FIATm/fiatm_synthesis_FOR-reading-first.md
Normal file
867
Parameters/FIATm/fiatm_synthesis_FOR-reading-first.md
Normal file
|
|
@ -0,0 +1,867 @@
|
|||
# FIATm — Complete Synthesis
|
||||
|
||||
> **Reading first.** This document is the single-source overview of FIATm — what it is, how it
|
||||
> works, what the structural claims are, and what's still open. It synthesizes the FIATm design
|
||||
> record, the catalytic-converter hypothesis, the wallet-UI architectural naming, and the
|
||||
> structural elaborations developed across the session that produced snapshot 0163. It is
|
||||
> deliberately self-contained for a reader who wants the full picture in one pass, and it
|
||||
> cross-references the corpus rather than duplicating it.
|
||||
>
|
||||
> **Audience.** A technically-engaged reader, a future session needing re-orientation, or the
|
||||
> author at a later date. Public-facing material lives in `wiki/sound-money-primer.md`; that
|
||||
> document is allowed to project; *this* document describes mechanism and stays inside the
|
||||
> corpus discipline (*"enthusiasm attaches to the math model, not predicted market outcomes"*).
|
||||
>
|
||||
> **Date:** 2026-06-15 (FIATm synthesis, post snapshot 0163).
|
||||
> **Companion files in this folder:**
|
||||
> - `fiatm_complete-design_FOR-design-record.md` — the canonical design record (§0–§22 + appendices).
|
||||
> - `catalytic-converter-hypothesis_FOR-testing.md` — the labelled hypothesis with structural elaboration.
|
||||
> - `usdm_sound-money-note_FOR-design-record.md` — the original USDm note (absorbed into the design record; retained as historical artefact).
|
||||
> - `usdm-and-market_diagram-report.html` — the USDm/market diagram report.
|
||||
> - `README.md` — folder index.
|
||||
> - `transcripts/` — verbatim session logs + design-journey narrative (gitignored).
|
||||
|
||||
---
|
||||
|
||||
## 1. What FIATm is, in one paragraph
|
||||
|
||||
FIATm is a family of fiat-denominated, on-chain, base-layer-backed sound-money notes built on
|
||||
Bitcoin Cash. Each unit is *self-backed* — the BCH that backs a "1 USDm" or "1 ARSm" lives in
|
||||
that unit's own UTXO, locked at the moment of mint, redeemable at any time by the holder's own
|
||||
P2PKH spend without any oracle, intermediary, or permission. The mint-time rate is set by an
|
||||
oracle through a five-layer controller (§12); the redemption is unconditional and trustless.
|
||||
There is no shared reserve, no fractional-reserve pool, no issuer with a back office, no
|
||||
counterparty risk, no liquidation trigger, and no over-collateralization. The fiat label
|
||||
(USD, EUR, ARS, TRY, …) is a denomination convention; the substance is real BCH; the unit's
|
||||
market value floats around its label, usually above. A FIATm note is *sound, not stable* —
|
||||
floored in hard money, uncapped in fiat, redeemable without permission. It is structurally
|
||||
inseparable from its substrate: ASM (atomic-swap market) for friction-less interchange, MBA
|
||||
(`DeviantOracleMBA` covenant) for the per-unit backing, and BCH base layer for the substance.
|
||||
|
||||
### 1a. The inversion — surface fiat, underneath sound (§1a)
|
||||
|
||||
The cleanest expression of what FIATm structurally *is*: an **inverted fiat**. Historically,
|
||||
fiat currency was *backed by* sound money (gold/silver) — the substance was real, the face was
|
||||
the political wrapping. The 1914–1971 arc severed the substance from the face, leaving the face
|
||||
alone as the modern unit-of-account. **FIATm returns the substance and re-couples it through
|
||||
the same fiat face value** — the exact inversion of the historical arrangement.
|
||||
|
||||
| Layer | Historical fiat (post-1971) | USDT / USDC / DAI | **FIATm (inverted fiat)** |
|
||||
|---|---|---|---|
|
||||
| Surface — denomination | Fiat face value | Same fiat face value | Same fiat face value |
|
||||
| Underneath — what backs it | Nothing (political fiat) | Off-chain reserves (paper claim) | **BCH locked in the unit's UTXO** |
|
||||
| Relationship | Surface *is* the unit | Surface *claims* the underneath | **Surface *carries* the underneath** |
|
||||
|
||||
The naive reading sees FIATm as "a fiat-denominated stablecoin." The actual structure is the
|
||||
inverted relationship: **the BCH is the primary thing; the fiat face is the delivery vehicle**.
|
||||
The substrate borrows the institution's own UI (denomination) to deliver real BCH backing to a
|
||||
population that already thinks in their local currency.
|
||||
|
||||
**Three structural consequences** (full development in §1a of the design record):
|
||||
1. **Denomination is not a threat surface** — institutions cannot identify FIATm as adversarial
|
||||
through its denomination because FIATm is denominated in *their* currency.
|
||||
2. **The primary monetary tool — printing — strengthens FIATm** — fiat debasement raises BCH
|
||||
in fiat terms; the central bank's defensive tool recruits new BCH demand. Applies
|
||||
independently and identically to **every fiat the family covers** (Fed action strengthens
|
||||
USDm; ECB action strengthens EURm; Central Bank of Argentina action strengthens ARSm; etc.).
|
||||
3. **Cognitive on-ramp is zero** — users keep their denomination, just change what backs it.
|
||||
The substrate is operationally invisible at the user-facing layer.
|
||||
|
||||
**Global scope by construction.** The inversion applies independently to every FIATm currency
|
||||
(USDm, EURm, GBPm, JPYm, INRm, ARSm, TRYm + every future state currency). The family addresses
|
||||
the **global fiat economy**, not the dollar economy. **A central bank facing FIATm in its own
|
||||
denomination faces the same structural inversion as every other central bank, on the same
|
||||
substrate, simultaneously.** No jurisdiction escape.
|
||||
|
||||
The §8.1 institutional-action asymmetry is the operational consequence of this structural
|
||||
inversion at family scale. The §7 reverse-trajectory thesis is the historical mirror. The
|
||||
§7a + §7a.1 three-values architecture names which layer survives across the gold→fiat→FIATm
|
||||
arc (the nominal layer) and which is restored (the metallic layer). The §8 magical reversal is
|
||||
the *mechanism* the inversion produces. **All four are facets of the single inverted-fiat
|
||||
structure §1a names.**
|
||||
|
||||
The public-facing primer is allowed to project this into trajectory language — *"a trap for
|
||||
Keynesian economics and the fiat financial system"* — where the discipline permits projection.
|
||||
Within the design record discipline: **the inverted fiat is the genus, the denomination is the
|
||||
delivery vehicle, the substance is BCH, and the global fiat economy is the addressable
|
||||
population by construction.**
|
||||
|
||||
---
|
||||
|
||||
## 2. The six defining properties (the family-level summary)
|
||||
|
||||
These are the §0.5 family-level properties of FIATm, expressed once for the whole family. Every
|
||||
FIATm currency exhibits all six by construction.
|
||||
|
||||
1. **State-currency-agnostic.** Any sovereign or supra-sovereign fiat denomination (USD, EUR,
|
||||
GBP, JPY, INR, ARS, TRY, …) can be minted as a FIATm. The contract template is the same; the
|
||||
per-currency configuration is just (a) the oracle's public key, (b) the denomination
|
||||
granularity, and (c) per-currency calibration of §22's parameters.
|
||||
2. **Base-layer backed.** Every unit holds real BCH inside its own UTXO. No shared reservoir,
|
||||
no fractional pool, no off-chain reserve attestation. Strip the surroundings and the unit
|
||||
still works.
|
||||
3. **Atomically swappable.** Between FIATm currencies (USDm ↔ EURm at oracle ratios; chipnet-
|
||||
validated in snapshot 0137) and back to BCH at any time, in a single covenant spend, with no
|
||||
counterparty consent required for the exit. The whole exchange cycle runs on-substrate.
|
||||
4. **Dynamic Rate Asset with correction mechanisms.** The mint-time rate floats with the
|
||||
oracle inside a five-layer adaptive controller (§12) that bounds volatility, dampens noise,
|
||||
and ratchets asymmetric pro-hold bias through real adoption rather than at genesis.
|
||||
5. **No liquidation trigger** *(unlike CDPs).* A FIATm unit is settled at mint, not an open
|
||||
debt. Nothing can liquidate it. No price drop in BCH can take your BCH away.
|
||||
6. **No over-collateralization** *(unlike CDPs).* 100% capital-efficient: $1 of BCH locked
|
||||
mints $1-equivalent of FIATm. CDPs require 110–200% collateral to absorb their liquidation
|
||||
tail; FIATm has no tail to absorb.
|
||||
|
||||
---
|
||||
|
||||
## 3. The chipnet-validated family (live on chain)
|
||||
|
||||
Seven FIATm currencies are validated on chipnet today, all running on the same
|
||||
`DeviantOracleMBA` contract template. No fork, no per-currency contract change — only the
|
||||
oracle pubkey + denomination differ.
|
||||
|
||||
| Instance | Status | Oracle | Genesis snapshot |
|
||||
|---|---|---|---|
|
||||
| **USDm** | chipnet-validated · worked example throughout | BCH/USD | 0136 |
|
||||
| **EURm** | chipnet-validated · atomic cross-asset swap with USDm | BCH/EUR | 0137 |
|
||||
| **GBPm** | chipnet-validated | BCH/GBP | 0144 |
|
||||
| **JPYm** | chipnet-validated | BCH/JPY | 0144 |
|
||||
| **INRm** | chipnet-validated | BCH/INR | 0144 |
|
||||
| **ARSm** | chipnet-validated | BCH/ARS (composed) | 0160 |
|
||||
| **TRYm** | chipnet-validated | BCH/TRY (composed) | 0160 |
|
||||
| *(future state currencies)* | — | BCH/X | — |
|
||||
|
||||
**Future deferred**: **VESm, ZWLm** — both currencies redenominated during the 2017→2026
|
||||
window (VES dropped 11 zeros across Aug 2018 + Oct 2021 redenominations; ZWL was replaced by
|
||||
ZiG in Apr 2024 at 13.56 ZWL per ZiG). A single monthly BCH/X series can't represent them
|
||||
honestly; the right treatment is a piecewise sim with explicit redenomination breaks. Flagged
|
||||
for follow-up (snapshot 0159).
|
||||
|
||||
**Dust-floor caveat**: at current-era hyperinflated BCH/ARS spot (~750k ARS per BCH, peso at
|
||||
~1,300/USD), 1 ARS ≈ 133 sats — below the 546-sat CashTokens dust floor. Real-world deployment
|
||||
of deep-collapse currencies needs a denomination strategy (larger face-units per atomic, or
|
||||
oracle-epoch denomination). The chipnet test used middle-of-window plausible rates that
|
||||
sidestep the issue. Flagged in snapshot 0160.
|
||||
|
||||
---
|
||||
|
||||
## 4. The reverse trajectory — fiat decays, FIATm hardens (§7)
|
||||
|
||||
The history of money is a one-way arc: sound money was hollowed into fiat over centuries.
|
||||
Roman silver dilution → bills of exchange → bank notes redeemable for specie → classical gold
|
||||
standard → Bretton Woods → 1971 Nixon shock → pure fiat. Each step removed one tether between
|
||||
the nominal note and the substance it claimed. **The arc has a name — the gold→fiat trajectory
|
||||
— and it ran in one direction: more discretion, less backing.**
|
||||
|
||||
FIATm reverses it in a single covenant. **The same arc, walked backwards, on-chain.** Where
|
||||
gold→fiat moved through fixed peg → devalue → float → sever, FIATm moves through floating DRA
|
||||
→ tighten → freeze the BCH rate → FIATm becomes the reference. The reversal is structurally
|
||||
enforced — not a policy choice that can be revoked — because the two engines that drove the
|
||||
historical decay are the two things FIATm removes:
|
||||
|
||||
| drove the historical decay | FIATm's answer |
|
||||
|---|---|
|
||||
| **discretionary issuer** (chose each step) | **automated, genesis-fixed schedule** — no ongoing discretion |
|
||||
| **inflatable base** (print / sever) | **hard-capped BCH** — nothing to inflate or sever |
|
||||
|
||||
The residual is the one-time, published, auditable genesis schedule (categorically weaker than
|
||||
ongoing discretion). Supply asymmetry — BCH hard-capped vs USD compounding-inflation, ~96%+
|
||||
purchasing-power loss since 1913 — gives a long-run **bias** toward appreciation. Bias, *not*
|
||||
guarantee.
|
||||
|
||||
**Why one covenant, not centuries.** The historical decay needed centuries because each step
|
||||
required political consensus, market acceptance of the next degradation, and time for memory of
|
||||
the prior tether to fade. The reversal needs none of that: a single deployment of a covenant
|
||||
that *is* the discipline. The discipline isn't a promise to be kept — it's the script the
|
||||
network enforces on the bytes themselves.
|
||||
|
||||
---
|
||||
|
||||
## 5. The three values, ancient Greek coinage (§7a)
|
||||
|
||||
Ancient Greek coins had **three values** simultaneously, and the drift between them was the
|
||||
value-discovery mechanism, not a defect:
|
||||
|
||||
| Greek coin | FIATm unit |
|
||||
|---|---|
|
||||
| **Metallic value** (gold / silver / copper content, fixed at striking) | **Backing value** — the BCH satoshis locked inside the unit's UTXO, fixed at mint |
|
||||
| **Nominal value** (the face stamp the issuing city set) | **Denomination** — "$1" / "€1" / "₹1", the unit the user thinks in |
|
||||
| **Commercial value** (the market trade price, floating with wear / debasement / regional demand) | **Market value** — what the unit trades for now, floating with BCH price moves and the oracle rate |
|
||||
|
||||
The Greeks understood that a coin with three values is not a *defect* — it's a richer
|
||||
instrument than one with only a face number. The 1:12 gold-silver ratio was the cross-rate
|
||||
between metals; by 400 BCE coins were the predominant means of exchange across the Greek world
|
||||
*without any single currency being imposed* — regional preference emerged on its own. The
|
||||
Attic Tetradrachm (17 grams) came to prevail; Sicilian colonies used the *liter* coin. Coins
|
||||
were struck with hammer and anvil, so shape was rarely perfectly round and image rarely perfect
|
||||
— but the metallic content was real and the denomination was honest.
|
||||
|
||||
**FIATm restores the three-values architecture in the substrate.** The face is preserved
|
||||
(*denomination*); the metallic layer returns (*BCH, hard-capped, in your own UTXO*); the
|
||||
commercial layer remains what it always was (*market discovery*). All three values are public,
|
||||
simultaneous, and inspectable by anyone on chain. *"Sound version of fiat money, interchangeable
|
||||
infrastructure"* — the architectural statement, not just an illustration.
|
||||
|
||||
---
|
||||
|
||||
## 6. The Artemision lineage — art of emission, universal substrate, why the lag exists (§7a.1)
|
||||
|
||||
§7a names *what* the three values are; §7a.1 names *where they come from*, *what makes the
|
||||
family architecture possible structurally*, and *why the §12 controller's correction lag is the
|
||||
recognition of an ancient truth*. The four registers — historical site, architectural craft,
|
||||
structural substrate, controller mechanism — are the same idea told four times.
|
||||
|
||||
### The historical site
|
||||
|
||||
Coinage as a category begins archaeologically at the **Artemision** — the Temple of Artemis at
|
||||
Ephesus, in ancient Ionia (western Anatolian coast). The temple's foundation deposits yielded
|
||||
the *Artemision hoard*: among the earliest electrum coins known archaeologically, contemporary
|
||||
with the Lydian invention of struck coinage under Alyattes and Croesus (~7th–6th c. BCE).
|
||||
**Coinage was born at a sanctuary, in electrum, struck by hand into figured discs whose
|
||||
substance and image were unified at the moment of striking.** The wallet UI surface where new
|
||||
FIATm currencies are minted carries this name — *Artemision* is the create/genesis surface in
|
||||
the shell.
|
||||
|
||||
### Art OF Emission — the *technē* reading
|
||||
|
||||
The wallet UI name carries a deliberate wordplay: **"Art Emission"** as the *technē* of
|
||||
emission — the *skilled practice* of bringing trustworthy value into being. In the Greek frame,
|
||||
*technē* (τέχνη) was the category of disciplined craft. Master die-cutters and minters belonged
|
||||
in it on par with sculptors, vase-painters, navigators, healers. **The wordplay is structurally
|
||||
encoded into the asset taxonomy**: the first MBA class is **DEA — Direct Emission Asset**, which
|
||||
carries the *Emission* reading explicitly. The wallet surface and the canonical asset class
|
||||
name agree that emission is a *practice with discipline*, not a passive act.
|
||||
|
||||
### Ionia → Magna Graecia → plausible conceptual lineage (not asserted etymology)
|
||||
|
||||
The Greek poleis of Ionia (Ephesus, Miletus, Smyrna, Phocaea) were colonising founders of much
|
||||
of *Magna Graecia*. The cultural influence of Greek-speaking southern Italy on early Rome is
|
||||
documented from at least the 6th–5th c. BCE: religious absorption via *interpretatio romana*
|
||||
(Artemis → Diana, Athena → Minerva), the alphabet via Greek-via-Etruscan, and minting
|
||||
practices in Magna Graecia predating and influencing Roman coinage. The Ionian *technē* of
|
||||
coinage — born at Artemision — travelled into the same cultural sphere that became
|
||||
Latin-speaking. **This is a conceptual lineage, plausible as cultural transmission. It is NOT
|
||||
asserted as the formal etymological derivation of Latin *ē-mittere*** (PIE *meit-*, traced
|
||||
directly). The Artemision↔Art-Emission resonance lives in the concept, not in the philology.
|
||||
|
||||
### Metal as universal substrate — the FIATm equivalent
|
||||
|
||||
The Ancient Greek monetary system worked across a fragmented political geography *because the
|
||||
metal was a universal substrate*. An Athenian tetradrachm and a Corinthian stater had different
|
||||
art but the silver underneath was the same silver, judged by the same touchstone, traded at
|
||||
the same weight. **The system did not need a central authority to enforce interchange because
|
||||
the metal itself enforced it.** FIATm + ASM reconstructs this architecture directly:
|
||||
|
||||
| Ancient Greek coinage | FIATm + on-chain substrate |
|
||||
|---|---|
|
||||
| The metal (electrum/gold/silver/copper) — universal interchange medium | **BCH** — universal interchange medium |
|
||||
| Regional gods/animals/figures stamped on each city's coinage | **Per-currency category mark** (USDm/EURm/GBPm/JPYm/INRm/ARSm/TRYm) |
|
||||
| The touchstone (whetstone, *ἀκόνη*) — the test that proves metal purity | **Akone** — the verify surface in the wallet UI |
|
||||
| The merchant — counterparty who validates each exchange | The **ASM** — counterparty-less swap on the substrate ("an ocean, not a pool" — Poseidon metaphor) |
|
||||
| Regional preference without imposed currency | Per-currency preference without imposed FIATm |
|
||||
|
||||
### Why the §12 correction lag exists — the three-values derivation
|
||||
|
||||
The §7a three values were never identical in ancient practice, and that was the design
|
||||
property, not a defect. The metallic value (silver content) was fixed at striking; the nominal
|
||||
value (face stamp) was set by the issuing city; the commercial value (market trade price)
|
||||
drifted continuously. **The drift was the value-discovery mechanism.** Debasement worked
|
||||
precisely by trying to break the lock between metallic and nominal value, which the market
|
||||
caught via commercial value drifting away.
|
||||
|
||||
**The §12 controller's correction lag exists for the same structural reason.** §4 fixes the
|
||||
metallic value at mint (locked BCH per unit, exact, never adjusted afterward); the
|
||||
denomination label preserves the nominal value (the unit still says "1 USDm"); the commercial
|
||||
value is allowed to drift; the §12 controller adjusts the *mint-time relationship* between
|
||||
metallic and nominal only when sustained, multi-signal evidence justifies it. **The lag is
|
||||
not a damping artefact. It is the structural recognition that the three values were always in
|
||||
motion in ancient coinage, and any system that tries to freeze them either fails or breaks
|
||||
the value-discovery layer.** A system without lag attempts to collapse all three values into
|
||||
one continuously — which is the move debasement uses, and the move that historically destroys
|
||||
monetary trust.
|
||||
|
||||
This derivation has two consequences carried into the rest of the design:
|
||||
|
||||
1. **The lag is *deliberate* (§7b)** — not a trade-off accepted for simplicity, not a
|
||||
side-effect of damping. It is the active mechanism the design imports from ancient practice.
|
||||
2. **The strength of the lag *scales with adoption*** (§12a.2 catalyst). A brand-new FIATm
|
||||
currency has a small lag (immature symmetric controller); a currency that has earned many
|
||||
catalysts carries a stronger lag, structurally proportional to what its participants have
|
||||
contributed. **The lag is always on, scaling continuously with cumulative-mint supply — no
|
||||
on/off switch.**
|
||||
|
||||
---
|
||||
|
||||
## 7. What this does for the holder + the global scale (§7b)
|
||||
|
||||
§0.5 / §7 / §7a / §7a.1 are *structural*. §7b is *experiential* — what holding FIATm does for
|
||||
a person, day by day, in their own local denomination.
|
||||
|
||||
### The holder's view in their own denomination
|
||||
|
||||
A FIATm holder sees something they have never been able to see before in their denomination:
|
||||
the face value of the unit appreciating *in the very money they pay rent and buy groceries
|
||||
with*. The mechanism is exactly the §0.5 properties, read from the holder's chair instead of
|
||||
the architect's:
|
||||
|
||||
- The denomination ("100 ARSm" / "100 USDm") **is the unit they think in**. Zero cognitive cost.
|
||||
- The backing is BCH — *not their local currency, not their banking system, not their state's
|
||||
treasury*. The unit's commercial value **decouples from the local currency** the moment the
|
||||
local currency begins to depreciate.
|
||||
- They watch the decoupling on their own statement. The unit still says "100 ARSm" on its face,
|
||||
but **what 100 ARSm trades for, today, is what 100 ARS *would have* traded for at a stronger
|
||||
point in the currency's history** — the locked BCH carries the value forward through the
|
||||
fiat collapse.
|
||||
|
||||
The 9-year USDm holder ended with $207 of purchasing power (mild, +107%). The 9-year **ARSm**
|
||||
holder ended with **15,804 ARS of commercial value vs 100 ARS in cash — a 158× spread on the
|
||||
cash baseline.** The TRYm holder: **24.8× cash**. The structural machinery is the same in
|
||||
every case; the holder *experience* scales with how badly the underlying fiat collapsed.
|
||||
(See `scripts/sim-fiatm-historical.mjs` and snapshot 0159.)
|
||||
|
||||
### Decoupling observable on the holder's device
|
||||
|
||||
The holder doesn't need to read the design record to see what's happening. A wallet that
|
||||
surfaces the §7a three values together — *face*, *real*, and the *spread* — converts the
|
||||
reverse-trajectory thesis into a number that updates on screen as the local currency
|
||||
depreciates. **The visible inflation gauge.** The face stays at 100 by definition; the real
|
||||
value rises; the spread is the empirical demonstration of §7 happening to *this* user.
|
||||
|
||||
### Rate-correction lag — what it IS and what it IS NOT
|
||||
|
||||
The lag is a **deliberate design choice** (per §7a.1's three-values derivation). It is **not a
|
||||
trade-off** for controller simplicity, and it is **not a side-effect** of damping. The lag is
|
||||
the active mechanism by which **the FIATm system becomes more powerful as more people use it
|
||||
for payments**, empowering both the individual holder and the wider ecosystem.
|
||||
|
||||
What this delivers:
|
||||
|
||||
- **For the holder.** Every entry point is empowered. The 2017 vintage holder watches their
|
||||
voucher appreciate. The 2024 late entrant gets a *better-than-equilibrium* mint rate during
|
||||
a lag window. The hyperinflating-fiat user who only discovers FIATm after their currency
|
||||
lost most of its purchasing power is **not punished for arriving late** — the next lag
|
||||
window is structurally available. **No "missed the boat" failure mode by design.**
|
||||
- **For the ecosystem.** Synthetic-market noise (leverage, futures, fractional venues —
|
||||
everything *counterfeit until settled*) decomposes into gap windows the controller refuses
|
||||
to chase. The gap windows attract arbitrage; arbitrage demands real BCH to mint at the
|
||||
lagged rate; the real BCH demand strengthens the substrate. **Volatility becomes
|
||||
settlement.** This is the catalytic-converter hypothesis (§11 below).
|
||||
- **For adoption.** Transactional use expands the arbitrage market that closes lag-window
|
||||
gaps. **The more people use FIATm for payments, the more powerful the lag-as-converter
|
||||
becomes.** The system rewards adoption with stronger systemic properties.
|
||||
|
||||
Across USDm, TRYm, ARSm the bargain-window frequency in the simulator is **~25-30% of months**
|
||||
— the lag opens every 2-4 months, lasts a few weeks. **The catch-up window is recurring, not
|
||||
one-shot.** (See `scripts/sim-fiatm-trajectory.mjs`.)
|
||||
|
||||
### Global scale
|
||||
|
||||
~2-3 billion people live under currencies losing double-digit annual purchasing power:
|
||||
Argentina (~45M), Turkey (~85M), Egypt (~110M), Pakistan (~240M), Nigeria (~225M), Venezuela
|
||||
(~28M), Lebanon (~5M), Iran (~88M), plus Sudan, Ethiopia, Ghana, Sri Lanka, Zimbabwe, Myanmar,
|
||||
Laos, and others. For all of them, **cash in their pocket IS the depreciating asset in §7's
|
||||
table.** FIATm is not a hedge against an abstract risk — it is the *direct fix* for the
|
||||
problem the local-currency user already lives with.
|
||||
|
||||
A face-value of "100" that gains commercial value while the local currency falls is not a
|
||||
financial product; it is a **monetary reform**, executed not by the state but by the holder,
|
||||
one mint at a time. That is the global story §7 implies and §7b makes explicit.
|
||||
|
||||
**Honest limits** (kept here for discipline): adoption is voluntary, on-ramps are a separate
|
||||
problem, FIATm carries full BCH variance (not stable for tomorrow's groceries — "preservation
|
||||
against multi-year collapse" is the honest pitch), the catch-up windows exist but aren't
|
||||
signalled to the holder by the on-chain rate itself (a UI feature, not a contract property).
|
||||
|
||||
---
|
||||
|
||||
## 8. The mechanism — mint, redeem, swap
|
||||
|
||||
| Operation | Path | Oracle? | Permission? |
|
||||
|---|---|---|---|
|
||||
| **Mint (forward, BCH → FIATm)** | Lock BCH at oracle rate; covenant emits an FT unit holding the locked BCH inside its UTXO; § 14 oracle integrity stack gates the rate | **Yes** — at mint time only | No (permissionless) |
|
||||
| **Redeem (backward, FIATm → BCH)** | Burn the unit; the BCH in its UTXO is recovered via a plain P2PKH spend — *no oracle, no intermediary, no permission*. The exact BCH locked at mint comes back. | **No** | No |
|
||||
| **Swap (FIATm ↔ FIATm)** | Atomic swap via ASM — burn one FIATm, mint another, in a single covenant tx at the oracle ratio | **Yes** for the target side | No |
|
||||
| **Transfer (FIATm → FIATm holder)** | Plain CashTokens transfer (P2PKH spend with token outputs) | **No** | No |
|
||||
|
||||
**The redemption guarantee is the load-bearing property of the family.** §4 in the design
|
||||
record states it: *"burn the unit, recover the exact locked BCH — no oracle, no intermediary,
|
||||
no permission."* This is what makes FIATm the "only stablecoin that can't break its peg —
|
||||
because it never made one — and the only one whose redemption is strongest in a crisis"
|
||||
(§0 headline). Live chipnet confirmation: snapshot 0157 (multi-FIATm atomic redemption, three
|
||||
currencies burned in one tx with zero oracle signatures).
|
||||
|
||||
---
|
||||
|
||||
## 9. The §12 five-layer controller (the rate-correction machinery)
|
||||
|
||||
The mint-time rate is set by the **§12 controller**, a multi-layer adaptive machinery with
|
||||
all thresholds **genesis-fixed**. The controller *selects among* fixed regimes; it never
|
||||
invents values. Trustless like Bitcoin difficulty, not discretionary like monetary policy.
|
||||
|
||||
| Layer | What it handles | Time scale | Reference |
|
||||
|---|---|---|---|
|
||||
| 1. Block-rate floor | Sub-block noise; absolute fastest update cadence the chain allows | ~10 min | §12 |
|
||||
| 2. DART (Difficulty-Adjustment Rate Targeting) | Two triggers: 2-week timer + 210k-mint catalyst | weeks + adoption | §12a, §12a.1, §12a.2 |
|
||||
| 3. Time-doubling schedule | Decade-scale maturation; base cadence doubles at fixed wall-clock intervals | ~4 years | §12c |
|
||||
| 4. Damping per allowed update | How much of the oracle-target gap any single allowed update closes; per-direction | per-update | §12b |
|
||||
| 5. Inner-loop guards | Deadband, max step, persistence — preventing spurious or malicious moves | per-update | §12 |
|
||||
|
||||
**DART** is the most-discussed layer. It has *two independent triggers*:
|
||||
|
||||
- **Time trigger** (every ~2016 blocks ≈ 2 weeks): runs the three-signal calculation
|
||||
(price direction, mint/redeem flow, supply velocity) producing the per-direction cadence
|
||||
multipliers `N_up`, `N_down` for the next window. The calculation has a path-dependence rule
|
||||
(full magnitude when signal agrees with trajectory; half when opposing) that makes reversals
|
||||
require sustained signals.
|
||||
- **Supply catalyst** (every 210,000 cumulative-minted units): applies a small, fixed,
|
||||
asymmetric adjustment to `N`/`d` parameters, biasing the system one step further toward
|
||||
favoring holders/minters. **The asymmetric bias is *earned through adoption*, not given at
|
||||
genesis.**
|
||||
|
||||
The §12a.2 catalyst table:
|
||||
|
||||
| Catalysts | Cumulative minted | N_down | N_up | d_down | d_up |
|
||||
|---|---|---|---|---|---|
|
||||
| 0 (genesis) | 0 | 1 | 1 | 10% | 10% |
|
||||
| 1 | 210,000 | 2 | 1 | 9.5% | 10.5% |
|
||||
| 5 | 1,050,000 | 6 | 1 | 7.5% | 12.5% |
|
||||
| 10 | 2,100,000 | 11 | 1 | 5% | 15% |
|
||||
| 20 | 4,200,000 | 21 | 1 | 5% | 20% |
|
||||
| 25+ | accumulating | clamped at ceilings/floors | | | |
|
||||
|
||||
The asymptotic end-state suggested in the design (`N_down = 21, N_up = 1, d_down = 5%, d_up =
|
||||
20%`) is the structural pro-hold/buy bias the system reaches after sufficient adoption. **Once
|
||||
reached, the controller is structurally locked into favoring hold-and-mint over redeem-and-
|
||||
sell** — irrespective of what subsequent 2-week DART signals would otherwise suggest.
|
||||
|
||||
**Open simulator-vs-design reconciliation** (carried as outstanding work in snapshot 0163):
|
||||
`sim-usdm-controller.mjs` has `N_CEILING = 144` (the simulator's hard ceiling), while the
|
||||
design record's §12a.2 catalyst table reaches `N_down = 21` at 20+ catalysts and calls that
|
||||
the suggested asymptotic value. The 7× discrepancy propagates through the catalytic-converter
|
||||
strength calculations in snapshots 0161/0162. Reconciliation is a Stage-2 prerequisite before
|
||||
further catalytic-converter modelling.
|
||||
|
||||
---
|
||||
|
||||
## 10. The architecture pantheon (wallet UI naming)
|
||||
|
||||
The corpus uses a Greek-pantheon naming for the wallet UI surfaces, all decided and documented
|
||||
in `Parameters/MBA_Shares/naming-and-branding_FOR-design-record.md` and `wiki/glossary.md`. The naming is
|
||||
not decorative — it directly maps the ancient *technē* of coinage onto the on-chain
|
||||
substrate.
|
||||
|
||||
| Component | Name | Greek anchor |
|
||||
|---|---|---|
|
||||
| Create / genesis surface | **Artemision** | Temple of Artemis at Ephesus — birthplace of struck coinage (the *Artemision hoard*); *"A coin is struck = a star is born"* |
|
||||
| Verify module | **Akone** (ἀκόνη) | The touchstone / whetstone that assays gold's purity — the instrument that proves value is real |
|
||||
| Liquidity / ASM (metaphor only) | **Poseidon** | God of the whole sea — *"you don't need a pool; the whole ocean IS the pool"* |
|
||||
| Loading screen (Artemision intro) | **Asterae Planitae** | "Plain of stars" — supernovae flaring into white stars, "each star a born asset; each supernova, a genesis" |
|
||||
| First MBA class | **DEA — *Direct Emission Asset*** | Carries the *Art-of-Emission* wordplay explicitly in the canonical class name |
|
||||
|
||||
**Pantheon coherence** (per the naming-and-branding doc): *"most cosmogonies begin with a
|
||||
primordial ocean from which the cosmos and stars emerge — so Poseidon's ocean (liquidity, the
|
||||
primordial sea) and the star-birth launch register sit in one creation-sequence rather than
|
||||
clashing."*
|
||||
|
||||
**The Chilonic epigraph for Akone** (Chilon of Lacedaemon, one of the Seven Sages per
|
||||
traditional ascription):
|
||||
|
||||
> Ἐν λιθίναις ἀκόναις ὁ χρυσὸς ἐξετάζεται διδοὺς βάσανον φανεράν.
|
||||
> Ἐν δὲ χρυσῷ ἀνδρῶν ἀγαθῶν τε κακῶν τε νοῦς ἔδωκ' ἔλεγχον.
|
||||
|
||||
> *"Gold is tested on the 'touchstone' (grinding stone) to verify its authenticity. With Gold
|
||||
> being an examination, mans true character bad or good is being tested and surfaced
|
||||
> (revealed) by means of consciousness (logic)."*
|
||||
|
||||
The aphorism's structure pairs two tests: a substance tested by a stone (touchstone's
|
||||
*basanos*), and persons tested by gold (consciousness's *elenchus*). **The FIATm substrate
|
||||
runs both tests at once** — BCH backing tested by the on-chain verification surface (Akone as
|
||||
*basanos*); economic actors tested by their behaviour toward that surface (Akone as
|
||||
*elenchus*). The situation does the work; the actors disclose themselves.
|
||||
|
||||
---
|
||||
|
||||
## 11. The catalytic-converter hypothesis (labelled hypothesis, Stage-1 tested)
|
||||
|
||||
The §12 controller's correction lag — §7a.1 derivation, §7b empowerment — has a hypothesised
|
||||
*systemic* property: **the lag absorbs the high-frequency volatility produced by synthetic
|
||||
markets, while real-settlement arbitrage closes the gap.** Together they convert counterfeit
|
||||
volatility into real BCH demand. Full statement and predictions in
|
||||
`Parameters/FIATm/catalytic-converter-hypothesis_FOR-testing.md`.
|
||||
|
||||
### The two-counterweight model (structural elaboration)
|
||||
|
||||
The mechanism rests on two counterweights applied simultaneously, both running on the same
|
||||
substrate:
|
||||
|
||||
1. **Counterweight A — arbitrage.** Lag opens; arbitrageur buys cheap BCH off-chain; mints
|
||||
FIATm at the lagged rate; real BCH gets locked inside FIATm UTXOs. The arbitrageur requires
|
||||
a profitable exit — which is provided by Counterweight B.
|
||||
2. **Counterweight B — real economy.** Merchants accepting FIATm for goods; people paying
|
||||
rent / wages / invoices in FIATm; real-world settlement at face value. **This is what
|
||||
creates the arbitrageur's exit market at face value.** Without it, arbitrage has no profit;
|
||||
with it, the converter runs. **The real economy IS the previously-pinned-ON
|
||||
transactional-adoption assumption, named structurally as Counterweight B.**
|
||||
|
||||
The two are simultaneous, not sequential. Counterweight B pays the arbitrageur, who closes the
|
||||
gap, which keeps the lag healthy as a catch-up mechanism for *more* Counterweight B
|
||||
participants. **They reinforce each other.**
|
||||
|
||||
### Substrate enablers — and the Akone expose mechanism
|
||||
|
||||
The two-counterweight asymmetry is *structural*, not contingent. The substrate enablers:
|
||||
|
||||
- **ASM** (Poseidon's ocean) — every position is a real UTXO; no synthetic counterpart
|
||||
possible inside the substrate.
|
||||
- **MBA** (`DeviantOracleMBA` covenant) — real BCH locked per unit; no fractional reserve
|
||||
possible by covenant construction.
|
||||
- **BCH base layer** — hard-capped 21M; no synthetic BCH supply venue within the substrate.
|
||||
|
||||
Together they make the substrate **structurally pro-real**. It is not neutral between real and
|
||||
synthetic; it *does not permit* synthetic supply to enter the on-chain mechanism. **The
|
||||
verification gate is Akone.** Akone is not a marketing surface; it is the substrate's
|
||||
structural rejection of unverified claims. Every economic action attempting to participate in
|
||||
the on-chain mechanism passes through Akone, and the pass/fail rule is binary: either the
|
||||
claim has real backing (in which case it becomes real), or it has none (in which case it
|
||||
stays off-substrate forever).
|
||||
|
||||
This produces the **expose mechanism** as an emergent property:
|
||||
|
||||
- An honest CEX settles real BCH outflows — *visible on chain*.
|
||||
- A dishonest CEX halts withdrawals when arbitrage pressure builds — *also visible*.
|
||||
- An arbitrageur who profits by locking real BCH — *visible as substrate-strengthening*.
|
||||
- A speculator who tries to extract value without settling — *unable to do so on-substrate*,
|
||||
must go elsewhere.
|
||||
|
||||
**Akone does not have to accuse anyone. The substrate does no work to reject synthetics; it
|
||||
simply does not invite them in, and they declare themselves by going elsewhere.** This is the
|
||||
elenchic property in operational form.
|
||||
|
||||
### Stage-1 test results (snapshots 0161, 0162, 0163)
|
||||
|
||||
The mini test (chipnet-scale 0.2 BCH reservoir, 50% BCH crash):
|
||||
- **WITH arb (mature controller)**: BCH ends −5%; 0.18 BCH locked into FIATm backing.
|
||||
- **WITHOUT arb (null)**: BCH ends −36%.
|
||||
- **Catalytic strength: +31.2 pp recovery vs null** at the simulated mature state.
|
||||
|
||||
The scale test (4 reservoirs × 4 offchain ratios × 3 crash sizes × 4 adoption levels = 192
|
||||
cases):
|
||||
- Mean catalytic strength: **+16.2 pp**.
|
||||
- **75% of cases meaningful (>1 pp); 63% strong (>10 pp).** Best case: +49.9 pp. Worst case:
|
||||
−6 pp (saturation when offchain >> reservoir).
|
||||
- Critical lever: offchain/reservoir ratio. **>2× saturates; >5× inverts.**
|
||||
|
||||
The cross-substrate test (real vs synthetic-permitted substrate, paired sims):
|
||||
- Real substrate: +31.2 pp. Synthetic-only substrate: −13.8 pp. **45 pp catalytic-strength
|
||||
degradation between real and synthetic-permitted substrates.**
|
||||
- **The substrate-load-bearing claim is CONFIRMED** at the level of the design counterfactual:
|
||||
had FIATm been built on a permissive substrate, the converter would not survive.
|
||||
|
||||
### Corrections that landed in snapshot 0163
|
||||
|
||||
Three corrections to the Stage-1 results, each carried into the hypothesis doc + the
|
||||
corresponding snapshot appendices:
|
||||
|
||||
1. **"Scale invariance" was an artefact** of hardcoded mature settings. The honest finding is
|
||||
that catalytic strength is *supply-history-conditional* via §12a.2 maturation, not
|
||||
scale-invariant. The mechanism is *always on*, scaling continuously with cumulative-mint
|
||||
supply.
|
||||
2. **The cross-substrate test addresses a substrate-design counterfactual**, NOT external-
|
||||
market coexistence. Synthetic-FIATm in some external venue (a CEX perpetual, a wrapped
|
||||
sidechain version) cannot enter the on-chain mechanism — Akone enforces market
|
||||
disjointness. **Institutional synthetics are structurally irrelevant** to the real
|
||||
catalytic mechanism.
|
||||
3. **`N_CEILING = 144` (simulator) vs `N_down = 21` (design suggested)** — 7× discrepancy that
|
||||
needs reconciliation before further catalytic modelling.
|
||||
|
||||
### Stage 2 — still required
|
||||
|
||||
Five robustness candidates before promotion to §12e + ADR:
|
||||
1. Varied transactional adoption (sizes Counterweight B explicitly).
|
||||
2. Synthetic-attack scenario (coordinated leverage cascade).
|
||||
3. Multi-currency competition (ARSm vs USDm sharing arbitrage capacity).
|
||||
4. Supply-driven maturation re-test (replaces hardcoded mature settings with §12a.2
|
||||
catalyst-driven evolution).
|
||||
5. Prediction P4 latency test (gap-closure time vs gap amplitude).
|
||||
|
||||
Plus the simulator-vs-design reconciliation (item 3 above). Stage 2 passes → §12e + companion
|
||||
ADR. Stage 2 fails on any prediction → honest acknowledgement and the hypothesis doc gets a
|
||||
_REJECTED_ prefix.
|
||||
|
||||
---
|
||||
|
||||
## 12. The institutional-action asymmetry — §8 at full structural strength (§8.1)
|
||||
|
||||
§8 states the magical reversal simply: *"USDm converts dollar-denominated demand into demand
|
||||
for real on-chain BCH."* §8.1 names what that reversal looks like at full structural strength
|
||||
— once §7, §9, §12, §16, §17, §19 are read together.
|
||||
|
||||
The reading is **NOT** a trajectory prediction (per the corpus discipline — *"enthusiasm
|
||||
attaches to the math model, not predicted market outcomes"*). It is a *structural claim*
|
||||
about which directions of institutional action can move the FIATm substrate — and the
|
||||
structural answer is: **none of the available directions move it adversely.** The substrate
|
||||
is unidirectional. Every column of the matrix below reads *strengthens* or *no effect*. None
|
||||
read *weakens*.
|
||||
|
||||
| Institutional action | Why it cannot affect real FIATm | What it does to the real substrate |
|
||||
|---|---|---|
|
||||
| Refuse to list FIATm on CEXes | ASM provides on-chain what listings provide off-chain; adoption needs no permission | **No effect** — bootstrap proceeds invisibly |
|
||||
| Print more fiat (USD, EUR, JPY) | Substrate covenant unchanged; oracle tracks the new fiat price directly | **Strengthens** — fiat debasement raises BCH/fiat; existing FIATm holders' BCH appreciates in fiat terms |
|
||||
| Print more synthetic stablecoins (USDT-style) | Akone gate keeps them in their own category; markets are disjoint | **Strengthens** — visible paper proliferation makes the real-vs-synthetic distinction more legible |
|
||||
| Print "synthetic-USDm" perpetuals on CEXes | Cannot enter on-chain without becoming real; gate is binary | **Strengthens** — adds to the visible-paper category alongside USDT |
|
||||
| Regulatory action against on-chain BCH | Cannot disable consensus; covenant code is jurisdiction-less | **Strengthens** — confirms §9 trust-surface property |
|
||||
| Inaction | Nothing | **Strengthens** — adoption grows; controller matures; catalytic-converter strengthens |
|
||||
|
||||
**The structural moats stack three deep:**
|
||||
|
||||
1. **Pre-launch invisibility** — no listing gates adoption (ASM replaces what listings provide).
|
||||
2. **Post-launch immunity** — institutions can copy the FIATm name but not the substrate
|
||||
property. Akone is the operational enforcer.
|
||||
3. **In-category exclusivity** — only on-substrate FIATm exhibits §4 redemption, §16
|
||||
oracle-failure-benign, §7b lag-as-catch-up, and the catalytic-converter mechanism.
|
||||
Synthetic competitors join the existing paper-stablecoin category alongside USDT/USDC/DAI;
|
||||
they **cannot enter the new on-chain-backed category that FIATm occupies alone**, because
|
||||
the substrate gate is structural, not market-share-driven.
|
||||
|
||||
**Historical mirror.** The gold→fiat arc over 1914–1971 was itself an asymmetric process *in
|
||||
the opposite direction*. Every institutional action available to states pushed toward
|
||||
unbacking; inaction also tended toward unbacking. **Once the system was structurally
|
||||
configured to favor debasement, every direction of state action moved it further toward
|
||||
synthetic. Nothing the public could do reversed it.** FIATm is the same shape, inverted: every
|
||||
direction of institutional action on a hard-capped substrate with a verification gate moves
|
||||
the system toward real backing, because the substrate's verification gate (Akone) is the
|
||||
structural inverse of the central-bank-printing seam that drove the historical decay.
|
||||
|
||||
**Discipline boundary.** The asymmetric checkmate is a *structural claim*, partially confirmed
|
||||
by simulation (catalytic-converter cross-substrate test, supply-driven maturation, 9-year
|
||||
back-test), partially open empirically (adoption growth at population scale is the test of
|
||||
history, not of the design). The structural claim is what §8 implies when read at full
|
||||
strength; *whether* the trajectory it makes possible actually realises depends on adoption,
|
||||
on-ramps, broad-population awareness, and the visible-inflation gauge of §7a doing its work.
|
||||
**The design has done its job by removing the failure modes that could have made the outcome
|
||||
contingent on institutional permission.** *Whether* the outcome arrives, and *how fast*, is
|
||||
not a design property and is not a prediction this record makes.
|
||||
|
||||
---
|
||||
|
||||
## 13. The oracle integrity stack (§14) + composed oracles for non-USD FIATm (§14a)
|
||||
|
||||
§14 describes the seven-layer integrity stack for a single BCH/X price feed:
|
||||
|
||||
1. **Measurement** — multi-oracle median + spread check.
|
||||
2. **Consensus-cluster** — largest tight ε-cluster of ≥M agreeing feeds; no consensus → hold.
|
||||
3. **Continuity bias** — prefer cluster within cap-range of prior rate.
|
||||
4. **Persistence (K windows)** — candidate must hold across K consecutive ~10-min windows
|
||||
before taking effect.
|
||||
5. **Bounds** — deadband + cap + 2-week retarget (§12).
|
||||
6. **Sortitioned human adjudication** — sortitioned citizens (via `SortitionBeacon` from the
|
||||
`CitizenToken` pool) judge which oracle/cluster is accurate. The truth anchor.
|
||||
7. **Freeze (end-state)** — oracle removed, FIATm self-references (§19).
|
||||
|
||||
§14a names three composition options for non-USD FIATm (where there's no deep direct BCH/X
|
||||
spot market):
|
||||
|
||||
- **A — off-chain composition, single signature.** Operator multiplies BCH/USD × USD/X
|
||||
off-chain, signs the product. Existing template handles it. Bootstrap-phase recommendation.
|
||||
- **B — on-chain composition, two signatures.** Mint tx carries BCH/USD oracle + USD/X FX
|
||||
oracle signatures; covenant verifies both and computes BCH/X on-chain. Pre-mainnet recommendation.
|
||||
- **C — multi-source attested (24-byte message).** Single signature, intermediate values
|
||||
exposed on chain for forensic audit. Intermediate option.
|
||||
|
||||
The substrate-load-bearing property holds for each feed independently: each oracle pool runs
|
||||
through the full §14 stack.
|
||||
|
||||
---
|
||||
|
||||
## 14. The §16 oracle-failure-is-benign property
|
||||
|
||||
**Redemption is P2PKH-only — it does not touch the oracle.** If every oracle in every pool
|
||||
dies tomorrow, existing FIATm holders can still redeem their units for the exact BCH locked
|
||||
at mint. Live chipnet confirmation: snapshot 0157 multi-FIATm atomic redemption — three
|
||||
currencies burned in one tx with **zero oracle signatures**.
|
||||
|
||||
Oracle failure stalls *new mints* (rate becomes stale, controller freezes); it does **not**
|
||||
break the asset's redemption guarantee. The §17 issuance-scale TVL framework, the §18
|
||||
oracle-set governance, and the §19 freeze all retain this benign-failure property as their
|
||||
load-bearing invariant.
|
||||
|
||||
---
|
||||
|
||||
## 15. The §17 issuance scale + §19 maturity ladder
|
||||
|
||||
§17 names the issuance-scale (cumulative-minted) proxy for system-health confirmation. The
|
||||
suggested launch baseline uses the reservoir-depletion counter (option A); the mature phase
|
||||
adds a TVL oracle (option C) once the use cases of §17b justify it.
|
||||
|
||||
§19 names the maturity ladder:
|
||||
|
||||
| Phase | Oracle integrity | Set governance | Controller cell |
|
||||
|---|---|---|---|
|
||||
| **Launch** | single oracle / median + cap | frozen, over-provisioned | (0,0) symmetric |
|
||||
| **Growth** | multi-oracle median + cluster + persistence | frozen | (1–3, 1–5) emerging asymmetry |
|
||||
| **Mature ("hard mode")** | + sortitioned human adjudication, TVL-scaled | sortition-governed | (4–10, 6–15) clear asymmetry |
|
||||
| **Asymptotic** | layers progressively redundant | governance progressively redundant | (10–20, 15–20) effectively frozen |
|
||||
| **End-state** | **freeze** — oracle removed | n/a | (20+, 20+) formality |
|
||||
|
||||
The maturity ladder is *traversed by the controller's life-trajectory*, not by external policy.
|
||||
**The §19 freeze becomes the asymptote of the §12 controller's lifetime trajectory rather than
|
||||
a discrete switch.**
|
||||
|
||||
---
|
||||
|
||||
## 16. Honest limits + discipline boundary
|
||||
|
||||
What FIATm does NOT do:
|
||||
|
||||
- **Not a USD-value guarantee.** For "$X in dollars next month regardless of crypto," FIATm
|
||||
doesn't serve it (full BCH exposure). That's a different need, not a risk.
|
||||
- **Functional-$1, not mechanical-$1.** §3.
|
||||
- **Vintage / cross-epoch.** Units back different BCH; price-by-backing is the honest default.
|
||||
- **Holder carries full BCH variance.** "Preservation against multi-year collapse" is the
|
||||
honest pitch, not "stable for tomorrow's groceries."
|
||||
- **Adoption is voluntary.** On-ramps, regulatory posture, merchant tooling, wallet UX —
|
||||
all outside the design.
|
||||
- **Consequences unknown.** The structure is demonstrable; adoption of "a dollar that floats
|
||||
with BCH" is an open experiment.
|
||||
|
||||
What is and is not a structural claim:
|
||||
|
||||
- **Structural claims** live in the design record. Each can be tested, simulated, or derived
|
||||
from corpus material.
|
||||
- **Trajectory predictions** live in the public-facing primer (`wiki/sound-money-primer.md`).
|
||||
Primer is allowed to project; design record describes mechanism. *"Enthusiasm attaches to
|
||||
the math model, not predicted market outcomes."*
|
||||
|
||||
---
|
||||
|
||||
## 17. What's confirmed vs hypothesis-stage vs open
|
||||
|
||||
### Confirmed (chipnet or back-test)
|
||||
|
||||
- Universal `DeviantOracleMBA` covenant (one template, 7 currencies, no fork) — snapshots
|
||||
0136, 0137, 0138, 0144, 0157, 0160.
|
||||
- Atomic cross-asset swap inside the family — 0137 (USDm↔EURm); 0138 (6-asset market, 111
|
||||
swaps).
|
||||
- Base-layer-backed redemption (P2PKH only, zero oracle signatures) — 0157 (three FIATm
|
||||
categories burned in one atomic tx).
|
||||
- §16 oracle-failure-is-benign — same 0157 evidence (no oracle signatures in redeem).
|
||||
- §12 controller adapts through real cycles — §20a 9-year back-test (snapshot 0148).
|
||||
- §12a.2 catalyst-driven asymmetric bias accumulation — same §20a back-test (99 catalysts
|
||||
fired across 9 years).
|
||||
- §22 calibration defaults are defensible (Pareto front, not strictly dominated) — snapshot
|
||||
0158.
|
||||
- Holder × cash spread tracks fiat collapse — snapshot 0159 (USDm 2×; TRYm 25×; ARSm 158×).
|
||||
- Bargain-window frequency ~25-30% across USDm/TRYm/ARSm — snapshot 0160 trajectory sim.
|
||||
|
||||
### Hypothesis-stage (Stage-1 tested, Stage-2 pending)
|
||||
|
||||
- **Catalytic-converter mechanism** — Stage 1 mini + scale tests confirm under stated
|
||||
assumptions (snapshots 0161, 0162). Stage 2 robustness pending: varied transactional
|
||||
adoption, synthetic-attack scenario, multi-currency competition, supply-driven maturation
|
||||
re-test, P4 latency test. **Plus simulator-vs-design reconciliation** (snapshot 0163).
|
||||
- **Two-counterweight model + Akone expose mechanism + invisible-bootstrap** — structural
|
||||
elaboration in `catalytic-converter-hypothesis_FOR-testing.md`. Will graduate to §12e + ADR
|
||||
if Stage 2 passes.
|
||||
|
||||
### Open / deferred
|
||||
|
||||
- VESm + ZWLm — piecewise sim with explicit redenomination breaks (deferred per 0159).
|
||||
- Per-currency §22 calibration sweeps (per-currency volatility profiles).
|
||||
- Dust-floor strategy for deep-collapse currencies (deferred per 0160).
|
||||
- Wallet UI lag-window signal — captures the §7b catch-up-opportunity property in UX.
|
||||
- Composed-oracle Option B implementation (`DeviantOracleMBA_Composed.cash` covenant).
|
||||
- `sim-usdm-controller.mjs` correction (`N_CEILING = 144` vs design's suggested `N_down = 21`;
|
||||
§12a.1 path-dependence rule not in simulator).
|
||||
- Public-facing primer extension translating the asymmetric-checkmate framing for
|
||||
hyperinflating-fiat audiences.
|
||||
- The `BchmCurrency` → `FiatmCurrency` type refactor in `src/merchant-pos/`.
|
||||
|
||||
---
|
||||
|
||||
## 18. Corpus cross-references
|
||||
|
||||
**Inside this folder (`Parameters/FIATm/`):**
|
||||
- `fiatm_complete-design_FOR-design-record.md` — full design record (§0–§22 + appendices A, B).
|
||||
- `catalytic-converter-hypothesis_FOR-testing.md` — labelled hypothesis with structural elaboration.
|
||||
- `usdm_sound-money-note_FOR-design-record.md` — absorbed USDm note (historical artefact).
|
||||
- `usdm-and-market_diagram-report.html` — diagram report.
|
||||
- `transcripts/` — session logs (gitignored).
|
||||
|
||||
**Adjacent in parent `Parameters/`:**
|
||||
- `../MBA_Shares/naming-and-branding_FOR-design-record.md` — source of truth for Artemision / Akone /
|
||||
Poseidon / Asterae Planitae names.
|
||||
- `../MBA_Shares/mba-shares_complete-design_FOR-design-record.md` — adjacent MBA-family equity instrument
|
||||
(ADR-0042), not FIATm.
|
||||
- `deviant_flow-and-bch-impact-model.md` — broader BCH-impact model.
|
||||
- `deviant_technical_spec_v2_8.md` — project-wide technical spec.
|
||||
|
||||
**Wiki:**
|
||||
- `wiki/sound-money-primer.md` — public-facing explainer (Greek tetradrachm parallel, fiat
|
||||
history in reverse, visible-inflation gauge, political fairness argument).
|
||||
- `wiki/glossary.md` — Artemision, Agora, Spectrum, Orbital Swap, Akone definitions.
|
||||
- `wiki/asset-landscape.md` — NBA/MBA taxonomy reader's guide.
|
||||
- `wiki/usd-rail.md` — BCH as USD payment rail framing.
|
||||
- `wiki/index.md` — wiki entry point.
|
||||
|
||||
**Source code / wallet UI:**
|
||||
- `src/merchant-pos/index.ts` — FIATm-family point-of-sale primitives.
|
||||
- `shells/app/src/screens/ArtemisionScreen.tsx` — genesis surface.
|
||||
- `design/mockups/artemision-tab.html`, `artemision-wizard.html`, `agora.html` — design mocks.
|
||||
|
||||
**Simulator + chipnet test scripts:**
|
||||
- `scripts/sim-usdm-controller.mjs` — single-currency §12 controller simulator.
|
||||
- `scripts/sim-usdm-historical-bch.mjs` — 9-year USDm back-test.
|
||||
- `scripts/sim-usdm-calibration-sweep.mjs` — §22 parameter sweep.
|
||||
- `scripts/sim-fiatm-historical.mjs` — multi-currency back-test.
|
||||
- `scripts/sim-fiatm-trajectory.mjs` — month-by-month trajectory + bargain-window detection.
|
||||
- `scripts/sim-fiatm-catalytic-mini.mjs` — single-case catalytic-converter test.
|
||||
- `scripts/sim-fiatm-catalytic-scale.mjs` — 192-case parameter sweep.
|
||||
- `scripts/sim-fiatm-catalytic-substrate.mjs` — cross-substrate comparison.
|
||||
- `scripts/chipnet-multicurrency-mba-test.mjs` — GBPm + JPYm + INRm genesis.
|
||||
- `scripts/chipnet-fiatm-hyperinflation-test.mjs` — ARSm + TRYm genesis.
|
||||
- `scripts/chipnet-fiatm-multi-redeem.mjs` — multi-FIATm atomic burn (snapshot 0157).
|
||||
- `scripts/merchant-pos-checkout-demo.mjs` — FIATm POS demo.
|
||||
|
||||
**Key snapshots in chronological order:**
|
||||
- 0136 — USDm round-trip (genesis + claim + redeem).
|
||||
- 0137 — EURm + atomic cross-asset swap with USDm.
|
||||
- 0138 — 6-asset market, 111 swaps.
|
||||
- 0143 — TVL oracle §17b amendment.
|
||||
- 0144 — GBPm + JPYm + INRm chipnet validation + merchant POS demo.
|
||||
- 0145 — sound-money primer public-facing.
|
||||
- 0146 — six-layer controller (superseded by 0147).
|
||||
- 0147 — five-layer correction + simulator.
|
||||
- 0148 — USDm 9-year back-test results.
|
||||
- 0149 — docs updated with back-test.
|
||||
- 0150 — SESSION SYNTHESIS for the 0143–0149 session.
|
||||
- 0155 — FIATm design record promoted to family level.
|
||||
- 0157 — multi-FIATm atomic-redemption chipnet test.
|
||||
- 0158 — §22 calibration sweep first cut.
|
||||
- 0159 — hyperinflating-currency back-tests (ARSm + TRYm).
|
||||
- 0160 — ARSm + TRYm chipnet live + §7b + §14a.
|
||||
- 0161 — catalytic-converter mini + scale Stage-1 tests.
|
||||
- 0162 — catalytic-converter cross-substrate test.
|
||||
- 0163 — consolidation: §7a.1, §7b correction, §8.1, hypothesis-doc structural elaboration.
|
||||
|
||||
---
|
||||
|
||||
## 19. The one-paragraph closing
|
||||
|
||||
FIATm is the structural answer to a long question. Money has carried three values for as long
|
||||
as money has existed — metallic, nominal, commercial — and the drift between them has been
|
||||
the value-discovery mechanism since the Artemision in the 7th c. BCE. The historical arc
|
||||
hollowed money out by trying to collapse the three values into one continuously, which is
|
||||
what debasement always is. FIATm reverses the arc on-chain, in one covenant, by re-imposing
|
||||
the architecture the Greeks already knew: metal (BCH) as universal substrate, art
|
||||
(denomination mark) as regional identity, touchstone (Akone) as the test that holds them
|
||||
honest. The substrate is structurally pro-real because the verification gate cannot be
|
||||
bribed and the covenant cannot be amended; the result is a category that institutions cannot
|
||||
enter (Akone admits only real backing) while occupying the same denomination space their
|
||||
products already serve. **What the institutions do — print, refuse to list, regulate, ignore
|
||||
— either strengthens the substrate or has no effect on it. None of the available institutional
|
||||
actions move it adversely.** Whether population-scale adoption actually realises the
|
||||
trajectory the structure makes possible is the test of history; the design has done its job
|
||||
by removing the failure modes that could have made the outcome contingent on permission.
|
||||
The metal is real, the art is honest, the touchstone exists, and the *technē* of emission —
|
||||
the practice we now call FIATm — has names: Artemision, Akone, Poseidon. The same idea,
|
||||
twenty-six centuries apart.
|
||||
|
|
@ -1,5 +1,13 @@
|
|||
# USDm — A Sound-Money Note (design record + stablecoin differentiation)
|
||||
|
||||
> **Status (2026-06-13): ABSORBED.** The content of this note has been absorbed into
|
||||
> the FIATm-level design record — `Parameters/FIATm/fiatm_complete-design_FOR-design-record.md`
|
||||
> (sibling file in this folder). The FIATm record covers this same USDm-vs-stablecoin
|
||||
> material as Part I, plus the price-adjustment / oracle-integrity layers + the family-level
|
||||
> (USDm + EURm + GBPm + JPYm + INRm + ARSm + TRYm) abstraction. **Read the FIATm record
|
||||
> going forward**; this file is retained as a historical reference for the original USDm-only
|
||||
> framing.
|
||||
|
||||
**Date:** 2026-06-07 · **Status:** Design record (conceptual; covenant `DeviantOracleMBA`
|
||||
compiled + USDm/EURm round-trips chipnet-validated, snapshots 0136–0137) · **For:** the
|
||||
USDm/DRA design and any public copy derived from it.
|
||||
60
Parameters/MBA_Shares/KEY-IDEAS.md
Normal file
60
Parameters/MBA_Shares/KEY-IDEAS.md
Normal file
|
|
@ -0,0 +1,60 @@
|
|||
# MBA Shares — key ideas (distilled)
|
||||
|
||||
The conceptual essence. Full reasoning lives in the canonical design record
|
||||
(`mba-shares_complete-design_FOR-design-record.md`) + ADR-0042.
|
||||
|
||||
1. **An MBA share *is* BCH.** Backing sits inside the unit's own UTXO, so at the limit of
|
||||
strict backing the "claim on BCH" and "BCH itself" *coincide* — both true at once. BCH is an
|
||||
internet of value; programmability is the rendering layer; an MBA is one rendered shape.
|
||||
|
||||
2. **Price = backing is an identity, not an estimate.** `value == amount × rate` at consensus.
|
||||
Everything in canonical equity that exists to cope with *price ≠ backing* (DCF/P-E,
|
||||
residual-claimant risk, issuer-solvency risk, disclosure-as-protection, illiquidity) has **no
|
||||
referent**.
|
||||
|
||||
3. **Value = `Q_sats × P_bch`** — BCH-shaped (the floor, consensus-enforced) *and*
|
||||
enterprise-shaped (the dynamics), reflexively coupled. The floor of a *held* unit is fixed at
|
||||
mint; enterprise success reaches holders via **distributions** and the **market premium**
|
||||
(`price = floor + PV(future income)`), not by the held floor auto-ratcheting.
|
||||
|
||||
4. **The "dividend" is an automated profit-share, not a classical dividend.** A mechanical cut
|
||||
of *gross fees* (the company's per-transaction margin), split off in the same tx — **no
|
||||
declaration leg, no board discretion, no dividend agency risk**. Taken *off the top* → it's
|
||||
**senior** to the company's costs (company becomes the residual), so the share must be small
|
||||
and pre-set, like a royalty.
|
||||
|
||||
5. **Three dials → the whole equity↔debt spectrum:** issuance split (`extractBps` = downside /
|
||||
fundraising), fee split (`companyBps`/`shareholderBps` = coupon), dividend horizon (`T` =
|
||||
term). 100%-floor perpetual = yield-note; 60/40 + term = secured bond; 0% + term = unsecured
|
||||
note. **Extraction is also the *fundraise* dial and the *security* dial — one dial.**
|
||||
|
||||
6. **Single vs dual = open vs scarce.** Single (DEA, unlimited) = *open shareholding* / rewards;
|
||||
broad diluted yield, customers earn by holding. Dual (capped supply) = *scarce equity*;
|
||||
dividend-per-share scales 1:1 with revenue (EPS), shares trade at a premium. You **cannot**
|
||||
have elastic money + scarce equity in one token — that's the only structural reason dual
|
||||
exists.
|
||||
|
||||
7. **Distribution: no claimable pool.** Fees attribute to whoever holds *at the moment each fee
|
||||
occurs* (time-weighted) → mint-then-redeem captures nothing (it *donates* to existing
|
||||
holders). Settled in batches from a **consensus-locked vault** (not company custody); oracle
|
||||
attests amounts; signatures **bound to the vault outpoint** (no replay).
|
||||
|
||||
8. **Securities posture (honest, not legal advice).** Substance = **BCH = commodity** (Bitcoin/
|
||||
CFTC precedent); securities analysis attaches only to the *income feature*. **Extraction**
|
||||
establishes Howey prongs (1)+(3) but **not (2)** (revenue-share, not a managed pool);
|
||||
automation **relocates** prong (4) but doesn't remove it; **prong (4) — whose efforts
|
||||
generate the fees — is decisive.** Single-asset rewards = a **non-custodial, holding-weighted
|
||||
network-fee share** — a *new class* (not cashback: cashback rewards *spending*, this rewards
|
||||
*holding*), defended on prongs (1)+(4) by structure (non-custodial, capital-not-deployed),
|
||||
not by a "rewards" label. Deposit-vs-security is the regulatory **wrapper**, not the
|
||||
economics. Voting and risk-bearing do **not** help the posture — only *performing the
|
||||
income-producing work* shifts prong (4).
|
||||
|
||||
9. **The floor is BCH-denominated, not fiat.** You always get your sats; fiat value rides BCH.
|
||||
The instrument is *levered on the BCH ecosystem*, not a diversifier — company-failure and
|
||||
BCH-weakness can be correlated.
|
||||
|
||||
10. **Two products, one engine.** ① rewards/loyalty coin and ② appreciating + dividends differ
|
||||
only in genesis params (supply cap, extraction, reward-for-holding vs dividends-on-scarce-
|
||||
shares + appreciation). Both ride the **collection split** + **oracle-attested payout** —
|
||||
both proven on chipnet.
|
||||
27
Parameters/MBA_Shares/README.md
Normal file
27
Parameters/MBA_Shares/README.md
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
# MBA Shares — hub
|
||||
|
||||
Folder for the MBA-shares work: the design, the key ideas, and a live status chart of
|
||||
what's been tried / tested / not yet built.
|
||||
|
||||
## Contents
|
||||
- **`KEY-IDEAS.md`** — the distilled concepts (one page).
|
||||
- **`STATUS-CHART.md`** — what we've tried, what's chipnet-verified, what's unit-tested, what's
|
||||
designed-only, with descriptions and evidence (txids / snapshots / files).
|
||||
- **Canonical full design record:** [`mba-shares_complete-design_FOR-design-record.md`](mba-shares_complete-design_FOR-design-record.md)
|
||||
(Parts I–VII: framing, obsolete/transformed concepts, mechanism, securities, Hertz example,
|
||||
build status, simulation plan). The companion decision record is **ADR-0042** in
|
||||
`wiki/decisions.md`.
|
||||
- **Naming/branding:** [`naming-and-branding_FOR-design-record.md`](naming-and-branding_FOR-design-record.md)
|
||||
(Artemision / Akone / Poseidon, the Chilon epigraph).
|
||||
|
||||
## One-line summary
|
||||
An **MBA share** is BCH wearing a programmable skin: a self-backed CashTokens asset whose
|
||||
holders earn an automated, consensus-routed share of the issuer's transaction fees — collected
|
||||
by a fee-splitting covenant and paid out by an oracle-attested, company-untouchable vault.
|
||||
**Both halves are proven on chipnet.**
|
||||
|
||||
## Two target products
|
||||
- **① Rewards / loyalty coin** — DEA (unlimited), reward *for holding*, none/low extraction →
|
||||
non-custodial loyalty. *Proven end-to-end.*
|
||||
- **② Appreciating asset + dividends** — capped/scarce, dividends + price appreciation, some
|
||||
extraction → investor-grade. *Reuses the same engine; not yet assembled.*
|
||||
93
Parameters/MBA_Shares/STATUS-CHART.md
Normal file
93
Parameters/MBA_Shares/STATUS-CHART.md
Normal file
|
|
@ -0,0 +1,93 @@
|
|||
# MBA Shares — status chart (tried / tested / not)
|
||||
|
||||
What's been built and how far it's been proven, for the MBA-shares engine and the oracle/MBA
|
||||
foundation it reuses. *Updated this session.*
|
||||
|
||||
**Legend**
|
||||
- ✅ **chipnet-verified** — real transactions on live chipnet (txids / snapshot cited)
|
||||
- 🧪 **unit-tested** — deterministic off-chain tests pass
|
||||
- 📐 **designed** — specified in the design record / ADR-0042, no code yet
|
||||
- 💡 **concept** — discussed & decided, not fully specified
|
||||
- ❌ **not started**
|
||||
|
||||
---
|
||||
|
||||
## A. Foundation — oracle-priced MBA (the substrate shares reuse)
|
||||
|
||||
| Item | Status | Evidence | Description |
|
||||
|---|---|---|---|
|
||||
| Oracle-priced MBA (USDm): claim → send → redeem | ✅ | snapshot 0136, `DeviantOracleMBA.cash` | Oracle-priced mint (`checkDataSig`, 16-byte AnyHedge fmt); self-backed P2PKH redeem (no oracle) |
|
||||
| EURm + cross-asset swaps | ✅ | snapshot 0137 | Second oracle asset; atomic burn+claim across categories/addresses |
|
||||
| DEA market (DEA/GLD/SLV/CUP), 111 swaps | ✅ | snapshot 0138 | Fixed-rate DEAs + metals; large multi-asset swap run |
|
||||
| PegState single-oracle price adjustment | ✅ | snapshot 0139, `PegState.cash` | Difficulty-adjustment-style epoch peg; band reject/accept, CLTV gate |
|
||||
| USDm multi-swap behavior (volatile path) | ✅ | snapshot 0140, `scripts/chipnet-usdm-swaps-behavior.mjs` | 6 mints across $450–$600; peg-independent redeem; divisibility |
|
||||
| Zero-fee USDm0/EURm0 cross-swaps (both ways + vs DEA) | ✅ | snapshot 0141 | Fee-free oracle assets; per-asset fee is per-covenant |
|
||||
| `src/oracleUsdm.ts` pure logic | 🧪 | `test/unit/oracle/usdm.test.ts` (20 tests) | Codec, inverse pricing, sub-dust fee **waiver**, peg-independence, backing conservation |
|
||||
|
||||
## B. Shares engine — the two halves (this session)
|
||||
|
||||
| Item | Status | Evidence | Description |
|
||||
|---|---|---|---|
|
||||
| **Collection split** — `DeviantShareMBA.cash` | ✅ | txids `382506a9…`, `4865cc61…`; `scripts/chipnet-share-collection-test.mjs` | Per-claim fee split on-chain → `companySats` (treasury, direct) + `shareholderSats` (distribution, routed). 2 claims: company Δ 10,000 ✓, pool Δ 15,000 ✓ |
|
||||
| **Payout vault** — `DistributionVault.cash` | ✅ | txids `b6a2a3ba…`, `1ebd51fa…`; `scripts/chipnet-distribution-payout-test.mjs` | Only valid spend = oracle-attested recipient+amount; remainder back to vault; company can't touch it; sig **bound to outpoint** (no replay). Pool 31k → C 18k ✓ + D 12k ✓, residual 1k ✓ (live residual re-queried = 1,000 ✓) |
|
||||
| End-to-end ① (claim-fee → pool → holder payout) | ✅ | both halves above | Each half chipnet-verified; not yet a single chained script, but the path is proven |
|
||||
|
||||
## C. Products
|
||||
|
||||
| Item | Status | Evidence | Description |
|
||||
|---|---|---|---|
|
||||
| **① Rewards / loyalty coin** | ✅ engine / 📐 packaging | B above | DEA (unlimited) + reward-for-holding payout. Engine proven; not yet wrapped as one product genesis/config |
|
||||
| **② Appreciating asset + dividends** | 📐 | design record Part VI | Capped/scarce share + dividends (reuses both covenants) + appreciation (market-premium **or** DRA+reserve). Not built |
|
||||
|
||||
## D. Payout hardening (designed, not built)
|
||||
|
||||
| Item | Status | Description |
|
||||
|---|---|---|
|
||||
| Time-weighted attribution (balance × duration) | 📐 | Oracle's off-chain accounting feeding per-holder amounts; minimal version paid flat oracle-attested amounts |
|
||||
| Batched settlement (attribute-on-fee → settle-in-batches) | 📐 | Scale path: can't emit an output per holder per fee; credit continuously, pay periodically |
|
||||
| Merkle liveness backstop | 📐 | If the oracle goes dark, holders self-claim against a published root so the pool can't be frozen |
|
||||
| Sub-dust fee-split waiver (small claims) | 📐 | `DeviantShareMBA` currently requires both split sides ≥ 546; a waiver for tiny claims is a refinement |
|
||||
|
||||
## E. Oracle integrity stack (designed for USDm, reused by shares)
|
||||
|
||||
| Item | Status | Description |
|
||||
|---|---|---|
|
||||
| Single oracle / 10-min | ✅ | Proven via PegState (snapshot 0139) — the agreed test-phase simplification |
|
||||
| Multi-oracle median → consensus-cluster → persistence → sortitioned adjudication | 📐 | Full integrity stack designed in `../usdm_complete-design_FOR-design-record.md`; not built |
|
||||
|
||||
## F. Distribution mechanism menu (design alternatives)
|
||||
|
||||
| Item | Status | Description |
|
||||
|---|---|---|
|
||||
| Oracle-attest payout | ✅ | Chosen default — proven (B above) |
|
||||
| Retention-ratchet (DRA, capital appreciation) | 💡 / 📐 | DRA itself proven (escalating-rate, snapshots 0128–0132), but reserve-backed *held*-appreciation for shares not built; held floor can't ratchet without a reserve |
|
||||
| Registered-NFT accumulator | 📐 | Per-holder entry-checkpoint; trustless but sacrifices fungibility |
|
||||
| Merkle-snapshot drop | 📐 | Trustless cash distribution; doubles as the liveness backstop |
|
||||
|
||||
## G. Governance / policy / modeling (concept-stage)
|
||||
|
||||
| Item | Status | Description |
|
||||
|---|---|---|
|
||||
| Fee-split governance (bicameral) | 💡 | Default immutable-at-genesis; if governed, both company + shareholders must consent |
|
||||
| Dual-asset "earn shares through usage" drip | 💡 | Spending the currency drips capped shares → velocity rewarded |
|
||||
| Wallet-level fee layer | 💡 | Optional fee in the tx-builder, independent of zero-fee covenants |
|
||||
| Securities positioning (per deployment) | 💡 | Protocol-toolkit vs operator-issued — a policy decision, not code |
|
||||
| Simulation: single vs dual under holding behavior | 📐 | Design record Part VII plan (variables, 3 outputs); not run |
|
||||
|
||||
---
|
||||
|
||||
## Roll-up
|
||||
|
||||
- **✅ Chipnet-verified:** the entire oracle/MBA foundation (USDm, EURm, DEA market, PegState,
|
||||
behavior run, zero-fee swaps) **and both halves of the shares engine** (fee-split collection +
|
||||
oracle-attested payout). Product ① is proven end-to-end at the engine level.
|
||||
- **🧪 Unit-tested:** the oracle pure-logic layer (`oracleUsdm.ts`, 20 tests) within the wider
|
||||
505-case suite.
|
||||
- **📐 Designed, not built:** payout hardening (time-weighting, batching, Merkle backstop),
|
||||
Product ② assembly, the full multi-oracle integrity stack, the alternative distribution
|
||||
mechanisms, the simulation.
|
||||
- **💡 Concept:** split-governance, earn-through-usage, wallet-fee layer, securities positioning.
|
||||
|
||||
**Bottom line:** the *core* "company coin that pays holders, with the funds locked away from the
|
||||
company" is **real and proven on live chipnet today**. What remains is hardening + the Product ②
|
||||
configuration + the trust-decentralization stack — all design-stage.
|
||||
|
|
@ -643,7 +643,7 @@ horizon** when the obligation should be bounded (turning it into a term note).
|
|||
- Zero-fee and per-asset-fee behavior; atomic cross-asset burn+claim (snapshot 0141).
|
||||
- Voting + sortition primitives — `PollCovenant`, `SortitionBeacon`, `CitizenToken`
|
||||
(snapshots 0105–0133).
|
||||
- The oracle-integrity stack — designed for USDm (`usdm_complete-design_FOR-design-record.md`).
|
||||
- The oracle-integrity stack — designed for USDm (`../usdm_complete-design_FOR-design-record.md`).
|
||||
|
||||
**Proven on chipnet (this session) — both halves of the engine:**
|
||||
- **Collection side** — `DeviantShareMBA.cash` (fork of `DeviantOpenMintFT`) splits the
|
||||
|
|
@ -721,7 +721,7 @@ only once yield is attractive enough that open entry self-dilutes.
|
|||
- `wiki/decisions.md` ADR-0042 (this design, decision form)
|
||||
- `wiki/asset-landscape.md` — Layer 2b / MBA classes; the closed-end-fund-share peer (MTA)
|
||||
- ADR-0027/0028/0033 — token vs asset; secured ≠ backed; the unilateral-redemption discriminator
|
||||
- `usdm_complete-design_FOR-design-record.md` — the oracle + oracle-integrity stack reused here
|
||||
- `../usdm_complete-design_FOR-design-record.md` — the oracle + oracle-integrity stack reused here
|
||||
- `wiki/voting-systems.md` — the bicameral / sortition governance the split and oracle reuse
|
||||
- snapshots 0136–0141 — the oracle MBA + fee mechanics this builds on
|
||||
- snapshot 0066 — `ExpiringMBA` (time-boxed self-backed instrument), the dividend-horizon pattern
|
||||
55
Parameters/dApp/Gallery/README.md
Normal file
55
Parameters/dApp/Gallery/README.md
Normal file
|
|
@ -0,0 +1,55 @@
|
|||
# Deviant Labs — Showcase Gallery
|
||||
|
||||
The Gallery is the **public catalog of every validated Deviant on-chain algorithm** — each one a CashScript covenant that has been proven end-to-end on chipnet. It is the first surface of **Deviant Labs**, the dApp laboratory.
|
||||
|
||||
## Why this exists
|
||||
|
||||
Deviant has dozens of covenant protocols (ASM swaps, MBAs, DRAs, totes, share markets, governance, anti-plutocracy vote assets) that are already **dApps at the protocol layer** — non-custodial, permissionless, consensus-enforced. The Gallery does three jobs:
|
||||
|
||||
1. **Showcase / credibility** — for each algorithm: *what it does*, *how it works*, a *code link*, and a *live chipnet TXID as proof*. Read-and-learn; no wallet required.
|
||||
2. **Catalog for the functional hub** — the Gallery is backed by a structured data file (`catalog.json`) so the future **functional dApp hub** and the in-wallet **Labs tab** consume the *same* source of truth. Build the catalog once; render it everywhere.
|
||||
3. **The safety wedge made visible** — every entry carries its verification status (canonical / D-1-verifiable). This is the one thing no other BCH wallet surfaces, and it is the defensible position Deviant Labs is built around: *the safety-verified BCH dApp gateway*.
|
||||
|
||||
## Structure
|
||||
|
||||
```
|
||||
Parameters/dApp/
|
||||
└── Gallery/
|
||||
├── README.md ← this file
|
||||
├── catalog.json ← machine-readable catalog (single source of truth; hub + Labs tab consume this)
|
||||
└── index.html ← rendered showcase (CosmoGenesis-styled, groups entries by family)
|
||||
```
|
||||
|
||||
## The catalog schema (`catalog.json`)
|
||||
|
||||
Each entry:
|
||||
|
||||
| field | meaning |
|
||||
|---|---|
|
||||
| `id` | stable kebab-case slug |
|
||||
| `name` | display name (and product alias, e.g. Agora = ASM) |
|
||||
| `family` | grouping: core / dra / prediction / shares / instruments / games / governance / anti-plutocracy / security-research |
|
||||
| `tagline` | one-line "what it does" |
|
||||
| `howItWorks` | 2–4 sentences of mechanism, in the project's own terms |
|
||||
| `contract` | path to the `.cash` source (code link) |
|
||||
| `script` | path to the chipnet test script (reproduce the proof) |
|
||||
| `snapshot` | the snapshot that recorded validation |
|
||||
| `proofTxid` | a representative live chipnet TXID (the proof) |
|
||||
| `status` | `validated` (chipnet-proven) / `spike` / `research` |
|
||||
| `network` | `chipnet` (mainnet deferred until audit + regulatory pass) |
|
||||
| `verification` | `canonical` (D-1 template exists) / `n-a` |
|
||||
| `feeModel` | how the founder/operator fee works, if any |
|
||||
|
||||
## Conventions
|
||||
|
||||
- **Chipnet only.** Everything here is validated on chipnet; mainnet is deferred until the audit + regulatory pass (R-016). The `network` field makes this explicit on every card.
|
||||
- **Proof is a TXID, not a claim.** Every `validated` entry links a real chipnet transaction. No TXID → status is `spike` or `research`, stated honestly.
|
||||
- **Attack PoCs are kept, not hidden.** The `security-research` family lists the red-team contracts (no-peg drain, backdoor mint, etc.) as evidence of rigor — proof the protocol was attacked before it was shipped.
|
||||
- **Add an entry = edit `catalog.json`.** The HTML renders from it. Do not hand-edit cards in `index.html` for content.
|
||||
|
||||
## Roadmap (this is step 1 of Deviant Labs)
|
||||
|
||||
1. **Gallery (here)** — catalog + showcase. ✅ in progress.
|
||||
2. **Functional dApp hub** — standalone + connectable front-ends to the same covenants, consuming `catalog.json`.
|
||||
3. **Labs tab in the wallet** — in-wallet window into the hub, reusing the Apps-tab connector pattern.
|
||||
4. **White-label / co-brand layer** *(deliberate follow-on)* — themeable build + verification-baked-in core + on-chain revenue split (ADR-0021), gated on legal/curation readiness.
|
||||
597
Parameters/dApp/Gallery/catalog.json
Normal file
597
Parameters/dApp/Gallery/catalog.json
Normal file
|
|
@ -0,0 +1,597 @@
|
|||
{
|
||||
"meta": {
|
||||
"title": "Deviant Labs — Showcase Gallery Catalog",
|
||||
"version": 1,
|
||||
"network": "chipnet",
|
||||
"explorerTxUrl": "https://chipnet.imaginary.cash/tx/",
|
||||
"repoRoot": "../../../",
|
||||
"note": "Single source of truth for the Gallery, the future functional dApp hub, and the in-wallet Labs tab. Edit this file to add/update entries; index.html renders from it. Every 'validated' entry is proven on chipnet; mainnet is deferred until the audit + regulatory pass (R-016).",
|
||||
"generated": "2026-06-17"
|
||||
},
|
||||
"families": [
|
||||
{ "id": "core", "name": "Core protocol", "blurb": "The Agora swap engine and Artemision asset creation — the self-backed MBA primitives everything else builds on." },
|
||||
{ "id": "dra", "name": "Dynamic-Rate Assets", "blurb": "MBAs whose backing rate is a transparent, published function of contract state — linear, stepped, exponential, super-exponential, and stepped-fee curves." },
|
||||
{ "id": "prediction", "name": "Prediction markets", "blurb": "Pari-mutuel totes and oracle-settled bilateral escrows — outcome trustless via oracle, payouts covenant-enforced." },
|
||||
{ "id": "shares", "name": "Binary share markets", "blurb": "Family D — collateralized fixed-terminal-value share markets (Polymarket-shape): split/merge, CLOB, AMM, oracle-priced vaults." },
|
||||
{ "id": "instruments", "name": "Backed instruments", "blurb": "Time-boxed, oracle-priced and peg-tracked MBA instruments — self-backed value that redeems unilaterally." },
|
||||
{ "id": "games", "name": "Games & escrow", "blurb": "Non-custodial prize pools and on-chain game settlement — the stake is in a covenant, never an operator wallet." },
|
||||
{ "id": "governance", "name": "On-chain governance", "blurb": "The bicameral-sortition voting stack — citizenship, applications, ballots, endorsement, and elder/complaint defences, validated phase by phase." },
|
||||
{ "id": "anti-plutocracy", "name": "Anti-plutocracy assets", "blurb": "Vote assets whose cost escalates per vote so capital cannot dominate — fixed redeemable backing, escalating non-recoverable fee." },
|
||||
{ "id": "integration", "name": "Integrations", "blurb": "External BCH-DeFi protocols proven to compose with the Deviant stack — AnyHedge hedge legs, buyer-funded cashback." },
|
||||
{ "id": "security", "name": "Security research", "blurb": "Red-team contracts attacked on chipnet before shipping. Kept on record as proof of rigor — these are the threats the verification layer (D-1/D-2) defends against." }
|
||||
],
|
||||
"entries": [
|
||||
{
|
||||
"id": "agora-asm-swap",
|
||||
"name": "Agora — ASM (Automated Swap Mechanism)",
|
||||
"family": "core",
|
||||
"tagline": "Permissionless, atomic, BCH-backed token swaps with no DEX, AMM, oracle, or operator.",
|
||||
"howItWorks": "Each token UTXO is self-backed: it carries its own BCH inside at a fixed rate. A swap is a single transaction — the source side is a plain P2PKH spend releasing its backing, the target side's claim() mints from a reservoir at whatever rate it computes. Atomicity is guaranteed at the BCH layer, not by coupling covenants. A founder fee produces a consensus-enforced bid/ask spread.",
|
||||
"contract": "contracts/DeviantOracleMBA.cash",
|
||||
"script": "scripts/chipnet-asm-swap.mjs",
|
||||
"snapshot": "0008",
|
||||
"snapshotFile": "snapshots/0008-q4-result.md",
|
||||
"proofTxid": "e68e610f0e4f5374d6bbc8564ca80ce10f11fae7c21cf526c094bec867dd7370",
|
||||
"status": "validated",
|
||||
"verification": "canonical",
|
||||
"feeModel": "Founder fee (bps) routed to a constructor-chosen address; consensus-enforced.",
|
||||
"highlight": "129+ swaps on chipnet, zero exploits."
|
||||
},
|
||||
{
|
||||
"id": "artemision-mba-genesis",
|
||||
"name": "Artemision — MBA asset creation",
|
||||
"family": "core",
|
||||
"tagline": "Mint a self-backed asset (MBA) anyone can later claim, swap, and redeem — permissionlessly.",
|
||||
"howItWorks": "Genesis pre-mints the full FT supply into a contract reservoir and parks a minting/declaration NFT at the contract address. Anyone can reconstruct the contract from public params and claim() at the protocol rate — no founder approval needed. Redemption is a contract-free P2PKH spend that releases the backing and burns the FT.",
|
||||
"contract": "contracts/DeviantOracleMBA.cash",
|
||||
"script": "scripts/chipnet-asm-genesis.mjs",
|
||||
"snapshot": "0009",
|
||||
"snapshotFile": "snapshots/0009-cross-founder-mint.md",
|
||||
"proofTxid": "7767c9dd2165229f78c95e48cacc6c289cac41d95cc3ff90c23b32f1815d47b8",
|
||||
"status": "validated",
|
||||
"verification": "canonical",
|
||||
"feeModel": "Optional founder fee at claim; zero-fee genesis is fully open-mint.",
|
||||
"highlight": "Cross-wallet claim proven — anyone can interact from registry params alone."
|
||||
},
|
||||
{
|
||||
"id": "bonding-curve-dra",
|
||||
"name": "Bonding-curve DRA (linear)",
|
||||
"family": "dra",
|
||||
"tagline": "An MBA whose backing rate rises linearly with issuance along a published curve.",
|
||||
"howItWorks": "claim() computes the rate as base + issuedSoFar/step · increment, reading issuance from reservoir depletion. The curve params are public, so the contract is D-1 verifiable; a masked single rate would be a T-003 masquerade. Arithmetic vote ladders (e.g. +2 votes/step → N² cumulative cost) reuse this exact template.",
|
||||
"contract": "contracts/DeviantBondingCurveFT.cash",
|
||||
"script": "scripts/chipnet-bonding-swap-test.mjs",
|
||||
"snapshot": "0027",
|
||||
"snapshotFile": "snapshots/0027-bonding-curve-swap-and-premium-feature.md",
|
||||
"proofTxid": "066f8ff104f22447e9c6bfa9c04e6b7c6213599fcf4ddb41707e9484ce210d64",
|
||||
"status": "validated",
|
||||
"verification": "canonical",
|
||||
"feeModel": "Founder fee bps optional; rate escalation is the pricing mechanism.",
|
||||
"adr": "ADR-0015"
|
||||
},
|
||||
{
|
||||
"id": "exp-dra",
|
||||
"name": "Exponential DRA",
|
||||
"family": "dra",
|
||||
"tagline": "Self-backed bonding curve where the rate multiplies each claim (×2, ×10, …).",
|
||||
"howItWorks": "The current rate lives in a mutable NFT commitment at the contract address; each claim reads it via int(), enforces payout, then ratchets it by the multiplier. Un-resettable because the position UTXO returns to the contract. No pow/loops needed; batch buys use bounded unroll (fixed-N claim3()).",
|
||||
"contract": "contracts/DeviantExpDRA.cash",
|
||||
"script": "scripts/chipnet-exp-dra-test.mjs",
|
||||
"snapshot": "0128",
|
||||
"snapshotFile": "snapshots/0128-exponential-dra-global-self-backed-rate-.md",
|
||||
"proofTxid": "e4c1498747561b4c390434d2c88f2cfb5adac61a54cff813b98a3e0ae5add614",
|
||||
"status": "validated",
|
||||
"verification": "canonical",
|
||||
"feeModel": "Escalation is the cost mechanism; self-backed."
|
||||
},
|
||||
{
|
||||
"id": "step-dra",
|
||||
"name": "Step / tiered DRA",
|
||||
"family": "dra",
|
||||
"tagline": "Rate is flat within a tier, then jumps at the tier boundary.",
|
||||
"howItWorks": "Derives minted = supply − reservoir and mintedInTier = minted % tierSize. claimBatch(k) enforces k ≤ remainingInTier and delivers k units as one bundle at the flat tier rate, escalating only when a tier completes. Lets arbitrary k be bought in one tx with no pow.",
|
||||
"contract": "contracts/DeviantStepDRA.cash",
|
||||
"script": "scripts/chipnet-step-dra-test.mjs",
|
||||
"snapshot": "0130",
|
||||
"snapshotFile": "snapshots/0130-step-tiered-dra-flat-rate-per-tier-bound.md",
|
||||
"proofTxid": "8e0722efa4f8eb46aeafd4f6377b1bbb31da61c9f81e236b668c63c684cfb46b",
|
||||
"status": "validated",
|
||||
"verification": "canonical",
|
||||
"feeModel": "Tiered rate escalation; self-backed."
|
||||
},
|
||||
{
|
||||
"id": "super-exp-dra",
|
||||
"name": "Super-exponential DRA",
|
||||
"family": "dra",
|
||||
"tagline": "A one-and-done wall: rate → (rate × 3.14)³ per claim, unbuyable past 2–3 units.",
|
||||
"howItWorks": "Escalation law applies (rate × 314/100)³ using only exact multiplies (no pow). After one cheap claim the next unit costs hundreds of BCH; two claims past that exceed the entire BCH supply — a hard structural cap per identity. The escalation law is a free design knob.",
|
||||
"contract": "contracts/DeviantSuperExpDRA.cash",
|
||||
"script": "scripts/chipnet-step-plutocrat-test.mjs",
|
||||
"snapshot": "0131",
|
||||
"snapshotFile": "snapshots/0131-step-plutocrat-cost-ladder-super-exponen.md",
|
||||
"proofTxid": null,
|
||||
"status": "validated",
|
||||
"verification": "canonical",
|
||||
"feeModel": "Escalation is a deterrent cap, not revenue."
|
||||
},
|
||||
{
|
||||
"id": "escfee-supply",
|
||||
"name": "Escalating-fee MBA (supply trigger)",
|
||||
"family": "dra",
|
||||
"tagline": "Founder fee steps UP as cumulative issuance grows.",
|
||||
"howItWorks": "feeBps = min(base + (issued/step)·feeStep, maxFee), reading issuance from reservoir depletion. Supply trigger is the canonical escalation (block-height was rejected — tx.time is only a CLTV lower bound). D-1 reconstructs the schedule from published params.",
|
||||
"contract": "contracts/DeviantEscFeeSupply.cash",
|
||||
"script": "scripts/chipnet-escfee-supply-test.mjs",
|
||||
"snapshot": "0058",
|
||||
"snapshotFile": "snapshots/0058-escalating-fee-feasibility-chipnet.md",
|
||||
"proofTxid": "d76c14926373ff2f280e77934b5d0d5596b347a72666110867d27c84cd8436ef",
|
||||
"status": "validated",
|
||||
"verification": "canonical",
|
||||
"feeModel": "Stepped founder fee, increasing with supply.",
|
||||
"adr": "ADR-0029"
|
||||
},
|
||||
{
|
||||
"id": "descfee-supply",
|
||||
"name": "Decreasing-fee MBA (metals: GLD/SLV/CUP)",
|
||||
"family": "dra",
|
||||
"tagline": "Founder fee steps DOWN over issuance — the metal MBAs use this.",
|
||||
"howItWorks": "feeBps = max(base − (issued/step)·feeStep, floor). The metal assets (GLD/SLV/CUP and divisible variants) ship 5.0% → 0.25% schedules with reservoirs seeded at 2⁶³−1 so 'depletion' is a non-event for circulating assets. First-class in the wallet via Route B.",
|
||||
"contract": "contracts/DeviantDescFeeSupply.cash",
|
||||
"script": "scripts/chipnet-create-metal-mbas.mjs",
|
||||
"snapshot": "0086",
|
||||
"snapshotFile": "snapshots/0086-metal-mbas-gld-slv-cup-decreasing-fee-an.md",
|
||||
"proofTxid": "eda2c713e6c7169174ca32ef4900c0e588f1150b7e73630368e56257105ebfdd",
|
||||
"status": "validated",
|
||||
"verification": "canonical",
|
||||
"feeModel": "Stepped founder fee, decreasing with supply; revenue proven via cross-account claims.",
|
||||
"adr": "ADR-0029 / ADR-0037"
|
||||
},
|
||||
{
|
||||
"id": "parimutuel-tote",
|
||||
"name": "Pari-mutuel tote (fixed roster)",
|
||||
"family": "prediction",
|
||||
"tagline": "Oracle-settled pooled wager with covenant-enforced pro-rata payout.",
|
||||
"howItWorks": "Bettors fund the pool; an oracle signs {eventId, outcome} via checkDataSig at settlement. Winners split the pool pro-rata (floor division, last claimant drains the residual so no dust is lost). Outcome is trustless (oracle), the split is covenant-computed.",
|
||||
"contract": "contracts/ParimutuelTote.cash",
|
||||
"script": "scripts/chipnet-oracle-markets-test.mjs",
|
||||
"snapshot": "0045",
|
||||
"snapshotFile": "snapshots/0045-oracle-markets-chipnet.md",
|
||||
"proofTxid": "79c732c6aca80e04ad43241cc6dff767c2f7a0ffb0f866741d8d60e768290031",
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "Optional covenant-enforced operator rake (published bps).",
|
||||
"adr": "ADR-0024"
|
||||
},
|
||||
{
|
||||
"id": "open-tote",
|
||||
"name": "Open-entry tote (Tier 2, covenant-enforced)",
|
||||
"family": "prediction",
|
||||
"tagline": "Anyone can join; double-claim and loser-claim are rejected on-chain.",
|
||||
"howItWorks": "A state NFT carries the pool commitment (phase, outcome, side totals); each bet mints a receipt NFT. claim() computes pro-rata payout and the receipt's claimed flag blocks reuse — double-claims and wrong-side claims fail at consensus. Refund and sweep backstops are CLTV-timelocked.",
|
||||
"contract": "contracts/ParimutuelToteOpen.cash",
|
||||
"script": "scripts/chipnet-opentote-test.mjs",
|
||||
"snapshot": "0047",
|
||||
"snapshotFile": "snapshots/0047-open-entry-tote-nft-free-chipnet.md",
|
||||
"proofTxid": "060c4caf8df06032fe72bff5235a815dd7ecad185502b1f0a9fd57cdb50dd083",
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "Optional operator rake taken off the top at attest().",
|
||||
"adr": "ADR-0024"
|
||||
},
|
||||
{
|
||||
"id": "tote4-multioutcome",
|
||||
"name": "Multi-outcome tote (K=4)",
|
||||
"family": "prediction",
|
||||
"tagline": "Pari-mutuel across up to 4 outcomes with 2-winner pro-rata splits.",
|
||||
"howItWorks": "Fixed-K commitment packs per-outcome totals (8 bytes each) in the state; claim collapses to the winning outcome with the same receipt-gated winner check as the binary case. K capped at 4 by the 40-byte commitment budget.",
|
||||
"contract": "contracts/ParimutuelTote4.cash",
|
||||
"script": "scripts/chipnet-tote4-test.mjs",
|
||||
"snapshot": "0046",
|
||||
"snapshotFile": "snapshots/0046-parimutuel-tote-4party-chipnet.md",
|
||||
"proofTxid": "a85621ac21e10c7a1ebccab2e316efd42a89d3cd1cf8c13542a81e2443429e6c",
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "Optional operator rake."
|
||||
},
|
||||
{
|
||||
"id": "event-prediction-escrow",
|
||||
"name": "Event-prediction escrow (bilateral)",
|
||||
"family": "prediction",
|
||||
"tagline": "Oracle-settled bilateral wager with asymmetric stakes (odds).",
|
||||
"howItWorks": "Two parties co-sign their own stakes into an escrow; an oracle signs the outcome via checkDataSig and the pool routes to the winner. Unequal stakes encode odds — a book of bilateral escrows, not a single pool.",
|
||||
"contract": "contracts/EventPredictionEscrow.cash",
|
||||
"script": "scripts/chipnet-oracle-markets-test.mjs",
|
||||
"snapshot": "0045",
|
||||
"snapshotFile": "snapshots/0045-oracle-markets-chipnet.md",
|
||||
"proofTxid": "fc2b5a08f00bdf7e661c8cef95a2e0b36073c3cd77019ed68b6ed66b8b84bc34",
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "None / optional arbiter fee."
|
||||
},
|
||||
{
|
||||
"id": "binary-share-vault-bch",
|
||||
"name": "Binary share vault (BCH CLOB)",
|
||||
"family": "shares",
|
||||
"tagline": "Polymarket-shape outcome shares: 1 collateral → 1 YES + 1 NO.",
|
||||
"howItWorks": "A vault holds BCH collateral and a minting NFT. split(N) locks N sats and mints a YES+NO share pair; merge() burns a matching pair and releases the sats; attest(outcome) settles via oracle; redeem() pays the winning share 1:1. The YES+NO ≡ collateral invariant is enforced on-chain.",
|
||||
"contract": "contracts/BinaryShareVaultBCH.cash",
|
||||
"script": "scripts/chipnet-clob-bch-test.mjs",
|
||||
"snapshot": "0062",
|
||||
"snapshotFile": "snapshots/0062-family-d-config-1-pure-bch-clob-split-me.md",
|
||||
"proofTxid": "aa23def8e7359000f056a5e5f75b8a9de1b497b30ebd52c9abb45e52ed00d7e2",
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "None in spike; fee policy TBD.",
|
||||
"adr": "ADR-0030",
|
||||
"note": "Spike — config 1 of 3."
|
||||
},
|
||||
{
|
||||
"id": "binary-share-fungible",
|
||||
"name": "Fungible binary shares (two-category)",
|
||||
"family": "shares",
|
||||
"tagline": "The real Polymarket product — tradeable fungible YES/NO tokens.",
|
||||
"howItWorks": "Full share supply is pre-minted into the covenant as FT reserves (RESERVE model). No live minting NFT survives, so over-issuance is impossible — consensus FT conservation + output pinning suffice. Shares trade freely as ordinary CashTokens.",
|
||||
"contract": "contracts/BinaryShareFungibleBCH.cash",
|
||||
"script": "scripts/chipnet-clob-fungible-test.mjs",
|
||||
"snapshot": "0063",
|
||||
"snapshotFile": "snapshots/0063-family-d-configs-2-3-mba-collateral-fung.md",
|
||||
"proofTxid": null,
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "None in spike.",
|
||||
"adr": "ADR-0030",
|
||||
"note": "Spike — config 3."
|
||||
},
|
||||
{
|
||||
"id": "share-limit-order",
|
||||
"name": "On-chain resting limit order",
|
||||
"family": "shares",
|
||||
"tagline": "A partially-fillable limit order parked in a covenant — no off-chain book.",
|
||||
"howItWorks": "A resting order is an ASM swap-offer in a covenant: take() fills partially (the covenant re-creates itself with the remainder), cancel() lets the maker reclaim. Price is integer sats/share; orders are discoverable by scanning the share category.",
|
||||
"contract": "contracts/ShareLimitOrderBCH.cash",
|
||||
"script": "scripts/chipnet-clob-orders-test.mjs",
|
||||
"snapshot": "0064",
|
||||
"snapshotFile": "snapshots/0064-family-d-on-chain-resting-limit-orders-s.md",
|
||||
"proofTxid": null,
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "None in spike.",
|
||||
"note": "Spike — ASK side; BID is the symmetric mirror."
|
||||
},
|
||||
{
|
||||
"id": "share-pair-amm",
|
||||
"name": "SharePairAMM (constant product)",
|
||||
"family": "shares",
|
||||
"tagline": "x·y=k automated market maker over fungible YES/NO shares.",
|
||||
"howItWorks": "Co-spent reserve UTXOs; swap() preserves the constant product; manageLiquidity() is LP-signed. An AMM alternative to the order book for probability discovery where no resting liquidity exists.",
|
||||
"contract": "contracts/SharePairAMM.cash",
|
||||
"script": "scripts/chipnet-clob-amm-test.mjs",
|
||||
"snapshot": "0065",
|
||||
"snapshotFile": "snapshots/0065-family-d-amm-sharepairamm-adr-0031-oracl.md",
|
||||
"proofTxid": null,
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "Swap fee TBD; LP-share accounting open.",
|
||||
"note": "Spike."
|
||||
},
|
||||
{
|
||||
"id": "oracle-priced-vault",
|
||||
"name": "Oracle-priced vault",
|
||||
"family": "shares",
|
||||
"tagline": "A value-locked vault settled against a signed external price.",
|
||||
"howItWorks": "margin is locked at price p0 → a nominal value; settle() at p1 verifies the oracle via checkDataSig and pays the value-locked amount. Externally-priced assets can be oracle-priced (the covenant is the counterparty); binary events cannot (the market exists to discover the probability).",
|
||||
"contract": "contracts/OraclePricedVault.cash",
|
||||
"script": "scripts/chipnet-oracle-vault-test.mjs",
|
||||
"snapshot": "0065",
|
||||
"snapshotFile": "snapshots/0065-family-d-amm-sharepairamm-adr-0031-oracl.md",
|
||||
"proofTxid": null,
|
||||
"status": "spike",
|
||||
"verification": "n-a",
|
||||
"feeModel": "None in spike.",
|
||||
"adr": "ADR-0031",
|
||||
"note": "Spike — oracle freshness bound still open (production-blocking)."
|
||||
},
|
||||
{
|
||||
"id": "expiring-mba",
|
||||
"name": "ExpiringMBA",
|
||||
"family": "instruments",
|
||||
"tagline": "A time-boxed self-backed instrument that reverts to a fixed owner at maturity.",
|
||||
"howItWorks": "redeem() releases backing to the owner anytime. expire() is permissionless after the CLTV maturity height and reverts all backing to a fixed owner address (non-capturable by the triggerer). 'Automatic expiry' = consensus time gate + permissionless destination; nothing schedules itself on a UTXO.",
|
||||
"contract": "contracts/ExpiringMBA.cash",
|
||||
"script": "scripts/chipnet-expiring-mba-test.mjs",
|
||||
"snapshot": "0066",
|
||||
"snapshotFile": "snapshots/0066-expiringmba-time-boxed-self-backed-instr.md",
|
||||
"proofTxid": "9e551c3d63f0e3c8704c3a7658a0fc52585be31a43f9211b3d5281558d1c0e5c",
|
||||
"status": "validated",
|
||||
"verification": "canonical",
|
||||
"feeModel": "None.",
|
||||
"adr": "ADR-0032"
|
||||
},
|
||||
{
|
||||
"id": "pegstate-oracle-mba",
|
||||
"name": "PegState — oracle-tracked USDm",
|
||||
"family": "instruments",
|
||||
"tagline": "A single-oracle price-adjusting MBA that tracks a fiat peg (USDm).",
|
||||
"howItWorks": "A PegState covenant holds the current oracle price; the MBA's backing rate adjusts to track a fiat unit (the FIATm/USDm family). The oracle is a signaling machine filtered by threshold and multi-block confirmation, not a price authority — the immutable controller is the decision-maker, with bounded blast radius even if the oracle is compromised.",
|
||||
"contract": "contracts/PegState.cash",
|
||||
"script": "scripts/chipnet-pegstate-test.mjs",
|
||||
"snapshot": "0139",
|
||||
"snapshotFile": "snapshots/0139-pegstate-single-oracle-usdm-price-adjust.md",
|
||||
"proofTxid": "7703e81a296cba16542640583a095a9ed0bc8b0e82158ee1773a255dbac4ea04",
|
||||
"status": "validated",
|
||||
"verification": "canonical",
|
||||
"feeModel": "Founder fee per MBA template.",
|
||||
"note": "FIATm/USDm family — Dynamic Rate (Elevation) is a held-back surprise; keep out of public copy."
|
||||
},
|
||||
{
|
||||
"id": "game-pool-escrow",
|
||||
"name": "GamePoolEscrow",
|
||||
"family": "games",
|
||||
"tagline": "Winner-take-all prize pool with arbiter, hashlock, or refund resolution.",
|
||||
"howItWorks": "The stake sits in the covenant, never an operator wallet. resolveHashlock() is trustless commit-reveal; resolveArbiter() lets a named arbiter sign the winner; refund() is timelocked. Even a malicious arbiter can only route the pot between the two players — it cannot be stolen.",
|
||||
"contract": "contracts/GamePoolEscrow.cash",
|
||||
"script": "scripts/chipnet-escrow-test.mjs",
|
||||
"snapshot": "0039",
|
||||
"snapshotFile": "snapshots/0039-game-pool-escrow.md",
|
||||
"proofTxid": "dd6c0e72aed86338d3d4e9420f49c818d52625070b533200368315e62cbead61",
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "Optional arbiter fee (flat or bps), peg-preserving."
|
||||
},
|
||||
{
|
||||
"id": "checkers-game",
|
||||
"name": "CheckersGame (WalletConnect dApp)",
|
||||
"family": "games",
|
||||
"tagline": "Non-custodial checkers stake settled by GamePoolEscrow over WalletConnect.",
|
||||
"howItWorks": "Players co-sign their own stakes via WalletConnect — keys never leave the wallet. The escrow covenant holds the pot and pays the winner; checkers logic runs off-chain (the front-end) while custody and payout are on-chain. The reference example of a connectable Deviant dApp.",
|
||||
"contract": "contracts/CheckersGame.cash",
|
||||
"script": "scripts/chipnet-checkers-game-test.mjs",
|
||||
"snapshot": "0040",
|
||||
"snapshotFile": "snapshots/0040-escrow-flat-fee-and-irregular.md",
|
||||
"proofTxid": null,
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "Optional arbiter/operator fee.",
|
||||
"highlight": "WalletConnect co-sign validated end-to-end."
|
||||
},
|
||||
{
|
||||
"id": "poll-covenant",
|
||||
"name": "PollCovenant",
|
||||
"family": "governance",
|
||||
"tagline": "One-person-one-vote, allowlisted, permissionless expiry.",
|
||||
"howItWorks": "Per-voter covenants route their UTXO value to a ballot-box address by choice (0/1); expire() returns unvoted stakes to the issuer after closeHeight (CLTV). Sybil resistance lives in the issuer's allowlist (the trust anchor), not the covenant.",
|
||||
"contract": "contracts/PollCovenant.cash",
|
||||
"script": "scripts/chipnet-poll-test.mjs",
|
||||
"snapshot": "0105",
|
||||
"snapshotFile": "snapshots/0105-pollcovenant-binary-on-chain-voting-one-.md",
|
||||
"proofTxid": "9ad2f60518a564d25168909728d563a88207654e314b1435e84faecfb06f294e",
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "None.",
|
||||
"adr": "ADR-0040"
|
||||
},
|
||||
{
|
||||
"id": "tally-state",
|
||||
"name": "TallyState (trustless tally)",
|
||||
"family": "governance",
|
||||
"tagline": "On-chain vote tally read by other covenants with no oracle.",
|
||||
"howItWorks": "Tally counts live in an NFT commitment; another covenant reads the outcome by co-spending the tally UTXO — the 'co-spend as oracle' idiom — with no named signer. The Counting and Presentation layers become blockchain-trustless.",
|
||||
"contract": "contracts/TallyState.cash",
|
||||
"script": "scripts/chipnet-tally-as-oracle-test.mjs",
|
||||
"snapshot": "0106",
|
||||
"snapshotFile": "snapshots/0106-voting-composition-trilogy-poll-as-oracl.md",
|
||||
"proofTxid": null,
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "None.",
|
||||
"adr": "ADR-0040"
|
||||
},
|
||||
{
|
||||
"id": "voting-citizen-token",
|
||||
"name": "CitizenToken (Phase A)",
|
||||
"family": "governance",
|
||||
"tagline": "Per-rank membership NFT — Citizen / Delegated / Elder / Founder.",
|
||||
"howItWorks": "A mutable NFT whose commitment byte encodes rank (0x01–0x04). Used as a co-spent proof of rank to gate voting and elder actions across the governance stack. Phase A also lands the per-applicant ApplicationCovenant.",
|
||||
"contract": "contracts/CitizenToken.cash",
|
||||
"script": "scripts/chipnet-phase-a-test.mjs",
|
||||
"snapshot": "0114",
|
||||
"snapshotFile": "snapshots/0114-phase-a-citizentoken-applicationcovenant.md",
|
||||
"proofTxid": "511ee6ea55d599ce0fb3ea7b84025ee0011159bb703f73466de512f02dd822ee",
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "None.",
|
||||
"adr": "ADR-0040"
|
||||
},
|
||||
{
|
||||
"id": "voting-registry-state",
|
||||
"name": "RegistryState + bicameral application (Phase B)",
|
||||
"family": "governance",
|
||||
"tagline": "Adaptive-threshold membership registry with bicameral voting.",
|
||||
"howItWorks": "RegistryState holds memberCount + threshold; admit() increments and recomputes threshold = min(15, ceil(count/100)). ApplicationCovenantB runs Citizen and Delegated chambers with per-chamber rank-gated votes; close() requires both thresholds met. readOnly() exposes the registry as a co-spend oracle.",
|
||||
"contract": "contracts/RegistryState.cash",
|
||||
"script": "scripts/chipnet-phase-b-test.mjs",
|
||||
"snapshot": "0116",
|
||||
"snapshotFile": "snapshots/0116-phase-b-chipnet-validated-registrystate-.md",
|
||||
"proofTxid": "e68c314383549ce9658199d2997bd586265ec41dd6608f2f829ba4b01b7dfe9c",
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "None.",
|
||||
"adr": "ADR-0040"
|
||||
},
|
||||
{
|
||||
"id": "voting-ballot-commit-reveal",
|
||||
"name": "BallotCovenant — secret ballot (Phase E)",
|
||||
"family": "governance",
|
||||
"tagline": "Commit-reveal secret voting with hash-bound choices.",
|
||||
"howItWorks": "commit() stores sha256(choice‖nonce‖voterPkh) once; reveal() is co-spent with the application and verifies the preimage before recording the choice. Preserves the Phase D escrow (paid-regardless-of-vote) anti-bribery mechanics. Wrong-nonce reveals are rejected on-chain.",
|
||||
"contract": "contracts/BallotCovenant.cash",
|
||||
"script": "scripts/chipnet-phase-e-test.mjs",
|
||||
"snapshot": "0119",
|
||||
"snapshotFile": "snapshots/0119-phase-e-chipnet-validated-ballotcovenant.md",
|
||||
"proofTxid": null,
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "Embedded per-vote reward (paid regardless of choice).",
|
||||
"adr": "ADR-0040"
|
||||
},
|
||||
{
|
||||
"id": "voting-endorsement",
|
||||
"name": "EndorsementCovenant — on-chain pre-gate (Phase F prereq)",
|
||||
"family": "governance",
|
||||
"tagline": "On-chain rank-gated endorsement counter — the pre-gate, with no trusted verifier.",
|
||||
"howItWorks": "Per-applicant counter NFT; endorse() is co-spent with an endorser's CitizenToken (rank-gated) and increments up to threshold; graduate() consumes the UTXO at threshold. Replaces the abandoned off-chain pre-gate: 'what the chain CAN enforce, the chain SHOULD enforce.'",
|
||||
"contract": "contracts/EndorsementCovenant.cash",
|
||||
"script": "scripts/chipnet-endorsement-test.mjs",
|
||||
"snapshot": "0124",
|
||||
"snapshotFile": "snapshots/0124-correction-pre-gate-is-on-chain-endorsem.md",
|
||||
"proofTxid": null,
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "Trivial per-endorsement BCH fee.",
|
||||
"adr": "ADR-0040"
|
||||
},
|
||||
{
|
||||
"id": "voting-elder-complaint",
|
||||
"name": "ElderFreezeAction + ComplaintCovenant (Phase F)",
|
||||
"family": "governance",
|
||||
"tagline": "Elder-quorum freeze of founder actions + rising-cost complaint system.",
|
||||
"howItWorks": "ElderFreezeAction wraps a founder action in escrow; freeze() requires an Elder quorum co-spending rank-0x03 tokens. ComplaintCovenant charges baseFee·2^count per repeat complaint (unrolled, capped) and lets anyone drain accrued escrow at threshold — anti-spam by rising cost.",
|
||||
"contract": "contracts/ElderFreezeAction.cash",
|
||||
"script": "scripts/chipnet-phase-f-test.mjs",
|
||||
"snapshot": "0127",
|
||||
"snapshotFile": "snapshots/0127-phase-f-chipnet-validated-elder-tier-ran.md",
|
||||
"proofTxid": null,
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "Rising-cost complaint fee; treasury-routed.",
|
||||
"adr": "ADR-0040"
|
||||
},
|
||||
{
|
||||
"id": "sortition-beacon",
|
||||
"name": "SortitionBeacon",
|
||||
"family": "governance",
|
||||
"tagline": "Commit-reveal on-chain randomness for sortition.",
|
||||
"howItWorks": "A commit-reveal beacon produces unbiasable randomness used to draw sortitioned jurors for the bicameral chambers, so no party can grind the selection.",
|
||||
"contract": "contracts/SortitionBeacon.cash",
|
||||
"script": "scripts/chipnet-sortition-beacon-test.mjs",
|
||||
"snapshot": "0133",
|
||||
"snapshotFile": "snapshots/0133-sortitionbeacon-commit-reveal-randomness.md",
|
||||
"proofTxid": null,
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "None.",
|
||||
"adr": "ADR-0040"
|
||||
},
|
||||
{
|
||||
"id": "escalating-vote-nft",
|
||||
"name": "EscalatingVoteNFT",
|
||||
"family": "anti-plutocracy",
|
||||
"tagline": "Vote N costs base × 10^(N-1); only the fixed base is ever redeemable.",
|
||||
"howItWorks": "Fixed always-redeemable backing + an escalating non-recoverable fee (price − base). The NFT identity is un-resettable, so a voter never holds more than base recoverable per vote — capital cannot buy disproportionate weight. Labelled as a governance asset, not a pegged MBA.",
|
||||
"contract": "contracts/EscalatingVoteNFT.cash",
|
||||
"script": "scripts/chipnet-escalating-nft-test.mjs",
|
||||
"snapshot": "0123",
|
||||
"snapshotFile": "snapshots/0123-anti-plutocracy-voting-asset-escalating-.md",
|
||||
"proofTxid": null,
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "Escalating non-recoverable fee; fixed redeemable backing."
|
||||
},
|
||||
{
|
||||
"id": "escalating-vote-dual-nft",
|
||||
"name": "EscalatingVoteDualNFT",
|
||||
"family": "anti-plutocracy",
|
||||
"tagline": "Fixed redeemable backing with a dual rate×fee% ladder (×10 × ×10).",
|
||||
"howItWorks": "Backing stays fixed; a notional rate scales the fee% (feeBps = baseFeeBps × rate/startRate), composing to ×100 cost per vote. Corrects the escalating-backing flaw — anti-plutocracy requires the recoverable amount to stay fixed.",
|
||||
"contract": "contracts/EscalatingVoteDualNFT.cash",
|
||||
"script": "scripts/chipnet-vote-dual-test.mjs",
|
||||
"snapshot": "0126",
|
||||
"snapshotFile": "snapshots/0126-corrected-vote-dual-ladder-fixed-100k-re.md",
|
||||
"proofTxid": null,
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "Dual escalating fee ladder; fixed redeemable backing."
|
||||
},
|
||||
{
|
||||
"id": "anyhedge-hedge-leg",
|
||||
"name": "AnyHedge hedge leg",
|
||||
"family": "integration",
|
||||
"tagline": "General Protocols' AnyHedge proven to settle on chipnet with the Deviant stack.",
|
||||
"howItWorks": "A single covenant holds both sides; payout() settles via checkDataSig against a signed price (16-byte uint32-LE oracle message, shared with the FIATm PegState). Maturity-triggered settlement validated — hedge and long each receive exactly the simulation's predicted sats.",
|
||||
"contract": null,
|
||||
"script": "scripts/chipnet-anyhedge-hedge-leg-test.mjs",
|
||||
"snapshot": "0097",
|
||||
"snapshotFile": "snapshots/0097-turn1-anyhedge-chipnet-validated.md",
|
||||
"proofTxid": "ec45512f5354c736089effd540c1ace98f5a3865ee077701de79ce4547556994",
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "AnyHedge protocol fees (external).",
|
||||
"adr": "ADR-0031 / ADR-0035",
|
||||
"note": "External MIT contract (General Protocols); composed, not authored."
|
||||
},
|
||||
{
|
||||
"id": "anyhedge-liquidation",
|
||||
"name": "AnyHedge liquidation path",
|
||||
"family": "integration",
|
||||
"tagline": "Price-out-of-bounds liquidation before maturity, validated on chipnet.",
|
||||
"howItWorks": "When the oracle price crosses a liquidation bound before maturity, payout() settles early. Validated: hedge +165,000 / long +33,000 sats, matching the BCH-frame simulation exactly.",
|
||||
"contract": null,
|
||||
"script": "scripts/chipnet-anyhedge-liquidation-test.mjs",
|
||||
"snapshot": "0098",
|
||||
"snapshotFile": "snapshots/0098-turn1-5-anyhedge-liquidation-plus-turn2-prep.md",
|
||||
"proofTxid": "82e78f5b9c5d75c581174aea9d2e1e4aa90623e018f7962901813f122e434859",
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "AnyHedge protocol fees (external).",
|
||||
"adr": "ADR-0031"
|
||||
},
|
||||
{
|
||||
"id": "cashback",
|
||||
"name": "Buyer-funded cashback",
|
||||
"family": "integration",
|
||||
"tagline": "A merchant-payment split that pays the buyer cashback — a tx feature, not a covenant.",
|
||||
"howItWorks": "The customer's wallet builds a single transaction with outputs [merchant, cashback→customer, change]. It is single-tx enforcement, deliberately NOT a covenant (a locking script only runs when its own UTXO is spent, never on receipt). Optional ECDSA merchant attestation binds the rate.",
|
||||
"contract": null,
|
||||
"script": "scripts/chipnet-cashback-test.mjs",
|
||||
"snapshot": "0069",
|
||||
"snapshotFile": "snapshots/0069-buyer-funded-cashback-wallet-feature.md",
|
||||
"proofTxid": "383dbd3733a12e437b1f382624aa296e70296d3b13bd65dfcba09f63b411930c",
|
||||
"status": "validated",
|
||||
"verification": "n-a",
|
||||
"feeModel": "Buyer-funded; not covenant-enforced.",
|
||||
"adr": "ADR-0034"
|
||||
},
|
||||
{
|
||||
"id": "research-no-peg",
|
||||
"name": "No-peg drain (V-002)",
|
||||
"family": "security",
|
||||
"tagline": "Remove the rate peg and the reservoir is drained for ~675 sats of dust.",
|
||||
"howItWorks": "A variant with the rate-peg check stripped. Anyone drains 10^18 FTs for dust — proving the peg (output.value == units × rate) is the single load-bearing invariant. Pegged tokens cost ~10^21 sats to drain; unpegged cost ~675. 18 orders of magnitude.",
|
||||
"contract": "contracts/DeviantOpenMintFT_NoPeg.cash",
|
||||
"script": "scripts/chipnet-attack-drain.mjs",
|
||||
"snapshot": "0011",
|
||||
"snapshotFile": "snapshots/0011-rate-peg-attack.md",
|
||||
"proofTxid": "6b5870e5",
|
||||
"status": "research",
|
||||
"verification": "n-a",
|
||||
"feeModel": "n/a — attack PoC.",
|
||||
"note": "Red-team contract. Never deploy. Caught by D-1 (non-canonical) on receipt."
|
||||
},
|
||||
{
|
||||
"id": "research-backdoor",
|
||||
"name": "Non-canonical backdoor rug (T-001)",
|
||||
"family": "security",
|
||||
"tagline": "A Deviant-looking contract with a founderFreeMint() backdoor issuing underbacked FTs.",
|
||||
"howItWorks": "Founder mints 1M tokens for 675 sats and sends underbacked UTXOs to victims. Neutralised on chipnet by D-1 (canonical bytecode mismatch) and D-2 (per-UTXO backing shortfall) firing independently. The reason the verification layer exists.",
|
||||
"contract": "contracts/DeviantOpenMintFT_Backdoor.cash",
|
||||
"script": "scripts/chipnet-attack-rogue-nft.mjs",
|
||||
"snapshot": "0020",
|
||||
"snapshotFile": "snapshots/0020-t001-poc-chipnet.md",
|
||||
"proofTxid": "e6f7e69d",
|
||||
"status": "research",
|
||||
"verification": "n-a",
|
||||
"feeModel": "n/a — attack PoC.",
|
||||
"note": "Red-team contract. Defended by D-1 + D-2."
|
||||
}
|
||||
]
|
||||
}
|
||||
273
Parameters/dApp/Gallery/index.html
Normal file
273
Parameters/dApp/Gallery/index.html
Normal file
|
|
@ -0,0 +1,273 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<title>Deviant Labs — Showcase Gallery</title>
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com" />
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
|
||||
<link href="https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,600;9..144,800&family=JetBrains+Mono:wght@400;600&display=swap" rel="stylesheet" />
|
||||
<style>
|
||||
:root {
|
||||
--sky:#0a0e17; --sky-2:#0e1422; --panel:#121a2b; --panel-2:#16203400;
|
||||
--ink:#eef2f8; --ink-soft:#aeb9cc; --muted:#6f7d96; --line:#1f2b42;
|
||||
--acid:#c6ff3a; --acid-dim:#9bd11f;
|
||||
--safe:#3ad6a0; --warn:#f0c040; --high:#ff5d6c; --research:#b07cff;
|
||||
--display:'Fraunces',Georgia,'Times New Roman',serif;
|
||||
--mono:'JetBrains Mono',ui-monospace,'Cascadia Code',Consolas,monospace;
|
||||
}
|
||||
* { box-sizing:border-box; }
|
||||
html,body { margin:0; background:var(--sky); color:var(--ink); font-family:var(--mono); }
|
||||
body {
|
||||
background:
|
||||
radial-gradient(1200px 600px at 80% -10%, #15203a55, transparent),
|
||||
radial-gradient(900px 500px at -10% 10%, #0f2a2055, transparent),
|
||||
var(--sky);
|
||||
min-height:100vh;
|
||||
}
|
||||
a { color:inherit; }
|
||||
.wrap { max-width:1180px; margin:0 auto; padding:40px 22px 80px; }
|
||||
|
||||
header.hero { border-bottom:1px solid var(--line); padding-bottom:26px; margin-bottom:26px; }
|
||||
.kicker { font-size:12px; letter-spacing:.32em; text-transform:uppercase; color:var(--acid-dim); }
|
||||
h1 { font-family:var(--display); font-weight:800; font-size:clamp(34px,5vw,56px); line-height:1.02; margin:.18em 0 .1em; letter-spacing:-.01em; }
|
||||
h1 .glow { color:var(--acid); text-shadow:0 0 26px #c6ff3a55; }
|
||||
.lede { color:var(--ink-soft); max-width:760px; font-size:15px; line-height:1.6; margin:14px 0 0; }
|
||||
.wedge { margin-top:16px; padding:12px 16px; border-left:3px solid var(--acid); background:#c6ff3a0d; color:var(--ink-soft); font-size:13.5px; line-height:1.55; border-radius:0 8px 8px 0; }
|
||||
.wedge b { color:var(--ink); }
|
||||
|
||||
.statbar { display:flex; flex-wrap:wrap; gap:10px; margin-top:22px; }
|
||||
.stat { background:var(--panel); border:1px solid var(--line); border-radius:10px; padding:10px 14px; }
|
||||
.stat .n { font-family:var(--display); font-weight:800; font-size:22px; color:var(--acid); }
|
||||
.stat .l { font-size:11px; letter-spacing:.12em; text-transform:uppercase; color:var(--muted); }
|
||||
.net { margin-left:auto; align-self:center; font-size:12px; color:var(--warn); border:1px solid #f0c04055; background:#f0c0400f; padding:7px 12px; border-radius:999px; }
|
||||
|
||||
.controls { display:flex; flex-wrap:wrap; gap:14px; align-items:center; margin:28px 0 22px; }
|
||||
.search { flex:1; min-width:220px; background:var(--panel); border:1px solid var(--line); color:var(--ink); border-radius:10px; padding:11px 14px; font-family:var(--mono); font-size:13.5px; }
|
||||
.search::placeholder { color:var(--muted); }
|
||||
.chips { display:flex; flex-wrap:wrap; gap:8px; }
|
||||
.chip { cursor:pointer; user-select:none; font-size:12px; padding:7px 13px; border-radius:999px; border:1px solid var(--line); background:var(--panel); color:var(--ink-soft); transition:.15s; }
|
||||
.chip:hover { border-color:var(--acid-dim); color:var(--ink); }
|
||||
.chip.active { background:var(--acid); color:#0a0e17; border-color:var(--acid); font-weight:600; }
|
||||
|
||||
.famhead { grid-column:1/-1; margin:18px 0 2px; }
|
||||
.famhead h2 { font-family:var(--display); font-weight:600; font-size:21px; margin:0; }
|
||||
.famhead p { color:var(--muted); font-size:12.5px; margin:5px 0 0; max-width:760px; line-height:1.5; }
|
||||
|
||||
.grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(330px,1fr)); gap:16px; }
|
||||
.card { position:relative; background:linear-gradient(180deg,var(--panel),#0f1726); border:1px solid var(--line); border-radius:14px; padding:18px 18px 14px; display:flex; flex-direction:column; transition:.18s; overflow:hidden; }
|
||||
.card::before { content:""; position:absolute; left:0; top:0; bottom:0; width:3px; background:var(--acid); opacity:.0; transition:.18s; }
|
||||
.card:hover { border-color:#2c3a59; transform:translateY(-2px); }
|
||||
.card:hover::before { opacity:.85; }
|
||||
.card .toprow { display:flex; align-items:center; gap:8px; margin-bottom:10px; }
|
||||
.tag { font-size:10.5px; letter-spacing:.1em; text-transform:uppercase; color:var(--muted); }
|
||||
.badges { margin-left:auto; display:flex; gap:6px; }
|
||||
.badge { font-size:10px; padding:3px 8px; border-radius:999px; border:1px solid var(--line); white-space:nowrap; }
|
||||
.b-validated { color:var(--safe); border-color:#3ad6a055; background:#3ad6a00f; }
|
||||
.b-spike { color:var(--warn); border-color:#f0c04055; background:#f0c0400f; }
|
||||
.b-research { color:var(--research); border-color:#b07cff55; background:#b07cff0f; }
|
||||
.b-canonical { color:var(--acid-dim); border-color:#9bd11f55; background:#9bd11f0f; }
|
||||
.card h3 { font-family:var(--display); font-weight:600; font-size:18px; line-height:1.15; margin:0 0 6px; }
|
||||
.card .tagline { color:var(--ink); font-size:13px; line-height:1.45; margin:0 0 10px; }
|
||||
.card .how { color:var(--ink-soft); font-size:12.5px; line-height:1.55; margin:0 0 12px; }
|
||||
.card .meta { font-size:11.5px; color:var(--muted); line-height:1.5; margin:0 0 12px; }
|
||||
.card .meta b { color:var(--ink-soft); font-weight:600; }
|
||||
.card .hl { font-size:11.5px; color:var(--acid-dim); margin:0 0 12px; }
|
||||
.links { margin-top:auto; display:flex; flex-wrap:wrap; gap:7px; padding-top:12px; border-top:1px solid var(--line); }
|
||||
.lk { font-size:11px; padding:5px 10px; border-radius:7px; border:1px solid var(--line); color:var(--ink-soft); text-decoration:none; transition:.15s; }
|
||||
.lk:hover { border-color:var(--acid-dim); color:var(--ink); }
|
||||
.lk.proof { color:var(--acid); border-color:#c6ff3a44; }
|
||||
.lk.dim { color:var(--muted); border-style:dashed; }
|
||||
|
||||
footer { margin-top:50px; padding-top:22px; border-top:1px solid var(--line); color:var(--muted); font-size:12px; line-height:1.6; }
|
||||
footer b { color:var(--ink-soft); }
|
||||
.fallback-note { display:none; margin-top:14px; font-size:11.5px; color:var(--warn); }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="wrap">
|
||||
<header class="hero">
|
||||
<div class="kicker">Deviant Labs</div>
|
||||
<h1>Showcase <span class="glow">Gallery</span></h1>
|
||||
<p class="lede">Every validated Deviant on-chain algorithm — each a CashScript covenant proven end-to-end on chipnet. What it does, how it works, the source, and a live transaction as proof. These are dApps at the protocol layer: non-custodial, permissionless, consensus-enforced.</p>
|
||||
<div class="wedge">The defensible wedge: several BCH wallets speak WalletConnect, but none tell a user <b>"this contract is canonical / this token is underbacked."</b> Deviant Labs is built as the <b>safety-verified BCH dApp gateway</b> — verification is a reported fact, not a gate.</div>
|
||||
<div class="statbar" id="statbar"></div>
|
||||
</header>
|
||||
|
||||
<div class="controls">
|
||||
<input class="search" id="search" type="text" placeholder="Search algorithms — name, mechanism, family…" />
|
||||
<div class="chips" id="chips"></div>
|
||||
</div>
|
||||
|
||||
<div class="grid" id="grid"></div>
|
||||
|
||||
<footer>
|
||||
<b>Network:</b> chipnet only. Mainnet is deferred until the audit + regulatory pass (R-016). ·
|
||||
<b>Proof:</b> every <span style="color:var(--safe)">validated</span> entry links a real chipnet transaction; where a single TXID was not surfaced, the validating snapshot is linked instead. ·
|
||||
<b>Source of truth:</b> <code>catalog.json</code> — this page renders from it, and the functional hub + in-wallet Labs tab consume the same file.
|
||||
<div class="fallback-note" id="fallbackNote">⚠ Rendering from the embedded fallback copy (catalog.json could not be fetched — likely opened as a local file). For the live catalog, serve this folder over HTTP.</div>
|
||||
</footer>
|
||||
</div>
|
||||
|
||||
<!-- FALLBACK MIRROR of catalog.json — used only when fetch() fails (e.g. opened via file://).
|
||||
Regenerate this block whenever catalog.json changes. catalog.json remains the canonical source. -->
|
||||
<script type="application/json" id="catalog-fallback">
|
||||
{
|
||||
"meta": {
|
||||
"title": "Deviant Labs — Showcase Gallery Catalog",
|
||||
"version": 1,
|
||||
"network": "chipnet",
|
||||
"explorerTxUrl": "https://chipnet.imaginary.cash/tx/",
|
||||
"repoRoot": "../../../",
|
||||
"generated": "2026-06-17"
|
||||
},
|
||||
"families": [
|
||||
{ "id": "core", "name": "Core protocol", "blurb": "The Agora swap engine and Artemision asset creation — the self-backed MBA primitives everything else builds on." },
|
||||
{ "id": "dra", "name": "Dynamic-Rate Assets", "blurb": "MBAs whose backing rate is a transparent, published function of contract state — linear, stepped, exponential, super-exponential, and stepped-fee curves." },
|
||||
{ "id": "prediction", "name": "Prediction markets", "blurb": "Pari-mutuel totes and oracle-settled bilateral escrows — outcome trustless via oracle, payouts covenant-enforced." },
|
||||
{ "id": "shares", "name": "Binary share markets", "blurb": "Family D — collateralized fixed-terminal-value share markets (Polymarket-shape): split/merge, CLOB, AMM, oracle-priced vaults." },
|
||||
{ "id": "instruments", "name": "Backed instruments", "blurb": "Time-boxed, oracle-priced and peg-tracked MBA instruments — self-backed value that redeems unilaterally." },
|
||||
{ "id": "games", "name": "Games & escrow", "blurb": "Non-custodial prize pools and on-chain game settlement — the stake is in a covenant, never an operator wallet." },
|
||||
{ "id": "governance", "name": "On-chain governance", "blurb": "The bicameral-sortition voting stack — citizenship, applications, ballots, endorsement, and elder/complaint defences, validated phase by phase." },
|
||||
{ "id": "anti-plutocracy", "name": "Anti-plutocracy assets", "blurb": "Vote assets whose cost escalates per vote so capital cannot dominate — fixed redeemable backing, escalating non-recoverable fee." },
|
||||
{ "id": "integration", "name": "Integrations", "blurb": "External BCH-DeFi protocols proven to compose with the Deviant stack — AnyHedge hedge legs, buyer-funded cashback." },
|
||||
{ "id": "security", "name": "Security research", "blurb": "Red-team contracts attacked on chipnet before shipping. Kept on record as proof of rigor — these are the threats the verification layer (D-1/D-2) defends against." }
|
||||
],
|
||||
"entries": [
|
||||
{ "id": "agora-asm-swap", "name": "Agora — ASM (Automated Swap Mechanism)", "family": "core", "tagline": "Permissionless, atomic, BCH-backed token swaps with no DEX, AMM, oracle, or operator.", "howItWorks": "Each token UTXO is self-backed: it carries its own BCH inside at a fixed rate. A swap is a single transaction — the source side is a plain P2PKH spend releasing its backing, the target side's claim() mints from a reservoir at whatever rate it computes. Atomicity is guaranteed at the BCH layer, not by coupling covenants. A founder fee produces a consensus-enforced bid/ask spread.", "contract": "contracts/DeviantOracleMBA.cash", "script": "scripts/chipnet-asm-swap.mjs", "snapshot": "0008", "snapshotFile": "snapshots/0008-q4-result.md", "proofTxid": "e68e610f0e4f5374d6bbc8564ca80ce10f11fae7c21cf526c094bec867dd7370", "status": "validated", "verification": "canonical", "feeModel": "Founder fee (bps) routed to a constructor-chosen address; consensus-enforced.", "highlight": "129+ swaps on chipnet, zero exploits." },
|
||||
{ "id": "artemision-mba-genesis", "name": "Artemision — MBA asset creation", "family": "core", "tagline": "Mint a self-backed asset (MBA) anyone can later claim, swap, and redeem — permissionlessly.", "howItWorks": "Genesis pre-mints the full FT supply into a contract reservoir and parks a minting/declaration NFT at the contract address. Anyone can reconstruct the contract from public params and claim() at the protocol rate — no founder approval needed. Redemption is a contract-free P2PKH spend that releases the backing and burns the FT.", "contract": "contracts/DeviantOracleMBA.cash", "script": "scripts/chipnet-asm-genesis.mjs", "snapshot": "0009", "snapshotFile": "snapshots/0009-cross-founder-mint.md", "proofTxid": "7767c9dd2165229f78c95e48cacc6c289cac41d95cc3ff90c23b32f1815d47b8", "status": "validated", "verification": "canonical", "feeModel": "Optional founder fee at claim; zero-fee genesis is fully open-mint.", "highlight": "Cross-wallet claim proven — anyone can interact from registry params alone." },
|
||||
{ "id": "bonding-curve-dra", "name": "Bonding-curve DRA (linear)", "family": "dra", "tagline": "An MBA whose backing rate rises linearly with issuance along a published curve.", "howItWorks": "claim() computes the rate as base + issuedSoFar/step · increment, reading issuance from reservoir depletion. The curve params are public, so the contract is D-1 verifiable; a masked single rate would be a T-003 masquerade. Arithmetic vote ladders (e.g. +2 votes/step → N² cumulative cost) reuse this exact template.", "contract": "contracts/DeviantBondingCurveFT.cash", "script": "scripts/chipnet-bonding-swap-test.mjs", "snapshot": "0027", "snapshotFile": "snapshots/0027-bonding-curve-swap-and-premium-feature.md", "proofTxid": "066f8ff104f22447e9c6bfa9c04e6b7c6213599fcf4ddb41707e9484ce210d64", "status": "validated", "verification": "canonical", "feeModel": "Founder fee bps optional; rate escalation is the pricing mechanism.", "adr": "ADR-0015" },
|
||||
{ "id": "exp-dra", "name": "Exponential DRA", "family": "dra", "tagline": "Self-backed bonding curve where the rate multiplies each claim (×2, ×10, …).", "howItWorks": "The current rate lives in a mutable NFT commitment at the contract address; each claim reads it via int(), enforces payout, then ratchets it by the multiplier. Un-resettable because the position UTXO returns to the contract. No pow/loops needed; batch buys use bounded unroll (fixed-N claim3()).", "contract": "contracts/DeviantExpDRA.cash", "script": "scripts/chipnet-exp-dra-test.mjs", "snapshot": "0128", "snapshotFile": "snapshots/0128-exponential-dra-global-self-backed-rate-.md", "proofTxid": "e4c1498747561b4c390434d2c88f2cfb5adac61a54cff813b98a3e0ae5add614", "status": "validated", "verification": "canonical", "feeModel": "Escalation is the cost mechanism; self-backed." },
|
||||
{ "id": "step-dra", "name": "Step / tiered DRA", "family": "dra", "tagline": "Rate is flat within a tier, then jumps at the tier boundary.", "howItWorks": "Derives minted = supply − reservoir and mintedInTier = minted % tierSize. claimBatch(k) enforces k ≤ remainingInTier and delivers k units as one bundle at the flat tier rate, escalating only when a tier completes. Lets arbitrary k be bought in one tx with no pow.", "contract": "contracts/DeviantStepDRA.cash", "script": "scripts/chipnet-step-dra-test.mjs", "snapshot": "0130", "snapshotFile": "snapshots/0130-step-tiered-dra-flat-rate-per-tier-bound.md", "proofTxid": "8e0722efa4f8eb46aeafd4f6377b1bbb31da61c9f81e236b668c63c684cfb46b", "status": "validated", "verification": "canonical", "feeModel": "Tiered rate escalation; self-backed." },
|
||||
{ "id": "super-exp-dra", "name": "Super-exponential DRA", "family": "dra", "tagline": "A one-and-done wall: rate → (rate × 3.14)³ per claim, unbuyable past 2–3 units.", "howItWorks": "Escalation law applies (rate × 314/100)³ using only exact multiplies (no pow). After one cheap claim the next unit costs hundreds of BCH; two claims past that exceed the entire BCH supply — a hard structural cap per identity. The escalation law is a free design knob.", "contract": "contracts/DeviantSuperExpDRA.cash", "script": "scripts/chipnet-step-plutocrat-test.mjs", "snapshot": "0131", "snapshotFile": "snapshots/0131-step-plutocrat-cost-ladder-super-exponen.md", "proofTxid": null, "status": "validated", "verification": "canonical", "feeModel": "Escalation is a deterrent cap, not revenue." },
|
||||
{ "id": "escfee-supply", "name": "Escalating-fee MBA (supply trigger)", "family": "dra", "tagline": "Founder fee steps UP as cumulative issuance grows.", "howItWorks": "feeBps = min(base + (issued/step)·feeStep, maxFee), reading issuance from reservoir depletion. Supply trigger is the canonical escalation (block-height was rejected — tx.time is only a CLTV lower bound). D-1 reconstructs the schedule from published params.", "contract": "contracts/DeviantEscFeeSupply.cash", "script": "scripts/chipnet-escfee-supply-test.mjs", "snapshot": "0058", "snapshotFile": "snapshots/0058-escalating-fee-feasibility-chipnet.md", "proofTxid": "d76c14926373ff2f280e77934b5d0d5596b347a72666110867d27c84cd8436ef", "status": "validated", "verification": "canonical", "feeModel": "Stepped founder fee, increasing with supply.", "adr": "ADR-0029" },
|
||||
{ "id": "descfee-supply", "name": "Decreasing-fee MBA (metals: GLD/SLV/CUP)", "family": "dra", "tagline": "Founder fee steps DOWN over issuance — the metal MBAs use this.", "howItWorks": "feeBps = max(base − (issued/step)·feeStep, floor). The metal assets (GLD/SLV/CUP and divisible variants) ship 5.0% → 0.25% schedules with reservoirs seeded at 2⁶³−1 so 'depletion' is a non-event for circulating assets. First-class in the wallet via Route B.", "contract": "contracts/DeviantDescFeeSupply.cash", "script": "scripts/chipnet-create-metal-mbas.mjs", "snapshot": "0086", "snapshotFile": "snapshots/0086-metal-mbas-gld-slv-cup-decreasing-fee-an.md", "proofTxid": "eda2c713e6c7169174ca32ef4900c0e588f1150b7e73630368e56257105ebfdd", "status": "validated", "verification": "canonical", "feeModel": "Stepped founder fee, decreasing with supply; revenue proven via cross-account claims.", "adr": "ADR-0029 / ADR-0037" },
|
||||
{ "id": "parimutuel-tote", "name": "Pari-mutuel tote (fixed roster)", "family": "prediction", "tagline": "Oracle-settled pooled wager with covenant-enforced pro-rata payout.", "howItWorks": "Bettors fund the pool; an oracle signs {eventId, outcome} via checkDataSig at settlement. Winners split the pool pro-rata (floor division, last claimant drains the residual so no dust is lost). Outcome is trustless (oracle), the split is covenant-computed.", "contract": "contracts/ParimutuelTote.cash", "script": "scripts/chipnet-oracle-markets-test.mjs", "snapshot": "0045", "snapshotFile": "snapshots/0045-oracle-markets-chipnet.md", "proofTxid": "79c732c6aca80e04ad43241cc6dff767c2f7a0ffb0f866741d8d60e768290031", "status": "validated", "verification": "n-a", "feeModel": "Optional covenant-enforced operator rake (published bps).", "adr": "ADR-0024" },
|
||||
{ "id": "open-tote", "name": "Open-entry tote (Tier 2, covenant-enforced)", "family": "prediction", "tagline": "Anyone can join; double-claim and loser-claim are rejected on-chain.", "howItWorks": "A state NFT carries the pool commitment (phase, outcome, side totals); each bet mints a receipt NFT. claim() computes pro-rata payout and the receipt's claimed flag blocks reuse — double-claims and wrong-side claims fail at consensus. Refund and sweep backstops are CLTV-timelocked.", "contract": "contracts/ParimutuelToteOpen.cash", "script": "scripts/chipnet-opentote-test.mjs", "snapshot": "0047", "snapshotFile": "snapshots/0047-open-entry-tote-nft-free-chipnet.md", "proofTxid": "060c4caf8df06032fe72bff5235a815dd7ecad185502b1f0a9fd57cdb50dd083", "status": "validated", "verification": "n-a", "feeModel": "Optional operator rake taken off the top at attest().", "adr": "ADR-0024" },
|
||||
{ "id": "tote4-multioutcome", "name": "Multi-outcome tote (K=4)", "family": "prediction", "tagline": "Pari-mutuel across up to 4 outcomes with 2-winner pro-rata splits.", "howItWorks": "Fixed-K commitment packs per-outcome totals (8 bytes each) in the state; claim collapses to the winning outcome with the same receipt-gated winner check as the binary case. K capped at 4 by the 40-byte commitment budget.", "contract": "contracts/ParimutuelTote4.cash", "script": "scripts/chipnet-tote4-test.mjs", "snapshot": "0046", "snapshotFile": "snapshots/0046-parimutuel-tote-4party-chipnet.md", "proofTxid": "a85621ac21e10c7a1ebccab2e316efd42a89d3cd1cf8c13542a81e2443429e6c", "status": "validated", "verification": "n-a", "feeModel": "Optional operator rake." },
|
||||
{ "id": "event-prediction-escrow", "name": "Event-prediction escrow (bilateral)", "family": "prediction", "tagline": "Oracle-settled bilateral wager with asymmetric stakes (odds).", "howItWorks": "Two parties co-sign their own stakes into an escrow; an oracle signs the outcome via checkDataSig and the pool routes to the winner. Unequal stakes encode odds — a book of bilateral escrows, not a single pool.", "contract": "contracts/EventPredictionEscrow.cash", "script": "scripts/chipnet-oracle-markets-test.mjs", "snapshot": "0045", "snapshotFile": "snapshots/0045-oracle-markets-chipnet.md", "proofTxid": "fc2b5a08f00bdf7e661c8cef95a2e0b36073c3cd77019ed68b6ed66b8b84bc34", "status": "validated", "verification": "n-a", "feeModel": "None / optional arbiter fee." },
|
||||
{ "id": "binary-share-vault-bch", "name": "Binary share vault (BCH CLOB)", "family": "shares", "tagline": "Polymarket-shape outcome shares: 1 collateral → 1 YES + 1 NO.", "howItWorks": "A vault holds BCH collateral and a minting NFT. split(N) locks N sats and mints a YES+NO share pair; merge() burns a matching pair and releases the sats; attest(outcome) settles via oracle; redeem() pays the winning share 1:1. The YES+NO ≡ collateral invariant is enforced on-chain.", "contract": "contracts/BinaryShareVaultBCH.cash", "script": "scripts/chipnet-clob-bch-test.mjs", "snapshot": "0062", "snapshotFile": "snapshots/0062-family-d-config-1-pure-bch-clob-split-me.md", "proofTxid": "aa23def8e7359000f056a5e5f75b8a9de1b497b30ebd52c9abb45e52ed00d7e2", "status": "validated", "verification": "n-a", "feeModel": "None in spike; fee policy TBD.", "adr": "ADR-0030", "note": "Spike — config 1 of 3." },
|
||||
{ "id": "binary-share-fungible", "name": "Fungible binary shares (two-category)", "family": "shares", "tagline": "The real Polymarket product — tradeable fungible YES/NO tokens.", "howItWorks": "Full share supply is pre-minted into the covenant as FT reserves (RESERVE model). No live minting NFT survives, so over-issuance is impossible — consensus FT conservation + output pinning suffice. Shares trade freely as ordinary CashTokens.", "contract": "contracts/BinaryShareFungibleBCH.cash", "script": "scripts/chipnet-clob-fungible-test.mjs", "snapshot": "0063", "snapshotFile": "snapshots/0063-family-d-configs-2-3-mba-collateral-fung.md", "proofTxid": null, "status": "validated", "verification": "n-a", "feeModel": "None in spike.", "adr": "ADR-0030", "note": "Spike — config 3." },
|
||||
{ "id": "share-limit-order", "name": "On-chain resting limit order", "family": "shares", "tagline": "A partially-fillable limit order parked in a covenant — no off-chain book.", "howItWorks": "A resting order is an ASM swap-offer in a covenant: take() fills partially (the covenant re-creates itself with the remainder), cancel() lets the maker reclaim. Price is integer sats/share; orders are discoverable by scanning the share category.", "contract": "contracts/ShareLimitOrderBCH.cash", "script": "scripts/chipnet-clob-orders-test.mjs", "snapshot": "0064", "snapshotFile": "snapshots/0064-family-d-on-chain-resting-limit-orders-s.md", "proofTxid": null, "status": "validated", "verification": "n-a", "feeModel": "None in spike.", "note": "Spike — ASK side; BID is the symmetric mirror." },
|
||||
{ "id": "share-pair-amm", "name": "SharePairAMM (constant product)", "family": "shares", "tagline": "x·y=k automated market maker over fungible YES/NO shares.", "howItWorks": "Co-spent reserve UTXOs; swap() preserves the constant product; manageLiquidity() is LP-signed. An AMM alternative to the order book for probability discovery where no resting liquidity exists.", "contract": "contracts/SharePairAMM.cash", "script": "scripts/chipnet-clob-amm-test.mjs", "snapshot": "0065", "snapshotFile": "snapshots/0065-family-d-amm-sharepairamm-adr-0031-oracl.md", "proofTxid": null, "status": "validated", "verification": "n-a", "feeModel": "Swap fee TBD; LP-share accounting open.", "note": "Spike." },
|
||||
{ "id": "oracle-priced-vault", "name": "Oracle-priced vault", "family": "shares", "tagline": "A value-locked vault settled against a signed external price.", "howItWorks": "margin is locked at price p0 → a nominal value; settle() at p1 verifies the oracle via checkDataSig and pays the value-locked amount. Externally-priced assets can be oracle-priced (the covenant is the counterparty); binary events cannot (the market exists to discover the probability).", "contract": "contracts/OraclePricedVault.cash", "script": "scripts/chipnet-oracle-vault-test.mjs", "snapshot": "0065", "snapshotFile": "snapshots/0065-family-d-amm-sharepairamm-adr-0031-oracl.md", "proofTxid": null, "status": "spike", "verification": "n-a", "feeModel": "None in spike.", "adr": "ADR-0031", "note": "Spike — oracle freshness bound still open (production-blocking)." },
|
||||
{ "id": "expiring-mba", "name": "ExpiringMBA", "family": "instruments", "tagline": "A time-boxed self-backed instrument that reverts to a fixed owner at maturity.", "howItWorks": "redeem() releases backing to the owner anytime. expire() is permissionless after the CLTV maturity height and reverts all backing to a fixed owner address (non-capturable by the triggerer). 'Automatic expiry' = consensus time gate + permissionless destination; nothing schedules itself on a UTXO.", "contract": "contracts/ExpiringMBA.cash", "script": "scripts/chipnet-expiring-mba-test.mjs", "snapshot": "0066", "snapshotFile": "snapshots/0066-expiringmba-time-boxed-self-backed-instr.md", "proofTxid": "9e551c3d63f0e3c8704c3a7658a0fc52585be31a43f9211b3d5281558d1c0e5c", "status": "validated", "verification": "canonical", "feeModel": "None.", "adr": "ADR-0032" },
|
||||
{ "id": "pegstate-oracle-mba", "name": "PegState — oracle-tracked USDm", "family": "instruments", "tagline": "A single-oracle price-adjusting MBA that tracks a fiat peg (USDm).", "howItWorks": "A PegState covenant holds the current oracle price; the MBA's backing rate adjusts to track a fiat unit (the FIATm/USDm family). The oracle is a signaling machine filtered by threshold and multi-block confirmation, not a price authority — the immutable controller is the decision-maker, with bounded blast radius even if the oracle is compromised.", "contract": "contracts/PegState.cash", "script": "scripts/chipnet-pegstate-test.mjs", "snapshot": "0139", "snapshotFile": "snapshots/0139-pegstate-single-oracle-usdm-price-adjust.md", "proofTxid": "7703e81a296cba16542640583a095a9ed0bc8b0e82158ee1773a255dbac4ea04", "status": "validated", "verification": "canonical", "feeModel": "Founder fee per MBA template.", "note": "FIATm/USDm family." },
|
||||
{ "id": "game-pool-escrow", "name": "GamePoolEscrow", "family": "games", "tagline": "Winner-take-all prize pool with arbiter, hashlock, or refund resolution.", "howItWorks": "The stake sits in the covenant, never an operator wallet. resolveHashlock() is trustless commit-reveal; resolveArbiter() lets a named arbiter sign the winner; refund() is timelocked. Even a malicious arbiter can only route the pot between the two players — it cannot be stolen.", "contract": "contracts/GamePoolEscrow.cash", "script": "scripts/chipnet-escrow-test.mjs", "snapshot": "0039", "snapshotFile": "snapshots/0039-game-pool-escrow.md", "proofTxid": "dd6c0e72aed86338d3d4e9420f49c818d52625070b533200368315e62cbead61", "status": "validated", "verification": "n-a", "feeModel": "Optional arbiter fee (flat or bps), peg-preserving." },
|
||||
{ "id": "checkers-game", "name": "CheckersGame (WalletConnect dApp)", "family": "games", "tagline": "Non-custodial checkers stake settled by GamePoolEscrow over WalletConnect.", "howItWorks": "Players co-sign their own stakes via WalletConnect — keys never leave the wallet. The escrow covenant holds the pot and pays the winner; checkers logic runs off-chain (the front-end) while custody and payout are on-chain. The reference example of a connectable Deviant dApp.", "contract": "contracts/CheckersGame.cash", "script": "scripts/chipnet-checkers-game-test.mjs", "snapshot": "0040", "snapshotFile": "snapshots/0040-escrow-flat-fee-and-irregular.md", "proofTxid": null, "status": "validated", "verification": "n-a", "feeModel": "Optional arbiter/operator fee.", "highlight": "WalletConnect co-sign validated end-to-end." },
|
||||
{ "id": "poll-covenant", "name": "PollCovenant", "family": "governance", "tagline": "One-person-one-vote, allowlisted, permissionless expiry.", "howItWorks": "Per-voter covenants route their UTXO value to a ballot-box address by choice (0/1); expire() returns unvoted stakes to the issuer after closeHeight (CLTV). Sybil resistance lives in the issuer's allowlist (the trust anchor), not the covenant.", "contract": "contracts/PollCovenant.cash", "script": "scripts/chipnet-poll-test.mjs", "snapshot": "0105", "snapshotFile": "snapshots/0105-pollcovenant-binary-on-chain-voting-one-.md", "proofTxid": "9ad2f60518a564d25168909728d563a88207654e314b1435e84faecfb06f294e", "status": "validated", "verification": "n-a", "feeModel": "None.", "adr": "ADR-0040" },
|
||||
{ "id": "tally-state", "name": "TallyState (trustless tally)", "family": "governance", "tagline": "On-chain vote tally read by other covenants with no oracle.", "howItWorks": "Tally counts live in an NFT commitment; another covenant reads the outcome by co-spending the tally UTXO — the 'co-spend as oracle' idiom — with no named signer. The Counting and Presentation layers become blockchain-trustless.", "contract": "contracts/TallyState.cash", "script": "scripts/chipnet-tally-as-oracle-test.mjs", "snapshot": "0106", "snapshotFile": "snapshots/0106-voting-composition-trilogy-poll-as-oracl.md", "proofTxid": null, "status": "validated", "verification": "n-a", "feeModel": "None.", "adr": "ADR-0040" },
|
||||
{ "id": "voting-citizen-token", "name": "CitizenToken (Phase A)", "family": "governance", "tagline": "Per-rank membership NFT — Citizen / Delegated / Elder / Founder.", "howItWorks": "A mutable NFT whose commitment byte encodes rank (0x01–0x04). Used as a co-spent proof of rank to gate voting and elder actions across the governance stack. Phase A also lands the per-applicant ApplicationCovenant.", "contract": "contracts/CitizenToken.cash", "script": "scripts/chipnet-phase-a-test.mjs", "snapshot": "0114", "snapshotFile": "snapshots/0114-phase-a-citizentoken-applicationcovenant.md", "proofTxid": "511ee6ea55d599ce0fb3ea7b84025ee0011159bb703f73466de512f02dd822ee", "status": "validated", "verification": "n-a", "feeModel": "None.", "adr": "ADR-0040" },
|
||||
{ "id": "voting-registry-state", "name": "RegistryState + bicameral application (Phase B)", "family": "governance", "tagline": "Adaptive-threshold membership registry with bicameral voting.", "howItWorks": "RegistryState holds memberCount + threshold; admit() increments and recomputes threshold = min(15, ceil(count/100)). ApplicationCovenantB runs Citizen and Delegated chambers with per-chamber rank-gated votes; close() requires both thresholds met. readOnly() exposes the registry as a co-spend oracle.", "contract": "contracts/RegistryState.cash", "script": "scripts/chipnet-phase-b-test.mjs", "snapshot": "0116", "snapshotFile": "snapshots/0116-phase-b-chipnet-validated-registrystate-.md", "proofTxid": "e68c314383549ce9658199d2997bd586265ec41dd6608f2f829ba4b01b7dfe9c", "status": "validated", "verification": "n-a", "feeModel": "None.", "adr": "ADR-0040" },
|
||||
{ "id": "voting-ballot-commit-reveal", "name": "BallotCovenant — secret ballot (Phase E)", "family": "governance", "tagline": "Commit-reveal secret voting with hash-bound choices.", "howItWorks": "commit() stores sha256(choice‖nonce‖voterPkh) once; reveal() is co-spent with the application and verifies the preimage before recording the choice. Preserves the Phase D escrow (paid-regardless-of-vote) anti-bribery mechanics. Wrong-nonce reveals are rejected on-chain.", "contract": "contracts/BallotCovenant.cash", "script": "scripts/chipnet-phase-e-test.mjs", "snapshot": "0119", "snapshotFile": "snapshots/0119-phase-e-chipnet-validated-ballotcovenant.md", "proofTxid": null, "status": "validated", "verification": "n-a", "feeModel": "Embedded per-vote reward (paid regardless of choice).", "adr": "ADR-0040" },
|
||||
{ "id": "voting-endorsement", "name": "EndorsementCovenant — on-chain pre-gate (Phase F prereq)", "family": "governance", "tagline": "On-chain rank-gated endorsement counter — the pre-gate, with no trusted verifier.", "howItWorks": "Per-applicant counter NFT; endorse() is co-spent with an endorser's CitizenToken (rank-gated) and increments up to threshold; graduate() consumes the UTXO at threshold. Replaces the abandoned off-chain pre-gate: 'what the chain CAN enforce, the chain SHOULD enforce.'", "contract": "contracts/EndorsementCovenant.cash", "script": "scripts/chipnet-endorsement-test.mjs", "snapshot": "0124", "snapshotFile": "snapshots/0124-correction-pre-gate-is-on-chain-endorsem.md", "proofTxid": null, "status": "validated", "verification": "n-a", "feeModel": "Trivial per-endorsement BCH fee.", "adr": "ADR-0040" },
|
||||
{ "id": "voting-elder-complaint", "name": "ElderFreezeAction + ComplaintCovenant (Phase F)", "family": "governance", "tagline": "Elder-quorum freeze of founder actions + rising-cost complaint system.", "howItWorks": "ElderFreezeAction wraps a founder action in escrow; freeze() requires an Elder quorum co-spending rank-0x03 tokens. ComplaintCovenant charges baseFee·2^count per repeat complaint (unrolled, capped) and lets anyone drain accrued escrow at threshold — anti-spam by rising cost.", "contract": "contracts/ElderFreezeAction.cash", "script": "scripts/chipnet-phase-f-test.mjs", "snapshot": "0127", "snapshotFile": "snapshots/0127-phase-f-chipnet-validated-elder-tier-ran.md", "proofTxid": null, "status": "validated", "verification": "n-a", "feeModel": "Rising-cost complaint fee; treasury-routed.", "adr": "ADR-0040" },
|
||||
{ "id": "sortition-beacon", "name": "SortitionBeacon", "family": "governance", "tagline": "Commit-reveal on-chain randomness for sortition.", "howItWorks": "A commit-reveal beacon produces unbiasable randomness used to draw sortitioned jurors for the bicameral chambers, so no party can grind the selection.", "contract": "contracts/SortitionBeacon.cash", "script": "scripts/chipnet-sortition-beacon-test.mjs", "snapshot": "0133", "snapshotFile": "snapshots/0133-sortitionbeacon-commit-reveal-randomness.md", "proofTxid": null, "status": "validated", "verification": "n-a", "feeModel": "None.", "adr": "ADR-0040" },
|
||||
{ "id": "escalating-vote-nft", "name": "EscalatingVoteNFT", "family": "anti-plutocracy", "tagline": "Vote N costs base × 10^(N-1); only the fixed base is ever redeemable.", "howItWorks": "Fixed always-redeemable backing + an escalating non-recoverable fee (price − base). The NFT identity is un-resettable, so a voter never holds more than base recoverable per vote — capital cannot buy disproportionate weight. Labelled as a governance asset, not a pegged MBA.", "contract": "contracts/EscalatingVoteNFT.cash", "script": "scripts/chipnet-escalating-nft-test.mjs", "snapshot": "0123", "snapshotFile": "snapshots/0123-anti-plutocracy-voting-asset-escalating-.md", "proofTxid": null, "status": "validated", "verification": "n-a", "feeModel": "Escalating non-recoverable fee; fixed redeemable backing." },
|
||||
{ "id": "escalating-vote-dual-nft", "name": "EscalatingVoteDualNFT", "family": "anti-plutocracy", "tagline": "Fixed redeemable backing with a dual rate×fee% ladder (×10 × ×10).", "howItWorks": "Backing stays fixed; a notional rate scales the fee% (feeBps = baseFeeBps × rate/startRate), composing to ×100 cost per vote. Corrects the escalating-backing flaw — anti-plutocracy requires the recoverable amount to stay fixed.", "contract": "contracts/EscalatingVoteDualNFT.cash", "script": "scripts/chipnet-vote-dual-test.mjs", "snapshot": "0126", "snapshotFile": "snapshots/0126-corrected-vote-dual-ladder-fixed-100k-re.md", "proofTxid": null, "status": "validated", "verification": "n-a", "feeModel": "Dual escalating fee ladder; fixed redeemable backing." },
|
||||
{ "id": "anyhedge-hedge-leg", "name": "AnyHedge hedge leg", "family": "integration", "tagline": "General Protocols' AnyHedge proven to settle on chipnet with the Deviant stack.", "howItWorks": "A single covenant holds both sides; payout() settles via checkDataSig against a signed price (16-byte uint32-LE oracle message, shared with the FIATm PegState). Maturity-triggered settlement validated — hedge and long each receive exactly the simulation's predicted sats.", "contract": null, "script": "scripts/chipnet-anyhedge-hedge-leg-test.mjs", "snapshot": "0097", "snapshotFile": "snapshots/0097-turn1-anyhedge-chipnet-validated.md", "proofTxid": "ec45512f5354c736089effd540c1ace98f5a3865ee077701de79ce4547556994", "status": "validated", "verification": "n-a", "feeModel": "AnyHedge protocol fees (external).", "adr": "ADR-0031 / ADR-0035", "note": "External MIT contract (General Protocols); composed, not authored." },
|
||||
{ "id": "anyhedge-liquidation", "name": "AnyHedge liquidation path", "family": "integration", "tagline": "Price-out-of-bounds liquidation before maturity, validated on chipnet.", "howItWorks": "When the oracle price crosses a liquidation bound before maturity, payout() settles early. Validated: hedge +165,000 / long +33,000 sats, matching the BCH-frame simulation exactly.", "contract": null, "script": "scripts/chipnet-anyhedge-liquidation-test.mjs", "snapshot": "0098", "snapshotFile": "snapshots/0098-turn1-5-anyhedge-liquidation-plus-turn2-prep.md", "proofTxid": "82e78f5b9c5d75c581174aea9d2e1e4aa90623e018f7962901813f122e434859", "status": "validated", "verification": "n-a", "feeModel": "AnyHedge protocol fees (external).", "adr": "ADR-0031" },
|
||||
{ "id": "cashback", "name": "Buyer-funded cashback", "family": "integration", "tagline": "A merchant-payment split that pays the buyer cashback — a tx feature, not a covenant.", "howItWorks": "The customer's wallet builds a single transaction with outputs [merchant, cashback→customer, change]. It is single-tx enforcement, deliberately NOT a covenant (a locking script only runs when its own UTXO is spent, never on receipt). Optional ECDSA merchant attestation binds the rate.", "contract": null, "script": "scripts/chipnet-cashback-test.mjs", "snapshot": "0069", "snapshotFile": "snapshots/0069-buyer-funded-cashback-wallet-feature.md", "proofTxid": "383dbd3733a12e437b1f382624aa296e70296d3b13bd65dfcba09f63b411930c", "status": "validated", "verification": "n-a", "feeModel": "Buyer-funded; not covenant-enforced.", "adr": "ADR-0034" },
|
||||
{ "id": "research-no-peg", "name": "No-peg drain (V-002)", "family": "security", "tagline": "Remove the rate peg and the reservoir is drained for ~675 sats of dust.", "howItWorks": "A variant with the rate-peg check stripped. Anyone drains 10^18 FTs for dust — proving the peg (output.value == units × rate) is the single load-bearing invariant. Pegged tokens cost ~10^21 sats to drain; unpegged cost ~675. 18 orders of magnitude.", "contract": "contracts/DeviantOpenMintFT_NoPeg.cash", "script": "scripts/chipnet-attack-drain.mjs", "snapshot": "0011", "snapshotFile": "snapshots/0011-rate-peg-attack.md", "proofTxid": "6b5870e5", "status": "research", "verification": "n-a", "feeModel": "n/a — attack PoC.", "note": "Red-team contract. Never deploy. Caught by D-1 (non-canonical) on receipt." },
|
||||
{ "id": "research-backdoor", "name": "Non-canonical backdoor rug (T-001)", "family": "security", "tagline": "A Deviant-looking contract with a founderFreeMint() backdoor issuing underbacked FTs.", "howItWorks": "Founder mints 1M tokens for 675 sats and sends underbacked UTXOs to victims. Neutralised on chipnet by D-1 (canonical bytecode mismatch) and D-2 (per-UTXO backing shortfall) firing independently. The reason the verification layer exists.", "contract": "contracts/DeviantOpenMintFT_Backdoor.cash", "script": "scripts/chipnet-attack-rogue-nft.mjs", "snapshot": "0020", "snapshotFile": "snapshots/0020-t001-poc-chipnet.md", "proofTxid": "e6f7e69d", "status": "research", "verification": "n-a", "feeModel": "n/a — attack PoC.", "note": "Red-team contract. Defended by D-1 + D-2." }
|
||||
]
|
||||
}
|
||||
</script>
|
||||
|
||||
<script>
|
||||
const FAMILY_BADGE = { spike:'b-spike', research:'b-research' };
|
||||
const STATUS_LABEL = { validated:'validated', spike:'spike', research:'research' };
|
||||
|
||||
function el(tag, cls, html){ const e=document.createElement(tag); if(cls)e.className=cls; if(html!=null)e.innerHTML=html; return e; }
|
||||
function esc(s){ return (s==null?'':String(s)).replace(/[&<>]/g,c=>({'&':'&','<':'<','>':'>'}[c])); }
|
||||
|
||||
let DATA=null, activeFamily='all', query='';
|
||||
|
||||
async function load(){
|
||||
try {
|
||||
const res = await fetch('./catalog.json', {cache:'no-store'});
|
||||
if(!res.ok) throw new Error('http '+res.status);
|
||||
DATA = await res.json();
|
||||
} catch(e){
|
||||
const fb = document.getElementById('catalog-fallback').textContent.trim();
|
||||
DATA = JSON.parse(fb);
|
||||
document.getElementById('fallbackNote').style.display='block';
|
||||
}
|
||||
render();
|
||||
}
|
||||
|
||||
function render(){
|
||||
const entries = DATA.entries, fams = DATA.families, meta = DATA.meta;
|
||||
// stats
|
||||
const sb = document.getElementById('statbar'); sb.innerHTML='';
|
||||
const nValidated = entries.filter(e=>e.status==='validated').length;
|
||||
const nProof = entries.filter(e=>e.proofTxid && e.proofTxid.length===64).length;
|
||||
const stats = [[entries.length,'algorithms'],[nValidated,'chipnet-validated'],[nProof,'tx proofs'],[fams.length,'families']];
|
||||
stats.forEach(([n,l])=>{ const s=el('div','stat'); s.append(el('div','n',n), el('div','l',l)); sb.append(s); });
|
||||
sb.append(el('div','net','● chipnet'));
|
||||
|
||||
// chips
|
||||
const chips = document.getElementById('chips'); chips.innerHTML='';
|
||||
const mk=(id,label)=>{ const c=el('span','chip'+(activeFamily===id?' active':''),esc(label)); c.onclick=()=>{activeFamily=id; render();}; return c; };
|
||||
chips.append(mk('all','All'));
|
||||
fams.forEach(f=>chips.append(mk(f.id,f.name)));
|
||||
|
||||
// grid
|
||||
const grid = document.getElementById('grid'); grid.innerHTML='';
|
||||
const q = query.trim().toLowerCase();
|
||||
const famsToShow = (activeFamily==='all') ? fams : fams.filter(f=>f.id===activeFamily);
|
||||
let shown=0;
|
||||
famsToShow.forEach(fam=>{
|
||||
let items = entries.filter(e=>e.family===fam.id);
|
||||
if(q) items = items.filter(e=>(e.name+' '+e.tagline+' '+e.howItWorks+' '+fam.name).toLowerCase().includes(q));
|
||||
if(!items.length) return;
|
||||
const h=el('div','famhead'); h.append(el('h2',null,esc(fam.name)), el('p',null,esc(fam.blurb))); grid.append(h);
|
||||
items.forEach(e=>{ grid.append(card(e,fam,meta)); shown++; });
|
||||
});
|
||||
if(!shown){ grid.append(el('div','famhead','<p>No algorithms match that search.</p>')); }
|
||||
}
|
||||
|
||||
function card(e, fam, meta){
|
||||
const c = el('div','card');
|
||||
const top = el('div','toprow');
|
||||
top.append(el('span','tag',esc(fam.name)));
|
||||
const badges = el('div','badges');
|
||||
if(e.verification==='canonical') badges.append(el('span','badge b-canonical','✓ canonical'));
|
||||
const stCls = 'b-'+(e.status||'validated');
|
||||
badges.append(el('span','badge '+stCls, esc(STATUS_LABEL[e.status]||e.status)));
|
||||
top.append(badges);
|
||||
c.append(top);
|
||||
|
||||
c.append(el('h3',null,esc(e.name)));
|
||||
c.append(el('p','tagline',esc(e.tagline)));
|
||||
c.append(el('p','how',esc(e.howItWorks)));
|
||||
|
||||
let meta_html = '';
|
||||
if(e.feeModel) meta_html += '<b>Fee:</b> '+esc(e.feeModel)+'<br>';
|
||||
if(e.adr) meta_html += '<b>ADR:</b> '+esc(e.adr);
|
||||
if(meta_html) c.append(el('p','meta',meta_html));
|
||||
if(e.highlight) c.append(el('p','hl','★ '+esc(e.highlight)));
|
||||
if(e.note) c.append(el('p','meta','<b>Note:</b> '+esc(e.note)));
|
||||
|
||||
const links = el('div','links');
|
||||
const root = meta.repoRoot || '../../../';
|
||||
if(e.contract) links.append(linkEl(root+e.contract,'⟨/⟩ Contract'));
|
||||
if(e.script) links.append(linkEl(root+e.script,'▷ Test script'));
|
||||
if(e.snapshotFile) links.append(linkEl(root+e.snapshotFile,'❏ '+esc(e.snapshot)));
|
||||
if(e.proofTxid && e.proofTxid.length===64){
|
||||
const a=linkEl(meta.explorerTxUrl+e.proofTxid,'⛓ Proof tx'); a.classList.add('proof'); a.target='_blank'; a.rel='noopener'; links.append(a);
|
||||
} else if(e.proofTxid){
|
||||
links.append(el('span','lk dim','⛓ PoC '+esc(e.proofTxid)+'…'));
|
||||
} else {
|
||||
links.append(el('span','lk dim','⛓ validated · '+esc(e.snapshot)));
|
||||
}
|
||||
c.append(links);
|
||||
return c;
|
||||
}
|
||||
function linkEl(href,label){ const a=el('a','lk',label); a.href=href; return a; }
|
||||
|
||||
document.getElementById('search').addEventListener('input', ev=>{ query=ev.target.value; render(); });
|
||||
load();
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
2335
adaptive-data.json
Normal file
2335
adaptive-data.json
Normal file
File diff suppressed because it is too large
Load diff
1
bch-history.json
Normal file
1
bch-history.json
Normal file
File diff suppressed because one or more lines are too long
1
bch-market.json
Normal file
1
bch-market.json
Normal file
File diff suppressed because one or more lines are too long
|
|
@ -124,7 +124,7 @@
|
|||
function showView(id){document.querySelectorAll('.view').forEach(function(v){v.classList.toggle('active',v.id==='v-'+id);});}
|
||||
document.querySelectorAll('[data-go]').forEach(function(el){el.addEventListener('click',function(){showView(el.getAttribute('data-go'));});});
|
||||
document.querySelectorAll('.fchip').forEach(function(f){f.addEventListener('click',function(){document.querySelectorAll('.fchip').forEach(function(x){x.classList.remove('on');});f.classList.add('on');});});
|
||||
(function(){var map={main:'main-tab.html',assets:'assets-tab.html',artemision:'artemision-tab.html',apps:'apps-tab.html'};document.querySelectorAll('.tabbar .tab').forEach(function(t){var el=t.querySelector('.lbl');if(!el)return;var d=map[el.textContent.trim().toLowerCase()];if(d){t.style.cursor='pointer';t.addEventListener('click',function(){location.href=d;});}});})();
|
||||
(function(){var map={main:'main-tab.html',agora:'agora.html',artemision:'artemision-tab.html',apps:'apps-tab.html'};document.querySelectorAll('.tabbar .tab').forEach(function(t){var el=t.querySelector('.lbl');if(!el)return;var d=map[el.textContent.trim().toLowerCase()];if(d){t.style.cursor='pointer';t.addEventListener('click',function(){location.href=d;});}});})();
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
|||
|
|
@ -38,7 +38,13 @@
|
|||
.sec.first { margin-top:2px; }
|
||||
|
||||
/* rows */
|
||||
.row { display:flex; align-items:center; gap:13px; min-height:66px; box-sizing:border-box; background: var(--surface-1); border:1px solid var(--border); border-radius:16px; padding:13px 15px; margin-bottom:9px; cursor:pointer; transition:border-color .2s; }
|
||||
/* Asset rows now live inside a category card (.cat-list), so each row is a
|
||||
plain list item with a 1px bottom divider — no individual box. */
|
||||
.cat-list { background: var(--surface-1); border:1px solid var(--border); border-radius:16px; margin-bottom:10px; overflow:hidden; }
|
||||
.cat-list .row { background:transparent; border:0; border-bottom:1px solid var(--border); border-radius:0; padding:12px 15px; margin-bottom:0; min-height:auto; }
|
||||
.cat-list .row:last-child { border-bottom:0; }
|
||||
.cat-list .row:hover { background: rgba(214,255,61,.04); }
|
||||
.row { display:flex; align-items:center; gap:13px; min-height:66px; box-sizing:border-box; background: var(--surface-1); border:1px solid var(--border); border-radius:16px; padding:13px 15px; margin-bottom:9px; cursor:pointer; transition:border-color .2s, background .2s; }
|
||||
.row:hover { border-color: rgba(214,255,61,.3); }
|
||||
.glyph { width:36px; height:36px; flex:none; border-radius:11px; display:grid; place-items:center; background: var(--surface-2); color: var(--ink-soft); font-family: var(--font-mono); font-size:15px; }
|
||||
.row-main { flex:1; min-width:0; }
|
||||
|
|
@ -58,10 +64,19 @@
|
|||
.chip.risk { color: var(--risk-warn); border-color: rgba(255,159,28,.45); }
|
||||
|
||||
/* adaptive swap sheet (opens on tap) */
|
||||
.swap-backdrop { position:absolute; inset:0; z-index:10; border-radius:30px; display:none; background:rgba(5,8,16,.66); backdrop-filter:blur(2px); }
|
||||
.swap-backdrop.open { display:block; }
|
||||
.swap-sheet { position:absolute; left:14px; right:14px; bottom:100px; z-index:11; display:none; padding:16px; border-radius:18px; background:var(--surface-2); border:1px solid var(--border-strong); box-shadow:0 -8px 40px rgba(0,0,0,.55); }
|
||||
/* Swap sheet — IN-PLACE expansion (no modal, no backdrop). Opening replaces
|
||||
the active panel in the same DOM slot; ✕ restores the list. Same pattern
|
||||
as Artemision class detail. */
|
||||
.swap-backdrop { display:none; } /* retired — kept selector for legacy class refs */
|
||||
.swap-sheet { display:none; position:relative; padding:18px; border-radius:18px;
|
||||
background:var(--surface-2); border:1px solid rgba(214,255,61,.32);
|
||||
box-shadow:0 14px 36px rgba(0,0,0,.55), 0 0 16px var(--acid-dim);
|
||||
animation: ss-in .25s ease-out; }
|
||||
.swap-sheet.open { display:block; }
|
||||
.panel.swap-open { display:none; }
|
||||
@keyframes ss-in { from { opacity:0; transform:translateY(4px); } to { opacity:1; transform:translateY(0); } }
|
||||
.ss-close { position:absolute; top:14px; right:16px; font-size:18px; color:var(--muted); cursor:pointer; background:0; border:0; }
|
||||
.ss-close:hover { color:var(--acid); text-shadow:0 0 6px var(--acid-halo); }
|
||||
.ss-path { display:inline-flex; gap:8px; font-family:var(--font-mono); font-size:10px; letter-spacing:.04em; border-radius:9px; padding:8px 12px; margin-bottom:14px; }
|
||||
.ss-path.orbital { color:var(--acid); border:1px solid rgba(214,255,61,.4); text-shadow:0 0 6px var(--acid-halo); }
|
||||
.ss-path.market { color:var(--risk-warn); border:1px solid rgba(255,159,28,.4); }
|
||||
|
|
@ -104,35 +119,35 @@
|
|||
<button class="seg" data-panel="spectrum">Spectrum</button>
|
||||
</div>
|
||||
|
||||
<!-- ===== MY ASSETS (holdings) — MBA | NBA | Show all (default MBA) ===== -->
|
||||
<!-- ===== MY ASSETS (holdings) — multi-select MBA · FIATμ · NBA ===== -->
|
||||
<div id="panel-mine" class="panel">
|
||||
<div class="groupbar">
|
||||
<span class="label-mono">Your holdings</span>
|
||||
<div class="gb-toggle">
|
||||
<button class="gb on" data-panel="mine" data-f="mba">MBA</button>
|
||||
<button class="gb" data-panel="mine" data-f="nba">NBA</button>
|
||||
<button class="gb" data-panel="mine" data-f="all">Show all</button>
|
||||
<button class="gb on" data-panel="mine" data-f="fiatm">FIATμ</button>
|
||||
<button class="gb on" data-panel="mine" data-f="nba">NBA</button>
|
||||
</div>
|
||||
</div>
|
||||
<div id="mine-list"></div>
|
||||
</div>
|
||||
|
||||
<!-- ===== SPECTRUM (full directory) — MBA | NBA | Show all (default MBA) ===== -->
|
||||
<!-- ===== SPECTRUM (full directory) — multi-select MBA · FIATμ · NBA ===== -->
|
||||
<div id="panel-spectrum" class="panel hidden">
|
||||
<div class="groupbar">
|
||||
<span class="label-mono">All assets</span>
|
||||
<div class="gb-toggle">
|
||||
<button class="gb on" data-panel="spectrum" data-f="mba">MBA</button>
|
||||
<button class="gb" data-panel="spectrum" data-f="nba">NBA</button>
|
||||
<button class="gb" data-panel="spectrum" data-f="all">Show all</button>
|
||||
<button class="gb on" data-panel="spectrum" data-f="fiatm">FIATμ</button>
|
||||
<button class="gb on" data-panel="spectrum" data-f="nba">NBA</button>
|
||||
</div>
|
||||
</div>
|
||||
<div id="spectrum-list"></div>
|
||||
</div>
|
||||
|
||||
<!-- ===== adaptive swap sheet ===== -->
|
||||
<div class="swap-backdrop" id="swapBackdrop"></div>
|
||||
<!-- ===== adaptive swap sheet — IN-PLACE, replaces the active panel ===== -->
|
||||
<div class="swap-sheet" id="swapSheet">
|
||||
<button class="ss-close" id="ssClose">✕</button>
|
||||
<div class="ss-path" id="ssPath"></div>
|
||||
<div class="ss-leg"><div class="ss-lt"><span>From</span><span id="ssBal"></span></div><div class="ss-lm"><span class="ss-asset" id="ssFrom">◇ Nova</span><span class="ss-amt" id="ssFromAmt">120 NOVA</span></div></div>
|
||||
<div class="ss-flip"><span><i>⇅</i></span></div>
|
||||
|
|
@ -154,12 +169,17 @@
|
|||
<script>
|
||||
(function(){var c=document.getElementById('stars');if(!c)return;var n=window.innerWidth<700?120:180;var f=document.createDocumentFragment();for(var i=0;i<n;i++){var s=document.createElement('div');s.className='star';var r=Math.random(),sz,o,d;if(r<.78){sz=1+Math.random()*.4;o=.18+Math.random()*.22;d=14+Math.random()*8;}else if(r<.95){sz=1.4+Math.random()*.6;o=.32+Math.random()*.22;d=10+Math.random()*6;}else{sz=1.8+Math.random()*.8;o=.45+Math.random()*.25;d=8+Math.random()*5;}s.style.width=sz+'px';s.style.height=sz+'px';s.style.left=Math.random()*100+'%';s.style.top=Math.random()*100+'%';s.style.opacity=o;s.style.setProperty('--twinkle-duration',d+'s');s.style.setProperty('--twinkle-delay',(Math.random()*d)+'s');f.appendChild(s);}c.appendChild(f);})();
|
||||
|
||||
// ── data: the full directory ──
|
||||
// ── data: the full directory. `fam` = MBA / FIATμ / NBA. FIATμ items are
|
||||
// technically MBA (DEA/MCA template) but surfaced as their own category for
|
||||
// UX — users care about "stable to fiat" vs general MBA. ──
|
||||
var ASSETS = [
|
||||
{fam:'mba', name:'Nova', glyph:'◇', cls:'DEA', sub:'PNV 1,200,000 sat', right:'10,000 sat/unit', safe:true},
|
||||
{fam:'mba', name:'Helix', glyph:'✦', cls:'DEA', sub:'PNV — 1.00 vs Nova', right:'10,000 sat/unit', safe:true},
|
||||
{fam:'mba', name:'Lumen', glyph:'◈', cls:'PLA', sub:'PNV 400,000 sat', right:'10,000 sat/unit', safe:true},
|
||||
{fam:'mba', name:'Arcane', glyph:'◆', cls:'MCA', sub:'PNV 850,000 sat', right:'10,000 sat/unit', safe:true},
|
||||
{fam:'fiatm', name:'USDμ', glyph:'$', cls:'DEA', sub:'DEA · fiat-paced · 1 USDμ ≈ $1', right:'oracle-paced', safe:true},
|
||||
{fam:'fiatm', name:'EURμ', glyph:'€', cls:'DEA', sub:'DEA · fiat-paced · 1 EURμ ≈ €1', right:'oracle-paced', safe:true},
|
||||
{fam:'fiatm', name:'GBPμ', glyph:'£', cls:'DEA', sub:'DEA · fiat-paced · 1 GBPμ ≈ £1', right:'oracle-paced', safe:true},
|
||||
{fam:'nba', name:'Meridian',glyph:'✸', cls:'MTU', sub:'no peg', right:'~0.041 BCH'},
|
||||
{fam:'nba', name:'Doge2', glyph:'◍', cls:'PTU', sub:'no peg', right:'~0.0007 BCH'},
|
||||
{fam:'nba', name:'FestPass',glyph:'❂', cls:'MTL', sub:'membership', right:'—'}
|
||||
|
|
@ -177,34 +197,47 @@
|
|||
+ '<div class="row-main"><div class="row-top"><span class="name">'+a.name+'</span>'+chips+'</div><div class="row-sub">'+a.sub+'</div></div>'
|
||||
+ '<div class="row-right"><div class="px">'+a.right+'</div><div class="swap-into '+v+'">'+lbl+'</div></div></div>';
|
||||
}
|
||||
var HOLDINGS = ASSETS.filter(function(a){return ['Nova','Lumen','Meridian','Doge2'].indexOf(a.name)>=0;});
|
||||
var HOLDINGS = ASSETS.filter(function(a){return ['Nova','Lumen','USDμ','Meridian','Doge2'].indexOf(a.name)>=0;});
|
||||
function sectionH(dot,name,note){return '<div class="sec'+(dot==='backed'?' first':'')+'"><span class="dot '+dot+'"></span><span class="sname">'+name+'</span><span class="snote">'+note+'</span></div>';}
|
||||
function renderList(containerId, list, filter){
|
||||
function renderList(containerId, list, activeFams){
|
||||
var el=document.getElementById(containerId); var html='';
|
||||
if(filter==='all'){
|
||||
html+=sectionH('backed','Backed','MBA · BCH floor · Orbital Swap');
|
||||
list.filter(function(a){return a.fam==='mba';}).forEach(function(a){html+=rowHTML(a);});
|
||||
html+=sectionH('nopeg','Non-backed','NBA · market-priced · Market');
|
||||
list.filter(function(a){return a.fam==='nba';}).forEach(function(a){html+=rowHTML(a);});
|
||||
} else {
|
||||
list.filter(function(a){return a.fam===filter;}).forEach(function(a){html+=rowHTML(a);});
|
||||
var mbas = list.filter(function(a){return a.fam==='mba';});
|
||||
var fms = list.filter(function(a){return a.fam==='fiatm';});
|
||||
var nbas = list.filter(function(a){return a.fam==='nba';});
|
||||
var multi = activeFams.size > 1;
|
||||
function group(rows, dot, name, note){
|
||||
if(multi) html+=sectionH(dot, name, note);
|
||||
html+='<div class="cat-list">';
|
||||
rows.forEach(function(a){html+=rowHTML(a);});
|
||||
html+='</div>';
|
||||
}
|
||||
if(activeFams.has('mba') && mbas.length) group(mbas,'backed','Backed (MBA)','BCH floor · Orbital Swap');
|
||||
if(activeFams.has('fiatm') && fms.length) group(fms,'backed','FIATμ','fiat-paced MBA · Orbital Swap');
|
||||
if(activeFams.has('nba') && nbas.length) group(nbas,'nopeg','Non-backed (NBA)','market-priced · Market');
|
||||
el.innerHTML=html; wireRows();
|
||||
}
|
||||
|
||||
// ── sub-tab + toggle ──
|
||||
document.querySelectorAll('.seg').forEach(function(s){s.addEventListener('click',function(){document.querySelectorAll('.seg').forEach(function(x){x.classList.remove('active');});s.classList.add('active');var p=s.getAttribute('data-panel');document.getElementById('panel-mine').classList.toggle('hidden',p!=='mine');document.getElementById('panel-spectrum').classList.toggle('hidden',p!=='spectrum');});});
|
||||
// Multi-select filter: toggle each chip independently. Visible = union of
|
||||
// active chips. If none active, the list is empty (user disabled all).
|
||||
function refreshPanel(panel){
|
||||
var active = new Set();
|
||||
document.querySelectorAll('.gb[data-panel="'+panel+'"].on').forEach(function(x){active.add(x.getAttribute('data-f'));});
|
||||
if(panel==='mine') renderList('mine-list', HOLDINGS, active);
|
||||
else renderList('spectrum-list', ASSETS, active);
|
||||
}
|
||||
document.querySelectorAll('.gb[data-panel]').forEach(function(b){
|
||||
b.addEventListener('click',function(){
|
||||
var panel=b.getAttribute('data-panel'), f=b.getAttribute('data-f');
|
||||
document.querySelectorAll('.gb[data-panel="'+panel+'"]').forEach(function(x){x.classList.remove('on');});
|
||||
b.classList.add('on');
|
||||
if(panel==='mine') renderList('mine-list',HOLDINGS,f); else renderList('spectrum-list',ASSETS,f);
|
||||
b.classList.toggle('on');
|
||||
refreshPanel(b.getAttribute('data-panel'));
|
||||
});
|
||||
});
|
||||
|
||||
// ── adaptive swap ──
|
||||
var backdrop=document.getElementById('swapBackdrop'), sheet=document.getElementById('swapSheet');
|
||||
// ── adaptive swap — in-place expansion (no modal) ──
|
||||
var sheet=document.getElementById('swapSheet');
|
||||
var panelMine=document.getElementById('panel-mine'), panelSpec=document.getElementById('panel-spectrum');
|
||||
function closeSwap(){ sheet.classList.remove('open'); panelMine.classList.remove('swap-open'); panelSpec.classList.remove('swap-open'); }
|
||||
function openSwap(cls,name,glyph,amt){
|
||||
var path=document.getElementById('ssPath');
|
||||
document.getElementById('ssFrom').textContent=glyph+' '+name;
|
||||
|
|
@ -228,16 +261,32 @@
|
|||
document.getElementById('ssCta').textContent='Review Orbital Swap →';
|
||||
document.getElementById('ssNote').textContent='Permissionless-mint MBA (DEA / PLA) → full ASM. Atomic, both directions: swap to BCH or any other DEA/PLA, and it can be a swap target too.';
|
||||
}
|
||||
sheet.classList.add('open'); backdrop.classList.add('open');
|
||||
// Hide both panels; the sheet renders in their place (in-flow).
|
||||
panelMine.classList.add('swap-open'); panelSpec.classList.add('swap-open');
|
||||
sheet.classList.add('open');
|
||||
}
|
||||
function wireRows(){
|
||||
document.querySelectorAll('.row[data-cls]').forEach(function(r){
|
||||
r.onclick=function(){ openSwap(r.getAttribute('data-cls'), r.getAttribute('data-name'), r.getAttribute('data-glyph'), (r.querySelector('.units')||{}).textContent); };
|
||||
});
|
||||
}
|
||||
backdrop.addEventListener('click',function(){sheet.classList.remove('open');backdrop.classList.remove('open');});
|
||||
document.getElementById('ssClose').addEventListener('click', closeSwap);
|
||||
|
||||
renderList('mine-list', HOLDINGS, 'mba'); renderList('spectrum-list', ASSETS, 'mba');
|
||||
// Bottom-bar navigation — Main / Agora (active) / Artemision / Apps
|
||||
(function(){
|
||||
var map = { main:'main-tab.html', agora:'agora.html', artemision:'artemision-tab.html', apps:'apps-tab.html' };
|
||||
document.querySelectorAll('.tabbar .tab').forEach(function(t){
|
||||
var el = t.querySelector('.lbl'); if(!el) return;
|
||||
var dest = map[el.textContent.trim().toLowerCase()];
|
||||
if(dest && !t.classList.contains('active')){
|
||||
t.style.cursor='pointer';
|
||||
t.addEventListener('click', function(){ location.href = dest; });
|
||||
}
|
||||
});
|
||||
})();
|
||||
|
||||
// Initial render: both panels start with all three families visible
|
||||
refreshPanel('mine'); refreshPanel('spectrum');
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
|||
|
|
@ -38,6 +38,14 @@
|
|||
.label-row { display:flex; align-items:center; justify-content:space-between; margin: 20px 4px 11px; }
|
||||
.cat { margin: 18px 4px 9px; }
|
||||
|
||||
/* Discover category filter — horizontally scrollable chip row.
|
||||
Single-select: All | DeFi | Games | Merchant | Tools | Explorers. */
|
||||
.catbar { display:flex; gap:7px; margin: 4px 0 16px; overflow-x:auto; padding-bottom:4px; scrollbar-width:none; }
|
||||
.catbar::-webkit-scrollbar { display:none; }
|
||||
.cchip { flex:none; font-family: var(--font-mono); font-size:10px; letter-spacing:.08em; text-transform:uppercase; padding:8px 13px; border-radius:18px; border:1px solid var(--border); background:transparent; color: var(--muted); cursor:pointer; transition: color .2s, border-color .2s, background .2s; }
|
||||
.cchip.active { color: var(--acid); border-color: rgba(214,255,61,.45); background: rgba(214,255,61,.06); text-shadow: 0 0 6px var(--acid-halo); }
|
||||
.cat.hidden, .row.hidden { display:none; }
|
||||
|
||||
/* chips & protocol badges */
|
||||
.chip { font-family: var(--font-mono); font-size:9px; letter-spacing:.08em; text-transform:uppercase; padding:3px 7px; border-radius:6px; border:1px solid var(--border-strong); color: var(--ink-soft); display:inline-flex; align-items:center; gap:5px; }
|
||||
.proto.wc { color:#7fb0ff; border-color: rgba(127,176,255,.4); }
|
||||
|
|
@ -138,46 +146,57 @@
|
|||
<div id="panel-discover" class="panel hidden">
|
||||
<!-- Discover directory -->
|
||||
<!-- Trade/DEX (Cauldron / TapSwap / Fex.cash) moved to Assets → NBA → Market (routed ⚠, ADR-0028). Apps is dApp connectivity only. -->
|
||||
<div class="cat label-mono">DeFi</div>
|
||||
<div class="row">
|
||||
|
||||
<!-- Category filter — horizontally scrollable chips, multi-select.
|
||||
Default: all active (= show everything). Tap to toggle a category. -->
|
||||
<div class="catbar">
|
||||
<button class="cchip active" data-cat="defi">DeFi</button>
|
||||
<button class="cchip active" data-cat="games">Games</button>
|
||||
<button class="cchip active" data-cat="merchant">Merchant</button>
|
||||
<button class="cchip active" data-cat="tools">Tools</button>
|
||||
<button class="cchip active" data-cat="explorers">Explorers</button>
|
||||
</div>
|
||||
|
||||
<div class="cat label-mono" data-cat="defi">DeFi</div>
|
||||
<div class="row" data-cat="defi">
|
||||
<div class="glyph">⛨</div>
|
||||
<div class="row-main"><div class="row-top"><span class="name">BCH Bull</span><span class="chip proto web">Web</span></div><div class="row-sub">Hedge & leverage (AnyHedge)</div></div>
|
||||
<button class="mini">Open</button>
|
||||
</div>
|
||||
|
||||
<div class="cat label-mono">Games</div>
|
||||
<div class="row">
|
||||
<div class="cat label-mono" data-cat="games">Games</div>
|
||||
<div class="row" data-cat="games">
|
||||
<div class="glyph">◐</div>
|
||||
<div class="row-main"><div class="row-top"><span class="name">BCH Guru</span><span class="chip proto cc">CC</span></div><div class="row-sub">Price-prediction game (NFTs)</div></div>
|
||||
<button class="mini go">Connect</button>
|
||||
</div>
|
||||
|
||||
<div class="cat label-mono">Merchant</div>
|
||||
<div class="row">
|
||||
<div class="cat label-mono" data-cat="merchant">Merchant</div>
|
||||
<div class="row" data-cat="merchant">
|
||||
<div class="glyph">▦</div>
|
||||
<div class="row-main"><div class="row-top"><span class="name">Paytaca POS</span><span class="chip proto web">Web</span></div><div class="row-sub">Point-of-sale register for shops</div></div>
|
||||
<button class="mini">Open</button>
|
||||
</div>
|
||||
|
||||
<div class="cat label-mono">Tools</div>
|
||||
<div class="row">
|
||||
<div class="cat label-mono" data-cat="tools">Tools</div>
|
||||
<div class="row" data-cat="tools">
|
||||
<div class="glyph">✸</div>
|
||||
<div class="row-main"><div class="row-top"><span class="name">Flipstarter</span><span class="chip proto web">Web</span></div><div class="row-sub">Assurance-contract crowdfunding</div></div>
|
||||
<button class="mini">Open</button>
|
||||
</div>
|
||||
|
||||
<div class="cat label-mono">Explorers</div>
|
||||
<div class="row">
|
||||
<div class="cat label-mono" data-cat="explorers">Explorers</div>
|
||||
<div class="row" data-cat="explorers">
|
||||
<div class="glyph">▦</div>
|
||||
<div class="row-main"><div class="row-top"><span class="name">BCH Block Explorer</span><span class="chip proto web">Web</span></div><div class="row-sub">bchblockexplorer.com · blocks & transactions</div></div>
|
||||
<button class="mini">Open</button>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="row" data-cat="explorers">
|
||||
<div class="glyph">◎</div>
|
||||
<div class="row-main"><div class="row-top"><span class="name">Token Explorer</span><span class="chip proto web">Web</span></div><div class="row-sub">tokenexplorer.cash · CashTokens</div></div>
|
||||
<button class="mini">Open</button>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="row" data-cat="explorers">
|
||||
<div class="glyph">⬡</div>
|
||||
<div class="row-main"><div class="row-top"><span class="name">BCH Explorer</span><span class="chip proto web">Web</span></div><div class="row-sub">bchexplorer.cash · blocks, tx & tokens</div></div>
|
||||
<button class="mini">Open</button>
|
||||
|
|
@ -215,6 +234,18 @@
|
|||
c.appendChild(frag);
|
||||
})();
|
||||
|
||||
// Discover category filter — multi-select. Visible = union of active chips.
|
||||
function applyCatFilter() {
|
||||
var active = new Set(Array.from(document.querySelectorAll('.cchip.active')).map(function (c) { return c.getAttribute('data-cat'); }));
|
||||
document.querySelectorAll('#panel-discover [data-cat]').forEach(function (el) {
|
||||
if (el.classList.contains('cchip')) return;
|
||||
el.classList.toggle('hidden', !active.has(el.getAttribute('data-cat')));
|
||||
});
|
||||
}
|
||||
document.querySelectorAll('.cchip').forEach(function (c) {
|
||||
c.addEventListener('click', function () { c.classList.toggle('active'); applyCatFilter(); });
|
||||
});
|
||||
|
||||
// Sub-tab switching: Connected | Discover
|
||||
document.querySelectorAll('.seg').forEach(function (s) {
|
||||
s.addEventListener('click', function () {
|
||||
|
|
@ -235,7 +266,7 @@
|
|||
});
|
||||
// Bottom-bar navigation between mockup screens
|
||||
(function () {
|
||||
var map = { main:'main-tab.html', assets:'assets-tab.html', artemision:'artemision-tab.html', apps:'apps-tab.html' };
|
||||
var map = { main:'main-tab.html', agora:'agora.html', artemision:'artemision-tab.html', apps:'apps-tab.html' };
|
||||
document.querySelectorAll('.tabbar .tab').forEach(function (t) {
|
||||
var el = t.querySelector('.lbl'); if (!el) return;
|
||||
var dest = map[el.textContent.trim().toLowerCase()];
|
||||
|
|
|
|||
|
|
@ -76,12 +76,16 @@
|
|||
.col-note { font-family:var(--font-mono); font-size:8px; letter-spacing:.05em; color:var(--muted); margin:0 2px 11px; }
|
||||
.tax-col .preset { margin-bottom:10px; min-height:112px; }
|
||||
|
||||
/* asset-type detail sheet */
|
||||
/* contained panel over the taxonomy cards — not full-page */
|
||||
.detail { position:absolute; left:16px; right:16px; top:204px; bottom:102px; z-index:20; display:none; overflow-y:auto;
|
||||
padding:18px 18px 20px; border-radius:18px; background: var(--sky-mid);
|
||||
border:1px solid rgba(214,255,61,.32); box-shadow: 0 14px 44px rgba(0,0,0,.6), 0 0 16px var(--acid-dim); }
|
||||
/* asset-type detail — IN-PLACE expansion: replaces .tax-cols in normal flow.
|
||||
No overlay, no fullscreen modal — clicking a class card swaps the grid
|
||||
contents for the detail in the same slot. ✕ restores the grid. */
|
||||
.detail { display:none; position:relative; padding:18px 18px 20px; border-radius:18px;
|
||||
background: var(--sky-mid); border:1px solid rgba(214,255,61,.32);
|
||||
box-shadow: 0 14px 44px rgba(0,0,0,.6), 0 0 16px var(--acid-dim);
|
||||
animation: detail-in .25s ease-out; }
|
||||
.detail.open { display:block; }
|
||||
.tax-cols.hidden { display:none; }
|
||||
@keyframes detail-in { from { opacity:0; transform:translateY(4px); } to { opacity:1; transform:translateY(0); } }
|
||||
.detail-close { position:absolute; top:18px; right:20px; font-size:18px; color:var(--muted); cursor:pointer; }
|
||||
.detail-code { display:none; }
|
||||
.detail-name { font-family:var(--font-display); font-weight:500; font-size:23px; color:var(--ink-bright); margin-top:2px; letter-spacing:-.005em; }
|
||||
|
|
@ -198,7 +202,7 @@
|
|||
<div class="col-note">Mathematically Backed · fixed rate · PNV floor</div>
|
||||
<div class="preset" data-class="DEA"><div class="p-code">DEA</div><div class="p-name">Hard-Backed</div><div class="p-axes">permissionless · unlimited</div></div>
|
||||
<div class="preset" data-class="PLA"><div class="p-code">PLA</div><div class="p-name">Commodity</div><div class="p-axes">permissionless · limited</div></div>
|
||||
<div class="preset" data-class="MCA"><div class="p-code">MCA</div><div class="p-name">Bond</div><div class="p-axes">managed · unlimited</div></div>
|
||||
<div class="preset" data-class="MCA"><div class="p-code">MCA</div><div class="p-name">Certificate</div><div class="p-axes">managed · unlimited</div></div>
|
||||
<div class="preset" data-class="MTA"><div class="p-code">MTA</div><div class="p-name">Tranche</div><div class="p-axes">managed · limited</div></div>
|
||||
</div>
|
||||
<div class="tax-col">
|
||||
|
|
@ -262,7 +266,7 @@
|
|||
NBA:{n:'Non-Backed Assets',chips:['Family','no backing','market-priced'],def:'Casual assets with no backing mechanism — the contract locks no BCH at a fixed rate and there is no protocol redemption. Value is set entirely by the market: exchanges, issuer reputation and traded liquidity. Tokens, memecoins, collectibles and PoW-style coins all live here.',use:['PTU — game currency · non-convertible VC (open-mint, uncapped)','PTL — mineable coin (capped, Bitcoin-style)','MTU — tokens / memecoins (incl. fiat & stablecoins; issuer-minted, uncapped)','MTL — NFT / collectibles (capped, issuer-minted)'],ex:'Conventional tokens, memecoins, PoW coins — and, structurally, every classical "backed" claim too: a gold certificate, USDT, a bond. Their backing was a soft, unenforced promise on a counterparty — and because the promise did not always hold (and could be broken at will), there was no actual backing. By the enforced-floor test they are NBA, not MBA.'},
|
||||
DEA:{n:'Direct Emission Asset',fam:'MBA',mint:'permissionless',sup:'unlimited',asm:1,asmt:'Agora / ASM eligible',def:'A counterparty-free backed currency — every unit carries its BCH backing inside its own UTXO, redeemable by your own spend. The contract replaces counterparty, market-maker and liquidity provider at once.',use:['Everyday / platform currencies','Game currencies','Loyalty & rewards points'],ex:'Novel — no traditional peer. Backed directly by BCH held in the unit itself, not by an external market peg or a custodian who could default — arguably the hardest backing any currency has ever carried.'},
|
||||
PLA:{n:'Permissionless Limited Asset',fam:'MBA',mint:'permissionless',sup:'limited',asm:1,asmt:'Orbital / ASM (until depleted)',def:'Backed like a DEA but with a capped reservoir. Once minted out the ASM goes inert, yet the BCH floor (PNV) stays redeemable forever.',use:['Capped, BCH-backed reserve assets','Backed claims with a hard floor + supply cap','Fixed-supply backed currencies'],ex:'Like a capped certificate backed by a reserve — NOT raw gold/silver themselves (those are unbacked direct value → PTL). PLA shares the permissionless-extraction pattern but adds the BCH redemption floor metal lacks.'},
|
||||
MCA:{n:'Managed Certificate Asset',fam:'MBA',mint:'managed',sup:'unlimited',asm:0,asmt:'No ASM (managed mint)',def:'Issuer-gated, uncapped issuance with a protocol-enforced BCH floor and redemption — a rolling backed program (bond / reserve-note style). The genuinely-backed instrument the existing world only approximates: every unit is redeemable by consensus, not by trusting an off-chain reserve.',use:['Rolling / perpetual bond programs','Issuer-backed reserve notes','A properly-backed stablecoin (reserves enforced on-chain)'],ex:'The HARD certificate — the enforced version that never existed before. A gold certificate, USDT or USDC are NOT MCAs: their "backing" is an off-chain trust claim, never enforced → NBA (MTL / MTU). Honest peer: a reserve note whose reserve is actually held inside the instrument.'},
|
||||
MCA:{n:'Managed Certificate Asset',fam:'MBA',mint:'managed',sup:'unlimited',asm:0,asmt:'No ASM (managed mint)',def:'The HARD certificate — what classical gold certificates claimed to be but could not enforce. Issuer-gated, uncapped issuance with a protocol-enforced BCH floor and redemption: every unit is redeemable by consensus, not by trusting an off-chain reserve.',use:['Bond / rolling reserve-note programs','Protocol-backed stablecoins (reserves enforced on-chain)','Issuer-backed perpetual notes'],ex:'A gold certificate, USDT or USDC are NOT MCAs: their "backing" is an off-chain trust claim, never enforced → NBA (MTL / MTU). The MCA is the enforced version of that promise — the certificate that does not need a trusted reserve because the reserve is consensus-locked inside the instrument itself.'},
|
||||
MTA:{n:'Managed Tranche Asset',fam:'MBA',mint:'managed',sup:'limited',asm:0,asmt:'No ASM (managed mint)',def:'Issuer-gated and hard-capped, with a protocol-enforced BCH floor — a single fixed slice (tranche) of backed issuance.',use:['Fixed tranches & structured slices','Notes & bills (T-notes / T-bills — fixed-term, capped)','Numbered backed editions','Closed, capped reserve series'],ex:'A closed-end fund share, an ETF tranche, a fixed bond series, Treasury notes & bills — capped, backed, issuer-gated.'},
|
||||
PTU:{n:'Permissionless Token Unlimited',fam:'NBA',mint:'permissionless',sup:'unlimited',asm:0,asmt:'No peg · market-priced',def:'A Non-Convertible Virtual Currency — usable only inside one platform / ecosystem and not convertible to real money. Open-mint (tap to mint): anyone mints by spending into the covenant, no exclusive issuer, uncapped, no backing.',use:['In-game currencies earned by play (anyone)','Tap-to-mint / faucet tokens (click to claim)','Open community / play-to-earn currencies','Collateralized-debt stablecoins (MakerDAO / DAI) — permissionless mint; token unbacked (ADR-0033)'],ex:'Currencies anyone earns just by playing or clicking — MMORPG gold (RuneScape GP, WoW gold), arcade redemption tickets, faucet / tap-to-earn tokens. All open to anyone, inflationary (uncapped), and not officially cashable out. The convertible outlier here is a collateralized-debt stablecoin (MakerDAO / DAI): permissionless to mint, but the collateral backs the debt vault, not the token — the token itself is unbacked and market-priced (ADR-0033).'},
|
||||
PTL:{n:'Permissionless Token Limited',fam:'NBA',mint:'permissionless',sup:'limited',asm:0,asmt:'No peg · market-priced',def:'Open-mint but hard-capped, no backing floor and no exclusive operator — permissionless issuance up to a fixed total; value is market-set.',use:['Capped-supply mined coins (Bitcoin-style)','Tokenised commodities / barter goods — gold, silver (no issuer)','Permissionless capped mint events (no exclusive operator)'],ex:'Bitcoin, gold, silver, barter goods — direct-value Layer-1 assets: mined/extracted by anyone, finite, unbacked. (A *claim* on such value — a gold certificate / promissory note — is NOT an MBA: its backing is unenforced trust, so it too is NBA, in the MANAGED row → MTL / MTU.)'},
|
||||
|
|
@ -270,6 +274,7 @@
|
|||
MTL:{n:'Managed Token Limited',fam:'NBA',mint:'managed',sup:'limited',asm:0,asmt:'No peg · market-priced',def:'Issuer-controlled and capped, no ENFORCED backing — a creator mints a fixed supply. Home of soft-backed *claims* capped by a reserve (backing is a trust assumption, not enforced → NBA), plus credentials, collections and capped memecoins.',use:['The historical gold certificate (claimed gold backing, supply gold-limited)','Fixed NFT collections & numbered editions','Event tickets, memberships & credentials','Capped-supply memecoins'],ex:'The classic case is the GOLD CERTIFICATE — a managed, limited token that *claimed* gold backing but only by trust (a counterparty who could default; never enforced → NBA), supply meant to be gold-limited. Once the gold link was cut (1971) it degraded to MTU: fiat, no claim, unlimited. Also: tickets, memberships, fixed collections.'}
|
||||
};
|
||||
var detail = document.getElementById('detail');
|
||||
var taxCols = document.querySelector('.tax-cols');
|
||||
function openDetail(code) {
|
||||
var d = DATA[code]; if (!d) return;
|
||||
document.getElementById('dName').innerHTML = d.n.replace(/[A-Z]/g, function (m) { return '<span class="cap">' + m + '</span>'; });
|
||||
|
|
@ -281,12 +286,18 @@
|
|||
document.getElementById('dDef').textContent = d.def;
|
||||
document.getElementById('dUse').innerHTML = d.use.map(function (u) { return '<li>' + u + '</li>'; }).join('');
|
||||
document.getElementById('dEx').textContent = d.ex;
|
||||
// In-place swap: hide the taxonomy grid, show the detail in the same slot.
|
||||
if (taxCols) taxCols.classList.add('hidden');
|
||||
detail.classList.add('open');
|
||||
}
|
||||
function closeDetail() {
|
||||
detail.classList.remove('open');
|
||||
if (taxCols) taxCols.classList.remove('hidden');
|
||||
}
|
||||
document.querySelectorAll('.preset[data-class]').forEach(function (p) {
|
||||
p.addEventListener('click', function () { openDetail(p.getAttribute('data-class')); });
|
||||
});
|
||||
document.getElementById('detailClose').addEventListener('click', function () { detail.classList.remove('open'); });
|
||||
document.getElementById('detailClose').addEventListener('click', closeDetail);
|
||||
// Family headers (MBA / NBA) → generalized category description
|
||||
document.querySelectorAll('.col-head').forEach(function (h) {
|
||||
var g = h.querySelector('.gname'); if (!g) return;
|
||||
|
|
@ -295,7 +306,7 @@
|
|||
|
||||
// Bottom-bar navigation between mockup screens
|
||||
(function () {
|
||||
var map = { main:'main-tab.html', assets:'assets-tab.html', artemision:'artemision-tab.html', apps:'apps-tab.html' };
|
||||
var map = { main:'main-tab.html', agora:'agora.html', artemision:'artemision-tab.html', apps:'apps-tab.html' };
|
||||
document.querySelectorAll('.tabbar .tab').forEach(function (t) {
|
||||
var el = t.querySelector('.lbl'); if (!el) return;
|
||||
var dest = map[el.textContent.trim().toLowerCase()];
|
||||
|
|
|
|||
|
|
@ -144,7 +144,7 @@
|
|||
</div>
|
||||
<script>
|
||||
(function generateStars(){const c=document.getElementById('stars');if(!c)return;const n=window.innerWidth<700?100:180;const f=document.createDocumentFragment();for(let i=0;i<n;i++){const s=document.createElement('div');s.className='star';const r=Math.random();let sz,o,d;if(r<.78){sz=1+Math.random()*.4;o=.18+Math.random()*.22;d=14+Math.random()*8;}else if(r<.95){sz=1.4+Math.random()*.6;o=.32+Math.random()*.22;d=10+Math.random()*6;}else{sz=1.8+Math.random()*.8;o=.45+Math.random()*.25;d=8+Math.random()*5;}s.style.width=sz+'px';s.style.height=sz+'px';s.style.left=Math.random()*100+'%';s.style.top=Math.random()*100+'%';s.style.opacity=o;s.style.setProperty('--twinkle-duration',d+'s');s.style.setProperty('--twinkle-delay',(Math.random()*d)+'s');f.appendChild(s);}c.appendChild(f);})();
|
||||
(function(){var map={main:'main-tab.html',assets:'assets-tab.html',artemision:'artemision-tab.html',apps:'apps-tab.html'};document.querySelectorAll('.tabbar .tab').forEach(function(t){var el=t.querySelector('.lbl');if(!el)return;var d=map[el.textContent.trim().toLowerCase()];if(d){t.style.cursor='pointer';t.addEventListener('click',function(){location.href=d;});}});document.querySelectorAll('[data-link="assets"]').forEach(function(b){b.addEventListener('click',function(){location.href='assets-tab.html';});});})();
|
||||
(function(){var map={main:'main-tab.html',agora:'agora.html',artemision:'artemision-tab.html',apps:'apps-tab.html'};document.querySelectorAll('.tabbar .tab').forEach(function(t){var el=t.querySelector('.lbl');if(!el)return;var d=map[el.textContent.trim().toLowerCase()];if(d){t.style.cursor='pointer';t.addEventListener('click',function(){location.href=d;});}});document.querySelectorAll('[data-link="assets"]').forEach(function(b){b.addEventListener('click',function(){location.href='assets-tab.html';});});})();
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
|||
|
|
@ -506,7 +506,7 @@
|
|||
document.querySelectorAll('.sheet-item').forEach(function (i) { i.addEventListener('click', function () { location.href = 'send-flow.html'; }); });
|
||||
// Bottom-bar navigation between mockup screens
|
||||
(function () {
|
||||
var map = { main:'main-tab.html', assets:'assets-tab.html', artemision:'artemision-tab.html', apps:'apps-tab.html' };
|
||||
var map = { main:'main-tab.html', agora:'agora.html', artemision:'artemision-tab.html', apps:'apps-tab.html' };
|
||||
document.querySelectorAll('.tabbar .tab').forEach(function (t) {
|
||||
var el = t.querySelector('.lbl'); if (!el) return;
|
||||
var dest = map[el.textContent.trim().toLowerCase()];
|
||||
|
|
|
|||
|
|
@ -91,7 +91,7 @@
|
|||
</div>
|
||||
<script>
|
||||
(function generateStars(){const c=document.getElementById('stars');if(!c)return;const n=window.innerWidth<700?100:180;const f=document.createDocumentFragment();for(let i=0;i<n;i++){const s=document.createElement('div');s.className='star';const r=Math.random();let sz,o,d;if(r<.78){sz=1+Math.random()*.4;o=.18+Math.random()*.22;d=14+Math.random()*8;}else if(r<.95){sz=1.4+Math.random()*.6;o=.32+Math.random()*.22;d=10+Math.random()*6;}else{sz=1.8+Math.random()*.8;o=.45+Math.random()*.25;d=8+Math.random()*5;}s.style.width=sz+'px';s.style.height=sz+'px';s.style.left=Math.random()*100+'%';s.style.top=Math.random()*100+'%';s.style.opacity=o;s.style.setProperty('--twinkle-duration',d+'s');s.style.setProperty('--twinkle-delay',(Math.random()*d)+'s');f.appendChild(s);}c.appendChild(f);})();
|
||||
(function(){var map={main:'main-tab.html',assets:'assets-tab.html',artemision:'artemision-tab.html',apps:'apps-tab.html'};document.querySelectorAll('.tabbar .tab').forEach(function(t){var el=t.querySelector('.lbl');if(!el)return;var d=map[el.textContent.trim().toLowerCase()];if(d){t.style.cursor='pointer';t.addEventListener('click',function(){location.href=d;});}});})();
|
||||
(function(){var map={main:'main-tab.html',agora:'agora.html',artemision:'artemision-tab.html',apps:'apps-tab.html'};document.querySelectorAll('.tabbar .tab').forEach(function(t){var el=t.querySelector('.lbl');if(!el)return;var d=map[el.textContent.trim().toLowerCase()];if(d){t.style.cursor='pointer';t.addEventListener('click',function(){location.href=d;});}});})();
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
|||
|
|
@ -149,7 +149,7 @@
|
|||
document.querySelectorAll('[data-go]').forEach(function(el){el.addEventListener('click',function(){showView(el.getAttribute('data-go'));});});
|
||||
document.querySelectorAll('.utxo:not(.locked)').forEach(function(u){u.addEventListener('click',function(){u.classList.toggle('on');u.querySelector('.chk').textContent=u.classList.contains('on')?'✓':'';});});
|
||||
document.querySelectorAll('.switch').forEach(function(s){s.addEventListener('click',function(){s.classList.toggle('on');});});
|
||||
(function(){var map={main:'main-tab.html',assets:'assets-tab.html',artemision:'artemision-tab.html',apps:'apps-tab.html'};document.querySelectorAll('.tabbar .tab').forEach(function(t){var el=t.querySelector('.lbl');if(!el)return;var d=map[el.textContent.trim().toLowerCase()];if(d){t.style.cursor='pointer';t.addEventListener('click',function(){location.href=d;});}});document.querySelectorAll('[data-link="main"]').forEach(function(b){b.addEventListener('click',function(){location.href='main-tab.html';});});})();
|
||||
(function(){var map={main:'main-tab.html',agora:'agora.html',artemision:'artemision-tab.html',apps:'apps-tab.html'};document.querySelectorAll('.tabbar .tab').forEach(function(t){var el=t.querySelector('.lbl');if(!el)return;var d=map[el.textContent.trim().toLowerCase()];if(d){t.style.cursor='pointer';t.addEventListener('click',function(){location.href=d;});}});document.querySelectorAll('[data-link="main"]').forEach(function(b){b.addEventListener('click',function(){location.href='main-tab.html';});});})();
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
|||
374
design/mockups/main-tab-routeB.html
Normal file
374
design/mockups/main-tab-routeB.html
Normal file
|
|
@ -0,0 +1,374 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Deviant · Main · CosmoGenesis mockup</title>
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,300;9..144,400;9..144,500;9..144,600&family=JetBrains+Mono:wght@400;500&display=swap" rel="stylesheet">
|
||||
<link href="../cosmo-genesis.css" rel="stylesheet">
|
||||
<style>
|
||||
body { display:flex; justify-content:center; padding:28px 0; }
|
||||
.phone { position:relative; z-index:1; width:392px; min-height:840px; background: linear-gradient(180deg, rgba(19,26,42,.55), rgba(10,15,28,.55)); border:1px solid var(--border); border-radius:30px; padding:22px 18px 92px; backdrop-filter: blur(2px); }
|
||||
|
||||
/* header / wordmark */
|
||||
.topbar { display:flex; align-items:center; justify-content:space-between; margin-bottom:22px; }
|
||||
.wordmark { font-family: var(--font-display); font-weight:500; font-size:22px; color: var(--ink-bright); }
|
||||
.wordmark::after { content:""; display:inline-block; width:5px; height:5px; margin-left:6px; vertical-align:middle; transform:translateY(-3px); background: var(--acid); border-radius:50%; box-shadow:0 0 6px var(--acid-glow),0 0 14px var(--acid-halo); }
|
||||
.gear { font-size:18px; color: var(--muted); cursor:pointer; }
|
||||
|
||||
/* BCH "B" badge (Bitcoin Cash brand green, distinct from acid) */
|
||||
.bch-b { display:inline-grid; place-items:center; line-height:0; border-radius:50%; }
|
||||
.bch-b .bch-logo { width:100%; height:100%; display:block; } /* official BCH logo (simple-icons) */
|
||||
.bch-b.lg { width:46px; height:46px; box-shadow:0 0 18px rgba(10,193,142,.35); }
|
||||
.bch-b.sm { width:28px; height:28px; }
|
||||
|
||||
/* portfolio donut — BCH-denominated only (free BCH + Σ MBA PNV). NBA is a
|
||||
separate count line below, never a wedge (glossary rule: a claim of
|
||||
backing is not backing, so NBA has no place in a BCH-denominated chart). */
|
||||
.portfolio { display:flex; align-items:center; gap:20px; margin-bottom:22px; }
|
||||
.donut { width:128px; height:128px; flex:none; border-radius:50%; position:relative; display:grid; place-items:center;
|
||||
background: conic-gradient(#0ac18e 0 67%, var(--acid) 67% 100%); }
|
||||
.donut::before { content:""; position:absolute; width:96px; height:96px; border-radius:50%; background: var(--sky-deep); }
|
||||
.donut::after { content:""; position:absolute; inset:-6px; border-radius:50%; z-index:-1;
|
||||
background: conic-gradient(#0ac18e 0 67%, var(--acid) 67% 100%);
|
||||
filter: blur(9px); opacity:0; transition: opacity .4s; }
|
||||
.donut:hover::after { opacity:.75; }
|
||||
.d-center { position:relative; z-index:1; text-align:center; }
|
||||
.d-total { font-family: var(--font-mono); font-size:16px; color: var(--ink-bright); }
|
||||
.d-label { font-family: var(--font-mono); font-size:8px; letter-spacing:.14em; text-transform:uppercase; color: var(--muted); margin-top:3px; }
|
||||
.legend { flex:1; }
|
||||
.leg { display:flex; align-items:center; gap:9px; margin-bottom:11px; font-family: var(--font-mono); font-size:11px; color: var(--ink-soft); }
|
||||
.leg .sw { width:9px; height:9px; border-radius:3px; flex:none; }
|
||||
.leg .val { margin-left:auto; color: var(--ink); }
|
||||
.leg[data-fam] { cursor:pointer; border-radius:7px; transition: background .2s; }
|
||||
.leg[data-fam]:hover { background: rgba(255,255,255,.04); }
|
||||
.leg .sw { transition: box-shadow .3s; }
|
||||
.leg.mba:hover .sw { box-shadow: 0 0 9px var(--acid-glow); }
|
||||
/* NBA — sits in the legend under MBA. Not a wedge: no BCH floor, so the value
|
||||
shown is a market estimate (~), distinguished from the protocol-enforced
|
||||
BCH/MBA numbers above. Dashed top border marks the protocol/market boundary. */
|
||||
.nba-line { display:flex; align-items:center; gap:9px; font-family: var(--font-mono); font-size:11px; color: var(--ink-soft); margin-bottom:11px; cursor:pointer; transition: background .2s; }
|
||||
.nba-line:hover { background: rgba(255,255,255,.03); }
|
||||
.nba-line .sw { width:9px; height:9px; border-radius:3px; flex:none; background:#7f8cff; }
|
||||
.nba-line .val { margin-left:auto; color: var(--muted); }
|
||||
|
||||
.label-mono { font-family: var(--font-mono); font-size:10px; letter-spacing:.22em; text-transform:uppercase; color: var(--muted); }
|
||||
|
||||
/* Route B: Assets | Wallets sub-tabs (Bitcoin.com pattern) */
|
||||
.subtabs { display:flex; gap:0; margin:8px 4px 14px; border-bottom:1px solid var(--border); }
|
||||
.subtab { flex:1; text-align:center; font-family:var(--font-display); font-weight:500; font-size:16px; color:var(--muted); padding:10px 0 12px; cursor:pointer; background:0; border:0; border-bottom:2px solid transparent; margin-bottom:-1px; transition: color .2s, border-color .2s; }
|
||||
.subtab.active { color:var(--ink-bright); border-bottom-color:var(--acid); text-shadow:0 0 6px var(--acid-halo); }
|
||||
.pane { display:none; }
|
||||
.pane.active { display:block; }
|
||||
|
||||
/* Wallets pane — multi-wallet list + ADD/IMPORT CTA */
|
||||
.wlist { background:var(--surface-1); border:1px solid var(--border); border-radius:14px; padding:4px 0; margin-bottom:14px; }
|
||||
.wlist .wrow { display:flex; align-items:center; gap:13px; padding:14px 16px; border-bottom:1px solid var(--border); cursor:pointer; }
|
||||
.wlist .wrow:last-child { border-bottom:0; }
|
||||
.wdot { width:11px; height:11px; flex:none; border-radius:50%; background:#0ac18e; box-shadow:0 0 6px rgba(10,193,142,.6); }
|
||||
.wdot.idle { background:var(--muted); box-shadow:none; }
|
||||
.wlist .wname { font-family:var(--font-display); font-weight:500; font-size:16px; color:var(--ink-bright); }
|
||||
.wlist .wsub { font-family:var(--font-mono); font-size:10px; color:var(--muted); margin-top:3px; }
|
||||
.wlist .wmain { flex:1; min-width:0; }
|
||||
.wlist .wval { text-align:right; font-family:var(--font-mono); }
|
||||
.wlist .wval .b { font-size:13px; color:var(--ink-bright); }
|
||||
.wlist .wval .s { font-size:10px; color:var(--muted); margin-top:2px; }
|
||||
.wlist .wval.zero .b { color:var(--muted); }
|
||||
.add-cta { display:block; width:100%; text-align:center; font-family:var(--font-mono); font-size:11px; letter-spacing:.16em; text-transform:uppercase; padding:14px; border-radius:12px; background:rgba(214,255,61,.08); border:1px solid rgba(214,255,61,.4); color:var(--acid); cursor:pointer; text-shadow:0 0 6px var(--acid-halo); }
|
||||
.add-cta:hover { background:rgba(214,255,61,.14); }
|
||||
|
||||
/* Wallet-level secondary actions (Activity / Fuse / Sweep). Send / Receive /
|
||||
Scan are on the central FAB. */
|
||||
.actions { display:flex; gap:8px; margin: 4px 0 18px; padding: 10px 6px; background:var(--surface-1); border:1px solid var(--border); border-radius:14px; }
|
||||
.actions .mini { flex:1; display:flex; flex-direction:column; align-items:center; gap:5px; padding:6px 4px; background:0; border:0; cursor:pointer; color:var(--ink-soft); }
|
||||
.actions .mini .ai { font-size:18px; color:var(--acid); text-shadow:0 0 8px var(--acid-halo); line-height:1; }
|
||||
.actions .mini .al { font-family:var(--font-mono); font-size:9px; letter-spacing:.1em; text-transform:uppercase; color:var(--ink-soft); }
|
||||
.actions .mini:hover .al { color:var(--ink-bright); }
|
||||
|
||||
/* FAB quick-action sheet — floats just above the central FAB. */
|
||||
.fab-sheet { position:absolute; left:50%; bottom:100px; transform:translateX(-50%) translateY(8px); z-index:30; display:none; gap:10px; padding:12px 14px; border-radius:18px; background:var(--sky-mid); border:1px solid rgba(214,255,61,.35); box-shadow:0 14px 36px rgba(0,0,0,.55), 0 0 18px var(--acid-dim); opacity:0; transition: opacity .2s ease, transform .2s ease; }
|
||||
.fab-sheet.open { display:flex; opacity:1; transform:translateX(-50%) translateY(0); }
|
||||
.fab-sheet .qa { display:flex; flex-direction:column; align-items:center; gap:6px; padding:9px 10px; min-width:74px; background:transparent; border:0; cursor:pointer; border-radius:11px; transition: background .2s; }
|
||||
.fab-sheet .qa:hover { background: rgba(214,255,61,.07); }
|
||||
.fab-sheet .qa .qi { width:34px; height:34px; display:grid; place-items:center; border-radius:50%; background: rgba(214,255,61,.12); color:var(--acid); font-size:18px; text-shadow:0 0 8px var(--acid-halo); }
|
||||
.fab-sheet .qa .ql { font-family:var(--font-mono); font-size:9.5px; letter-spacing:.1em; text-transform:uppercase; color:var(--ink-soft); }
|
||||
.fab-sheet::after { content:""; position:absolute; left:50%; bottom:-7px; transform:translateX(-50%) rotate(45deg); width:13px; height:13px; background:var(--sky-mid); border-right:1px solid rgba(214,255,61,.35); border-bottom:1px solid rgba(214,255,61,.35); }
|
||||
.fab-backdrop { position:absolute; inset:0; z-index:25; display:none; border-radius:30px; background:rgba(5,8,16,.45); backdrop-filter:blur(1.5px); }
|
||||
.fab-backdrop.open { display:block; }
|
||||
|
||||
/* Three category cards (accordion). See main-tab.html for the full rule set. */
|
||||
.ccard { display:block; background:var(--surface-1); border:1px solid var(--border); border-radius:14px; margin-bottom:10px; overflow:hidden; transition: border-color .2s; }
|
||||
.ccard:hover { border-color:rgba(214,255,61,.25); }
|
||||
.csum { display:flex; align-items:center; gap:13px; padding:14px 16px; cursor:pointer; }
|
||||
.csum .cdot { width:11px; height:11px; flex:none; border-radius:50%; }
|
||||
.csum .cdot.bch { background:#0ac18e; box-shadow:0 0 6px rgba(10,193,142,.5); }
|
||||
.csum .cdot.mba { background:var(--acid); box-shadow:0 0 6px var(--acid-halo); }
|
||||
.csum .cdot.nba { background:#7f8cff; box-shadow:0 0 6px rgba(127,140,255,.5); }
|
||||
.csum .cmeta { flex:1; min-width:0; }
|
||||
.csum .cname { font-family:var(--font-display); font-weight:500; font-size:16px; color:var(--ink-bright); }
|
||||
.csum .csub { font-family:var(--font-mono); font-size:9.5px; color:var(--muted); margin-top:2px; }
|
||||
.csum .cval { text-align:right; font-family:var(--font-mono); }
|
||||
.csum .cval .cb { font-size:14px; color:var(--ink-bright); }
|
||||
.csum .cval .cb.soft { color:var(--ink-soft); font-style:italic; }
|
||||
.csum .cval .ccnt { font-size:9.5px; color:var(--muted); margin-top:2px; }
|
||||
.csum .cchev { color:var(--muted); margin-left:8px; transition: transform .25s; }
|
||||
.ccard.open .cchev { transform: rotate(90deg); color:var(--acid); }
|
||||
.clist { display:none; padding:0 16px 14px; border-top:1px solid var(--border); }
|
||||
.ccard.open .clist { display:block; }
|
||||
.crow { display:flex; align-items:center; gap:11px; padding:11px 0; border-bottom:1px solid var(--border); cursor:pointer; }
|
||||
.crow:last-of-type { border-bottom:0; }
|
||||
.crow .rico { width:30px; height:30px; flex:none; border-radius:50%; display:grid; place-items:center; background:var(--surface-2); color:var(--ink-soft); font-family:var(--font-mono); font-size:11px; font-weight:600; }
|
||||
.crow .rmeta { flex:1; min-width:0; }
|
||||
.crow .rname { font-family:var(--font-display); font-weight:500; font-size:14px; color:var(--ink-bright); display:flex; align-items:center; gap:7px; }
|
||||
.crow .rsub { font-family:var(--font-mono); font-size:9px; color:var(--muted); margin-top:2px; }
|
||||
.crow .rbal { text-align:right; font-family:var(--font-mono); }
|
||||
.crow .rbal .rb { font-size:12px; color:var(--ink-bright); }
|
||||
.crow .rbal .rs { font-size:9px; color:var(--ink-soft); margin-top:1px; }
|
||||
.crow .rbal .rs.soft { color:var(--muted); font-style:italic; }
|
||||
.vagora { display:block; text-align:right; padding:9px 0 0; font-family:var(--font-mono); font-size:9.5px; letter-spacing:.12em; text-transform:uppercase; color:var(--muted); cursor:pointer; }
|
||||
.vagora:hover { color:var(--acid); text-shadow:0 0 5px var(--acid-halo); }
|
||||
.chip { font-family:var(--font-mono); font-size:8px; letter-spacing:.08em; text-transform:uppercase; padding:2px 6px; border-radius:5px; border:1px solid var(--border-strong); color:var(--ink-soft); }
|
||||
.chip.safe { color:var(--acid); border-color:rgba(214,255,61,.35); text-shadow:0 0 5px var(--acid-halo); }
|
||||
.chip.warn { color:var(--risk-warn); border-color:rgba(255,159,28,.4); }
|
||||
|
||||
/* Recent activity footer link */
|
||||
.recent-link { text-align:center; font-family:var(--font-mono); font-size:10px; letter-spacing:.16em; text-transform:uppercase; color:var(--muted); padding:14px 0 6px; cursor:pointer; }
|
||||
.recent-link:hover { color:var(--acid); text-shadow:0 0 6px var(--acid-halo); }
|
||||
|
||||
/* bottom bar + fab */
|
||||
.tabbar { position:absolute; left:0; right:0; bottom:0; display:flex; justify-content:space-around; align-items:center; padding:14px 10px 18px; border-top:1px solid var(--border); background: linear-gradient(0deg, var(--sky-deep), transparent); border-radius:0 0 30px 30px; }
|
||||
.tab { display:flex; flex-direction:column; align-items:center; gap:6px; background:0; border:0; cursor:pointer; }
|
||||
.tab .ico { font-size:24px; color: var(--muted); }
|
||||
.tab .lbl { font-family: var(--font-mono); font-size:8px; letter-spacing:.12em; text-transform:uppercase; color: var(--muted); }
|
||||
/* selected tab = acid glow, universally (matches the central FAB) */
|
||||
.tab.active .ico { color: var(--acid); text-shadow: 0 0 10px var(--acid-glow), 0 0 20px var(--acid-halo); }
|
||||
.tab.active .lbl { color: var(--ink-bright); }
|
||||
.tab:not(.active) .bch-b { opacity:.6; }
|
||||
.tab.active .bch-b { box-shadow: 0 0 12px var(--acid-glow), 0 0 20px var(--acid-halo); }
|
||||
.fab { position:relative; margin-top:-28px; flex:none; width:58px; height:58px; border-radius:50%; background: var(--acid); color: var(--sky-deep); border:4px solid var(--sky-deep); cursor:pointer; display:grid; place-items:center; font-size:23px; box-shadow: 0 0 18px var(--acid-glow), 0 0 34px var(--acid-halo); }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="stars" aria-hidden="true" id="stars"></div>
|
||||
|
||||
<div class="phone">
|
||||
<div class="topbar">
|
||||
<div class="wordmark">Deviant</div>
|
||||
<div class="gear">⚙</div>
|
||||
</div>
|
||||
|
||||
<!-- Portfolio donut — BCH-denominated only (free BCH + Σ MBA PNV) -->
|
||||
<div class="portfolio">
|
||||
<div class="donut"><div class="d-center"><div class="d-total">0.0600</div><div class="d-label">BCH total</div></div></div>
|
||||
<div class="legend">
|
||||
<div class="leg" data-fam="bch"><span class="sw" style="background:#0ac18e"></span>Bitcoin Cash<span class="val">0.040</span></div>
|
||||
<div class="leg mba" data-fam="mba"><span class="sw" style="background:var(--acid)"></span>MBA · backed<span class="val">0.020</span></div>
|
||||
<!-- NBA — count line, not a wedge (no BCH floor, not BCH-denominated) -->
|
||||
<div class="nba-line" data-fam="token"><span class="sw"></span>NBA · non-backed<span class="val">~ 0.040</span></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Wallet-level secondary actions. Send / Receive / Scan live on the
|
||||
central FAB; this row covers the rest (Activity, Fuse, Sweep). -->
|
||||
<div class="actions">
|
||||
<button class="mini" data-link="activity"><span class="ai">⌖</span><span class="al">Activity</span></button>
|
||||
<button class="mini" id="fuseBtn"><span class="ai">⊜</span><span class="al">Fuse</span></button>
|
||||
<button class="mini" data-link="sweep"><span class="ai">⤓</span><span class="al">Sweep</span></button>
|
||||
</div>
|
||||
|
||||
<!-- ROUTE B: Assets | Wallets sub-tabs (Bitcoin.com pattern, peer-level) -->
|
||||
<div class="subtabs">
|
||||
<button class="subtab active" data-pane="assets">Assets</button>
|
||||
<button class="subtab" data-pane="wallets">Wallets</button>
|
||||
</div>
|
||||
|
||||
<!-- ASSETS PANE — category-filtered asset list (same as Route A) -->
|
||||
<div class="pane active" data-pane="assets">
|
||||
|
||||
<!-- Three category cards — collapsed by default. Same content as Route A. -->
|
||||
<div class="ccard" data-cat="bch">
|
||||
<div class="csum">
|
||||
<span class="cdot bch"></span>
|
||||
<div class="cmeta"><div class="cname">Bitcoin Cash</div><div class="csub">Free balance · fuel + send</div></div>
|
||||
<div class="cval"><div class="cb">0.0400 BCH</div><div class="ccnt">4,000,000 sat</div></div>
|
||||
<span class="cchev">›</span>
|
||||
</div>
|
||||
<div class="clist">
|
||||
<div class="crow" data-link="asset-bch">
|
||||
<div class="rico bch">B</div>
|
||||
<div class="rmeta"><div class="rname">Bitcoin Cash</div><div class="rsub">Free · fuel</div></div>
|
||||
<div class="rbal"><div class="rb">0.0400 BCH</div><div class="rs">4,000,000 sat</div></div>
|
||||
</div>
|
||||
<a class="vagora" data-link="agora-bch">View in Agora →</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="ccard" data-cat="mba">
|
||||
<div class="csum">
|
||||
<span class="cdot mba"></span>
|
||||
<div class="cmeta"><div class="cname">Mathematically Backed Assets</div><div class="csub">Protocol-enforced BCH floor · redeemable</div></div>
|
||||
<div class="cval"><div class="cb">0.0200 BCH</div><div class="ccnt">2 categories</div></div>
|
||||
<span class="cchev">›</span>
|
||||
</div>
|
||||
<div class="clist">
|
||||
<div class="crow" data-link="asset-nova">
|
||||
<div class="rico">NV</div>
|
||||
<div class="rmeta"><div class="rname">Nova<span class="chip safe">DEA</span></div><div class="rsub">120 NOVA · 1 NOVA = 100 sat</div></div>
|
||||
<div class="rbal"><div class="rb">0.0120 BCH</div><div class="rs">PNV</div></div>
|
||||
</div>
|
||||
<div class="crow" data-link="asset-lumen">
|
||||
<div class="rico">LM</div>
|
||||
<div class="rmeta"><div class="rname">Lumen<span class="chip safe">PLA</span></div><div class="rsub">40 LMN · 1 LMN = 200 sat · capped</div></div>
|
||||
<div class="rbal"><div class="rb">0.0080 BCH</div><div class="rs">PNV</div></div>
|
||||
</div>
|
||||
<a class="vagora" data-link="agora-mba">View in Agora →</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="ccard" data-cat="nba">
|
||||
<div class="csum">
|
||||
<span class="cdot nba"></span>
|
||||
<div class="cmeta"><div class="cname">Non-backed Assets</div><div class="csub">No floor · market-priced</div></div>
|
||||
<div class="cval"><div class="cb soft">~ 0.0400 BCH</div><div class="ccnt">2 categories</div></div>
|
||||
<span class="cchev">›</span>
|
||||
</div>
|
||||
<div class="clist">
|
||||
<div class="crow" data-link="asset-meridian">
|
||||
<div class="rico">MR</div>
|
||||
<div class="rmeta"><div class="rname">Meridian<span class="chip warn">MTU</span></div><div class="rsub">5,000 MRD · issuer-minted</div></div>
|
||||
<div class="rbal"><div class="rb">~ 0.0250</div><div class="rs soft">market</div></div>
|
||||
</div>
|
||||
<div class="crow" data-link="asset-doge2">
|
||||
<div class="rico">D2</div>
|
||||
<div class="rmeta"><div class="rname">Doge2<span class="chip warn">PTU</span></div><div class="rsub">100,000 D2 · open-mint</div></div>
|
||||
<div class="rbal"><div class="rb">~ 0.0150</div><div class="rs soft">market</div></div>
|
||||
</div>
|
||||
<a class="vagora" data-link="agora-nba">View in Agora →</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="recent-link" data-link="activity">Recent activity →</div>
|
||||
|
||||
</div><!-- /pane.assets -->
|
||||
|
||||
<!-- WALLETS PANE — multi-wallet list + ADD/IMPORT (Bitcoin.com pattern) -->
|
||||
<div class="pane" data-pane="wallets">
|
||||
<div class="wlist">
|
||||
<div class="wrow">
|
||||
<span class="wdot"></span>
|
||||
<div class="wmain"><div class="wname">Main</div><div class="wsub">bchtest:qrd5g7…2ltaxuwh · 16 tok utxos</div></div>
|
||||
<div class="wval"><div class="b">0.0590 BCH</div><div class="s">5,903,166 sat</div></div>
|
||||
</div>
|
||||
<div class="wrow">
|
||||
<span class="wdot idle"></span>
|
||||
<div class="wmain"><div class="wname">Savings</div><div class="wsub">bchtest:qzd2dw…v9t3eyc6 · 2 tok utxos</div></div>
|
||||
<div class="wval"><div class="b">0.5767 BCH</div><div class="s">57,668,955 sat</div></div>
|
||||
</div>
|
||||
<div class="wrow">
|
||||
<span class="wdot idle"></span>
|
||||
<div class="wmain"><div class="wname">Chipnet test <span class="chip warn" style="margin-left:6px;">Dev</span></div><div class="wsub">bchtest:qpn0w8…7l4mzeux · 0 tok utxos</div></div>
|
||||
<div class="wval zero"><div class="b">0.0230 BCH</div><div class="s">2,300,000 sat</div></div>
|
||||
</div>
|
||||
</div>
|
||||
<button class="add-cta">+ Add / Import wallet</button>
|
||||
</div><!-- /pane.wallets -->
|
||||
|
||||
<!-- FAB quick-action sheet -->
|
||||
<div class="fab-backdrop" id="fabBackdrop"></div>
|
||||
<div class="fab-sheet" id="fabSheet">
|
||||
<button class="qa" data-qa="send"><span class="qi">⇧</span><span class="ql">Send</span></button>
|
||||
<button class="qa" data-qa="receive"><span class="qi">⇩</span><span class="ql">Receive</span></button>
|
||||
<button class="qa" data-qa="scan"><span class="qi">⊞</span><span class="ql">Scan</span></button>
|
||||
</div>
|
||||
|
||||
<!-- BOTTOM BAR -->
|
||||
<nav class="tabbar">
|
||||
<button class="tab active"><span class="ico"><span class="bch-b sm"><svg class="bch-logo" viewBox="0 0 24 24" aria-hidden="true"><circle cx="12" cy="12" r="12" fill="#fff"/><path fill="#0ac18e" d="m10.84 11.22-.688-2.568c.728-.18 2.839-1.051 3.39.506.27 1.682-1.978 1.877-2.702 2.062zm.289 1.313.755 2.829c.868-.228 3.496-.46 3.241-2.351-.433-1.666-3.125-.706-3.996-.478zM24 12c0 6.627-5.373 12-12 12S0 18.627 0 12 5.373 0 12 0s12 5.373 12 12zm-6.341.661c-.183-1.151-1.441-2.095-2.485-2.202.643-.57.969-1.401.57-2.488-.603-1.368-1.989-1.66-3.685-1.377l-.546-2.114-1.285.332.536 2.108c-.338.085-.685.158-1.029.256L9.198 5.08l-1.285.332.545 2.114c-.277.079-2.595.673-2.595.673l.353 1.377s.944-.265.935-.244c.524-.137.771.125.886.372l1.498 5.793c.018.168-.012.454-.372.551.021.012-.935.241-.935.241l.14 1.605s2.296-.588 2.598-.664l.551 2.138 1.285-.332-.551-2.153c.353-.082.697-.168 1.032-.256l.548 2.141 1.285-.332-.551-2.135c1.982-.482 3.38-1.73 3.094-3.64z"/></svg></span></span><span class="lbl">Main</span></button>
|
||||
<button class="tab"><span class="ico">⬡</span><span class="lbl">Agora</span></button>
|
||||
<button class="fab" id="fab" aria-label="Send, receive, or scan"><span style="display:inline-block;transform:rotate(45deg)">⇅</span></button>
|
||||
<button class="tab"><span class="ico">△</span><span class="lbl">Artemision</span></button>
|
||||
<button class="tab"><span class="ico">⧉</span><span class="lbl">Apps</span></button>
|
||||
</nav>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
(function generateStars() {
|
||||
const c = document.getElementById('stars'); if (!c) return;
|
||||
const count = window.innerWidth < 700 ? 140 : 260;
|
||||
const frag = document.createDocumentFragment();
|
||||
for (let i = 0; i < count; i++) {
|
||||
const s = document.createElement('div'); s.className = 'star';
|
||||
const roll = Math.random(); let size, opacity, dur;
|
||||
if (roll < 0.72) { size = 1 + Math.random()*0.7; opacity = 0.32 + Math.random()*0.25; dur = 14 + Math.random()*8; }
|
||||
else if (roll < 0.93) { size = 1.6 + Math.random()*0.8; opacity = 0.52 + Math.random()*0.26; dur = 10 + Math.random()*6; }
|
||||
else { size = 2.2 + Math.random()*1.1; opacity = 0.74 + Math.random()*0.26; dur = 8 + Math.random()*5; }
|
||||
s.style.width = size+'px'; s.style.height = size+'px';
|
||||
s.style.left = Math.random()*100+'%'; s.style.top = Math.random()*100+'%';
|
||||
s.style.opacity = opacity; s.style.setProperty('--twinkle-duration', dur+'s'); s.style.setProperty('--twinkle-delay', (Math.random()*dur)+'s');
|
||||
frag.appendChild(s);
|
||||
}
|
||||
c.appendChild(frag);
|
||||
})();
|
||||
|
||||
// Route B: Assets | Wallets sub-tabs — radio (one active at a time)
|
||||
document.querySelectorAll('.subtab').forEach(function (st) {
|
||||
st.addEventListener('click', function () {
|
||||
var pane = st.getAttribute('data-pane');
|
||||
document.querySelectorAll('.subtab').forEach(function (x) { x.classList.toggle('active', x === st); });
|
||||
document.querySelectorAll('.pane').forEach(function (p) { p.classList.toggle('active', p.getAttribute('data-pane') === pane); });
|
||||
});
|
||||
});
|
||||
|
||||
// Category cards — tap header (.csum) to expand/collapse the accordion.
|
||||
document.querySelectorAll('.ccard .csum').forEach(function (sum) {
|
||||
sum.addEventListener('click', function (e) {
|
||||
if (e.target.closest('.crow, .vagora')) return;
|
||||
sum.parentElement.classList.toggle('open');
|
||||
});
|
||||
});
|
||||
|
||||
// Mouse parallax — the starfield drifts with the cursor (à la bch.guru)
|
||||
(function parallax() {
|
||||
var layer = document.getElementById('stars');
|
||||
if (!layer || window.matchMedia('(prefers-reduced-motion: reduce)').matches) return;
|
||||
window.addEventListener('mousemove', function (e) {
|
||||
var x = e.clientX / window.innerWidth - 0.5;
|
||||
var y = e.clientY / window.innerHeight - 0.5;
|
||||
layer.style.transform = 'translate(' + (-x * 28) + 'px,' + (-y * 28) + 'px)';
|
||||
});
|
||||
})();
|
||||
// Bottom-bar navigation between mockup screens
|
||||
(function () {
|
||||
var map = { main:'main-tab.html', agora:'agora.html', artemision:'artemision-tab.html', apps:'apps-tab.html' };
|
||||
document.querySelectorAll('.tabbar .tab').forEach(function (t) {
|
||||
var el = t.querySelector('.lbl'); if (!el) return;
|
||||
var dest = map[el.textContent.trim().toLowerCase()];
|
||||
if (dest && !t.classList.contains('active')) {
|
||||
t.style.cursor = 'pointer';
|
||||
t.addEventListener('click', function () { location.href = dest; });
|
||||
}
|
||||
});
|
||||
var gear = document.querySelector('.gear'); if (gear) { gear.style.cursor = 'pointer'; gear.addEventListener('click', function () { location.href = 'settings.html'; }); }
|
||||
var fab = document.getElementById('fab');
|
||||
var sheet = document.getElementById('fabSheet');
|
||||
var backdrop = document.getElementById('fabBackdrop');
|
||||
function openSheet() { sheet.classList.add('open'); backdrop.classList.add('open'); }
|
||||
function closeSheet() { sheet.classList.remove('open'); backdrop.classList.remove('open'); }
|
||||
if (fab) fab.addEventListener('click', function (e) { e.stopPropagation(); sheet.classList.contains('open') ? closeSheet() : openSheet(); });
|
||||
if (backdrop) backdrop.addEventListener('click', closeSheet);
|
||||
document.querySelectorAll('.fab-sheet .qa').forEach(function (qa) {
|
||||
qa.addEventListener('click', function () { location.href = 'send-flow.html'; });
|
||||
});
|
||||
var linkMap = { send:'send-flow.html', receive:'send-flow.html', activity:'activity.html' };
|
||||
document.querySelectorAll('[data-link]').forEach(function (el) {
|
||||
var k = el.getAttribute('data-link'); if (linkMap[k]) { el.style.cursor='pointer'; el.addEventListener('click', function () { location.href = linkMap[k]; }); }
|
||||
if (k && k.indexOf('asset-') === 0) { el.style.cursor='pointer'; el.addEventListener('click', function () { location.href = 'asset-detail.html'; }); }
|
||||
if (k && k.indexOf('agora-') === 0) { el.style.cursor='pointer'; el.addEventListener('click', function () { location.href = 'agora.html'; }); }
|
||||
});
|
||||
var fuseBtn = document.getElementById('fuseBtn'); if (fuseBtn) fuseBtn.addEventListener('click', function () { location.href = 'fuse-flow.html'; });
|
||||
})();
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
@ -24,14 +24,15 @@
|
|||
.bch-b.lg { width:46px; height:46px; box-shadow:0 0 18px rgba(10,193,142,.35); }
|
||||
.bch-b.sm { width:28px; height:28px; }
|
||||
|
||||
/* portfolio donut */
|
||||
/* portfolio donut — BCH-denominated only (free BCH + Σ MBA PNV). NBA is a
|
||||
separate count line below, never a wedge (glossary rule: a claim of
|
||||
backing is not backing, so NBA has no place in a BCH-denominated chart). */
|
||||
.portfolio { display:flex; align-items:center; gap:20px; margin-bottom:22px; }
|
||||
.donut { width:128px; height:128px; flex:none; border-radius:50%; position:relative; display:grid; place-items:center;
|
||||
background: conic-gradient(#0ac18e 0 55%, var(--acid) 55% 82%, #7f8cff 82% 100%); }
|
||||
background: conic-gradient(#0ac18e 0 67%, var(--acid) 67% 100%); }
|
||||
.donut::before { content:""; position:absolute; width:96px; height:96px; border-radius:50%; background: var(--sky-deep); }
|
||||
/* soft even halo, off by default, on hover — a CSS blur (not SVG, so never clipped) */
|
||||
.donut::after { content:""; position:absolute; inset:-6px; border-radius:50%; z-index:-1;
|
||||
background: conic-gradient(#0ac18e 0 55%, var(--acid) 55% 82%, #7f8cff 82% 100%);
|
||||
background: conic-gradient(#0ac18e 0 67%, var(--acid) 67% 100%);
|
||||
filter: blur(9px); opacity:0; transition: opacity .4s; }
|
||||
.donut:hover::after { opacity:.75; }
|
||||
.d-center { position:relative; z-index:1; text-align:center; }
|
||||
|
|
@ -43,38 +44,122 @@
|
|||
.leg .val { margin-left:auto; color: var(--ink); }
|
||||
.leg[data-fam] { cursor:pointer; border-radius:7px; transition: background .2s; }
|
||||
.leg[data-fam]:hover { background: rgba(255,255,255,.04); }
|
||||
/* MBA — only the dot is acid; text stays neutral. Glow on interaction only. */
|
||||
.leg .sw { transition: box-shadow .3s; }
|
||||
.leg.mba:hover .sw { box-shadow: 0 0 9px var(--acid-glow); }
|
||||
|
||||
/* BCH card */
|
||||
.bch-card { background: var(--surface-1); border:1px solid var(--border); border-radius:18px; padding:16px; margin-bottom:18px; }
|
||||
.bch-head { display:flex; align-items:center; gap:13px; }
|
||||
.bch-meta { flex:1; }
|
||||
.bch-name { font-family: var(--font-display); font-weight:500; font-size:17px; color: var(--ink-bright); }
|
||||
.bch-fuel { font-family: var(--font-mono); font-size:9px; letter-spacing:.06em; color:#0ac18e; margin-top:3px; }
|
||||
.bch-bal { text-align:right; font-family: var(--font-mono); }
|
||||
.bch-bal .b { font-size:18px; color: var(--ink-bright); }
|
||||
.bch-bal .f { font-size:10px; color: var(--muted); margin-top:3px; }
|
||||
.bch-actions { display:flex; gap:10px; margin-top:15px; }
|
||||
.bch-actions .mini { flex:1; text-align:center; font-family: var(--font-mono); font-size:10px; letter-spacing:.1em; text-transform:uppercase; padding:11px; border-radius:10px; cursor:pointer; background:transparent; color: var(--ink-soft); border:1px solid var(--border-strong); }
|
||||
/* NBA — sits in the legend under MBA. Not a wedge: no BCH floor, so the value
|
||||
shown is a market estimate (~), distinguished from the protocol-enforced
|
||||
BCH/MBA numbers above. Dashed top border marks the protocol/market boundary. */
|
||||
.nba-line { display:flex; align-items:center; gap:9px; font-family: var(--font-mono); font-size:11px; color: var(--ink-soft); margin-bottom:11px; cursor:pointer; transition: background .2s; }
|
||||
.nba-line:hover { background: rgba(255,255,255,.03); }
|
||||
.nba-line .sw { width:9px; height:9px; border-radius:3px; flex:none; background:#7f8cff; }
|
||||
.nba-line .val { margin-left:auto; color: var(--muted); }
|
||||
|
||||
.label-mono { font-family: var(--font-mono); font-size:10px; letter-spacing:.22em; text-transform:uppercase; color: var(--muted); }
|
||||
.label-row { display:flex; align-items:center; justify-content:space-between; margin: 6px 4px 11px; }
|
||||
|
||||
/* activity feed */
|
||||
.act { display:flex; align-items:center; gap:13px; padding:11px 4px; border-bottom:1px solid var(--border); }
|
||||
.act:last-child { border-bottom:0; }
|
||||
.act .ico { width:32px; height:32px; flex:none; border-radius:9px; display:grid; place-items:center; background: var(--surface-1); color: var(--ink-soft); font-size:14px; }
|
||||
.act .a-main { flex:1; }
|
||||
.act .a-title { font-family: var(--font-display); font-size:14px; color: var(--ink); }
|
||||
.act .a-sub { font-family: var(--font-mono); font-size:9px; color: var(--muted); margin-top:2px; }
|
||||
.act .a-amt { font-family: var(--font-mono); font-size:12px; color: var(--ink-bright); }
|
||||
.act .a-amt.in { color:#0ac18e; }
|
||||
/* Sub-tabs: Assets | Wallets | Activity (peer surfaces inside Main) */
|
||||
.subtabs { display:flex; gap:0; margin:8px 4px 14px; border-bottom:1px solid var(--border); }
|
||||
.subtab { flex:1; text-align:center; font-family:var(--font-display); font-weight:500; font-size:15px; color:var(--muted); padding:9px 0 11px; cursor:pointer; background:0; border:0; border-bottom:2px solid transparent; margin-bottom:-1px; transition: color .2s, border-color .2s; }
|
||||
.subtab.active { color:var(--ink-bright); border-bottom-color:var(--acid); text-shadow:0 0 6px var(--acid-halo); }
|
||||
.pane { display:none; }
|
||||
.pane.active { display:block; }
|
||||
|
||||
/* Recent feed filter — borderless mono labels, evenly spaced, all clickable */
|
||||
.flab { background:transparent; border:0; padding:0; cursor:pointer; font-family: var(--font-mono); font-size:10px; letter-spacing:.2em; text-transform:uppercase; color: var(--muted); transition: color .3s, text-shadow .3s; }
|
||||
.flab.active { color: var(--acid); text-shadow:0 0 8px var(--acid-halo); }
|
||||
/* Wallets pane (Bitcoin.com pattern: list + ADD/IMPORT CTA) */
|
||||
.wlist { background:var(--surface-1); border:1px solid var(--border); border-radius:14px; padding:4px 0; margin-bottom:14px; }
|
||||
.wlist .wrow { display:flex; align-items:center; gap:13px; padding:14px 16px; border-bottom:1px solid var(--border); cursor:pointer; }
|
||||
.wlist .wrow:last-child { border-bottom:0; }
|
||||
.wdot { width:11px; height:11px; flex:none; border-radius:50%; background:#0ac18e; box-shadow:0 0 6px rgba(10,193,142,.6); }
|
||||
.wdot.idle { background:var(--muted); box-shadow:none; }
|
||||
.wlist .wname { font-family:var(--font-display); font-weight:500; font-size:16px; color:var(--ink-bright); }
|
||||
.wlist .wsub { font-family:var(--font-mono); font-size:10px; color:var(--muted); margin-top:3px; }
|
||||
.wlist .wmain { flex:1; min-width:0; }
|
||||
.wlist .wval { text-align:right; font-family:var(--font-mono); }
|
||||
.wlist .wval .b { font-size:13px; color:var(--ink-bright); }
|
||||
.wlist .wval .s { font-size:10px; color:var(--muted); margin-top:2px; }
|
||||
.add-cta { display:block; width:100%; text-align:center; font-family:var(--font-mono); font-size:11px; letter-spacing:.16em; text-transform:uppercase; padding:14px; border-radius:12px; background:rgba(214,255,61,.08); border:1px solid rgba(214,255,61,.4); color:var(--acid); cursor:pointer; text-shadow:0 0 6px var(--acid-halo); }
|
||||
.add-cta:hover { background:rgba(214,255,61,.14); }
|
||||
|
||||
/* Activity pane — filter chips + transaction list */
|
||||
.actfilter { display:flex; gap:6px; margin:6px 0 12px; overflow-x:auto; scrollbar-width:none; padding-bottom:2px; }
|
||||
.actfilter::-webkit-scrollbar { display:none; }
|
||||
.actchip { flex:none; font-family:var(--font-mono); font-size:10px; letter-spacing:.08em; text-transform:uppercase; padding:7px 12px; border-radius:16px; border:1px solid var(--border); background:transparent; color:var(--muted); cursor:pointer; transition: color .2s, border-color .2s, background .2s; }
|
||||
.actchip.on { color:var(--acid); border-color:rgba(214,255,61,.45); background:rgba(214,255,61,.06); text-shadow:0 0 5px var(--acid-halo); }
|
||||
.actlist { background:var(--surface-1); border:1px solid var(--border); border-radius:14px; overflow:hidden; }
|
||||
.actitem { display:flex; align-items:center; gap:13px; padding:13px 15px; border-bottom:1px solid var(--border); }
|
||||
.actitem:last-child { border-bottom:0; }
|
||||
.actitem.hidden { display:none; }
|
||||
.actitem .ico { width:32px; height:32px; flex:none; border-radius:9px; display:grid; place-items:center; background: var(--surface-2); color: var(--ink-soft); font-size:14px; }
|
||||
.actitem .a-main { flex:1; min-width:0; }
|
||||
.actitem .a-title { font-family: var(--font-display); font-size:14px; color: var(--ink); }
|
||||
.actitem .a-sub { font-family: var(--font-mono); font-size:9px; color: var(--muted); margin-top:2px; }
|
||||
.actitem .a-amt { font-family: var(--font-mono); font-size:12px; color: var(--ink-bright); text-align:right; }
|
||||
.actitem .a-amt.in { color:#0ac18e; }
|
||||
|
||||
/* Legend rows as multi-select category filters (assets pane) */
|
||||
.leg, .nba-line { user-select:none; }
|
||||
.leg.off, .nba-line.off { opacity:.4; }
|
||||
.leg.off .sw, .nba-line.off .sw { box-shadow:none !important; }
|
||||
.ccard.hidden { display:none; }
|
||||
|
||||
/* Wallet-level secondary actions (Activity / Fuse). Send / Receive / Scan
|
||||
are on the central FAB, not duplicated here. */
|
||||
.actions { display:flex; gap:8px; margin: 4px 0 18px; padding: 10px 6px; background:var(--surface-1); border:1px solid var(--border); border-radius:14px; }
|
||||
.actions .mini { flex:1; display:flex; flex-direction:column; align-items:center; gap:5px; padding:6px 4px; background:0; border:0; cursor:pointer; color:var(--ink-soft); }
|
||||
.actions .mini .ai { font-size:18px; color:var(--acid); text-shadow:0 0 8px var(--acid-halo); line-height:1; }
|
||||
.actions .mini .al { font-family:var(--font-mono); font-size:9px; letter-spacing:.1em; text-transform:uppercase; color:var(--ink-soft); }
|
||||
.actions .mini:hover .al { color:var(--ink-bright); }
|
||||
|
||||
/* FAB quick-action sheet — floats just above the central FAB. Three options:
|
||||
Send · Receive · Scan. Tap a backdrop to dismiss. NOT a fullscreen modal. */
|
||||
.fab-sheet { position:absolute; left:50%; bottom:100px; transform:translateX(-50%) translateY(8px); z-index:30; display:none; gap:10px; padding:12px 14px; border-radius:18px; background:var(--sky-mid); border:1px solid rgba(214,255,61,.35); box-shadow:0 14px 36px rgba(0,0,0,.55), 0 0 18px var(--acid-dim); opacity:0; transition: opacity .2s ease, transform .2s ease; }
|
||||
.fab-sheet.open { display:flex; opacity:1; transform:translateX(-50%) translateY(0); }
|
||||
.fab-sheet .qa { display:flex; flex-direction:column; align-items:center; gap:6px; padding:9px 10px; min-width:74px; background:transparent; border:0; cursor:pointer; border-radius:11px; transition: background .2s; }
|
||||
.fab-sheet .qa:hover { background: rgba(214,255,61,.07); }
|
||||
.fab-sheet .qa .qi { width:34px; height:34px; display:grid; place-items:center; border-radius:50%; background: rgba(214,255,61,.12); color:var(--acid); font-size:18px; text-shadow:0 0 8px var(--acid-halo); }
|
||||
.fab-sheet .qa .ql { font-family:var(--font-mono); font-size:9.5px; letter-spacing:.1em; text-transform:uppercase; color:var(--ink-soft); }
|
||||
.fab-sheet::after { content:""; position:absolute; left:50%; bottom:-7px; transform:translateX(-50%) rotate(45deg); width:13px; height:13px; background:var(--sky-mid); border-right:1px solid rgba(214,255,61,.35); border-bottom:1px solid rgba(214,255,61,.35); }
|
||||
.fab-backdrop { position:absolute; inset:0; z-index:25; display:none; border-radius:30px; background:rgba(5,8,16,.45); backdrop-filter:blur(1.5px); }
|
||||
.fab-backdrop.open { display:block; }
|
||||
|
||||
/* Three category cards — Bitcoin Cash / MBA / NBA. Each is a tappable summary
|
||||
row showing the family total. Tap to expand (accordion) and reveal the held
|
||||
assets inside, or use the "View in Agora →" link for the full surface. */
|
||||
.ccard { display:block; background:var(--surface-1); border:1px solid var(--border); border-radius:14px; margin-bottom:10px; overflow:hidden; transition: border-color .2s; }
|
||||
.ccard:hover { border-color:rgba(214,255,61,.25); }
|
||||
.csum { display:flex; align-items:center; gap:13px; padding:14px 16px; cursor:pointer; }
|
||||
.csum .cdot { width:11px; height:11px; flex:none; border-radius:50%; }
|
||||
.csum .cdot.bch { background:#0ac18e; box-shadow:0 0 6px rgba(10,193,142,.5); }
|
||||
.csum .cdot.mba { background:var(--acid); box-shadow:0 0 6px var(--acid-halo); }
|
||||
.csum .cdot.nba { background:#7f8cff; box-shadow:0 0 6px rgba(127,140,255,.5); }
|
||||
.csum .cmeta { flex:1; min-width:0; }
|
||||
.csum .cname { font-family:var(--font-display); font-weight:500; font-size:16px; color:var(--ink-bright); }
|
||||
.csum .csub { font-family:var(--font-mono); font-size:9.5px; color:var(--muted); margin-top:2px; }
|
||||
.csum .cval { text-align:right; font-family:var(--font-mono); }
|
||||
.csum .cval .cb { font-size:14px; color:var(--ink-bright); }
|
||||
.csum .cval .cb.soft { color:var(--ink-soft); font-style:italic; }
|
||||
.csum .cval .ccnt { font-size:9.5px; color:var(--muted); margin-top:2px; }
|
||||
.csum .cchev { color:var(--muted); margin-left:8px; transition: transform .25s; }
|
||||
.ccard.open .cchev { transform: rotate(90deg); color:var(--acid); }
|
||||
.clist { display:none; padding:0 16px 14px; border-top:1px solid var(--border); }
|
||||
.ccard.open .clist { display:block; }
|
||||
.crow { display:flex; align-items:center; gap:11px; padding:11px 0; border-bottom:1px solid var(--border); cursor:pointer; }
|
||||
.crow:last-of-type { border-bottom:0; }
|
||||
.crow .rico { width:30px; height:30px; flex:none; border-radius:50%; display:grid; place-items:center; background:var(--surface-2); color:var(--ink-soft); font-family:var(--font-mono); font-size:11px; font-weight:600; }
|
||||
.crow .rmeta { flex:1; min-width:0; }
|
||||
.crow .rname { font-family:var(--font-display); font-weight:500; font-size:14px; color:var(--ink-bright); display:flex; align-items:center; gap:7px; }
|
||||
.crow .rsub { font-family:var(--font-mono); font-size:9px; color:var(--muted); margin-top:2px; }
|
||||
.crow .rbal { text-align:right; font-family:var(--font-mono); }
|
||||
.crow .rbal .rb { font-size:12px; color:var(--ink-bright); }
|
||||
.crow .rbal .rs { font-size:9px; color:var(--ink-soft); margin-top:1px; }
|
||||
.crow .rbal .rs.soft { color:var(--muted); font-style:italic; }
|
||||
.vagora { display:block; text-align:right; padding:9px 0 0; font-family:var(--font-mono); font-size:9.5px; letter-spacing:.12em; text-transform:uppercase; color:var(--muted); cursor:pointer; }
|
||||
.vagora:hover { color:var(--acid); text-shadow:0 0 5px var(--acid-halo); }
|
||||
.chip { font-family:var(--font-mono); font-size:8px; letter-spacing:.08em; text-transform:uppercase; padding:2px 6px; border-radius:5px; border:1px solid var(--border-strong); color:var(--ink-soft); }
|
||||
.chip.safe { color:var(--acid); border-color:rgba(214,255,61,.35); text-shadow:0 0 5px var(--acid-halo); }
|
||||
.chip.warn { color:var(--risk-warn); border-color:rgba(255,159,28,.4); }
|
||||
|
||||
/* Recent activity footer link */
|
||||
.recent-link { text-align:center; font-family:var(--font-mono); font-size:10px; letter-spacing:.16em; text-transform:uppercase; color:var(--muted); padding:14px 0 6px; cursor:pointer; }
|
||||
.recent-link:hover { color:var(--acid); text-shadow:0 0 6px var(--acid-halo); }
|
||||
|
||||
/* bottom bar + fab */
|
||||
.tabbar { position:absolute; left:0; right:0; bottom:0; display:flex; justify-content:space-around; align-items:center; padding:14px 10px 18px; border-top:1px solid var(--border); background: linear-gradient(0deg, var(--sky-deep), transparent); border-radius:0 0 30px 30px; }
|
||||
|
|
@ -98,67 +183,165 @@
|
|||
<div class="gear">⚙</div>
|
||||
</div>
|
||||
|
||||
<!-- Portfolio donut -->
|
||||
<!-- Portfolio donut — BCH-denominated only (free BCH + Σ MBA PNV) -->
|
||||
<div class="portfolio">
|
||||
<div class="donut"><div class="d-center"><div class="d-total">0.0734</div><div class="d-label">BCH total</div></div></div>
|
||||
<div class="donut"><div class="d-center"><div class="d-total">0.0600</div><div class="d-label">BCH total</div></div></div>
|
||||
<div class="legend">
|
||||
<div class="leg" data-fam="bch"><span class="sw" style="background:#0ac18e"></span>Bitcoin Cash<span class="val">0.040</span></div>
|
||||
<div class="leg mba" data-fam="mba"><span class="sw" style="background:var(--acid)"></span>MBA · backed<span class="val">0.020</span></div>
|
||||
<div class="leg" data-fam="token"><span class="sw" style="background:#7f8cff"></span>NBA · non-backed<span class="val">0.013</span></div>
|
||||
<div class="leg" style="color:var(--muted);font-size:9px;margin-top:2px;">~ $48.21 · tap to toggle fiat</div>
|
||||
<!-- NBA — count line, not a wedge (no BCH floor, not BCH-denominated) -->
|
||||
<div class="nba-line" data-fam="token"><span class="sw"></span>NBA · non-backed<span class="val">~ 0.040</span></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- BCH card: its own card (Rule 4 — asset + fuel) -->
|
||||
<div class="bch-card">
|
||||
<div class="bch-head">
|
||||
<span class="bch-b lg"><svg class="bch-logo" viewBox="0 0 24 24" aria-hidden="true"><circle cx="12" cy="12" r="12" fill="#fff"/><path fill="#0ac18e" d="m10.84 11.22-.688-2.568c.728-.18 2.839-1.051 3.39.506.27 1.682-1.978 1.877-2.702 2.062zm.289 1.313.755 2.829c.868-.228 3.496-.46 3.241-2.351-.433-1.666-3.125-.706-3.996-.478zM24 12c0 6.627-5.373 12-12 12S0 18.627 0 12 5.373 0 12 0s12 5.373 12 12zm-6.341.661c-.183-1.151-1.441-2.095-2.485-2.202.643-.57.969-1.401.57-2.488-.603-1.368-1.989-1.66-3.685-1.377l-.546-2.114-1.285.332.536 2.108c-.338.085-.685.158-1.029.256L9.198 5.08l-1.285.332.545 2.114c-.277.079-2.595.673-2.595.673l.353 1.377s.944-.265.935-.244c.524-.137.771.125.886.372l1.498 5.793c.018.168-.012.454-.372.551.021.012-.935.241-.935.241l.14 1.605s2.296-.588 2.598-.664l.551 2.138 1.285-.332-.551-2.153c.353-.082.697-.168 1.032-.256l.548 2.141 1.285-.332-.551-2.135c1.982-.482 3.38-1.73 3.094-3.64z"/></svg></span>
|
||||
<div class="bch-meta">
|
||||
<div class="bch-name">Bitcoin Cash</div>
|
||||
<div class="bch-fuel">● fuel OK — covers network fees</div>
|
||||
<!-- Wallet-level secondary actions. Send / Receive / Scan live on the
|
||||
central FAB; this row covers the rest (Activity, Fuse, Sweep). -->
|
||||
<div class="actions">
|
||||
<button class="mini" data-link="activity"><span class="ai">⌖</span><span class="al">Activity</span></button>
|
||||
<button class="mini" id="fuseBtn"><span class="ai">⊜</span><span class="al">Fuse</span></button>
|
||||
<button class="mini" data-link="sweep"><span class="ai">⤓</span><span class="al">Sweep</span></button>
|
||||
</div>
|
||||
|
||||
<!-- Sub-tabs: Assets | Wallets | Activity (peer panes inside Main) -->
|
||||
<div class="subtabs">
|
||||
<button class="subtab active" data-pane="assets">Assets</button>
|
||||
<button class="subtab" data-pane="wallets">Wallets</button>
|
||||
<button class="subtab" data-pane="activity">Activity</button>
|
||||
</div>
|
||||
|
||||
<!-- ASSETS PANE — category cards; legend rows above toggle visibility -->
|
||||
<div class="pane active" data-pane="assets">
|
||||
|
||||
<!-- Three category cards — collapsed by default. Tap header to expand.
|
||||
"View in Agora →" jumps to the full asset surface. -->
|
||||
<div class="ccard" data-cat="bch">
|
||||
<div class="csum">
|
||||
<span class="cdot bch"></span>
|
||||
<div class="cmeta"><div class="cname">Bitcoin Cash</div><div class="csub">Free balance · fuel + send</div></div>
|
||||
<div class="cval"><div class="cb">0.0400 BCH</div><div class="ccnt">4,000,000 sat</div></div>
|
||||
<span class="cchev">›</span>
|
||||
</div>
|
||||
<div class="clist">
|
||||
<div class="crow" data-link="asset-bch">
|
||||
<div class="rico bch">B</div>
|
||||
<div class="rmeta"><div class="rname">Bitcoin Cash</div><div class="rsub">Free · fuel</div></div>
|
||||
<div class="rbal"><div class="rb">0.0400 BCH</div><div class="rs">4,000,000 sat</div></div>
|
||||
</div>
|
||||
<div class="bch-bal"><div class="b">0.0400 BCH</div><div class="f">~ $26.28</div></div>
|
||||
</div>
|
||||
<div class="bch-actions">
|
||||
<button class="mini">Send</button>
|
||||
<button class="mini">Receive</button>
|
||||
<button class="mini">Activity</button>
|
||||
<button class="mini" id="fuseBtn">Fuse</button>
|
||||
<a class="vagora" data-link="agora-bch">View in Agora →</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Recent activity -->
|
||||
<div class="label-row">
|
||||
<button class="flab active" data-fam="all">Recent</button>
|
||||
<button class="flab" data-fam="mba">MBA</button>
|
||||
<button class="flab" data-fam="token">NBA</button>
|
||||
<button class="flab" data-link="all">View all</button>
|
||||
<div class="ccard" data-cat="mba">
|
||||
<div class="csum">
|
||||
<span class="cdot mba"></span>
|
||||
<div class="cmeta"><div class="cname">Backed Assets</div><div class="csub">Protocol-enforced BCH floor · redeemable (MBA)</div></div>
|
||||
<div class="cval"><div class="cb">0.0200 BCH</div><div class="ccnt">2 categories</div></div>
|
||||
<span class="cchev">›</span>
|
||||
</div>
|
||||
<div class="clist">
|
||||
<div class="crow" data-link="asset-nova">
|
||||
<div class="rico">NV</div>
|
||||
<div class="rmeta"><div class="rname">Nova<span class="chip safe">DEA</span></div><div class="rsub">120 NOVA · 1 NOVA = 100 sat</div></div>
|
||||
<div class="rbal"><div class="rb">0.0120 BCH</div><div class="rs">PNV</div></div>
|
||||
</div>
|
||||
<div class="crow" data-link="asset-lumen">
|
||||
<div class="rico">LM</div>
|
||||
<div class="rmeta"><div class="rname">Lumen<span class="chip safe">PLA</span></div><div class="rsub">40 LMN · 1 LMN = 200 sat · capped</div></div>
|
||||
<div class="rbal"><div class="rb">0.0080 BCH</div><div class="rs">PNV</div></div>
|
||||
</div>
|
||||
<a class="vagora" data-link="agora-mba">View in Agora →</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="act" data-fam="bch">
|
||||
<div class="ico">↓</div>
|
||||
<div class="a-main"><div class="a-title">Received</div><div class="a-sub">from bchtest:qz9…k4f · 2h ago</div></div>
|
||||
<div class="a-amt in">+0.010 BCH</div>
|
||||
<div class="ccard" data-cat="nba">
|
||||
<div class="csum">
|
||||
<span class="cdot nba"></span>
|
||||
<div class="cmeta"><div class="cname">Non-backed Assets</div><div class="csub">No floor · market-priced</div></div>
|
||||
<div class="cval"><div class="cb soft">~ 0.0400 BCH</div><div class="ccnt">2 categories</div></div>
|
||||
<span class="cchev">›</span>
|
||||
</div>
|
||||
<div class="clist">
|
||||
<div class="crow" data-link="asset-meridian">
|
||||
<div class="rico">MR</div>
|
||||
<div class="rmeta"><div class="rname">Meridian<span class="chip warn">MTU</span></div><div class="rsub">5,000 MRD · issuer-minted</div></div>
|
||||
<div class="rbal"><div class="rb">~ 0.0250</div><div class="rs soft">market</div></div>
|
||||
</div>
|
||||
<div class="crow" data-link="asset-doge2">
|
||||
<div class="rico">D2</div>
|
||||
<div class="rmeta"><div class="rname">Doge2<span class="chip warn">PTU</span></div><div class="rsub">100,000 D2 · open-mint</div></div>
|
||||
<div class="rbal"><div class="rb">~ 0.0150</div><div class="rs soft">market</div></div>
|
||||
</div>
|
||||
<a class="vagora" data-link="agora-nba">View in Agora →</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="act" data-fam="mba">
|
||||
<div class="ico">⇄</div>
|
||||
<div class="a-main"><div class="a-title">Orbital swap</div><div class="a-sub">50 NOVA → 0.005 BCH · ASM · 1d</div></div>
|
||||
<div class="a-amt">atomic</div>
|
||||
|
||||
</div><!-- /pane.assets -->
|
||||
|
||||
<!-- WALLETS PANE -->
|
||||
<div class="pane" data-pane="wallets">
|
||||
<div class="wlist">
|
||||
<div class="wrow">
|
||||
<span class="wdot"></span>
|
||||
<div class="wmain"><div class="wname">Main</div><div class="wsub">bchtest:qrd5g7…2ltaxuwh · 16 tok utxos</div></div>
|
||||
<div class="wval"><div class="b">0.0590 BCH</div><div class="s">5,903,166 sat</div></div>
|
||||
</div>
|
||||
<div class="wrow">
|
||||
<span class="wdot idle"></span>
|
||||
<div class="wmain"><div class="wname">Savings</div><div class="wsub">bchtest:qzd2dw…v9t3eyc6 · 2 tok utxos</div></div>
|
||||
<div class="wval"><div class="b">0.5767 BCH</div><div class="s">57,668,955 sat</div></div>
|
||||
</div>
|
||||
<div class="wrow">
|
||||
<span class="wdot idle"></span>
|
||||
<div class="wmain"><div class="wname">Chipnet test</div><div class="wsub">bchtest:qpn0w8…7l4mzeux · 0 tok utxos</div></div>
|
||||
<div class="wval"><div class="b">0.0230 BCH</div><div class="s">2,300,000 sat</div></div>
|
||||
</div>
|
||||
</div>
|
||||
<button class="add-cta">+ Add / Import wallet</button>
|
||||
</div>
|
||||
<div class="act" data-fam="mba">
|
||||
<div class="ico">↓</div>
|
||||
<div class="a-main"><div class="a-title">Claimed</div><div class="a-sub">Nova reservoir · DEA · 2d</div></div>
|
||||
<div class="a-amt in">+120 NOVA</div>
|
||||
|
||||
<!-- ACTIVITY PANE — in-place transaction history with filter chips -->
|
||||
<div class="pane" data-pane="activity">
|
||||
<div class="actfilter">
|
||||
<button class="actchip on" data-act="all">All</button>
|
||||
<button class="actchip" data-act="sent">Sent</button>
|
||||
<button class="actchip" data-act="received">Received</button>
|
||||
<button class="actchip" data-act="swap">Swap</button>
|
||||
</div>
|
||||
<div class="actlist">
|
||||
<div class="actitem" data-act="received">
|
||||
<div class="ico">↓</div>
|
||||
<div class="a-main"><div class="a-title">Received</div><div class="a-sub">from bchtest:qz9…k4f · 2h ago</div></div>
|
||||
<div class="a-amt in">+0.010 BCH</div>
|
||||
</div>
|
||||
<div class="actitem" data-act="swap">
|
||||
<div class="ico">⇄</div>
|
||||
<div class="a-main"><div class="a-title">Orbital swap</div><div class="a-sub">50 NOVA → 0.005 BCH · ASM · 1d</div></div>
|
||||
<div class="a-amt">atomic</div>
|
||||
</div>
|
||||
<div class="actitem" data-act="received">
|
||||
<div class="ico">↓</div>
|
||||
<div class="a-main"><div class="a-title">Claimed</div><div class="a-sub">Nova reservoir · DEA · 2d</div></div>
|
||||
<div class="a-amt in">+120 NOVA</div>
|
||||
</div>
|
||||
<div class="actitem" data-act="sent">
|
||||
<div class="ico">↑</div>
|
||||
<div class="a-main"><div class="a-title">Sent</div><div class="a-sub">to bchtest:qp2…7lm · 4d</div></div>
|
||||
<div class="a-amt">−5 LMN</div>
|
||||
</div>
|
||||
<div class="actitem" data-act="sent">
|
||||
<div class="ico">↑</div>
|
||||
<div class="a-main"><div class="a-title">Sent</div><div class="a-sub">Meridian · MTU · 5d</div></div>
|
||||
<div class="a-amt">−100 MRD</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="act" data-fam="mba">
|
||||
<div class="ico">↑</div>
|
||||
<div class="a-main"><div class="a-title">Sent</div><div class="a-sub">to bchtest:qp2…7lm · 4d</div></div>
|
||||
<div class="a-amt">−5 LMN</div>
|
||||
</div>
|
||||
<div class="act" data-fam="token">
|
||||
<div class="ico">↑</div>
|
||||
<div class="a-main"><div class="a-title">Sent</div><div class="a-sub">Meridian · MTU · 5d</div></div>
|
||||
<div class="a-amt">−100 MRD</div>
|
||||
|
||||
<!-- FAB quick-action sheet — floats above the central FAB. -->
|
||||
<div class="fab-backdrop" id="fabBackdrop"></div>
|
||||
<div class="fab-sheet" id="fabSheet">
|
||||
<button class="qa" data-qa="send"><span class="qi">⇧</span><span class="ql">Send</span></button>
|
||||
<button class="qa" data-qa="receive"><span class="qi">⇩</span><span class="ql">Receive</span></button>
|
||||
<button class="qa" data-qa="scan"><span class="qi">⊞</span><span class="ql">Scan</span></button>
|
||||
</div>
|
||||
|
||||
<!-- BOTTOM BAR -->
|
||||
|
|
@ -190,25 +373,45 @@
|
|||
c.appendChild(frag);
|
||||
})();
|
||||
|
||||
// Feed filter shared by the Recent labels and the donut segments
|
||||
function filterFeed(fam) {
|
||||
document.querySelectorAll('.flab[data-fam]').forEach(function (x) {
|
||||
x.classList.toggle('active', x.getAttribute('data-fam') === fam);
|
||||
});
|
||||
document.querySelectorAll('.act').forEach(function (r) {
|
||||
r.style.display = (fam === 'all' || r.getAttribute('data-fam') === fam) ? '' : 'none';
|
||||
// Category cards — tap header to expand/collapse accordion.
|
||||
document.querySelectorAll('.ccard .csum').forEach(function (sum) {
|
||||
sum.addEventListener('click', function (e) {
|
||||
if (e.target.closest('.crow, .vagora')) return;
|
||||
sum.parentElement.classList.toggle('open');
|
||||
});
|
||||
});
|
||||
|
||||
// Sub-tabs: Assets | Wallets | Activity (one active at a time)
|
||||
function showPane(name) {
|
||||
document.querySelectorAll('.subtab').forEach(function (s) { s.classList.toggle('active', s.getAttribute('data-pane') === name); });
|
||||
document.querySelectorAll('.pane').forEach(function (p) { p.classList.toggle('active', p.getAttribute('data-pane') === name); });
|
||||
}
|
||||
document.querySelectorAll('.flab[data-fam]').forEach(function (b) {
|
||||
b.addEventListener('click', function () { filterFeed(b.getAttribute('data-fam')); });
|
||||
document.querySelectorAll('.subtab').forEach(function (st) {
|
||||
st.addEventListener('click', function () { showPane(st.getAttribute('data-pane')); });
|
||||
});
|
||||
// Legend rows: click → show that family's transactions
|
||||
document.querySelectorAll('.leg[data-fam]').forEach(function (l) {
|
||||
l.addEventListener('click', function () { filterFeed(l.getAttribute('data-fam')); });
|
||||
|
||||
// Legend rows = multi-select category filters for the Assets pane.
|
||||
// Default: all on. Tap → toggle that family's card visibility.
|
||||
var FAM_TO_CAT = { bch:'bch', mba:'mba', token:'nba' };
|
||||
document.querySelectorAll('.leg[data-fam], .nba-line[data-fam]').forEach(function (l) {
|
||||
l.addEventListener('click', function () {
|
||||
l.classList.toggle('off');
|
||||
var cat = FAM_TO_CAT[l.getAttribute('data-fam')];
|
||||
var card = document.querySelector('.ccard[data-cat="' + cat + '"]');
|
||||
if (card) card.classList.toggle('hidden', l.classList.contains('off'));
|
||||
});
|
||||
});
|
||||
// View all → reset to the full feed (and would open the Activity screen)
|
||||
document.querySelectorAll('.flab[data-link]').forEach(function (l) {
|
||||
l.addEventListener('click', function () { filterFeed('all'); });
|
||||
|
||||
// Activity-chip filter (Recent / Sent / Received / Swap — single-select)
|
||||
document.querySelectorAll('.actchip').forEach(function (c) {
|
||||
c.addEventListener('click', function () {
|
||||
document.querySelectorAll('.actchip').forEach(function (x) { x.classList.remove('on'); });
|
||||
c.classList.add('on');
|
||||
var f = c.getAttribute('data-act');
|
||||
document.querySelectorAll('.actitem').forEach(function (it) {
|
||||
it.classList.toggle('hidden', f !== 'all' && it.getAttribute('data-act') !== f);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
// Mouse parallax — the starfield drifts with the cursor (à la bch.guru)
|
||||
|
|
@ -223,7 +426,7 @@
|
|||
})();
|
||||
// Bottom-bar navigation between mockup screens
|
||||
(function () {
|
||||
var map = { main:'main-tab.html', assets:'assets-tab.html', artemision:'artemision-tab.html', apps:'apps-tab.html' };
|
||||
var map = { main:'main-tab.html', agora:'agora.html', artemision:'artemision-tab.html', apps:'apps-tab.html' };
|
||||
document.querySelectorAll('.tabbar .tab').forEach(function (t) {
|
||||
var el = t.querySelector('.lbl'); if (!el) return;
|
||||
var dest = map[el.textContent.trim().toLowerCase()];
|
||||
|
|
@ -233,9 +436,24 @@
|
|||
}
|
||||
});
|
||||
var gear = document.querySelector('.gear'); if (gear) { gear.style.cursor = 'pointer'; gear.addEventListener('click', function () { location.href = 'settings.html'; }); }
|
||||
var fab = document.getElementById('fab'); if (fab) fab.addEventListener('click', function () { location.href = 'send-flow.html'; });
|
||||
var va = document.querySelector('.flab[data-link="all"]'); if (va) va.addEventListener('click', function () { location.href = 'activity.html'; });
|
||||
var bchSend = document.querySelector('.bch-actions .mini'); if (bchSend) bchSend.addEventListener('click', function () { location.href = 'send-flow.html'; });
|
||||
var fab = document.getElementById('fab');
|
||||
var sheet = document.getElementById('fabSheet');
|
||||
var backdrop = document.getElementById('fabBackdrop');
|
||||
function openSheet() { sheet.classList.add('open'); backdrop.classList.add('open'); }
|
||||
function closeSheet() { sheet.classList.remove('open'); backdrop.classList.remove('open'); }
|
||||
if (fab) fab.addEventListener('click', function (e) { e.stopPropagation(); sheet.classList.contains('open') ? closeSheet() : openSheet(); });
|
||||
if (backdrop) backdrop.addEventListener('click', closeSheet);
|
||||
document.querySelectorAll('.fab-sheet .qa').forEach(function (qa) {
|
||||
qa.addEventListener('click', function () { location.href = 'send-flow.html'; });
|
||||
});
|
||||
var linkMap = { send:'send-flow.html', receive:'send-flow.html', sweep:'sweep-flow.html' };
|
||||
document.querySelectorAll('[data-link]').forEach(function (el) {
|
||||
var k = el.getAttribute('data-link');
|
||||
if (k === 'activity') { el.style.cursor='pointer'; el.addEventListener('click', function () { showPane('activity'); }); }
|
||||
else if (linkMap[k]) { el.style.cursor='pointer'; el.addEventListener('click', function () { location.href = linkMap[k]; }); }
|
||||
else if (k && k.indexOf('asset-') === 0) { el.style.cursor='pointer'; el.addEventListener('click', function () { location.href = 'asset-detail.html'; }); }
|
||||
else if (k && k.indexOf('agora-') === 0) { el.style.cursor='pointer'; el.addEventListener('click', function () { location.href = 'agora.html'; }); }
|
||||
});
|
||||
var fuseBtn = document.getElementById('fuseBtn'); if (fuseBtn) fuseBtn.addEventListener('click', function () { location.href = 'fuse-flow.html'; });
|
||||
})();
|
||||
</script>
|
||||
|
|
|
|||
|
|
@ -154,7 +154,6 @@
|
|||
<div class="field">
|
||||
<span class="flabel">Amount</span>
|
||||
<input class="input" value="100 ZC">
|
||||
<div class="hint ok">● fuel OK — plain BCH covers the ~2,000 sat network fee ✓</div>
|
||||
</div>
|
||||
|
||||
<button class="cta" data-go="review">Review →</button>
|
||||
|
|
@ -284,7 +283,7 @@
|
|||
|
||||
// Bottom-bar navigation between mockup screens
|
||||
(function () {
|
||||
var map = { main:'main-tab.html', assets:'assets-tab.html', artemision:'artemision-tab.html', apps:'apps-tab.html' };
|
||||
var map = { main:'main-tab.html', agora:'agora.html', artemision:'artemision-tab.html', apps:'apps-tab.html' };
|
||||
document.querySelectorAll('.tabbar .tab').forEach(function (t) {
|
||||
var el = t.querySelector('.lbl'); if (!el) return;
|
||||
var dest = map[el.textContent.trim().toLowerCase()];
|
||||
|
|
|
|||
|
|
@ -45,6 +45,27 @@
|
|||
.thr { padding:13px 15px; font-family:var(--font-mono); font-size:10px; color:var(--ink-soft); line-height:1.7; border-top:1px solid var(--border); }
|
||||
.thr .t { color:var(--risk-warn); }
|
||||
|
||||
/* multi-wallet rows (Settings → Wallets) — names front, balance right.
|
||||
Letter badges (M / S / T) are stylistic only; dev variant uses muted color
|
||||
to mark __DEV__-flagged surfaces (chipnet test wallets). */
|
||||
.group-label { display:flex; align-items:center; justify-content:space-between; }
|
||||
.wrow { gap:11px; padding:12px 14px; }
|
||||
.wrow.active .wbadge { background:rgba(214,255,61,.18); border-color:rgba(214,255,61,.5); color:var(--acid); }
|
||||
.wbadge { width:30px; height:30px; flex:none; border-radius:50%; display:grid; place-items:center; font-family:var(--font-mono); font-size:12px; font-weight:600; background:var(--surface-2); border:1px solid var(--border-strong); color:var(--ink-soft); }
|
||||
.wbadge.dev { color:var(--muted); border-style:dashed; }
|
||||
.wmeta { flex:1; min-width:0; }
|
||||
.wname { font-family:var(--font-display); font-size:15px; color:var(--ink-bright); display:flex; align-items:center; gap:6px; }
|
||||
.wedit { background:0; border:0; padding:0; color:var(--muted); cursor:pointer; font-size:11px; line-height:1; }
|
||||
.wedit:hover { color:var(--acid); }
|
||||
.waddr { font-family:var(--font-mono); font-size:10px; color:var(--ink-soft); margin-top:2px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
|
||||
.waddr .wutxo { margin-left:6px; color:var(--muted); }
|
||||
.wbal { text-align:right; font-family:var(--font-mono); }
|
||||
.wbal .wb { font-size:13px; color:var(--ink-bright); }
|
||||
.wbal .ws { font-size:9.5px; color:var(--muted); margin-top:2px; }
|
||||
.wbal .wact { font-size:9px; color:var(--acid); text-shadow:0 0 6px var(--acid-halo); margin-top:3px; }
|
||||
.wadd { color:var(--ink-soft); }
|
||||
.wadd .si { background:transparent; border:1px dashed var(--border-strong); }
|
||||
|
||||
/* tabbar */
|
||||
.tabbar { position:absolute; left:0; right:0; bottom:0; display:flex; justify-content:space-around; align-items:center; padding:14px 10px 18px; border-top:1px solid var(--border); background: linear-gradient(0deg, var(--sky-deep), transparent); border-radius:0 0 30px 30px; }
|
||||
.tab { display:flex; flex-direction:column; align-items:center; gap:6px; background:0; border:0; cursor:pointer; }
|
||||
|
|
@ -68,6 +89,53 @@
|
|||
</div>
|
||||
|
||||
<div class="scroll">
|
||||
<!-- WALLETS — multi-wallet picker / HD-account list. Glossary §Shell UX rule 1:
|
||||
production UX is name-labelled accounts here (NOT a topbar pill).
|
||||
Letter badges (A/B/C…) are dev-only, behind __DEV__ flag. -->
|
||||
<div class="group">
|
||||
<div class="group-label">
|
||||
<span>Wallets · 3</span>
|
||||
<span style="float:right;color:var(--ink-soft);text-transform:none;letter-spacing:.05em;">Σ 0.6587 BCH</span>
|
||||
</div>
|
||||
<div class="card">
|
||||
<div class="srow wrow active">
|
||||
<div class="wbadge active">M</div>
|
||||
<div class="wmeta">
|
||||
<div class="wname">Main <button class="wedit" title="Rename">✎</button></div>
|
||||
<div class="waddr">bchtest:qrd5g7…2ltaxuwh<span class="wutxo">· 16 tok utxos</span></div>
|
||||
</div>
|
||||
<div class="wbal">
|
||||
<div class="wb">0.0590</div>
|
||||
<div class="ws">5,903,166 sat</div>
|
||||
<div class="wact">● active</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="srow wrow">
|
||||
<div class="wbadge">S</div>
|
||||
<div class="wmeta">
|
||||
<div class="wname">Savings <button class="wedit" title="Rename">✎</button></div>
|
||||
<div class="waddr">bchtest:qzd2dw…v9t3eyc6<span class="wutxo">· 2 tok utxos</span></div>
|
||||
</div>
|
||||
<div class="wbal">
|
||||
<div class="wb">0.5767</div>
|
||||
<div class="ws">57,668,955 sat</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="srow wrow">
|
||||
<div class="wbadge dev">T</div>
|
||||
<div class="wmeta">
|
||||
<div class="wname">Chipnet test <span class="pill" style="margin-left:6px;">Dev</span></div>
|
||||
<div class="waddr">bchtest:qpn0w8…7l4mzeux<span class="wutxo">· 0 tok utxos</span></div>
|
||||
</div>
|
||||
<div class="wbal">
|
||||
<div class="wb">0.0230</div>
|
||||
<div class="ws">2,300,000 sat</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="srow wadd"><div class="si">+</div><div><div class="st">Add wallet</div><div class="ss">New HD account · m/44'/145'/N'</div></div><div class="sv"><span class="chev">›</span></div></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- SECURITY -->
|
||||
<div class="group">
|
||||
<div class="group-label">Security</div>
|
||||
|
|
@ -106,10 +174,10 @@
|
|||
|
||||
<!-- REGISTRIES -->
|
||||
<div class="group">
|
||||
<div class="group-label">Registries · Trusted keys</div>
|
||||
<div class="group-label">Registries · Token definitions</div>
|
||||
<div class="empty">
|
||||
Deviant ships <b>no default registries</b> and <b>no default trusted keys</b> (ADR-0008). The wallet never becomes the authority — add your own when ready. Tier-B definitions are unverified until you root them in a key you trust.
|
||||
<div class="add">+ Add registry · + Add trusted key</div>
|
||||
Deviant ships <b>no default registries</b> and <b>no default trusted keys</b> (ADR-0008). The wallet never becomes the authority — add your own when ready. Until rooted in a key you trust, token definitions remain unverified.
|
||||
<div class="add" data-link="token-import">+ Import token · + Add registry · + Add trusted key</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
|
@ -162,13 +230,14 @@
|
|||
})();
|
||||
document.querySelectorAll('.switch').forEach(function (s) { s.addEventListener('click', function () { s.classList.toggle('on'); }); });
|
||||
(function () {
|
||||
var map = { main:'main-tab.html', assets:'assets-tab.html', artemision:'artemision-tab.html', apps:'apps-tab.html' };
|
||||
var map = { main:'main-tab.html', agora:'agora.html', artemision:'artemision-tab.html', apps:'apps-tab.html' };
|
||||
document.querySelectorAll('.tabbar .tab').forEach(function (t) {
|
||||
var el = t.querySelector('.lbl'); if (!el) return;
|
||||
var dest = map[el.textContent.trim().toLowerCase()];
|
||||
if (dest) { t.style.cursor='pointer'; t.addEventListener('click', function () { location.href = dest; }); }
|
||||
});
|
||||
document.querySelectorAll('[data-link="main"]').forEach(function (b) { b.addEventListener('click', function () { location.href='main-tab.html'; }); });
|
||||
document.querySelectorAll('[data-link="token-import"]').forEach(function (b) { b.style.cursor='pointer'; b.addEventListener('click', function () { location.href='token-import.html'; }); });
|
||||
})();
|
||||
</script>
|
||||
</body>
|
||||
|
|
|
|||
|
|
@ -191,7 +191,7 @@
|
|||
});
|
||||
})();
|
||||
(function () {
|
||||
var map = { main:'main-tab.html', assets:'assets-tab.html', artemision:'artemision-tab.html', apps:'apps-tab.html' };
|
||||
var map = { main:'main-tab.html', agora:'agora.html', artemision:'artemision-tab.html', apps:'apps-tab.html' };
|
||||
document.querySelectorAll('.tabbar .tab').forEach(function (t) {
|
||||
var el = t.querySelector('.lbl'); if (!el) return;
|
||||
var dest = map[el.textContent.trim().toLowerCase()];
|
||||
|
|
|
|||
191
design/mockups/sweep-flow.html
Normal file
191
design/mockups/sweep-flow.html
Normal file
|
|
@ -0,0 +1,191 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Deviant · Sweep · CosmoGenesis mockup</title>
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,300;9..144,400;9..144,500;9..144,600&family=JetBrains+Mono:wght@400;500&display=swap" rel="stylesheet">
|
||||
<link href="../cosmo-genesis.css" rel="stylesheet">
|
||||
<style>
|
||||
body { display:flex; justify-content:center; padding:28px 0; }
|
||||
.phone { position:relative; z-index:1; width:392px; min-height:840px; background: linear-gradient(180deg, rgba(19,26,42,.55), rgba(10,15,28,.55)); border:1px solid var(--border); border-radius:30px; padding:22px 20px 36px; backdrop-filter: blur(2px); }
|
||||
|
||||
/* Mirrors Capacitor's SweepFlow — two entry modes:
|
||||
mnemonic — BIP-44 gap scan, finds ALL funded addresses in an old wallet.
|
||||
wif — single private key, one known address, no scan needed.
|
||||
Both share the same review → broadcast → done flow. */
|
||||
.flow-head { display:flex; align-items:center; gap:12px; margin-bottom:18px; }
|
||||
.back { font-size:20px; color:var(--ink-soft); cursor:pointer; background:0; border:0; line-height:1; padding:4px 6px; }
|
||||
.flow-title { font-family:var(--font-display); font-weight:500; font-size:22px; color:var(--ink-bright); }
|
||||
.flow-step { margin-left:auto; font-family:var(--font-mono); font-size:9px; letter-spacing:.12em; color:var(--muted); text-transform:uppercase; }
|
||||
|
||||
/* Mode picker */
|
||||
.mode-tabs { display:flex; gap:8px; margin: 4px 2px 18px; padding:4px; background:var(--surface-1); border:1px solid var(--border); border-radius:12px; }
|
||||
.mt { flex:1; text-align:center; font-family:var(--font-mono); font-size:11px; letter-spacing:.1em; text-transform:uppercase; padding:10px 8px; border-radius:9px; background:0; border:0; color:var(--muted); cursor:pointer; transition: color .2s, background .2s; }
|
||||
.mt.active { color:var(--acid); background:var(--surface-2); text-shadow:0 0 7px var(--acid-halo); }
|
||||
|
||||
.note { font-family:var(--font-mono); font-size:10.5px; color:var(--ink-soft); line-height:1.6; margin-bottom:14px; }
|
||||
.note b { color:var(--ink-bright); }
|
||||
.note.warn { color:var(--risk-warn); }
|
||||
|
||||
.label { font-family:var(--font-mono); font-size:9px; letter-spacing:.22em; text-transform:uppercase; color:var(--muted); margin:0 0 7px; }
|
||||
.ta { width:100%; box-sizing:border-box; min-height:96px; background:var(--surface-1); border:1px solid var(--border-strong); border-radius:12px; padding:13px; font-family:var(--font-mono); font-size:12px; color:var(--ink-bright); resize:vertical; line-height:1.6; }
|
||||
.ta:focus { outline:none; border-color:rgba(214,255,61,.4); box-shadow:0 0 12px var(--acid-dim); }
|
||||
.input { width:100%; box-sizing:border-box; background:var(--surface-1); border:1px solid var(--border-strong); border-radius:12px; padding:13px; color:var(--ink-bright); font-family:var(--font-mono); font-size:12px; }
|
||||
|
||||
.field { margin-bottom:14px; }
|
||||
|
||||
.cta { width:100%; font-family:var(--font-mono); font-size:12px; letter-spacing:.14em; text-transform:uppercase; color:var(--sky-deep); background:var(--acid); border:0; border-radius:12px; padding:15px; cursor:pointer; box-shadow:0 0 16px var(--acid-halo); margin-top:8px; }
|
||||
.cta.disabled { background:var(--surface-2); color:var(--muted); box-shadow:none; cursor:not-allowed; }
|
||||
|
||||
/* Scan progress */
|
||||
.progress-card { background:var(--surface-1); border:1px solid var(--border); border-radius:14px; padding:22px 18px; text-align:center; margin: 6px 0 14px; }
|
||||
.pc-ring { width:54px; height:54px; margin:6px auto 16px; border:3px solid rgba(214,255,61,.18); border-top-color:var(--acid); border-radius:50%; animation: spin 1s linear infinite; }
|
||||
@keyframes spin { to { transform: rotate(360deg); } }
|
||||
.pc-status { font-family:var(--font-display); font-weight:500; font-size:15px; color:var(--ink-bright); }
|
||||
.pc-sub { font-family:var(--font-mono); font-size:10px; color:var(--muted); margin-top:6px; }
|
||||
|
||||
/* Review */
|
||||
.summary { background:var(--surface-1); border:1px solid var(--border); border-radius:14px; padding:14px 16px; margin-bottom:12px; }
|
||||
.sum-row { display:flex; justify-content:space-between; padding:6px 0; font-family:var(--font-mono); font-size:11px; color:var(--ink); }
|
||||
.sum-row .k { color:var(--muted); }
|
||||
.sum-row.total .v { color:var(--acid); text-shadow:0 0 6px var(--acid-halo); font-size:13px; }
|
||||
|
||||
.utxo-list { background:var(--surface-1); border:1px solid var(--border); border-radius:14px; overflow:hidden; margin-bottom:12px; }
|
||||
.utxo { display:flex; align-items:center; gap:11px; padding:11px 14px; border-bottom:1px solid var(--border); }
|
||||
.utxo:last-child { border-bottom:0; }
|
||||
.utxo .addr { flex:1; font-family:var(--font-mono); font-size:10px; color:var(--ink-soft); overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
|
||||
.utxo .amt { font-family:var(--font-mono); font-size:11px; color:var(--ink-bright); }
|
||||
.utxo .hd { font-family:var(--font-mono); font-size:8.5px; color:var(--muted); letter-spacing:.1em; text-transform:uppercase; }
|
||||
|
||||
/* Done */
|
||||
.tick { width:54px; height:54px; margin:30px auto 16px; border-radius:50%; display:grid; place-items:center; background:rgba(214,255,61,.10); border:1px solid rgba(214,255,61,.45); color:var(--acid); font-size:30px; text-shadow:0 0 12px var(--acid-halo); }
|
||||
.done-big { font-family:var(--font-display); font-weight:500; font-size:21px; color:var(--ink-bright); text-align:center; }
|
||||
.txid { font-family:var(--font-mono); font-size:10px; color:var(--ink-soft); text-align:center; margin-top:10px; word-break:break-all; padding:9px 12px; background:var(--surface-1); border:1px solid var(--border); border-radius:9px; }
|
||||
|
||||
.view { display:none; }
|
||||
.view.on { display:block; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="stars" aria-hidden="true" id="stars"></div>
|
||||
|
||||
<div class="phone">
|
||||
<div class="flow-head">
|
||||
<button class="back" id="closeBtn">←</button>
|
||||
<div class="flow-title">Sweep wallet</div>
|
||||
<div class="flow-step" id="step">1 / 3 · setup</div>
|
||||
</div>
|
||||
|
||||
<!-- ============= SETUP ============= -->
|
||||
<div class="view on" id="v-setup">
|
||||
<div class="note">
|
||||
Move BCH and tokens from an <b>old wallet</b> into this one. Choose how
|
||||
you'll authorize: a 12 / 24-word seed (scans all addresses) or a single
|
||||
WIF private key. Source keys are wiped after broadcast.
|
||||
</div>
|
||||
|
||||
<div class="mode-tabs">
|
||||
<button class="mt active" data-mode="mnemonic">Mnemonic</button>
|
||||
<button class="mt" data-mode="wif">WIF</button>
|
||||
</div>
|
||||
|
||||
<div class="field" id="f-mnemonic">
|
||||
<div class="label">12 / 24 words</div>
|
||||
<textarea class="ta" placeholder="abandon ability able about above absent absorb abstract absurd abuse access accident…" spellcheck="false">forest myth ladder velvet ocean rare pencil august chimney trial knife guitar</textarea>
|
||||
<div class="note" style="margin: 9px 0 0; font-size:9.5px; color:var(--muted);">12 words detected · BIP-44 gap scan ready</div>
|
||||
</div>
|
||||
|
||||
<div class="field" id="f-wif" style="display:none;">
|
||||
<div class="label">WIF private key</div>
|
||||
<input class="input" placeholder="L1aW4aubDFB7yfras2S1mN3bqg9nwySY8nkoLmJebSLD5BWv3ENZ" spellcheck="false">
|
||||
</div>
|
||||
|
||||
<div class="field">
|
||||
<div class="label">Destination · this wallet</div>
|
||||
<input class="input" value="bchtest:qrd5g7f2k…2ltaxuwh">
|
||||
</div>
|
||||
|
||||
<button class="cta" id="goScan">Start scan →</button>
|
||||
</div>
|
||||
|
||||
<!-- ============= SCANNING ============= -->
|
||||
<div class="view" id="v-scan">
|
||||
<div class="note">Scanning the BIP-44 gap on chipnet — change & receive chains, coin type 145' and 0' for cross-chain sweeps.</div>
|
||||
<div class="progress-card">
|
||||
<div class="pc-ring"></div>
|
||||
<div class="pc-status">Scanning addresses…</div>
|
||||
<div class="pc-sub" id="pcSub">m/44'/145'/0'/0/12 · 4 funded so far</div>
|
||||
</div>
|
||||
<button class="cta disabled">Continue →</button>
|
||||
</div>
|
||||
|
||||
<!-- ============= REVIEW ============= -->
|
||||
<div class="view" id="v-review">
|
||||
<div class="note">Found <b>5 funded addresses</b> across the seed. Review the
|
||||
sweep — keys stay in memory only until broadcast, then are wiped.</div>
|
||||
|
||||
<div class="summary">
|
||||
<div class="sum-row"><span class="k">Found UTXOs</span><span class="v">5 addresses · 11 UTXOs</span></div>
|
||||
<div class="sum-row"><span class="k">Fee estimate</span><span class="v">~ 1,840 sat</span></div>
|
||||
<div class="sum-row"><span class="k">Destination</span><span class="v">bchtest:qrd5g7…uwh</span></div>
|
||||
<div class="sum-row total"><span class="k">Total</span><span class="v">0.0867 BCH → this wallet</span></div>
|
||||
</div>
|
||||
|
||||
<div class="label" style="margin:14px 0 7px;">UTXOs to sweep</div>
|
||||
<div class="utxo-list">
|
||||
<div class="utxo"><span class="hd">0'/0/0</span><span class="addr">bchtest:qpz…h4f</span><span class="amt">0.0500 BCH</span></div>
|
||||
<div class="utxo"><span class="hd">0'/0/3</span><span class="addr">bchtest:qrf…m22</span><span class="amt">0.0180 BCH</span></div>
|
||||
<div class="utxo"><span class="hd">0'/0/7</span><span class="addr">bchtest:qz9…k4f</span><span class="amt">0.0120 BCH</span></div>
|
||||
<div class="utxo"><span class="hd">0'/1/2</span><span class="addr">bchtest:qpn…7l4</span><span class="amt">0.0049 BCH</span></div>
|
||||
<div class="utxo"><span class="hd">0'/0/12</span><span class="addr">bchtest:qm5…3eu</span><span class="amt">0.0020 BCH</span></div>
|
||||
</div>
|
||||
|
||||
<button class="cta" id="goSweep">Broadcast sweep →</button>
|
||||
</div>
|
||||
|
||||
<!-- ============= DONE ============= -->
|
||||
<div class="view" id="v-done">
|
||||
<div class="tick">✓</div>
|
||||
<div class="done-big">Sweep complete</div>
|
||||
<div class="note" style="text-align:center; margin:9px 0 16px; color:var(--ink-soft);">11 UTXOs consolidated into this wallet · source keys wiped from memory.</div>
|
||||
<div class="label" style="text-align:center;">Transaction ID</div>
|
||||
<div class="txid">a3f7e1c8b04d2f9a6e8b1c5d7903e4f7a5b9c2d4e8f0a1b3c5d7e9f0a2b4c6d8</div>
|
||||
<button class="cta" style="margin-top:24px;" id="doneBtn">Back to Main →</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
(function(){var c=document.getElementById('stars');if(!c)return;var n=window.innerWidth<700?100:180;var f=document.createDocumentFragment();for(var i=0;i<n;i++){var s=document.createElement('div');s.className='star';var r=Math.random(),sz,o,d;if(r<.78){sz=1+Math.random()*.4;o=.18+Math.random()*.22;d=14+Math.random()*8;}else if(r<.95){sz=1.4+Math.random()*.6;o=.32+Math.random()*.22;d=10+Math.random()*6;}else{sz=1.8+Math.random()*.8;o=.45+Math.random()*.25;d=8+Math.random()*5;}s.style.width=sz+'px';s.style.height=sz+'px';s.style.left=Math.random()*100+'%';s.style.top=Math.random()*100+'%';s.style.opacity=o;s.style.setProperty('--twinkle-duration',d+'s');s.style.setProperty('--twinkle-delay',(Math.random()*d)+'s');f.appendChild(s);}c.appendChild(f);})();
|
||||
|
||||
// Mode picker
|
||||
document.querySelectorAll('.mt').forEach(function(t){
|
||||
t.addEventListener('click', function(){
|
||||
document.querySelectorAll('.mt').forEach(function(x){x.classList.remove('active');});
|
||||
t.classList.add('active');
|
||||
var m = t.getAttribute('data-mode');
|
||||
document.getElementById('f-mnemonic').style.display = m === 'mnemonic' ? '' : 'none';
|
||||
document.getElementById('f-wif').style.display = m === 'wif' ? '' : 'none';
|
||||
});
|
||||
});
|
||||
|
||||
function show(view, step){
|
||||
document.querySelectorAll('.view').forEach(function(v){v.classList.remove('on');});
|
||||
document.getElementById(view).classList.add('on');
|
||||
document.getElementById('step').textContent = step;
|
||||
}
|
||||
document.getElementById('goScan').addEventListener('click', function(){
|
||||
show('v-scan', '2 / 3 · scanning');
|
||||
// After a couple seconds, transition to review (mockup pacing)
|
||||
setTimeout(function(){ show('v-review', '2 / 3 · review'); }, 1800);
|
||||
});
|
||||
document.getElementById('goSweep').addEventListener('click', function(){
|
||||
show('v-done', '3 / 3 · done');
|
||||
});
|
||||
document.getElementById('doneBtn').addEventListener('click', function(){ location.href='main-tab.html'; });
|
||||
document.getElementById('closeBtn').addEventListener('click', function(){ location.href='main-tab.html'; });
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
111
design/mockups/token-import.html
Normal file
111
design/mockups/token-import.html
Normal file
|
|
@ -0,0 +1,111 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Deviant · Token import · CosmoGenesis mockup</title>
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,300;9..144,400;9..144,500;9..144,600&family=JetBrains+Mono:wght@400;500&display=swap" rel="stylesheet">
|
||||
<link href="../cosmo-genesis.css" rel="stylesheet">
|
||||
<style>
|
||||
body { display:flex; justify-content:center; padding:28px 0; }
|
||||
.phone { position:relative; z-index:1; width:392px; min-height:840px; background: linear-gradient(180deg, rgba(19,26,42,.55), rgba(10,15,28,.55)); border:1px solid var(--border); border-radius:30px; padding:22px 20px 36px; backdrop-filter: blur(2px); }
|
||||
|
||||
/* Mirrors Capacitor's TokenImportModal — paste a token descriptor JSON to
|
||||
register it into the persistent LocalStorageTokenRegistry. After import,
|
||||
the token appears in: Agora list (if held), Swap From/To pickers, Elevation. */
|
||||
.flow-head { display:flex; align-items:center; gap:12px; margin-bottom:18px; }
|
||||
.back { font-size:20px; color:var(--ink-soft); cursor:pointer; background:0; border:0; line-height:1; padding:4px 6px; }
|
||||
.flow-title { font-family:var(--font-display); font-weight:500; font-size:22px; color:var(--ink-bright); }
|
||||
|
||||
.note { font-family:var(--font-mono); font-size:10.5px; color:var(--ink-soft); line-height:1.6; margin-bottom:14px; }
|
||||
.note b { color:var(--ink-bright); }
|
||||
|
||||
.ta-label { font-family:var(--font-mono); font-size:9px; letter-spacing:.22em; text-transform:uppercase; color:var(--muted); margin:14px 0 7px; }
|
||||
.ta { width:100%; box-sizing:border-box; min-height:180px; background:var(--surface-1); border:1px solid var(--border-strong); border-radius:12px; padding:13px; font-family:var(--font-mono); font-size:11px; color:var(--ink-bright); resize:vertical; line-height:1.55; }
|
||||
.ta:focus { outline:none; border-color:rgba(214,255,61,.45); box-shadow:0 0 12px var(--acid-dim); }
|
||||
|
||||
.req-row { display:flex; flex-wrap:wrap; gap:6px; margin: 12px 0 18px; }
|
||||
.req { font-family:var(--font-mono); font-size:9px; letter-spacing:.05em; padding:5px 10px; border-radius:8px; border:1px solid var(--border-strong); color:var(--muted); }
|
||||
.req.ok { color:var(--acid); border-color:rgba(214,255,61,.4); text-shadow:0 0 5px var(--acid-halo); }
|
||||
.req.miss { color:var(--risk-warn); border-color:rgba(255,159,28,.4); }
|
||||
|
||||
.err { font-family:var(--font-mono); font-size:10px; color:var(--risk-warn); padding:9px 12px; border-radius:9px; background:rgba(255,159,28,.07); border:1px solid rgba(255,159,28,.3); margin-bottom:12px; }
|
||||
|
||||
.cta { width:100%; font-family:var(--font-mono); font-size:12px; letter-spacing:.14em; text-transform:uppercase; color:var(--sky-deep); background:var(--acid); border:0; border-radius:12px; padding:15px; cursor:pointer; box-shadow:0 0 16px var(--acid-halo); }
|
||||
.cta.disabled { background:var(--surface-2); color:var(--muted); box-shadow:none; cursor:not-allowed; }
|
||||
|
||||
/* success state */
|
||||
.success { display:none; }
|
||||
.success.on { display:block; }
|
||||
.tick { width:54px; height:54px; margin:34px auto 16px; border-radius:50%; display:grid; place-items:center; background:rgba(214,255,61,.10); border:1px solid rgba(214,255,61,.45); color:var(--acid); font-size:30px; text-shadow:0 0 12px var(--acid-halo); }
|
||||
.rw-big { font-family:var(--font-display); font-weight:500; font-size:21px; color:var(--ink-bright); text-align:center; }
|
||||
.atomic { font-family:var(--font-mono); font-size:11px; color:var(--ink-soft); text-align:center; margin-top:8px; }
|
||||
.rev-note { font-family:var(--font-mono); font-size:10px; color:var(--muted); text-align:center; line-height:1.55; margin-top:16px; }
|
||||
|
||||
.view { display:block; }
|
||||
.view.hidden { display:none; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="stars" aria-hidden="true" id="stars"></div>
|
||||
|
||||
<div class="phone">
|
||||
<div class="flow-head">
|
||||
<button class="back" id="closeBtn">←</button>
|
||||
<div class="flow-title">Import token</div>
|
||||
</div>
|
||||
|
||||
<div class="view" id="v-paste">
|
||||
<div class="note">
|
||||
Paste a <b>token descriptor JSON</b> — the canonical export from Artemision
|
||||
genesis or a sibling wallet. Imports into the persistent token registry;
|
||||
after this the token shows up in Agora, Swap pickers, and Asset details.
|
||||
</div>
|
||||
|
||||
<div class="ta-label">Descriptor</div>
|
||||
<textarea class="ta" id="raw" spellcheck="false">{
|
||||
"categoryId": "9f3d1ab4c52e7860ff20a4d9ec5b7f238a14d6e9c0b5847f33ad1928fe7c4b06",
|
||||
"contractTokenAddress": "bchtest:zr8c…",
|
||||
"rateSats": 10000,
|
||||
"founderFeeBps": 50,
|
||||
"founderLockingBytecodeHex": "76a9143b…88ac",
|
||||
"name": "Nova",
|
||||
"ticker": "NOVA"
|
||||
}</textarea>
|
||||
|
||||
<div class="req-row">
|
||||
<span class="req ok">✓ categoryId · 64 hex</span>
|
||||
<span class="req ok">✓ rateSats</span>
|
||||
<span class="req ok">✓ founderFeeBps</span>
|
||||
<span class="req ok">✓ founderLockingBytecodeHex</span>
|
||||
<span class="req ok">✓ name</span>
|
||||
<span class="req ok">✓ contractTokenAddress</span>
|
||||
</div>
|
||||
|
||||
<button class="cta" id="importBtn">Import →</button>
|
||||
</div>
|
||||
|
||||
<div class="view success" id="v-success">
|
||||
<div class="tick">✓</div>
|
||||
<div class="rw-big">Nova (NOVA)</div>
|
||||
<div class="atomic">9f3d1ab4…7c4b06</div>
|
||||
<div class="rev-note">Rate: 10,000 sat/unit · fee: 0.5%</div>
|
||||
<div class="rev-note" style="margin-top:24px;">Nova is now visible in Agora, Swap pickers, and Asset details.</div>
|
||||
<div style="height:24px;"></div>
|
||||
<button class="cta" id="doneBtn">Done</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
(function(){var c=document.getElementById('stars');if(!c)return;var n=window.innerWidth<700?100:180;var f=document.createDocumentFragment();for(var i=0;i<n;i++){var s=document.createElement('div');s.className='star';var r=Math.random(),sz,o,d;if(r<.78){sz=1+Math.random()*.4;o=.18+Math.random()*.22;d=14+Math.random()*8;}else if(r<.95){sz=1.4+Math.random()*.6;o=.32+Math.random()*.22;d=10+Math.random()*6;}else{sz=1.8+Math.random()*.8;o=.45+Math.random()*.25;d=8+Math.random()*5;}s.style.width=sz+'px';s.style.height=sz+'px';s.style.left=Math.random()*100+'%';s.style.top=Math.random()*100+'%';s.style.opacity=o;s.style.setProperty('--twinkle-duration',d+'s');s.style.setProperty('--twinkle-delay',(Math.random()*d)+'s');f.appendChild(s);}c.appendChild(f);})();
|
||||
document.getElementById('importBtn').addEventListener('click', function(){
|
||||
document.getElementById('v-paste').classList.add('hidden');
|
||||
document.getElementById('v-success').classList.add('on');
|
||||
});
|
||||
document.getElementById('doneBtn').addEventListener('click', function(){ location.href='apps-tab.html'; });
|
||||
document.getElementById('closeBtn').addEventListener('click', function(){ location.href='apps-tab.html'; });
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
68
design/mockups/unlock.html
Normal file
68
design/mockups/unlock.html
Normal file
|
|
@ -0,0 +1,68 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Deviant · Unlock · CosmoGenesis mockup</title>
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,300;9..144,400;9..144,500;9..144,600&family=JetBrains+Mono:wght@400;500&display=swap" rel="stylesheet">
|
||||
<link href="../cosmo-genesis.css" rel="stylesheet">
|
||||
<style>
|
||||
body { display:flex; justify-content:center; padding:28px 0; }
|
||||
.phone { position:relative; z-index:1; width:392px; min-height:840px; background: linear-gradient(180deg, rgba(19,26,42,.55), rgba(10,15,28,.55)); border:1px solid var(--border); border-radius:30px; padding:36px 26px 36px; backdrop-filter: blur(2px); display:flex; flex-direction:column; }
|
||||
|
||||
/* Mirrors Capacitor's Unlock.tsx — wallet exists, just locked. The cached
|
||||
public identity (address) is shown so the user knows what they're unlocking. */
|
||||
.ob-wordmark { font-family: var(--font-display); font-weight:500; font-size:30px; color: var(--ink-bright); text-align:center; }
|
||||
.ob-wordmark .acid-dot { display:inline-block; width:6px; height:6px; margin-left:7px; vertical-align:middle; transform:translateY(-4px); background: var(--acid); border-radius:50%; box-shadow:0 0 8px var(--acid-glow),0 0 18px var(--acid-halo); }
|
||||
.tagline { font-family: var(--font-display); font-style:italic; font-weight:300; font-size:14px; color: var(--ink-soft); text-align:center; margin: 9px 0 28px; }
|
||||
|
||||
.ill { display:grid; place-items:center; width:128px; height:128px; margin: 18px auto 26px; border-radius:50%; background: radial-gradient(circle, rgba(214,255,61,.10), transparent 70%); }
|
||||
.ill span { font-size:54px; filter: drop-shadow(0 0 12px var(--acid-halo)); }
|
||||
|
||||
.addr-label { font-family: var(--font-mono); font-size:9px; letter-spacing:.22em; text-transform:uppercase; color:var(--muted); margin:0 0 6px; }
|
||||
.addr-box { font-family: var(--font-mono); font-size:12px; color:var(--ink); background:var(--surface-1); border:1px solid var(--border); border-radius:12px; padding:13px; text-align:center; word-break:break-all; }
|
||||
|
||||
.input { width:100%; box-sizing:border-box; background:var(--surface-1); border:1px solid var(--border-strong); border-radius:12px; padding:14px; color:var(--ink-bright); font-family:var(--font-mono); font-size:14px; letter-spacing:.4em; text-align:center; margin-top:18px; }
|
||||
.input::placeholder { letter-spacing:.16em; color:var(--muted); }
|
||||
|
||||
.seed-warn { font-family:var(--font-mono); font-size:10px; color:var(--risk-warn); text-align:center; }
|
||||
|
||||
.spacer { flex:1; min-height:24px; }
|
||||
|
||||
.cta { width:100%; font-family:var(--font-mono); font-size:12px; letter-spacing:.14em; text-transform:uppercase; color:var(--sky-deep); background:var(--acid); border:0; border-radius:12px; padding:15px; cursor:pointer; box-shadow:0 0 16px var(--acid-halo); margin-bottom:10px; }
|
||||
.cta.ghost { background:var(--surface-2); color:var(--ink-bright); box-shadow:none; }
|
||||
.ob-ghost { width:100%; font-family:var(--font-mono); font-size:10px; letter-spacing:.16em; text-transform:uppercase; padding:13px; border:0; background:transparent; color:var(--muted); cursor:pointer; }
|
||||
.ob-ghost:hover { color:var(--risk-warn); }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="stars" aria-hidden="true" id="stars"></div>
|
||||
|
||||
<div class="phone">
|
||||
<div class="ob-wordmark">Deviant<span class="acid-dot"></span></div>
|
||||
<div class="tagline">Welcome back — unlock to continue.</div>
|
||||
|
||||
<div class="ill"><span>🔒</span></div>
|
||||
|
||||
<div class="addr-label" style="text-align:center;">chipnet</div>
|
||||
<div class="addr-box" style="text-align:center;">bchtest:qrd5g7f2k…2ltaxuwh</div>
|
||||
|
||||
<input class="input" type="password" inputMode="numeric" placeholder="PIN" value="••••">
|
||||
|
||||
<div class="spacer"></div>
|
||||
|
||||
<!-- Biometric option appears on native platforms; web wallet hides it -->
|
||||
<button class="cta ghost">🔐 Use Face ID / Fingerprint</button>
|
||||
<button class="cta">Unlock with PIN</button>
|
||||
<button class="ob-ghost">Forget wallet (start over)</button>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
(function(){var c=document.getElementById('stars');if(!c)return;var n=window.innerWidth<700?100:180;var f=document.createDocumentFragment();for(var i=0;i<n;i++){var s=document.createElement('div');s.className='star';var r=Math.random(),sz,o,d;if(r<.78){sz=1+Math.random()*.4;o=.18+Math.random()*.22;d=14+Math.random()*8;}else if(r<.95){sz=1.4+Math.random()*.6;o=.32+Math.random()*.22;d=10+Math.random()*6;}else{sz=1.8+Math.random()*.8;o=.45+Math.random()*.25;d=8+Math.random()*5;}s.style.width=sz+'px';s.style.height=sz+'px';s.style.left=Math.random()*100+'%';s.style.top=Math.random()*100+'%';s.style.opacity=o;s.style.setProperty('--twinkle-duration',d+'s');s.style.setProperty('--twinkle-delay',(Math.random()*d)+'s');f.appendChild(s);}c.appendChild(f);})();
|
||||
document.querySelectorAll('.cta').forEach(function(b){b.addEventListener('click',function(){location.href='main-tab.html';});});
|
||||
document.querySelector('.ob-ghost')?.addEventListener('click',function(){location.href='onboarding.html';});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
@ -62,8 +62,8 @@ import {
|
|||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const ARTIFACT = join(ROOT, '.external/anyhedge-artifacts/AnyHedge_v0_12.json');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-anyhedge-hedge-leg-test.json');
|
||||
const ORACLE_KEYS = join(ROOT, '.chipnet-anyhedge-test-oracle.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-anyhedge-hedge-leg-test.json');
|
||||
const ORACLE_KEYS = join(ROOT, 'ChipnetTests', '.chipnet-anyhedge-test-oracle.json');
|
||||
const KEYS_B = join(ROOT, '.chipnet-keys-b.json');
|
||||
const KEYS_C = join(ROOT, '.chipnet-keys-c.json');
|
||||
const KEYS_D = join(ROOT, '.chipnet-keys-d.json');
|
||||
|
|
|
|||
|
|
@ -48,8 +48,8 @@ import {
|
|||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const ARTIFACT = join(ROOT, '.external/anyhedge-artifacts/AnyHedge_v0_12.json');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-anyhedge-liquidation-test.json');
|
||||
const ORACLE_KEYS = join(ROOT, '.chipnet-anyhedge-test-oracle.json'); // reuse Turn 1 oracle
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-anyhedge-liquidation-test.json');
|
||||
const ORACLE_KEYS = join(ROOT, 'ChipnetTests', '.chipnet-anyhedge-test-oracle.json'); // reuse Turn 1 oracle
|
||||
const KEYS_B = join(ROOT, '.chipnet-keys-b.json');
|
||||
const KEYS_C = join(ROOT, '.chipnet-keys-c.json');
|
||||
const KEYS_D = join(ROOT, '.chipnet-keys-d.json');
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-arith-vote-dra-test.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-arith-vote-dra-test.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantBondingCurveFT.json');
|
||||
const KEYS = join(ROOT, '.chipnet-keys-b.json');
|
||||
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ import {
|
|||
} from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const ASM_FILE = join(ROOT, '.chipnet-asm-token.json');
|
||||
const ASM_FILE = join(ROOT, 'ChipnetTests', '.chipnet-asm-token.json');
|
||||
const KEYS_C = join(ROOT, '.chipnet-keys-c.json');
|
||||
|
||||
const BATCH = parseInt(process.env.BATCH ?? '100', 10);
|
||||
|
|
|
|||
|
|
@ -31,8 +31,8 @@ import {
|
|||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
const ASM_FILE = join(ROOT, '.chipnet-asm-token.json');
|
||||
const ASM2_FILE = join(ROOT, '.chipnet-asm2-token.json');
|
||||
const ASM_FILE = join(ROOT, 'ChipnetTests', '.chipnet-asm-token.json');
|
||||
const ASM2_FILE = join(ROOT, 'ChipnetTests', '.chipnet-asm2-token.json');
|
||||
|
||||
const FROM = (process.env.FROM ?? 'a').toLowerCase();
|
||||
const TARGET_SWAPS = parseInt(process.env.TARGET_SWAPS ?? '100', 10);
|
||||
|
|
|
|||
|
|
@ -44,9 +44,9 @@ if (!KEYS[WHICH]) throw new Error(`WALLET must be a/b/c, got ${WHICH}`);
|
|||
if (!KEYS[RECIPIENT_WALLET]) throw new Error(`RECIPIENT must be a/b/c, got ${RECIPIENT_WALLET}`);
|
||||
|
||||
const TOKEN_FILES = {
|
||||
asm: join(ROOT, '.chipnet-asm-token.json'),
|
||||
asm2: join(ROOT, '.chipnet-asm2-token.json'),
|
||||
cap: join(ROOT, '.chipnet-cap-token.json'),
|
||||
asm: join(ROOT, 'ChipnetTests', '.chipnet-asm-token.json'),
|
||||
asm2: join(ROOT, 'ChipnetTests', '.chipnet-asm2-token.json'),
|
||||
cap: join(ROOT, 'ChipnetTests', '.chipnet-cap-token.json'),
|
||||
};
|
||||
if (!TOKEN_FILES[TOKEN]) throw new Error(`TOKEN must be asm|asm2|cap, got ${TOKEN}`);
|
||||
const ASM_FILE = TOKEN_FILES[TOKEN];
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ import { Contract, ElectrumNetworkProvider } from 'cashscript';
|
|||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const KEYS_B = join(ROOT, '.chipnet-keys-b.json');
|
||||
const ASM_FILE = join(ROOT, '.chipnet-asm-token.json');
|
||||
const ASM_FILE = join(ROOT, 'ChipnetTests', '.chipnet-asm-token.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
|
||||
const ASM = {
|
||||
|
|
|
|||
|
|
@ -29,7 +29,7 @@ import {
|
|||
} from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const ASM_FILE = join(ROOT, '.chipnet-asm-token.json');
|
||||
const ASM_FILE = join(ROOT, 'ChipnetTests', '.chipnet-asm-token.json');
|
||||
|
||||
const FROM = (process.env.FROM ?? 'a').toLowerCase();
|
||||
const TO = (process.env.TO ?? 'b').toLowerCase();
|
||||
|
|
|
|||
|
|
@ -62,8 +62,8 @@ const KEYS = {
|
|||
if (!KEYS[FROM]) throw new Error(`FROM must be a or c`);
|
||||
|
||||
const TOKEN_FILES = {
|
||||
asm: join(ROOT, '.chipnet-asm-token.json'),
|
||||
asm2: join(ROOT, '.chipnet-asm2-token.json'),
|
||||
asm: join(ROOT, 'ChipnetTests', '.chipnet-asm-token.json'),
|
||||
asm2: join(ROOT, 'ChipnetTests', '.chipnet-asm2-token.json'),
|
||||
};
|
||||
if (!TOKEN_FILES[SOURCE] || !TOKEN_FILES[TARGET]) {
|
||||
throw new Error('SOURCE/TARGET must be asm or asm2');
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ import { Contract, ElectrumNetworkProvider } from 'cashscript';
|
|||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const KEYS_B = join(ROOT, '.chipnet-keys-b.json');
|
||||
const ASM2_FILE = join(ROOT, '.chipnet-asm2-token.json');
|
||||
const ASM2_FILE = join(ROOT, 'ChipnetTests', '.chipnet-asm2-token.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
|
||||
const ASM2 = {
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ import {
|
|||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const KEYS_B = join(ROOT, '.chipnet-keys-b.json');
|
||||
const VULNERABLE_TOKENS_FILE = join(ROOT, '.chipnet-vulnerable-tokens.json');
|
||||
const VULNERABLE_TOKENS_FILE = join(ROOT, 'ChipnetTests', '.chipnet-vulnerable-tokens.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantOpenMintFT_NoPeg.json');
|
||||
|
||||
function hexToBin(hex) {
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ import {
|
|||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const KEYS_B = join(ROOT, '.chipnet-keys-b.json');
|
||||
const TOKENS_FILE = join(ROOT, '.chipnet-tokens.json');
|
||||
const TOKENS_FILE = join(ROOT, 'ChipnetTests', '.chipnet-tokens.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
|
||||
function hexToBin(hex) {
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ import {
|
|||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const KEYS_B = join(ROOT, '.chipnet-keys-b.json');
|
||||
const TOKENS_FILE = join(ROOT, '.chipnet-tokens.json');
|
||||
const TOKENS_FILE = join(ROOT, 'ChipnetTests', '.chipnet-tokens.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
|
||||
const CLAIM_AMOUNT = 1n; // tiny legitimate claim, just enough to exercise the path
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ import {
|
|||
} from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-bonding-swap-test.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-bonding-swap-test.json');
|
||||
const CANONICAL_ARTIFACT = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
const ESCALATING_ARTIFACT = join(ROOT, 'contracts/dist/DeviantOpenMintFT_Escalating.json');
|
||||
const KEYS_C = join(ROOT, '.chipnet-keys-c.json');
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ import { Contract, ElectrumNetworkProvider } from 'cashscript';
|
|||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const KEYS_B = join(ROOT, '.chipnet-keys-b.json');
|
||||
const CAP_FILE = join(ROOT, '.chipnet-cap-token.json');
|
||||
const CAP_FILE = join(ROOT, 'ChipnetTests', '.chipnet-cap-token.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
|
||||
const CAP = {
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-che-perside-test.json');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-che-perside-test.json');
|
||||
const MBA_ARTIFACT = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
const FLAT_ARTIFACT = join(ROOT, 'contracts/dist/GamePoolEscrowFlat.json');
|
||||
const KEYS = { a: join(ROOT, '.chipnet-keys.json'), b: join(ROOT, '.chipnet-keys-b.json'), c: join(ROOT, '.chipnet-keys-c.json') };
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-che-escrow-test.json');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-che-escrow-test.json');
|
||||
const MBA_ARTIFACT = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
const FLAT_ARTIFACT = join(ROOT, 'contracts/dist/GamePoolEscrowFlat.json');
|
||||
const KEYS = { a: join(ROOT, '.chipnet-keys.json'), b: join(ROOT, '.chipnet-keys-b.json'), c: join(ROOT, '.chipnet-keys-c.json') };
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplat
|
|||
import { secp256k1 } from '@bitauth/libauth';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-clob-amm-test.json');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-clob-amm-test.json');
|
||||
const ARTIFACT = join(ROOT, 'contracts/dist/SharePairAMM.json');
|
||||
const KEYS = { b: join(ROOT, '.chipnet-keys-b.json'), c: join(ROOT, '.chipnet-keys-c.json') };
|
||||
const SUPPLY = 100000n;
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplat
|
|||
import { secp256k1, sha256 } from '@bitauth/libauth';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-clob-bch-test.json');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-clob-bch-test.json');
|
||||
const ARTIFACT = join(ROOT, 'contracts/dist/BinaryShareVaultBCH.json');
|
||||
const KEYS = { b: join(ROOT, '.chipnet-keys-b.json'), c: join(ROOT, '.chipnet-keys-c.json') };
|
||||
const SEED = 1000n; // structural vault-NFT dust (stranded — the one accepted wart)
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplat
|
|||
import { secp256k1, sha256 } from '@bitauth/libauth';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-clob-fungible-test.json');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-clob-fungible-test.json');
|
||||
const ARTIFACT = join(ROOT, 'contracts/dist/BinaryShareFungibleBCH.json');
|
||||
const KEYS = { b: join(ROOT, '.chipnet-keys-b.json'), c: join(ROOT, '.chipnet-keys-c.json') };
|
||||
const RESERVE = 1_000_000n;
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplat
|
|||
import { secp256k1, sha256 } from '@bitauth/libauth';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-clob-mba-test.json');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-clob-mba-test.json');
|
||||
const MBA_ARTIFACT = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
const ARTIFACT = join(ROOT, 'contracts/dist/BinaryShareVaultMBA.json');
|
||||
const KEYS = { b: join(ROOT, '.chipnet-keys-b.json'), c: join(ROOT, '.chipnet-keys-c.json') };
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplat
|
|||
import { secp256k1 } from '@bitauth/libauth';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-clob-orders-test.json');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-clob-orders-test.json');
|
||||
const ARTIFACT = join(ROOT, 'contracts/dist/ShareLimitOrderBCH.json');
|
||||
const KEYS = { b: join(ROOT, '.chipnet-keys-b.json'), c: join(ROOT, '.chipnet-keys-c.json') };
|
||||
const SUPPLY = 100000n;
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ import { Contract, ElectrumNetworkProvider } from 'cashscript';
|
|||
import { DESC_FEE_SUPPLY_BYTECODE_HASH } from '../src/verify/canonical.js';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-divisible-metals.json'); // shared with GLDd/SLVd
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-divisible-metals.json'); // shared with GLDd/SLVd
|
||||
const TOKENS_DIR = join(ROOT, '.deviant', 'tokens');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantDescFeeSupply.json');
|
||||
const KEYS = join(ROOT, '.chipnet-keys-c.json');
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ import { Contract, ElectrumNetworkProvider } from 'cashscript';
|
|||
import { DESC_FEE_SUPPLY_BYTECODE_HASH } from '../src/verify/canonical.js';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-divisible-metals.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-divisible-metals.json');
|
||||
const TOKENS_DIR = join(ROOT, '.deviant', 'tokens');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantDescFeeSupply.json');
|
||||
const KEYS = join(ROOT, '.chipnet-keys-c.json'); // Wallet C — founder
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-metal-mbas.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-metal-mbas.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantDescFeeSupply.json');
|
||||
const KEYS = join(ROOT, '.chipnet-keys-c.json'); // Wallet C — least BCH (founder)
|
||||
|
||||
|
|
|
|||
|
|
@ -14,8 +14,8 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-dea-large-proof.json');
|
||||
const MARKET = JSON.parse(readFileSync(join(ROOT, '.chipnet-dea-market-100swaps.json'), 'utf8'));
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-dea-large-proof.json');
|
||||
const MARKET = JSON.parse(readFileSync(join(ROOT, 'ChipnetTests', '.chipnet-dea-market-100swaps.json'), 'utf8'));
|
||||
const OMINT = JSON.parse(readFileSync(join(ROOT, 'contracts/dist/DeviantOpenMintFT.json'), 'utf8'));
|
||||
const POSITION_VALUE = 1000n;
|
||||
const A = { DEA: { rate: 1000n, fee: 5n, cat: MARKET.cats.DEA }, GLD: { rate: 10000n, fee: 500n, cat: MARKET.cats.GLD } };
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplat
|
|||
import { secp256k1, sha256 as laSha256 } from '@bitauth/libauth';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-dea-market-100swaps.json');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-dea-market-100swaps.json');
|
||||
const OMINT = JSON.parse(readFileSync(join(ROOT, 'contracts/dist/DeviantOpenMintFT.json'), 'utf8'));
|
||||
const OMBA = JSON.parse(readFileSync(join(ROOT, 'contracts/dist/DeviantOracleMBA.json'), 'utf8'));
|
||||
const TARGET = Number((process.argv.find((a) => a.startsWith('--target=')) || '--target=110').split('=')[1]);
|
||||
|
|
@ -43,8 +43,8 @@ async function main() {
|
|||
const E = await TestNetWallet.fromWIF(JSON.parse(readFileSync(join(ROOT, '.chipnet-keys-e.json'), 'utf8')).wif);
|
||||
const W = { B, C, D }; const SIG = { B: new SignatureTemplate(B.privateKey), C: new SignatureTemplate(C.privateKey), D: new SignatureTemplate(D.privateKey) };
|
||||
const oraclePk = E.publicKey, founderLB = p2pkh(E.publicKeyHash);
|
||||
const usdm = JSON.parse(readFileSync(join(ROOT, '.chipnet-usdm-roundtrip-test.json'), 'utf8'));
|
||||
const eurm = JSON.parse(readFileSync(join(ROOT, '.chipnet-eurm-crossasset-test.json'), 'utf8'));
|
||||
const usdm = JSON.parse(readFileSync(join(ROOT, 'ChipnetTests', '.chipnet-usdm-roundtrip-test.json'), 'utf8'));
|
||||
const eurm = JSON.parse(readFileSync(join(ROOT, 'ChipnetTests', '.chipnet-eurm-crossasset-test.json'), 'utf8'));
|
||||
const st = existsSync(STATE) ? JSON.parse(readFileSync(STATE, 'utf8')) : { cats: {}, ops: [], counts: { claim: 0, redeem: 0, cross: 0, send: 0 } };
|
||||
const save = () => writeFileSync(STATE, JSON.stringify(st, null, 2));
|
||||
|
||||
|
|
|
|||
|
|
@ -29,7 +29,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-denomination-fee-test.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-denomination-fee-test.json');
|
||||
const CANONICAL_ARTIFACT = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
const KEYS_C = join(ROOT, '.chipnet-keys-c.json');
|
||||
const KEYS_B = join(ROOT, '.chipnet-keys-b.json');
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-descfee-supply-test.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-descfee-supply-test.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantDescFeeSupply.json');
|
||||
const KEYS = join(ROOT, '.chipnet-keys-d.json'); // Wallet D
|
||||
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplat
|
|||
import { secp256k1, sha256 as laSha256 } from '@bitauth/libauth';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-distribution-payout.json');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-distribution-payout.json');
|
||||
const ARTIFACT = join(ROOT, 'contracts/dist/DistributionVault.json');
|
||||
|
||||
const POOL = 31000n;
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-dual-ladder-test.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-dual-ladder-test.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/EscalatingDualLadderNFT.json');
|
||||
const VOTER_KEYS = join(ROOT, '.chipnet-keys.json'); // A (most BCH)
|
||||
const TREASURY_KEYS = join(ROOT, '.chipnet-keys-c.json'); // C
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplat
|
|||
import { secp256k1 } from '@bitauth/libauth';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-endorsement-test.json');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-endorsement-test.json');
|
||||
const CIT_ART = join(ROOT, 'contracts/dist/CitizenToken.json');
|
||||
const END_ART = join(ROOT, 'contracts/dist/EndorsementCovenant.json');
|
||||
const KEYS = {
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ import {
|
|||
} from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-escalating-50pc-test.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-escalating-50pc-test.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantOpenMintFT_Escalating.json');
|
||||
const KEYS_C = join(ROOT, '.chipnet-keys-c.json');
|
||||
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-escalating-dual-test.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-escalating-dual-test.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/EscalatingDualNFT.json');
|
||||
const BUYER_KEYS = join(ROOT, '.chipnet-keys-b.json');
|
||||
const FOUNDER_KEYS = join(ROOT, '.chipnet-keys-c.json');
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-escalating-nft-test.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-escalating-nft-test.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/EscalatingPriceNFT.json');
|
||||
const BUYER_KEYS = join(ROOT, '.chipnet-keys-b.json'); // funds genesis + buys
|
||||
const FOUNDER_KEYS = join(ROOT, '.chipnet-keys-c.json'); // escalating payment sink
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ import {
|
|||
} from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-escalating-source-swap-test.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-escalating-source-swap-test.json');
|
||||
const CANONICAL_ARTIFACT = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
const ESCALATING_ARTIFACT = join(ROOT, 'contracts/dist/DeviantOpenMintFT_Escalating.json');
|
||||
const KEYS_C = join(ROOT, '.chipnet-keys-c.json');
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@ import { verifyContractCanonical } from '../src/verify/contract.ts';
|
|||
import { verifyUtxoBacking } from '../src/verify/backing.ts';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-escalating-test.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-escalating-test.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantOpenMintFT_Escalating.json');
|
||||
const KEYS_C = join(ROOT, '.chipnet-keys-c.json');
|
||||
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-escfee-blockheight-test.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-escfee-blockheight-test.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantEscFeeBlockHeightV2.json');
|
||||
const KEYS = join(ROOT, '.chipnet-keys.json'); // Wallet A
|
||||
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-escfee-supply-test.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-escfee-supply-test.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantEscFeeSupply.json');
|
||||
const KEYS = join(ROOT, '.chipnet-keys.json'); // Wallet A
|
||||
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-escfee-txcount-test.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-escfee-txcount-test.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantEscFeeTxCount.json');
|
||||
const KEYS = join(ROOT, '.chipnet-keys-b.json'); // Wallet B
|
||||
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-escrow-fee-irregular-test.json');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-escrow-fee-irregular-test.json');
|
||||
const MBA_ARTIFACT = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
const ESCROW_ARTIFACT = join(ROOT, 'contracts/dist/GamePoolEscrow.json');
|
||||
const KEYS = { a: join(ROOT, '.chipnet-keys.json'), b: join(ROOT, '.chipnet-keys-b.json'), c: join(ROOT, '.chipnet-keys-c.json') };
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-escrow-fee-test.json');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-escrow-fee-test.json');
|
||||
const MBA_ARTIFACT = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
const ESCROW_ARTIFACT = join(ROOT, 'contracts/dist/GamePoolEscrow.json');
|
||||
const KEYS = { a: join(ROOT, '.chipnet-keys.json'), b: join(ROOT, '.chipnet-keys-b.json'), c: join(ROOT, '.chipnet-keys-c.json') };
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-escrow-flat-test.json');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-escrow-flat-test.json');
|
||||
const MBA_ARTIFACT = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
const FLAT_ARTIFACT = join(ROOT, 'contracts/dist/GamePoolEscrowFlat.json');
|
||||
const KEYS = { a: join(ROOT, '.chipnet-keys.json'), b: join(ROOT, '.chipnet-keys-b.json'), c: join(ROOT, '.chipnet-keys-c.json') };
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-escrow-test.json');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-escrow-test.json');
|
||||
const MBA_ARTIFACT = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
const ESCROW_ARTIFACT = join(ROOT, 'contracts/dist/GamePoolEscrow.json');
|
||||
const KEYS = { a: join(ROOT, '.chipnet-keys.json'), b: join(ROOT, '.chipnet-keys-b.json'), c: join(ROOT, '.chipnet-keys-c.json') };
|
||||
|
|
|
|||
|
|
@ -18,8 +18,8 @@ import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplat
|
|||
import { secp256k1, sha256 as laSha256 } from '@bitauth/libauth';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-eurm-crossasset-test.json');
|
||||
const USDM_STATE = join(ROOT, '.chipnet-usdm-roundtrip-test.json');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-eurm-crossasset-test.json');
|
||||
const USDM_STATE = join(ROOT, 'ChipnetTests', '.chipnet-usdm-roundtrip-test.json');
|
||||
const ARTIFACT = join(ROOT, 'contracts/dist/DeviantOracleMBA.json');
|
||||
|
||||
const DECIMALS = 2n, POSITION_VALUE = 1000n, SUPPLY = 1000000n;
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-exp-dra-batch-test.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-exp-dra-batch-test.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantExpDRA.json');
|
||||
const KEYS = join(ROOT, '.chipnet-keys-b.json');
|
||||
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-exp-dra-test.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-exp-dra-test.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantExpDRA.json');
|
||||
const KEYS = join(ROOT, '.chipnet-keys-b.json');
|
||||
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ import { TestNetWallet } from 'mainnet-js';
|
|||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-exp-dra-x10-test.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-exp-dra-x10-test.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantExpDRA.json');
|
||||
const KEYS = join(ROOT, '.chipnet-keys-b.json');
|
||||
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplat
|
|||
import { secp256k1 } from '@bitauth/libauth';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-expiring-mba-test.json');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-expiring-mba-test.json');
|
||||
const ARTIFACT = join(ROOT, 'contracts/dist/ExpiringMBA.json');
|
||||
const KEYS = { b: join(ROOT, '.chipnet-keys-b.json'), c: join(ROOT, '.chipnet-keys-c.json') };
|
||||
const SUPPLY = 100000n;
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ import {
|
|||
} from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE_FILE = join(ROOT, '.chipnet-mut-state.json');
|
||||
const STATE_FILE = join(ROOT, 'ChipnetTests', '.chipnet-mut-state.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
const KEYS_C = join(ROOT, '.chipnet-keys-c.json');
|
||||
const TARGET_LABEL = process.env.LABEL ?? 'mba-1pc';
|
||||
|
|
|
|||
222
scripts/chipnet-fiatm-hyperinflation-test.mjs
Normal file
222
scripts/chipnet-fiatm-hyperinflation-test.mjs
Normal file
|
|
@ -0,0 +1,222 @@
|
|||
#!/usr/bin/env node
|
||||
/**
|
||||
* chipnet-fiatm-hyperinflation-test.mjs — extend the FIATm family on chipnet
|
||||
* with ARSm + TRYm (hyperinflating-fiat instances) using the same
|
||||
* `DeviantOracleMBA` template that already hosts USDm / EURm / GBPm / JPYm / INRm.
|
||||
*
|
||||
* What this proves on chain:
|
||||
* • The FIATm template generalises to currencies the design record's §7b
|
||||
* calls out as "the population it matters to" (people whose state currency
|
||||
* is failing fastest). No contract change, no fork — same artifact, different
|
||||
* constructor params + oracle price.
|
||||
* • Forward mint (oracle-priced) + backward redeem (P2PKH, oracle-free) both
|
||||
* work across the new currencies, exactly as for the existing family members.
|
||||
*
|
||||
* Founder/oracle = E. Funder/claimer = B. State file:
|
||||
* `ChipnetTests/.chipnet-fiatm-hyperinflation-test.json` (resumable).
|
||||
*
|
||||
* Denomination note (honest about the dust-floor edge): at current Jun 2026
|
||||
* BCH/ARS spot (~750k ARS per BCH, peso at ~1,300/USD), 1 ARS = ~133 sats —
|
||||
* BELOW the 546-sat CashTokens dust limit. The contract can't represent a
|
||||
* sub-dust atomic unit. Two real-world strategies:
|
||||
* (a) larger face-units per atomic (e.g. 1 atomic = 100 ARS),
|
||||
* (b) different oracle epoch (e.g. mint at the equivalent of an earlier-era
|
||||
* rate where 1 ARS > dust, then ride the controller).
|
||||
* For this chipnet demonstration we use (b): chipnet-plausible oracle prices
|
||||
* where 1 face-unit is comfortably above dust. The dust-floor strategy for
|
||||
* deep-collapse currencies is a separate design discussion (flagged §0.5
|
||||
* caveat extension).
|
||||
*
|
||||
* ARSm: oracle 1 ARS = 1,000 sats (≈ BCH=$500, ARS=200/USD) · 0 dp · fee 25 bps
|
||||
* TRYm: oracle 1 TRY = 10,000 sats (≈ BCH=$500, TRY=20/USD) · 2 dp · fee 10 bps
|
||||
*
|
||||
* Run (plan): node --import tsx scripts/chipnet-fiatm-hyperinflation-test.mjs
|
||||
* Run (yes): node --import tsx scripts/chipnet-fiatm-hyperinflation-test.mjs --yes
|
||||
*/
|
||||
import { existsSync, readFileSync, writeFileSync } from 'node:fs';
|
||||
import { join } from 'node:path';
|
||||
import { TestNetWallet } from 'mainnet-js';
|
||||
import { Contract, ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
import { secp256k1, sha256 as laSha256 } from '@bitauth/libauth';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-fiatm-hyperinflation-test.json');
|
||||
const ARTIFACT = join(ROOT, 'contracts/dist/DeviantOracleMBA.json');
|
||||
|
||||
const POSITION_VALUE = 1000n;
|
||||
const SUPPLY = 1_000_000n;
|
||||
const MINER_FEE = 3000n;
|
||||
|
||||
const CURRENCIES = [
|
||||
{
|
||||
code: 'ARS', name: 'Argentine Peso',
|
||||
decimals: 0n,
|
||||
atomicSats: 1_000n, // 1 ARS = 1,000 sats; comfortably above 546-sat dust
|
||||
feeBps: 25n, // 0.25%
|
||||
claimAtoms: 500n, // 500 ARS face
|
||||
},
|
||||
{
|
||||
code: 'TRY', name: 'Turkish Lira',
|
||||
decimals: 2n,
|
||||
atomicSats: 100n, // 1 atomic = 0.01 TRY = 100 sats; well above dust
|
||||
feeBps: 10n, // 0.10%
|
||||
claimAtoms: 500n, // 5.00 TRY face
|
||||
},
|
||||
];
|
||||
|
||||
const hexToBin = (h) => { const o = new Uint8Array(h.length / 2); for (let i = 0; i < o.length; i++) o[i] = parseInt(h.slice(i * 2, i * 2 + 2), 16); return o; };
|
||||
const txidToConsensusBytes = (h) => { const d = hexToBin(h); const o = new Uint8Array(d.length); for (let i = 0; i < d.length; i++) o[i] = d[d.length - 1 - i]; return o; };
|
||||
const p2pkh = (pkh) => { const o = new Uint8Array(25); o[0] = 0x76; o[1] = 0xa9; o[2] = 0x14; o.set(pkh, 3); o[23] = 0x88; o[24] = 0xac; return o; };
|
||||
const sleep = (ms) => new Promise((r) => setTimeout(r, ms));
|
||||
const u32le = (n) => { const b = new Uint8Array(4); new DataView(b.buffer).setUint32(0, Number(n), true); return b; };
|
||||
const omsg = (price) => { const m = new Uint8Array(16); m.set(u32le(1), 0); m.set(u32le(1), 4); m.set(u32le(1), 8); m.set(u32le(price), 12); return m; };
|
||||
const osign = (priv, m) => { const s = secp256k1.signMessageHashSchnorr(priv, laSha256.hash(m)); if (typeof s === 'string') throw new Error(s); return s; };
|
||||
const pickCash = (cash, need) => {
|
||||
const p = []; let t = 0n;
|
||||
for (const u of cash) { p.push(u); t += BigInt(u.satoshis); if (t >= need) break; }
|
||||
if (t < need) throw new Error(`insufficient ${t}<${need}`);
|
||||
return { p, t };
|
||||
};
|
||||
async function eligible(w, provider) {
|
||||
let u = await provider.getUtxos(w.cashaddr);
|
||||
let e = u.filter((x) => x.vout === 0 && !x.token);
|
||||
if (e.length) return e[0];
|
||||
const bad = u.filter((x) => !(x.vout === 0 && !x.token));
|
||||
const r = await w.send([{ cashaddr: w.cashaddr, value: 5000n, unit: 'sat' }], bad.length ? { utxoIds: bad } : undefined);
|
||||
console.log(` splitter ${r?.txId ?? r?.txid}`);
|
||||
await sleep(12_000);
|
||||
u = await provider.getUtxos(w.cashaddr);
|
||||
e = u.filter((x) => x.vout === 0 && !x.token);
|
||||
if (!e.length) throw new Error('no eligible');
|
||||
return e[0];
|
||||
}
|
||||
|
||||
async function main() {
|
||||
if (!process.argv.includes('--yes')) {
|
||||
console.log('Plan-only mode. Re-run with --yes to broadcast.');
|
||||
console.log('Will genesis + first-claim:');
|
||||
for (const cur of CURRENCIES) {
|
||||
const face = Number(cur.claimAtoms) / 10 ** Number(cur.decimals);
|
||||
const grossSats = Number(cur.claimAtoms) * Number(cur.atomicSats);
|
||||
const feeSats = Math.floor(grossSats * Number(cur.feeBps) / 10000);
|
||||
console.log(` ${cur.code}m (${cur.name}) · 1 atomic = ${cur.atomicSats} sats · ${cur.decimals} dp · ${cur.feeBps} bps fee`);
|
||||
console.log(` → claim ${face.toFixed(Number(cur.decimals))} ${cur.code} face value to B: ${grossSats} sats backing + ${feeSats} sats fee`);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
const artifact = JSON.parse(readFileSync(ARTIFACT, 'utf8'));
|
||||
const provider = new ElectrumNetworkProvider('chipnet');
|
||||
const B = await TestNetWallet.fromWIF(JSON.parse(readFileSync(join(ROOT, '.chipnet-keys-b.json'), 'utf8')).wif);
|
||||
const E = await TestNetWallet.fromWIF(JSON.parse(readFileSync(join(ROOT, '.chipnet-keys-e.json'), 'utf8')).wif);
|
||||
const sigB = new SignatureTemplate(B.privateKey);
|
||||
const oraclePk = E.publicKey, founderLB = p2pkh(E.publicKeyHash);
|
||||
|
||||
const st = existsSync(STATE) ? JSON.parse(readFileSync(STATE, 'utf8')) : { currencies: {} };
|
||||
if (!st.currencies) st.currencies = {};
|
||||
const save = () => writeFileSync(STATE, JSON.stringify(st, null, 2));
|
||||
|
||||
const reservoir = async (c, cat) => {
|
||||
const ru = await provider.getUtxos(c.tokenAddress);
|
||||
const p = ru.find((u) => u.token && u.token.category === cat && !u.token.nft && u.token.amount > 0n);
|
||||
if (!p) throw new Error('reservoir ' + cat.slice(0, 8));
|
||||
return p;
|
||||
};
|
||||
const cashOf = async (w) =>
|
||||
(await provider.getUtxos(w.cashaddr)).filter((u) => !u.token).sort((a, b) => Number(BigInt(b.satoshis) - BigInt(a.satoshis)));
|
||||
|
||||
async function claim(contract, cat, feeBps, atomicSats, atoms, to, funder, funderSig) {
|
||||
const pos = await reservoir(contract, cat);
|
||||
const gross = atoms * atomicSats, fee = (gross * feeBps) / 10_000n;
|
||||
const msg = omsg(atomicSats), sig = osign(E.privateKey, msg);
|
||||
const need = gross + fee + MINER_FEE + 1000n;
|
||||
const cash = await cashOf(funder); const { p, t } = pickCash(cash, need);
|
||||
const change = BigInt(pos.satoshis) + t - POSITION_VALUE - gross - fee - MINER_FEE;
|
||||
const tb = new TransactionBuilder({ provider, allowImplicitFungibleTokenBurn: true });
|
||||
tb.addInput(pos, contract.unlock.claim(atoms, p2pkh(to.publicKeyHash), sig, msg));
|
||||
for (const u of p) tb.addInput(u, funderSig.unlockP2PKH());
|
||||
tb.addOutput({ to: contract.tokenAddress, amount: POSITION_VALUE, token: { amount: BigInt(pos.token.amount) - atoms, category: cat } });
|
||||
tb.addOutput({ to: to.tokenaddr, amount: gross, token: { amount: atoms, category: cat } });
|
||||
if (fee >= 546n) tb.addOutput({ to: E.cashaddr, amount: fee });
|
||||
if (change >= 546n) tb.addOutput({ to: funder.cashaddr, amount: change });
|
||||
const sent = await tb.send();
|
||||
return { txid: typeof sent === 'string' ? sent : (sent?.txid ?? sent?.txId), gross: gross.toString(), fee: fee.toString() };
|
||||
}
|
||||
|
||||
console.log(`${'═'.repeat(72)}`);
|
||||
console.log(`FIATm hyperinflation extension — ARSm + TRYm on chipnet`);
|
||||
console.log(`${'═'.repeat(72)}\n`);
|
||||
console.log(`Founder/oracle = E (${E.cashaddr.slice(0, 32)}…)`);
|
||||
console.log(`Holder/claimer = B (${B.cashaddr.slice(0, 32)}…)\n`);
|
||||
|
||||
for (const cur of CURRENCIES) {
|
||||
console.log(`──── ${cur.code}m (${cur.name}) ────────────────────────────────`);
|
||||
const key = cur.code;
|
||||
let rec = st.currencies[key] ?? {};
|
||||
st.currencies[key] = rec;
|
||||
|
||||
// 1. Genesis
|
||||
if (!rec.category) {
|
||||
const utxo = await eligible(B, provider);
|
||||
const cat = utxo.txid;
|
||||
const ctor = [txidToConsensusBytes(cat), oraclePk, cur.feeBps, founderLB];
|
||||
const ct = new Contract(artifact, ctor, { provider });
|
||||
const r = await B.tokenGenesis(
|
||||
{ cashaddr: ct.tokenAddress, amount: SUPPLY, value: POSITION_VALUE },
|
||||
[],
|
||||
{ utxoIds: [utxo] },
|
||||
);
|
||||
const genTxid = r?.txId ?? r?.txid;
|
||||
console.log(` contract: ${ct.tokenAddress}`);
|
||||
console.log(` genesis: ${genTxid}`);
|
||||
console.log(` category: ${cat}`);
|
||||
rec.category = cat;
|
||||
rec.contractAddress = ct.tokenAddress;
|
||||
rec.genesisTxid = genTxid;
|
||||
rec.atomicSats = cur.atomicSats.toString();
|
||||
rec.decimals = Number(cur.decimals);
|
||||
rec.feeBps = Number(cur.feeBps);
|
||||
rec.name = cur.name;
|
||||
save();
|
||||
await sleep(10_000);
|
||||
} else {
|
||||
console.log(` resumed category ${rec.category.slice(0, 16)}…`);
|
||||
}
|
||||
|
||||
const contract = new Contract(artifact, [txidToConsensusBytes(rec.category), oraclePk, cur.feeBps, founderLB], { provider });
|
||||
|
||||
// 2. Claim
|
||||
if (!rec.claimTxid) {
|
||||
const r = await claim(contract, rec.category, cur.feeBps, cur.atomicSats, cur.claimAtoms, B, B, sigB);
|
||||
const human = (Number(cur.claimAtoms) / 10 ** Number(cur.decimals)).toFixed(Number(cur.decimals));
|
||||
console.log(` claim: ${human} ${cur.code}m → B · ${r.gross} sats backing · ${r.fee} sats fee`);
|
||||
console.log(` claim tx: ${r.txid}`);
|
||||
rec.claimTxid = r.txid;
|
||||
rec.claimAtoms = cur.claimAtoms.toString();
|
||||
rec.claimGrossSats = r.gross;
|
||||
rec.claimFeeSats = r.fee;
|
||||
save();
|
||||
await sleep(8_000);
|
||||
} else {
|
||||
console.log(` resumed claim ${rec.claimTxid.slice(0, 16)}…`);
|
||||
}
|
||||
console.log('');
|
||||
}
|
||||
|
||||
console.log(`${'═'.repeat(72)}`);
|
||||
console.log(`Summary — ${Object.keys(st.currencies).length} new FIATm currencies live on chipnet`);
|
||||
console.log(`${'═'.repeat(72)}\n`);
|
||||
for (const cur of CURRENCIES) {
|
||||
const rec = st.currencies[cur.code];
|
||||
if (!rec) continue;
|
||||
const face = Number(rec.claimAtoms) / 10 ** Number(rec.decimals);
|
||||
console.log(` ${cur.code}m category ${rec.category.slice(0, 16)}…`);
|
||||
console.log(` genesis ${rec.genesisTxid}`);
|
||||
console.log(` claim ${rec.claimTxid} (B holds ${face.toFixed(Number(rec.decimals))} ${cur.code} · backing ${rec.claimGrossSats} sats)`);
|
||||
}
|
||||
console.log(`\n State written to ${STATE}`);
|
||||
console.log(` Combined with snapshots 0136 (USDm), 0137 (EURm), 0144 (GBPm+JPYm+INRm), the FIATm family`);
|
||||
console.log(` now has 7 chipnet-validated currencies on one DeviantOracleMBA template.`);
|
||||
}
|
||||
|
||||
main().catch((e) => { console.error('FATAL:', e.message); console.error(e.stack); process.exit(1); });
|
||||
183
scripts/chipnet-fiatm-multi-redeem.mjs
Normal file
183
scripts/chipnet-fiatm-multi-redeem.mjs
Normal file
|
|
@ -0,0 +1,183 @@
|
|||
#!/usr/bin/env node
|
||||
/**
|
||||
* chipnet-fiatm-multi-redeem.mjs
|
||||
*
|
||||
* LIVE chipnet demonstration of the FIATm-family magical-redemption property,
|
||||
* exercised across multiple currencies in one atomic transaction.
|
||||
*
|
||||
* What this proves on chain (in one TXID):
|
||||
* • §4 mechanism — "burn the unit, recover the exact locked BCH — no oracle,
|
||||
* no intermediary, no permission" — at the family level (GBPm + JPYm + INRm
|
||||
* redeemed in the same tx).
|
||||
* • §0.5 property 2 (base-layer backed) — the BCH was always inside each
|
||||
* voucher UTXO; the tx is a plain P2PKH spend of B's own UTXOs.
|
||||
* • §0.5 property 5 (no liquidation trigger) — the recovery is exact regardless
|
||||
* of any current BCH/USD price; no oracle interaction needed.
|
||||
* • §16 oracle-failure-is-benign — the tx contains ZERO oracle signatures. If
|
||||
* the oracle were dead at this moment, this tx would still succeed.
|
||||
*
|
||||
* The reuse of one signing path across three different FIATm categories is the
|
||||
* "interchangeable infrastructure" claim from §7a literalized in CashTokens
|
||||
* consensus: each category is just a different mark on the same metal.
|
||||
*
|
||||
* Run (plan only): node --import tsx scripts/chipnet-fiatm-multi-redeem.mjs
|
||||
* Run (broadcast): node --import tsx scripts/chipnet-fiatm-multi-redeem.mjs --yes
|
||||
*
|
||||
* Wallet B (.chipnet-keys-b.json) holds the FIATm vouchers minted in snapshot 0144.
|
||||
* State file: .chipnet-multicurrency-mba-test.json (read-only here).
|
||||
*/
|
||||
import { readFileSync, writeFileSync, existsSync } from 'node:fs';
|
||||
import { join } from 'node:path';
|
||||
import { TestNetWallet } from 'mainnet-js';
|
||||
import { ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from 'cashscript';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-multicurrency-mba-test.json');
|
||||
const PROOF = join(ROOT, 'ChipnetTests', '.chipnet-fiatm-multi-redeem-proof.json');
|
||||
const KEYS = join(ROOT, '.chipnet-keys-b.json');
|
||||
|
||||
const MINER_FEE_SATS = 1500n; // 3 inputs, 1 output — comfortable margin.
|
||||
|
||||
const fmtSats = (s) => {
|
||||
const a = BigInt(s);
|
||||
const g = a.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ',');
|
||||
return `${g} sats (${(Number(a) / 1e8).toFixed(8)} BCH)`;
|
||||
};
|
||||
|
||||
async function main() {
|
||||
if (!existsSync(STATE)) throw new Error(`Missing ${STATE} — run chipnet-multicurrency-mba-test.mjs first.`);
|
||||
if (!existsSync(KEYS)) throw new Error(`Missing ${KEYS}.`);
|
||||
const yes = process.argv.includes('--yes');
|
||||
|
||||
const state = JSON.parse(readFileSync(STATE, 'utf8'));
|
||||
const currencies = state.currencies; // { GBP: {...}, JPY: {...}, INR: {...} }
|
||||
const targetCategories = new Map(); // category(hex) -> { code, name, atomicSats, decimals, claimAtoms }
|
||||
for (const [code, c] of Object.entries(currencies)) {
|
||||
targetCategories.set(c.category, {
|
||||
code, name: c.name, atomicSats: BigInt(c.atomicSats), decimals: c.decimals,
|
||||
claimAtoms: BigInt(c.claimAtoms),
|
||||
});
|
||||
}
|
||||
|
||||
const { wif } = JSON.parse(readFileSync(KEYS, 'utf8'));
|
||||
const B = await TestNetWallet.fromWIF(wif);
|
||||
const provider = new ElectrumNetworkProvider('chipnet');
|
||||
const sigB = new SignatureTemplate(B.privateKey);
|
||||
|
||||
// FIATm vouchers live at B's token-aware address.
|
||||
const utxos = await provider.getUtxos(B.tokenaddr);
|
||||
|
||||
// Select every FIATm voucher of a target category (FT only, not NFT).
|
||||
const vouchers = utxos.filter(
|
||||
(u) => u.token && !u.token.nft && targetCategories.has(u.token.category) && u.token.amount > 0n,
|
||||
);
|
||||
|
||||
if (vouchers.length === 0) {
|
||||
console.log(`No FIATm vouchers (GBPm/JPYm/INRm) found at ${B.tokenaddr}.`);
|
||||
console.log(`(Already redeemed in a prior run? Inspect ${B.tokenaddr} to confirm.)`);
|
||||
return;
|
||||
}
|
||||
|
||||
// Per-currency rollup for display + audit.
|
||||
let totalSatsIn = 0n;
|
||||
const byCurrency = new Map(); // code -> { atoms, sats, utxos }
|
||||
for (const v of vouchers) {
|
||||
const meta = targetCategories.get(v.token.category);
|
||||
const e = byCurrency.get(meta.code) ?? { meta, atoms: 0n, sats: 0n, utxos: 0 };
|
||||
e.atoms += BigInt(v.token.amount);
|
||||
e.sats += BigInt(v.satoshis);
|
||||
e.utxos += 1;
|
||||
byCurrency.set(meta.code, e);
|
||||
totalSatsIn += BigInt(v.satoshis);
|
||||
}
|
||||
|
||||
const netSats = totalSatsIn - MINER_FEE_SATS;
|
||||
|
||||
console.log(`\n${'='.repeat(72)}`);
|
||||
console.log(`FIATm multi-redemption demo — magical redemption at the family level`);
|
||||
console.log(`${'='.repeat(72)}\n`);
|
||||
console.log(`Holder: B (${B.cashaddr})`);
|
||||
console.log(`Spending FT UTXOs from: ${B.tokenaddr}\n`);
|
||||
for (const [, e] of byCurrency) {
|
||||
const peg = e.atoms * e.meta.atomicSats; // mint-time backing per voucher metadata
|
||||
const tag = e.sats === peg ? 'exact peg' : (e.sats > peg ? 'over-pegged' : '⚠ under-pegged');
|
||||
const human = e.meta.decimals > 0
|
||||
? `${Number(e.atoms) / 10 ** Number(e.meta.decimals)} ${e.meta.code}`
|
||||
: `${e.atoms} ${e.meta.code}`;
|
||||
console.log(
|
||||
` [${e.meta.code}m] ${human} ` +
|
||||
`(${e.atoms} atomic · ${e.meta.atomicSats} sats/atomic · ${e.utxos} UTXO${e.utxos > 1 ? 's' : ''}) ` +
|
||||
`→ ${fmtSats(e.sats)} ${tag}`,
|
||||
);
|
||||
}
|
||||
console.log(`\n Total BCH freed (gross): ${fmtSats(totalSatsIn)}`);
|
||||
console.log(` Miner fee: ${fmtSats(MINER_FEE_SATS)}`);
|
||||
console.log(` Net to B.cashaddr: ${fmtSats(netSats)}`);
|
||||
console.log(` Oracle signatures in tx: 0 ← the magical-redemption property`);
|
||||
|
||||
if (!yes) {
|
||||
console.log(`\n(preview only — re-run with --yes to broadcast)\n`);
|
||||
return;
|
||||
}
|
||||
|
||||
// Build the atomic multi-FIATm burn.
|
||||
const tb = new TransactionBuilder({ provider, allowImplicitFungibleTokenBurn: true });
|
||||
for (const v of vouchers) tb.addInput(v, sigB.unlockP2PKH());
|
||||
tb.addOutput({ to: B.cashaddr, amount: netSats });
|
||||
|
||||
console.log(`\nBroadcasting…`);
|
||||
const sent = await tb.send();
|
||||
const txid = typeof sent === 'string' ? sent : (sent?.txid ?? sent?.txId);
|
||||
if (!txid) throw new Error(`Could not extract txid from send() result: ${JSON.stringify(sent)}`);
|
||||
console.log(`✓ FIATm multi-redeem TXID: ${txid}`);
|
||||
|
||||
// Confirm on chain.
|
||||
const raw = await provider.getRawTransaction(txid);
|
||||
console.log(`✓ On-chain confirmation: getRawTransaction returned ${raw.length / 2} bytes for ${txid}`);
|
||||
|
||||
// Persist proof.
|
||||
const proof = {
|
||||
capturedAt: new Date().toISOString(),
|
||||
network: 'chipnet',
|
||||
txid,
|
||||
rawTxBytes: raw.length / 2,
|
||||
holder: B.cashaddr,
|
||||
spending: {
|
||||
vouchersBurned: vouchers.length,
|
||||
categoriesBurned: byCurrency.size,
|
||||
perCurrency: Object.fromEntries(
|
||||
[...byCurrency.entries()].map(([code, e]) => [code, {
|
||||
atoms: e.atoms.toString(),
|
||||
sats: e.sats.toString(),
|
||||
utxos: e.utxos,
|
||||
atomicSats: e.meta.atomicSats.toString(),
|
||||
}]),
|
||||
),
|
||||
totalSatsIn: totalSatsIn.toString(),
|
||||
},
|
||||
receiving: {
|
||||
to: B.cashaddr,
|
||||
netSats: netSats.toString(),
|
||||
minerFeeSats: MINER_FEE_SATS.toString(),
|
||||
},
|
||||
oracleSignaturesUsed: 0,
|
||||
proves: [
|
||||
'§4 mechanism — burn the unit, recover the exact locked BCH',
|
||||
'§0.5 property 2 — base-layer backed (BCH was always in the voucher UTXO)',
|
||||
'§0.5 property 5 — no liquidation trigger (recovery is exact regardless of current price)',
|
||||
'§16 — oracle failure is benign (zero oracle interaction in this tx)',
|
||||
'§7a — interchangeable infrastructure (3 FIATm categories burned in one atomic motion)',
|
||||
],
|
||||
};
|
||||
writeFileSync(PROOF, JSON.stringify(proof, null, 2));
|
||||
console.log(`✓ Proof saved: ${PROOF}`);
|
||||
console.log(`\n${'='.repeat(72)}`);
|
||||
console.log(`FIATm magical redemption proven on chipnet — txid above.`);
|
||||
console.log(`${'='.repeat(72)}\n`);
|
||||
}
|
||||
|
||||
main().catch((err) => {
|
||||
console.error('FAILED:', err?.message ?? err);
|
||||
if (err?.stack) console.error(err.stack);
|
||||
process.exit(1);
|
||||
});
|
||||
|
|
@ -27,7 +27,7 @@ import { ElectrumNetworkProvider, TransactionBuilder, SignatureTemplate } from '
|
|||
import { secp256k1, sha256, decodeTransaction, hexToBin, binToHex } from '@bitauth/libauth';
|
||||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const STATE = join(ROOT, '.chipnet-game-oracle.json');
|
||||
const STATE = join(ROOT, 'ChipnetTests', '.chipnet-game-oracle.json');
|
||||
const KEY = join(ROOT, '.chipnet-keys.json');
|
||||
const TAG = 'DEVGAME-RESULT';
|
||||
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ import { Contract, ElectrumNetworkProvider } from 'cashscript';
|
|||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const KEYS_A = join(ROOT, '.chipnet-keys.json');
|
||||
const VULNERABLE_TOKENS_FILE = join(ROOT, '.chipnet-vulnerable-tokens.json');
|
||||
const VULNERABLE_TOKENS_FILE = join(ROOT, 'ChipnetTests', '.chipnet-vulnerable-tokens.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantOpenMintFT_NoPeg.json');
|
||||
|
||||
const RESERVOIR_FT_SUPPLY = 1_000_000_000_000_000_000n;
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@ import { Contract, ElectrumNetworkProvider } from 'cashscript';
|
|||
|
||||
const ROOT = join(import.meta.dirname, '..');
|
||||
const KEYS_FILE = join(ROOT, '.chipnet-keys.json');
|
||||
const TOKENS_FILE = join(ROOT, '.chipnet-tokens.json');
|
||||
const TOKENS_FILE = join(ROOT, 'ChipnetTests', '.chipnet-tokens.json');
|
||||
const ARTIFACT_PATH = join(ROOT, 'contracts/dist/DeviantOpenMintFT.json');
|
||||
|
||||
// Reservoir model: genesis allocates the entire FT supply to a single
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Reference in a new issue