Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
95 changes: 56 additions & 39 deletions web/fossils/README.md
Original file line number Diff line number Diff line change
@@ -1,58 +1,75 @@
# The Fossil Record — Attestation Archaeology Visualizer

**Bounty #2311 · 75 RTC**
**Bounty #2311 · 75 RTC · Wallet: `C4c7r9WPsnEe6CUfegMU9M7ReHD1pWg8qeSfTBoRcLbg`**

Interactive D3.js visualization of RustChain attestation history, rendered as geological strata.

---

## Features

- **Stacked Area Chart** — architecture layers ordered by age (68K deepest, x86 on top)
- **Streamgraph Mode** — centered flow view for temporal dynamics
- **Normalized Mode** — percentage-based to see market share shifts
- **Interactive Tooltips** — hover any layer for miner count, epoch, RTC earned, share %
- **Architecture Color Coding** — 11 families from amber (68K) to pale grey (x86)
- **Epoch Settlement Markers** — vertical dashed lines every 25 epochs
- **First Appearance Markers** — shows when each architecture joined the network
- **Responsive** — works on desktop and mobile
- **No Backend Required** — static HTML + D3.js, deployable at `rustchain.org/fossils`
### Visualization Modes
- **Stacked Area** — architecture layers ordered by age (68K deepest, x86 on top)
- **Streamgraph** — centered flow view for temporal architecture dynamics
- **Normalized %** — percentage-based to see market share shifts over time
- **Stratigraphy** — geological stratum view where band width = active miner count

## Architecture Color Map
### Interactivity
- **Architecture Filter** — click legend items or use checkboxes to show/hide architecture families
- **Zoom In/Out/Reset** — control the visible epoch range
- **Hover Tooltips** — see architecture, epoch, miner count, share %, total RTC, era
- **Individual Miner Details** — click to see simulated miner ID, device name, fingerprint quality, RTC earned
- **Epoch Info Bar** — persistent bottom bar shows current epoch stats

| Architecture | Color | Depth |
### Architecture Color Map
| Architecture | Color | Era |
|---|---|---|
| 68K | Dark Amber | Deepest |
| G3 | Warm Gold | |
| G4 (PowerPC) | Copper | |
| G5 (PowerPC) | Bronze | |
| SPARC | Crimson | |
| MIPS | Jade | |
| POWER8 | Deep Blue | |
| ARM | Saddle Brown | |
| Apple Silicon | Silver | |
| Modern x86 | Pale Grey | |
| Virtual Machine | Dark Grey | Surface |
| 68K | Dark Amber | Genesis |
| G3 | Warm Gold | Genesis |
| G4 (PowerPC) | Copper | Genesis |
| G5 (PowerPC) | Bronze | Expansion |
| SPARC | Crimson | Expansion |
| MIPS | Jade | Consolidation |
| POWER8 | Deep Blue | Consolidation |
| ARM | Saddle Brown | Modern |
| Apple Silicon | Silver | Modern |
| Modern x86 | Pale Grey | Modern |
| Virtual Machine | Dark Grey | Modern |

## Deployment
### Data Layers
- **Epoch Settlement Markers** — vertical dashed lines every 25 epochs
- **First Appearance Markers** — shows when each architecture first joined the network
- **Era Labels** — Genesis / Expansion / Consolidation / Modern periods

Copy `index.html` to `rustchain.org/fossils/`:
## Tech
- D3.js v7 (CDN)
- Vanilla JS, no framework
- CSS custom properties for theming
- Responsive design (desktop + mobile)
- **No backend required** — static HTML, deployable at `rustchain.org/fossils`

```bash
cp web/fossils/index.html /var/www/rustchain/fossils/index.html
```
## Production Integration

No build step, no dependencies beyond D3.js (loaded from CDN).
The demo uses generated data that simulates the RustChain attestation database. To connect to live data:

## Production Integration
```javascript
// Replace generateData() with:
async function loadData() {
const res = await fetch('/api/attestations/history?group_by=arch&bucket=epoch');
const raw = await res.json();
// Transform to: [{epoch, 68k, g4, g5, sparc, mips, power8, arm, apple_silicon, x86, vm, totalRTC, miners:{}}]
return raw;
}
```

The demo uses generated data. To connect to live RustChain data:
Expected API format: `GET /api/attestations/history?group_by=arch&bucket=epoch`

1. Replace `generateData()` with a fetch to the attestation API
2. API endpoint: `GET /api/attestations/history?group_by=arch&bucket=epoch`
3. Expected format: `[{epoch, 68k, g4, g5, sparc, mips, power8, arm, apple_silicon, x86, vm, totalRTC}]`
## Deployment

## Tech Stack
```bash
cp web/fossils/index.html /var/www/rustchain/fossils/index.html
# No build step required — pure HTML + D3.js CDN
```

- D3.js v7 (CDN)
- Vanilla JS, no framework
- CSS custom properties for theming
- Vintage terminal aesthetic matching rustchain.org
## Wallet
`C4c7r9WPsnEe6CUfegMU9M7ReHD1pWg8qeSfTBoRcLbg`
Loading
Loading