How pothome/morluto-rea works
REA is a local reverse-engineering product exposed through a CLI and an MCP server. An agent or operator asks about an app or feature; REA opens an analysis session, gathers native, artifact, browser, Electron, or process observations, and returns structured results and evidence for investigation. The README also documents setup and agent integrations as product capabilities. Edges reflect the excerpts, SOURCE INDEX references, or README; unsampled wiring is left out or marked unverified.
Main entry points: BinarySession.ts Analysis session · createServer.ts MCP server · main.ts Runtime entry · cli.ts REA CLI
Components 20
Entry points
- REA CLI
src/cli.ts - Runtime entry
src/main.ts - MCP server
src/server/createServer.ts - Tool contracts
src/contracts/toolContracts.ts
Analysis engines
- Analysis session
src/application/BinarySession.ts - Provider interface
src/application/AnalysisProvider.ts - Hopper bridge
src/hopper/HopperClient.ts - Native inspection
src/native/NativeMacOSProvider.ts - Artifact analysis
src/artifacts/ArtifactProvider.ts
Runtime observation
- Browser observation
src/application/BrowserObservationService.ts - CDP browser adapter
src/browser/CdpBrowserProvider.ts - Electron observation
src/application/ElectronObservationService.ts - Process capture
src/application/ProcessHarness.ts
Evidence and investigation
- Evidence records
src/domain/evidence.ts - Investigation workspace
src/application/InvestigationWorkspaceStore.ts - Reference source reader
src/reference/ReferenceSourceReaderEntries.ts
Setup and permissions
- Permission authority
src/application/PermissionAuthority.ts - Setup workflow
src/application/Setup.ts - Agent registration
src/application/SetupClients.ts
Other components
- Agent or operator
Connections 19
- Agent or operator → REA CLI: invokes
- Agent or operator → MCP server: requests tools
- REA CLI → Analysis session: analyzes
src/cli.ts - Runtime entry → Analysis session: creates
src/main.ts - Runtime entry → MCP server: creates
src/main.ts - MCP server → Tool contracts: registers tools
- MCP server → Analysis session: dispatches session tools
- Analysis session → Provider interface: uses provider port
src/application/BinarySession.ts - Native inspection → Provider interface: implements analysis
src/native/NativeMacOSProvider.ts - Artifact analysis → Provider interface: uses provider
src/artifacts/ArtifactProvider.ts - Analysis session → Hopper bridge: may analyze via Hopper
- Runtime entry → CDP browser adapter: creates browser provider
src/main.ts - Browser observation → Evidence records: records observations
src/application/BrowserObservationService.ts - Electron observation → Evidence records: records observations
src/application/ElectronObservationService.ts - MCP server → Process capture: captures scenarios
- Analysis session → Evidence records: maintains evidence
src/application/BinarySession.ts - REA CLI → Setup workflow: runs setup
src/cli.ts - Setup workflow → Agent registration: configures clients
src/application/Setup.ts - Runtime entry → Permission authority: loads policy
src/main.ts