
jinshi666888/rea-playbook

実践的なREAプレイブック:最小限のElectronアプリを検査し、REAの1.8 MBのEvidence JSONを読みやすい `file:line` の検出結果に変換し、MCPサーバーを調査し、再現例を検証する——**ネイティブのリバースエンジニアリングエンジンをインストールすることなく**。

jinshi666888/rea-playbook

実践的なREAプレイブック:最小限のElectronアプリを検査し、REAの1.8 MBのEvidence JSONを読みやすい file:line の検出結果に変換し、MCPサーバーを調査し、再現例を検証する——ネイティブのリバースエンジニアリングエンジンをインストールすることなく。
インストール方法は元のソースをご確認ください。
A hands-on REA playbook: inspect a minimal Electron app, turn REA's 1.8 MB Evidence JSON into readable file:line findings, probe the MCP server, and verify a recreate example — without installing a native reverse-engineering engine.
Three commands from zero to a line-referenced report. The first run downloads [email protected] via npx, so allow a couple of minutes:
npm run analyze && npm run extract && npm run verify

The animation above is generated from the real stdout of those three commands (captured and rendered frame-by-frame), not hand-written.
REA (Reverse Engineer Anything) is a powerful MCP-based reverse-engineering toolkit, but getting from "I have a 1.8 MB Evidence file" to "this is what it means" is a gap.
rea-playbook fills that gap:
| You have | rea-playbook gives you |
|---|---|
| A desire to try REA but no analysis target | An 8-file minimal Electron app covering IPC / routing / DOM / fetch |
| A 1.8 MB Evidence file | A readable, file:line-referenced report (compressed to 4.21%) |
| A question about whether MCP is configured | A one-command MCP handshake + real tool call probe |
| Evidence but no code | A verified recreate loop, 10/10 assertions |
This is not a replacement for REA. It is the runnable layer next to it.
profile:read @ main.js:26:0, route:resolve @ main.js:30:0, not fuzzy summaries.paired_renderer_transmissions: 0 stays zero.| Approach | Install | Traceable | Handles uncertainty | Regression tests | |---|---|---|---|---| | Throw code at an LLM | None | No | No | No | | Ghidra / Hopper manual | Engine + license | Yes | Yes | No | | Plain AST tooling (ast-grep, etc.) | Light | Syntax only | N/A | Sometimes | | REA + rea-playbook | Only Node.js | Yes, to the line | Yes, via limitations | Yes, 32 tests |
npm install (it fetches the project's dependencies). After that, npm run demo:offline runs with no network and no REA — it only reads the bundled fixture.The fastest way to see what the output looks like. It only reads the bundled, sanitized fixture and runs pure-Node assertions.
npm install # or skip this in GitHub Codespaces
npm run demo:offline # → reads fixtures/electron-demo.evidence.json, prints report, runs 10/10 checks
This path does not call npx, download rea-agents, or start any reverse-engineering engine.
git clone https://github.com/jinshi666888/rea-playbook.git
cd rea-playbook
npm install
npm run analyze # Decompile: produce local Evidence with REA
npm run extract # Understand: line-referenced report
npm run verify # Recreate: 10/10 assertions
npm run analyze will fetch [email protected] on first use via npx fallback.
Click the Open in GitHub Codespaces badge at the top. The container has Node.js 22 and npm install pre-run.
npm run probe
# REA launcher: node_modules
# serverInfo: {"name":"rea","version":"6.3.0"}
# tools: 139 total, 58 available
# analyze_javascript_application: isError=false
MCP config for your client (REA uses stdio, the positional arg is mcp):
{
"mcpServers": {
"rea": {
"command": "npx",
"args": ["-y", "[email protected]", "mcp"]
}
}
}
Pin the version. After writing the config, restart your client.
rea-playbook/
├── bin/rea-playbook.mjs # CLI: demo:offline / analyze / extract / verify / probe / doctor
├── src/
│ ├── extract.mjs # Evidence → structured facts with file:line
│ ├── mcp-probe.mjs # MCP stdio probe
│ └── paths.mjs # no hard-coded machine paths
├── targets/electron-demo/ # 8-file minimal target
├── recreate/ # evidence → code → test loop
├── fixtures/ # sanitized offline sample (75 KB)
├── scripts/
│ ├── lint.mjs # zero-dependency static checks
│ └── make-fixture.mjs # generate sanitized fixture from real Evidence
└── tests/ # 32 tests, fully offline
flowchart LR
T[targets/electron-demo] -->|npm run analyze| R[REA CLI / MCP]
R -->|Evidence ~1.8 MB| E[src/extract.mjs]
E -->|file:line report| U[you read conclusions]
U -->|write from evidence| C[recreate/]
C -->|npm run verify| V[10/10 assertions]
E -.->|sanitize 4.21%| F[fixtures/]
F -.->|offline assertions| TS[tests/]
npm run demo:offline shows real output in one minute.npm run analyze -- /your/app/dir /tmp/out.json, then npm run extract /tmp/out.json.src/mcp-probe.mjs and run npm run probe to verify.npm run extract output carries exact file:line references for docs or review.$ npm run extract
Evidence: 7 files, 5 parsed JS, 767 AST nodes, 27 findings
### IPC CHANNELS (6)
profile:read side=main op=handle channel=profile:read resolution=literal @ main.js:26:0
route:resolve side=main op=handle channel=route:resolve resolution=literal @ main.js:30:0
profile:telemetry side=main op=on channel=profile:telemetry resolution=literal @ main.js:34:0
### ELECTRON BOUNDARIES
[browser-window] BrowserWindow@13:14-20:4 @ main.js:13:14
[context-bridge-api] demoBridge members=[readProfile,resolveRoute,sendTelemetry] @ preload.js:7:0
### NETWORK
[request] fetch @ src/profile-store.js:4
[response] json @ src/profile-store.js:13
### LIMITATIONS
- Dynamic IPC channel expressions remain unresolved and are never paired by textual similarity.
Full deployment and troubleshooting guides are in docs/.
Frequent questions live in docs/FAQ.md. Highlights:
| Symptom | Answer |
|---|---|
| rea doctor reports healthy: false | Only node and host matter for the JS path; missing engines are expected |
| 58/139 tools available | Expected — the rest need native engines or Linux/macOS features |
| MCP Input validation error | The parameter is input_path, not path |
| Node 23 / 25 fails | Not supported; use 22.19+ / 24.11+ / 26+ |
| git clone fails with invalid index-pack output | This machine's GitHub transport is flaky; use npm path or a different network |
PRs and issues are welcome. The four best types of contribution:
targets/.src/extract.mjs with a test.docs/TROUBLESHOOTING.md or docs/FAQ.md.Run npm run check (lint + typecheck + tests) before opening a PR.
See CONTRIBUTING.md.
.asar sample that can be publicly redistributedcompare_application_versions workflow examplerea-agents, not rea)CHANGELOG.mddocs/growth-log.mdMIT © 2026 jinshi666888
This repo does not contain REA source code. It calls the published rea-agents npm package at runtime. REA itself is MIT and its copyright belongs to its authors.