Skip to content

Commit 4847bcf

Browse files
orlandowclaude
andcommitted
Add site README
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent 5510163 commit 4847bcf

1 file changed

Lines changed: 60 additions & 0 deletions

File tree

site/README.md

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
# tx-benchmark site
2+
3+
Static site built with [Astro](https://astro.build) + Svelte. Publishes benchmark results as a browsable report.
4+
5+
## Development
6+
7+
```bash
8+
bun install # first time only
9+
bun run dev # dev server → http://localhost:4100
10+
bun run build # production build → dist/
11+
bun run preview # preview the production build locally
12+
```
13+
14+
## Adding a run
15+
16+
1. **Run the benchmark** (from repo root):
17+
```bash
18+
bun scripts/run.ts <server> <base-url> <run-id>
19+
```
20+
21+
2. **Export to the site** (from repo root):
22+
```bash
23+
bun scripts/export-run.ts --run <run-id> --date YYYY-MM-DD
24+
```
25+
Writes `src/data/<run-id>.json` and updates `src/data/runs.json`.
26+
27+
3. **(Optional) Add an errors CSV** — export from Grafana and place at:
28+
```
29+
src/data/<run-id>.errors.csv
30+
```
31+
The Breakdown page will show a Logs widget with a download link automatically.
32+
33+
4. **Commit and push**:
34+
```bash
35+
git add src/data/<run-id>.json src/data/runs.json
36+
git add src/data/<run-id>.errors.csv # if present
37+
git commit -m "Add run <run-id>"
38+
git push
39+
```
40+
GitHub Actions builds and deploys to GitHub Pages on push to `master`.
41+
42+
## Data files
43+
44+
`src/data/*.json` are gitignored by default so local dev runs don't pollute the repo. Add them explicitly with `git add -f` or list them in `.gitignore` exceptions when publishing official results.
45+
46+
## Structure
47+
48+
```
49+
src/
50+
content/tests/ markdown descriptions for each test (FS01, LK01, …)
51+
data/ per-run JSON + optional errors CSV
52+
layouts/ Run, Doc, Base layouts
53+
components/ Widget, Matrix, TestBadge, MD, …
54+
pages/
55+
index.astro home / leaderboard
56+
results/[run]/ per-run pages (overview, details, tests, servers)
57+
tests.mdx test catalogue
58+
scoring.mdx scoring methodology
59+
servers.mdx server descriptions
60+
```

0 commit comments

Comments
 (0)