1. Connect your agent to REA
Use a coding agent such as Claude Code, Codex or Cursor. You’ll need Node.js and npm; the setup guide lists supported versions.
Install REA and connect it to this coding agent using npx rea-agents@latest setup. Show me the setup plan for approval, then verify the installation.
Or run this command in your terminal:
npx rea-agents@latest setup
Review the plan, approve the setup, then restart your agent. Already connected? Continue below.
2. Ask where the CSV is written
The example is a six-file Electron app with an Export notes button. Your agent can inspect its code without installing or launching Electron.
Download https://rea.tools/examples/notes-example.zip into a new example folder and unpack it. Use REA to find what happens when I click Export notes. Show where notes.csv is written, which fields it contains, and the relevant files and lines.
Your agent downloads the files and gives the unpacked folder to REA for inspection.
If your agent can’t download files, unzip this archive yourself.
Give it the path to the notes-example folder and the
same export question.
3. Follow the answer back to the code
Look for a short explanation with file and line references:
The button sends a
notes:exportmessage. The main process formats the notes as CSV and writesnotes.csvin the user’s Downloads folder. The columns areidandtitle.
From the button to the file writer
-
Page · renderer.jsExport notesCalls
notes.exportCsv(). -
Bridge · preload.js
notes:exportSends a named message to the main process. -
Handler · main.jsWrite notes.csvCalls the formatter in
csv.jsand writes the file.
ipcMain.handle("notes:export", () => {
const destination = path.join(app.getPath("downloads"), "notes.csv");
writeFileSync(destination, toCsv(notes), "utf8");
return destination;
});
The file path, formatter and write call are together in this handler. Ask your agent to show these lines if its answer leaves them out.
4. Check a prediction
A comma separates CSV columns. What happens when a note title itself contains a comma or quotation marks?
Predict the CSV for a note with id 1 and title Hello, "REA". Then run the example’s toCsv formatter with Node.js to check it. Show the prediction and actual output.
id,title
1,"Hello, ""REA"""
The title stays in one quoted field; each quotation mark is doubled. This checks the formatter directly with Node.js.
Run the check yourself
Open a terminal in the unpacked
notes-example folder:
node <<'JS'
const { toCsv } = require('./csv.js');
process.stdout.write(toCsv([{ id: 1, title: 'Hello, "REA"' }]));
JS
This command uses a shell with here-document support, such as Bash or Zsh. Your agent can run the same JavaScript in your platform’s shell.
5. Ask another question
Try a follow-up in the same conversation:
What happens if the file can’t be written? Follow the error back to the page.
Or give your agent an app of your own and ask about one button, file or behavior.
- How Notion copies text and HTMLFollow a clipboard feature in a packaged Electron app.
- How DX-Ball calculates sound panningRead the original instructions and the reconstruction’s checks.
- Troubleshoot setup or analysisUpdate REA and check the connection if you get stuck.