free open source, MIT
      ▄    ▄▀▀
█▀▀▀ ▀█▀▀ ▀█▀▀ █▀▄▀█
█     █    █   █ ▀ █
▀     ▀▀▀  ▀   ▀   ▀

A coding tutor that lives in your terminal.

rtfm explains the next step, why it works, and exactly where the docs cover it. You write the code, and actually learn the thing.

$npm i -g rtfm-cli
macOS · Linux · Windowsany model, your key
~/projects/search-app — rtfm
how do I debounce the search input in src/SearchBox.tsx?
+ Thought: reading SearchBox.tsx · 1.8s
% WebFetch developer.mozilla.org/en-US/docs/Web/API/setTimeout

Right now every keystroke in handleChange fires a request. You want to wait until typing pauses. Three steps:

  1. Keep the latest text in state separately from the text you search for, so typing stays instant. React: useState
  2. Start a timer in an effect that runs when the text changes. When it fires, copy the text into the search value, and run the search off that. setTimeout(func, delay) with around 300ms feels natural. MDN: setTimeout
  3. Clear the old timer by returning a cleanup that calls clearTimeout, so only the last keystroke's timer survives.

Watch out: if the search runs in the effect without that cleanup, you'll still get one request per keystroke, just delayed.

I wrote it. can you review?
+ Thought: reading the diff · 1.2s
% git diff src/SearchBox.tsx

Nice, the state split is exactly right. Two things worth a second look:

  1. bugsrc/SearchBox.tsx:18: the effect's dependency list is empty, so the timer only starts once, on mount. It needs to re-run when the text changes. React: dependencies
  2. edgesrc/SearchBox.tsx:24: an empty query still sends a request after the delay. Decide what should happen when the box is cleared.

The fix is yours. Cmd+click a path to jump there.

Mentor · Claude Sonnet Anthropic
tab modectrl+p commands
// how it works

Like a patient senior engineer at the next desk.

AI that writes code for you is great when you just need something built. rtfm is for when you want to learn: a new language or framework, a course project, or a codebase you want to understand.

→

The next step, not the whole road

One to three things you can do in the next ten minutes, explained clearly enough to write yourself. Come back for the next ones.

↗

Always the source

Every API comes with a link to the right section of the official docs, or the Stack Overflow answer you needed, so you learn where to look next time.

?

Hints that meet you where you are

Stuck? Say so. Each hint gets more specific: the concept, then the API, then exactly what the line needs to do.

⇥

Review mode

Press tab. It reads your git diff and points to the lines worth a second look, and why. The fix stays yours.

◱

Reads, never edits

It can read your project and search the web, but it has no tools to change your files. Your code is your code.

⌘

Works in your editor

Run it in the terminal of VS Code or any editor you like, and cmd+click a file:line to jump straight there.

// get started

Up and running in a minute.

01

Install

$ npm i -g rtfm-cli

Or brew install varunbln/tap/rtfm

02

Open your project

$ cd my-app && rtfm

A short walkthrough explains the two modes.

03

Connect a model

› /connect

Claude, GPT, Gemini, DeepSeek, OpenRouter, or a local model via Ollama.

Learn it by writing it.

Free, open source, and yours to run with any model.

$npm i -g rtfm-cli