The piano that thinks in numbers. Drop a guitar chord sheet — or a tab, or an mp3 — and see it on a piano: lit keys, voice leading, Nashville numbers and Roman numerals, a capo advisor, playback with a band, and a set of rooms for learning, practicing, performing, and writing.
Keylit is built for a guitarist who thinks in chord shapes and numbers and is crossing over to piano and theory. It reads plain-text charts (Ultimate-Guitar paste, ChordPro, chords-over-lyrics) and ASCII tablature with tuning/capo intelligence, spells everything correctly for the key, and keeps all the music logic in a pure, unit-tested library (1,051 tests at last count).
npm install
npm run dev # http://localhost:5173
npm run build # production build (installable PWA) to dist/
npm test # the full suiteNode 18+ recommended. The production build is a PWA: install it from the browser and the app, fonts, and piano samples work offline after first load.
The top bar groups twelve-plus rooms into four wings:
Play
- Library — your shelves: a public-domain songbook, anything you add, and a song-of-the-day. Backup/restore carries songs, setlists, practice history, and preferences in one file, and imports never overwrite what's already yours.
- Song — the chart, chords lit on the keyboard, live transpose, tuning and capo controls. Change the guitar tuning and tablature re-frets itself the way chord sheets always transposed — with an honesty badge for anything that had to move or drop, and it never writes a chord a hand can't hold.
- Perform — the stage: an always-dark scrolling chart (Roll) or a chord-by-chord walk with the playhead on the exact token (Walk). Setlists run as a paged set, and each page can re-tune, re-capo, or transpose mid-set.
- Piano — the big readout, arranger styles (ballad, waltz, boom-chick, broken, After Hours with a walking bass and swing ride), an optional falling-note lane so your hands can pre-shape the next chord, and multi-track MIDI export.
Study
- Theory — the circle of fifths as a fixed dial with a traveling home wedge, harmonic-function colors, a tension curve over the progression, and a guided walkthrough.
- Learn — the theory tutor: scale workshop, degree drill, ear trainer, meter feel, pedal-point lab.
- Chordbook — a chord bible with zero stored diagrams: every grip derived live for the tuning in your hands, and the selected grip lights its exact notes on the piano.
Make
- One Song — the writing habit, made visible: a daily line from Jeff Tweedy's How to Write One Song, tally marks for days you showed up, a timer that drops you onto a blank page, six exercises for getting unstuck, and a shelf of every song you finished.
- Write — the desk: section-based sketching, a progression composer, word tools, hum-a-melody-into-chords, a pocket recorder, and MIDI export.
- Practice — drills, play-along (MIDI keyboard or mouse — Keylit waits for your hands and scores each section), the Session (a band that loops and listens without ever grading), the metronome, and the Mirror (a fingerprint of your own writing, with the moves you never make). A right rail keeps your practice history and a cold shelf of songs going stale.
- Setlists — tonight's bench: ordered, annotated, printable, runnable on the Perform stage.
- Voice — sing into a pitch trace, find your comfortable range, and get a measured verdict on what key a song wants to be in for your voice.
Shed — a file shelf for PDFs, books, and reference material.
Everywhere: number-row hotkeys switch rooms (? shows the map), five color themes, reduced-motion support, and a piano you can play from the computer keyboard.
Drop an mp3/wav and Keylit writes the chart: FFT chromagram → chord-template matching → a confidence timeline with tap-to-correct. Fully client-side — audio never leaves your machine. That's a product promise, not a setting.
"Analyze with Claude" and the Chord Lab's Deep mode call a small proxy that keeps your Anthropic key server-side (api/analyze.js, or node server.mjs locally). Without it the app degrades gracefully — the offline theory engine covers everything else. There's also a bring-your-own-key tutor panel (Anthropic / OpenAI / Google / xAI / local Ollama); keys stay in your browser.
ANTHROPIC_API_KEY=sk-ant-... npm run proxy # http://localhost:8787/api/analyze
echo "VITE_AI_PROXY_URL=http://localhost:8787/api/analyze" > .envEnv vars: KEYLIT_MODEL (model id), KEYLIT_ALLOW_ORIGIN (comma-separated CORS allowlist; defaults cover localhost dev), KEYLIT_PROXY_PORT. The proxy rate-limits per IP and caps request size; every chord a model returns is re-parsed by Keylit's own parser before it can be applied, so a hallucinated symbol is dropped, never played.
npm run dist:win # NSIS installer in release/The Electron shell serves the built app over a custom app:// protocol, so Web MIDI and offline use behave like Chrome. The installer is unsigned — SmartScreen will warn on first run (More info → Run anyway).
No telemetry. No accounts. Charts, sketches, setlists, practice history, and preferences live in your browser's storage; audio is decoded and analyzed locally; nothing is sent anywhere unless you press an AI button, and then only the chart text you're working on.
keylit/
├── api/analyze.js # serverless AI proxy (the key lives here, not in the browser)
├── server.mjs # local dev server for the proxy
├── electron/ # desktop shell (app:// protocol, context-isolated preload)
├── public/ # fonts, icons, public-domain songbook
└── src/
├── App.jsx # root state + room layout
├── audio/ # Tone.js engine, metronome singleton, voice memos
├── components/ # the rooms and instruments (React)
├── ui/ # theme registry + the material layer (CSS)
└── lib/ # ALL music logic — pure (no React/audio/DOM/network), unit-tested
The lib/ rule is the project's spine: parsing, voicing, key detection, numbering, re-fretting, and every other musical decision is a pure function with tests. A wrong chord is treated as worse than a missing feature.
Three self-hosted voices: Gloock (display), Onest (UI), Martian Mono (every chord and number). Berkeley Mono is the licensed mono fallback — it's a commercial font you supply yourself in public/fonts/ (gitignored); without it the app falls back to a system monospace.
- Piano samples: Salamander Grand Piano via the Tone.js sample host (CC-BY).
- The One Song and Write rooms are built around the method in Jeff Tweedy's How to Write One Song (Dutton, 2020) — quoted only verbatim and attributed.
- Theory approach informed by tonal.js; tension curve after Lerdahl & Krumhansl (2007), simplified and labeled as such.