Prompt: Have Claude Act as a Senior Engineer to Refactor an Unfamiliar Codebase
aitrendz_xyz · x · 2026-11-05
The tweet shares a reusable prompt that casts the model as a senior engineer joining a large, unfamiliar codebase: first map the architecture and data flow, then find structural problems, duplicated code, performance bottlenecks and maintenance risks, and finally output an architecture summary, a list of problem spots, a refactor plan and the improved code — with behavior kept identical.
It is part 2 of the author's "8 prompts" series; part 1 asks the model to build a production-ready full-stack MVP from scratch (architecture, file structure, DB schema, API endpoints, UI structure and full code).
Related event: Structured prompts beat vague asks for Claude coding, templates trend(3 posts)→
More from coding & agent
- Intelligence now 'too cheap to meter': investor drops Codex for all-you-can-eat Claude at $100 — StewartalsopIII · 2026-11-06
- One plain-English prompt turns your phone into a 200-particle physics simulator — tak3sh8 · 2026-11-06
- Zep Agent Skills turns verified agent traces into versioned, governed procedural memory — TheTuringPost · 2026-11-06
- Zep launches Agent Skills: compile verified agent runs into reusable skills — TheTuringPost · 2026-11-06
- Sentry's next MCP evolution: one CLI login powers both MCP and full CLI access — zeeg · 2026-11-06
- Box launches Box Content Retrieval with agentic platform and MCP support at BoxWorks — shashib · 2026-11-06