# Graze documentation

> Play Graze, choose courses, use lessons, recall gates, the Feed and spaced review, move progress between devices, and run or release your own build.

Project page: https://dbaney.com/projects/graze/

## Play

Open [Graze](https://baney75.github.io/graze/play/) in a modern browser. It is installable and works offline after the first visit.

## Choose what you learn

Open the Library and pick courses in the order you want. Your first course is your focus; the rest mix in. You set how many new items you get a day, from 5 to 30.

| Area | Courses |
| --- | --- |
| Languages | Spanish, French, German, Italian, Portuguese (Brazil), Polish, Latin, Greek (Koine and Classical), Japanese, Mandarin |
| Sciences and medicine | Biology, general and organic chemistry, functional groups with structures and pKa, physics, engineering, anatomy and physiology, medical terminology, medicine |
| Math | Calculus and generated mental math |
| Mind | Logic and critical thinking, philosophy, psychology, the arguments for God |
| Reading | The Bible, the Great Books, the Ancients, advanced vocabulary |
| World and skills | World geography with maps and flags, world history, the big ideas of *Sapiens*, grammar and style, research skills, strategy, martial arts, software engineering |

## Learn, recall, review

- **Lessons** introduce eight new items at a time with examples, pictures and audio, then a quick check.
- **Recall gates** appear during the arcade run: a short recall-first pause, then two choices under light time pressure.
- **Recall it first.** Feed cards hide their choices until you have tried to answer from memory. Functional groups also come back in reverse: you see a name and pick the structure.
- **The Feed** (press F) is a vertical stream of due reviews, new items, speaking cards, quick math and readings.
- **Spaced review** moves each item through 10 minutes, then 1, 3, 7, 16, 35, 90 and 180 days.
- **Speech** reads every language item aloud and checks pronunciation where the browser supports speech recognition (Chrome, Edge and Safari).

## Keep your progress

Progress is saved in the browser on your device. Transfer codes and backup files move it to another device and merge rather than overwrite.

## Run it locally

Requires Node 18 or newer.

```sh
npm test       # builds dist/ and runs content and version checks
npm run serve  # builds, then serves dist/ at http://localhost:8080
```

`dist/play/` is the game and `dist/index.html` is the project site.

## Release an update

1. Change `src/` (or `site/` for the project page).
2. Add an entry at the top of `changelog.json` with a higher version, a date and notes. That version is stamped into the game, service worker and site.
3. Run `npm test`, commit and push to `main`. The Pages workflow builds, checks and deploys.

Players see an Update button within about half an hour. Save data carries a schema version; a change to its shape needs a migration in `src/core.js`.

## Content sources

Courses are original wording checked against free sources, listed in each course's `meta.json`: OpenStax and LibreTexts textbooks, COERLL language courses, the Dickinson College Commentaries, Perseus, MedlinePlus, the Stanford and Internet Encyclopedias of Philosophy, and Project Gutenberg. Report a mistake by opening an issue. `node scripts/check-course.mjs <key>` validates a course.
