Skip to content
kapi-labPublic

About

No description, website, or topics provided.

Resources

Stars

3 stars

Watchers

1 watching

Forks

Repository files navigation

QuizMe

English | 简体中文

npm version npm downloads node license GitHub

QuizMe is a local-first CLI MVP that turns Claude Code session context, repository context, or a topic you type in into short interview-style multiple-choice questions.

How it works

 Claude Code transcript   repository context   a topic you type
 (~/.claude/projects)        (--repo .)            ("React ...")
            │                     │                     │
            └──────────┬──────────┴──────────┬──────────┘
                       ▼                     ▼
                 Sources ──────────► SourceSummary
                       │
                       ▼
          Generation · prompts + schema + validator + dedupe
                       │  builds a prompt carrying the context
                       ▼
            ClaudeAgent ─► `claude` CLI  (print mode: --safe-mode --tools "")
                       │  returns structured JSON questions
                       ▼
            Storage (quizme.json, atomic temp+rename)
                       │  stats · profile · pending review queue
                       ▼
            Ink TUI  ──►  answer  ──►  `why` mode (deep explanation
                                          on a wrong answer, via claude)

QuizMe does not call the Anthropic API directly. It shells out to your local claude CLI in print mode, so it uses whatever model and account your Claude Code is signed in with.

Documentation

Installation

npm install -g @kapi-lab/quizme

You can also run it directly with npx without a global install:

npx @kapi-lab/quizme

Prerequisites

Question generation and why mode invoke the local Claude Code CLI (the claude command). Make sure it is installed and on your PATH:

claude --version   # should print a version number

If not installed, run npm install -g @anthropic-ai/claude-code, or see the Claude Code docs.

Usage

quizme
quizme --repo .
quizme "React rendering and caching"

Configuration

Interactive settings (persisted)

On first run you'll be guided to choose a language and level; from the in-app Settings page you can adjust the following, all written to local config:

Option Description Values
Language Language of questions and explanations 中文 / English
Level Target difficulty Junior / Mid / Senior / Staff+
Daily goal Number of questions per day 1–9
Sound Answer sound effects On / Off
Question model Alias passed to claude --model for generation Haiku (default, fast) / Sonnet / Opus / account default
Question Effort Level passed to claude --effort for generation Low (default) / Medium / High / xHigh / Max

Default Haiku + Low: question generation is essentially structured JSON output, so Haiku/low is sufficient and noticeably faster and cheaper. Bump it up in Settings when you need higher quality.

The Settings page also has two actions: Export debug file writes a self-contained HTML dump (all local JSON plus every claude prompt/output of the current session) into the directory you launched from, and Clear settings & cache resets local config, stats, profile, review queue, and the prefetch cache.

Environment variables

Variable Purpose
QUIZME_CLAUDE_BIN Absolute path to the claude executable (use when PATH lookup fails)
QUIZME_DATA_DIR Override the local data directory; defaults to the platform app-data dir, falling back to ./.quizme in restricted environments
QUIZME_CLAUDE_WHY_MODEL Model alias used by why mode (deep explanation after a wrong answer); falls back to the account default
QUIZME_CLAUDE_WHY_EFFORT Effort level for why mode (low/medium/high/xhigh/max); falls back to the default

why mode is deliberately configured separately from question generation: explanations are more sensitive to model quality, so it keeps the account model by default; set these variables only when you want to globally downgrade or speed it up.

Notes

  • Default mode reads the most recent Claude Code transcript for the current repo from ~/.claude/projects. Stats, archive, settings, and review features are accessible from the interactive main menu.
  • Local data is a single quizme.json file in the platform app-data directory, written atomically (temp file + rename). The batch you are currently answering lives in memory, but the next batch is pre-generated in the background and its cache is persisted, so an unplayed batch survives restarts and only a cold start ever hits the loading screen.
  • Question generation and why mode invoke the local claude CLI in print mode (--safe-mode + --tools "", agent tools disabled; context is written into the prompt).

License

MIT

About

No description, website, or topics provided.

Resources

Stars

3 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages