Claude Code has been running flawlessly for me by literally telling it to come up with a plan to make a change.
For example: "Think of a way to create a custom contact page for this website. Think of any potential roadblocks and or errors that may occur".
Then, I just take that output and paste it into Gemini, and tell it "Here is my plan to create a custom contact page for my website: [plan would go here]" (If you want to make it even better give it access to your code). Tell it to critique and make changes to this plan. Then you just feed the critiques back into Claude code and they go back and forth for a while until they both settle on a plan that sounds good.
Now you just tell Claude code "Implement the plan, make sure to check for errors as you go" and I have done this about 13 times and it has built and deployed, no extra debugging.
Iβm looking for the tricks that turn βit worksβ into βwow, that shipped itself.β If youβve built a setup you trust on real deadlines, Iβd love to hear how youβve wired it up.
MCP Stack
Which 2β3 servers stay in your daily rotation, and why?
Any sleeper MCPs that quietly solve a painful problem?
Token + stability hacks when theyβre all chatting at once?
Sneaky claude.md wins
Non obvious directives or role frames that boosted consistency.
Tricks for locking in polished, exec-ready output.
Task() choreography
Patterns for agents sharing state without stepping on each other.
Pain points you wish someone had flagged sooner.
Multi LLM one-two punch
Workflows where Claude + Gemini/OpenAI/etc. do different jobs (not just critique loops).
How you decide who owns which slice.
Force multipliers
Shell scripts, Git hooks, dashboardsβanything that makes Claude hit harder.
Keeping long jobs on mission without babysitting.
βIf I knew thenβ¦β
One hard won lesson that wouldβve saved you a weekend of cursing.
Not looking for free consulting lol!! Iβm just here to trade ideas. Iβll drop my own builds in the comments. Excited to see what setups everyone rates as βbest.β
Thanks in advance! Lets chop it up.
Videos
I've been deep in the rabbit hole of optimizing my Claude Code setup because ADHD brain meets shiny new AI tool. I'm notorious for starting projects and never finishing them, but this one fiiiinally stuck.
The discovery process was hilariously meta (maybe not 'hilarious', I digress) - I was literally using Claude to research how to use Claude (Code) better. We spent hours going through research papers about "agentic development workflows" and "modular instruction patterns." Pretty sure I just invented the most expensive way to procrastinate on actual work (haven't we all at this point).
Everyone's doing this wrong.
I see people cramming everything into massive CLAUDE.md files. Like, 5,000+ words of instructions (my largest version was 2842 words) that Claude mostly ignores while burning through your tokens like it's cryptobros circa 2021.
The breakthrough came when I realized: Why am I giving Claude everything at once when I could give it exactly what it needs, when it needs it?
So I built this modular system with 20+ specific commands:
/project:create-feature auth-system/dev:code-review --focus=security/test:generate-tests --coverage=90%/deploy:prepare-release --type=patch
Each command is structured like this:
<instructions> <requirements>What you need to not break everything</requirements> <execution>Step-by-step so Claude doesn't get creative</execution> <validation>How to know if it worked</validation> <examples>Real examples because abstract is useless</examples> </instructions>
The results are honestly stupid good:
50-80% fewer tokens per session (based on Claude's own {deep} research)
Commands that Claude follows consistently
Sub-30-second setup for new projects
My ADHD brain can actually remember what each command does
The whole thing is open source here if you want to mess with it. Fair warning: it's built by someone who gets distracted by shiny objects, so YMMV.
Why this works when everything else doesn't:
Progressive disclosure - Claude only loads what it needs for the current task. You're not wasting context/tokens every single request.
Specific context - No more "please (for the love of god and all things holy) be helpful" instructions that mean nothing.
XML structure - Turns out Claude actually follows this format consistently.
Token efficiency - I went from burning through my monthly limit in a week to actually having tokens left over. Kidding, I can now sit for 23 hours instead of 16.
My CLAUDE.md is now 200 lines instead of 2,000. It focuses on project-specific stuff that actually matters instead of trying to be the AI equivalent of a self-help book.
The meta irony: I discovered this by asking Claude to help me figure out why Claude wasn't listening to me. The answer was basically "stop talking so much."
Classic.
If you're spending more time wrangling with Claude than building actual shit, try this approach. It's designed for people who want systems that work, not systems that look impressive in screenshots.
Your CLAUDE.md is probably too long. Use modular commands that load just-in-time. Trust me, I researched this with Claude for way too many hours.
Edit: this works with MCP servers, Linear, Notion, Memory, filesystem right now (I think I fogot Gemini but I can add it)
Double edit: repo is public now!
Third edit: moved the repo to GitLab because GitHub are being shitcunts. Here
Alright people, i'll be using claude code for the first time. I have a pro plan. What should be my approach and points that I should be aware of while using? And how to also make the most out of it without hitting rate limits?
Hey everyone,
Since Claude Code has been around for a while now and many of us are already familiar with Claude Sonnet 3.7, I wanted to share a quick step-by-step guide for those who havenβt had time to explore it yet.
This guide sums up everything you need to know about Claude Code, including:
How to install and set it up
The benefits and when to use it
A demo of its capabilities in action
Some Claude Code essential commands
I think Claude Code is a better alternative to coding assistants like Cursor and Bolt, especially for developers who want an AI that really understands the entire codebase instead of just suggesting lines.
https://medium.com/p/how-to-install-and-use-claude-code-the-new-agentic-coding-tool-d03fd7f677bc?source=social.tw
Three months ago I switched from Cursor to Claude Code CLI. Thought I'd share what my setup looks like now and get some feedback on what I might be missing.
Context: I'm a non-CS background dev (sales background, learned to code 2 years ago) building B2B software in a heavily regulated space (EU manufacturing, GDPR). So my setup is probably overkill for most people, but maybe useful for others in similar situations.
The Setup
Core:
- Claude Code CLI in terminal (tried the IDE plugins, prefer the raw CLI)
- Max subscription (worth it for the headroom on complex tasks)
- Windows 11 + PowerShell (yes, really)#
MCP Servers (4 active):
| Server | Why I use it |
|---|---|
| filesystem | Safer file operations than raw bash |
| git | Quick rollbacks when the agent breaks things |
| sequential-thinking | Forces step-by-step reasoning on complex refactors |
| playwright | E2E test automation |
Browser Automation:
- Google Antigravity for visual testing
- Claude for Chrome (can control it from CLI now, game changer)
Custom Skills I Wrote
This is where it gets interesting. Claude Code lets you define custom skills that auto-activate based on context. Here's what I built:
| Skill | Trigger | What is does |
|---|---|---|
| code-quality-gate | Before any deploy | 5-stage checks: pre-commit β PR β preview β E2E β pro |
| strict-typescript-mode | Any .ts/.tsx file | Blocks any, enforces generics, suggests type guards |
| multi-llm-advisor | Architecture decisions | Queries Gemini + OpenAI for alternative approaches |
| secret-scanner | Pre-commit hook | Catches API keys, passwords, tokens before they hit git |
| gdpr-compliance-scanner | EU projects | Checks data residency, PII handling, consent flows |
| gemini-image-ge | On demand | Generates images via Gemini API without leaving CLI |
The multi-llm-advisor has been surprisingly useful. When Claude suggests an architecture, I have it ask Gemini and GPT-4 "what would you do differently?" Catches blind spots I'd never notice.
The Secret Sauce: CLAUDE.md
This file changed everything. It's ~500 lines of project-specific instructions that the agent reads on every prompt. Key sections:
No-Touch Zones
NEVER modify without explicit permission:
- api/auth.ts (authentication)
- api/analyze.ts (core business logic)
- vercel.json (deployment config)
Without this, the agent would "helpfully" refactor my auth code while fixing an unrelated bug. Ask me how I know.
2. Quality Gates
Before ANY commit:
npm run build - MUST succeed
npm run test - All tests pass
npx tsc --noEmit - Zero TypeScript errors
The agent checks these automatically now. Catches ~80% of issues before I even review.
3. Regression Prevention Rules
- ONE change at a time
- List all affected files BEFORE writing code
- If touching more than 3 files, stop and ask
This stopped the "I'll just clean up this code while I'm here" behavior that caused so many bugs.
What Actually Changed My Workflow
"Vibe coding" with guardrails
I describe what I want in natural language. The agent builds it. But the CLAUDE.md rules prevent it from going off the rails. Best of both worlds.
2. The iteration loop
Agent writes code β runs tests β tests fail β agent reads error β fixes β repeat. I just watch until it's green or stuck. Most features ship without me writing a line.
3. Browser-in-the-loop testing
Agent makes UI change β opens Chrome β visually verifies β iterates. Still fails ~30% of the time but when it works, it's magic.
4. Fearless refactoring
With git MCP + quality gates + no-touch zones, I let the agent do refactors I'd never attempt manually. Worst case, git reset --hard and try again.
What Still Sucks, being honest here:
- Setup time: Took 2-3 weeks to dial in. Not beginner friendly at all.
- Browser automation reliability: Antigravity rate limits, Claude for Chrome loses context, ~30% failure rate on complex flows.
- Token usage: Max helps but big refactors can still burn through quota fast.
- Windows quirks: Some MCP servers assume Unix. Had to patch a few things.
- Agent overconfidence: Sometimes it says "done!" when it clearly isn't. Trust but verify.
Questions for This Community
MCP servers: Anyone using others I should try? Especially interested in database or API testing servers.
Preventing scope creep: How do you stop the agent from "improving" code you didn't ask it to touch? My no-touch zones help but curious about other approaches.
Browser automation: Anyone found something more reliable than Antigravity for visual testing?
CLAUDE.md patterns: Would be curious to see how others structure theirs. Happy to share my full file if there's interest.
TL;DR: Claude Code CLI + MCP servers + custom skills + strict CLAUDE.md rules = actual production-ready code from "vibe coding". Took weeks to set up but now I ship faster than I ever did manually. :)
Claude Code $200 Plan
Claudia (Claude Code UI is usable to if you need GUI to be web based, but Claudia is better imo)
Context7
Built in Claude Code fetch
Good prompting, PRDs, mock-ups, and docs
You really do not need anything else
Hey everyone,
Since Claude Code has been around for a while now and many of us are already familiar with Claude Sonnet 3.7, I wanted to share a quick step-by-step guide for those who havenβt had time to explore it yet.
This guide sums up everything you need to know about Claude Code, including:
How to install and set it up
The benefits and when to use it
A demo of its capabilities in action
Some Claude Code essential commands
I think Claude Code is a better alternative to coding assistants like Cursor and Bolt, especially for developers who want an AI that really understands the entire codebase instead of just suggesting lines.
https://medium.com/p/how-to-install-and-use-claude-code-the-new-agentic-coding-tool-d03fd7f677bc?source=social.tw
Hey r/ClaudeAI! This is a cross-post from my blog. I'm sharing what I've learned about Claude Code here & hopefully you find it useful :)
I've been a huge fan of Claude Code ever since it was released.
The first time I tried it, I was amazed by how good it was. But the token costs quickly turned me away. I couldn't justify those exorbitant costs at the time.
Since Anthropic enabled using Claude.ai subscriptions to power your Claude Code usage, it has been a no-brainer for me. I quickly bought the Max tier to power my usage.
Since then, I've used Claude Code extensively. I'm constantly running multiple CC instances doing some form of coding or task that is useful to me. This would have cost me many thousands of dollars if I had to pay for the usage. My productivity has noticeably improved since starting this, and it has been increasing steadily as I become better at using these agentic coding tools.
From throwaway projects...
Agentic coding gives the obvious benefit of taking on throwaway projects that you'd like to explore for fun. Just yesterday, I downloaded all my medical records from the Danish health systems and formatted them so an LLM would easily understand them. Then I gave it to OpenAI's o3 model to help me better understand my (somewhat atypical) medical history. This required barely 15 minutes of my time to set up and guide, and the result was fantastic. I finally got answers to questions I'd been wondering about for years.
There are countless instances where CC has helped me do things that are useful, but not critical enough to be prioritized in the day-to-day.
To serious development
What I'm most interested in is how I can use tools like Claude Code to increase my leverage and create better, more useful solutions. While side projects are fun, they are not the most important thing to optimize. Serious projects (usually) have existing codebases and quality standards to uphold.
I've had great experience using Claude Code, AmpCode, and other AI-coding tools for these kinds of projects, but the patterns of coding are different:
Context curation is critical: You have to include established experience and directional cues beyond task specifications.
You guide the architecture: The onus is on you to provide and guide the model to create designs that fit well in the context of your system. This means more hand-holding and creating explicit plans for the agentic tools to execute.
Less vibe-coding, more partnership: It's more like an intellectual sparring partner that eagerly does trivial tasks for you, is somehow insanely capable in some areas, can read and understand hundreds of documentation pages in minutes, but doesn't quite understand your system or project without guidance.
Patterns and tips for agentic coding
Much of this advice can be boiled down to:
Get good at using the tool you're using
Build and maintain tools and frameworks that help you use these agentic coding tools better. Use the agentic tools to write these
Your skills and productivity gains from agentic coding tools will improve exponentially over time.
Here's my attempt at boiling down some of the most useful patterns and tips I've learned using Claude Code extensively.
1. Establish and maintain a CLAUDE.md file
This can feel like a chore but it's insanely useful and can save you a ton of time.
Use # as the prefix to your CC prompt and it'll remember your instructions by adding them to CLAUDE.md.
Put CLAUDE.md files in subdirectories to give specific instructions for tests, frontend code, backend services, etc. Curate your context!
Your investment in curating files like CLAUDE.md, or procedures as in (7) and scripts (11), is the same as investing in your developer tooling. Would you code without a linter or formatter? Without a language server to correct you and give feedback? Or a type checker? You could, but most would agree that it's not as easy, nor productive.
2. Use the commands
A few useful ones:
Plan mode (shift+tab). I find that this increases the reliability of CC. It becomes more capable of seeing a task to completion.
Verbose mode (CTRL+R) to see the full context Claude is seeing
Bash mode (
!prefix) to run a command and add output as context for the next turnEscape to interrupt and double escape to jump back in the conversation history
3. Run multiple instances in parallel
Frontend + backend at the same time is a great approach. Have one instance build the frontend with placeholder/mocked API & iterate on design while another agent codes the backend.
You can use Git worktrees to work on the same codebase with multiple agents. It's honestly more of a pain than gain when you have to spin up multiple Docker Compose environments, so just use a single Claude instance in that kind of project. Or just don't have multiple instances of the project running at the same time.
4. Use subagents
Just ask Claude Code to do so.
A common and useful pattern is to use multiple subagents to approach a problem from multiple angles simultaneously, then have the main agent compare notes and find the best solution with you.
5. Use visuals
Use screenshots (just drag them in). Claude Code is excellent at understanding visual information and can help debug UI issues or replicate designs.
6. Choose Claude 4 Opus
Especially if you're on a higher tier. Why not use the best model available?
Anecdotally, it's a noticeable step up from Claude 4 Sonnet β which is already a good model in itself.
7. Create project-specific slash commands
Put them in .claude/commands.
Examples:
Common tasks or instructions
Creating migrations
Project setup
Loading context/instructions
Tasks that need repetition with different focus each time
@tokenbender wrote a great guide to their agent-guides setup that shows this practice.
8. Use Extended Thinking
Write think, think harder, or ultrathink for cases requiring more consideration, like debugging, planning, design.
These increase the thinking budget, which gives better results (but takes longer). ultrathink supposedly allocates 31,999 tokens.
9. Document everything
Have Claude Code write its thoughts, current task specifications, designs, requirement specifications, etc. to an intermediate markdown document. This both serves as context later and a scratchpad for now. And it'll be easier for you to verify and help guide the coding process.
Using these documents in later sessions is invaluable. As your sessions grow in length, context is lost. Regain important context by just reading the document again.
10. For the Vibe-Coders
USE GIT. USE IT OFTEN. You can just make Claude write your commit messages. But seriously, version control becomes even more critical when you're moving fast with AI assistance.
11. Optimize your workflow
Continue previous sessions to preserve context (use
--resume)Use MCP servers (context7, deepwiki, puppeteer, or build your own)
Write scripts for common deterministic tasks and have CC maintain them
Use the GitHub CLI instead of fetch tools for GitHub context. Don't use
fetchtools to retrieve context from GitHub. (Or use an MCP server, but the CLI is better).Track your usage with ccusage
It's more of a fun gimmick if you're on Pro/Max tier β you'll just see what you 'could have' spent if you were using the API.
But the live dashboard (
bunx ccusage blocks --live) is useful to see if your multiple agents are coming close to hitting your rate limits.
Stay up to date via the docs β they're super good
12. Aim for fast feedback loops
Provide a verification mechanism for the model to achieve a fast feedback loop. This usually leads to less reward-hacking, especially when paired with specific instructions and constraints.
Reward hacking: when the AI takes shortcuts to make it look like it succeeded without actually solving the problem. For example, it might hardcode fake outputs or write tests that always pass instead of doing the real work.
13. Use Claude Code in your IDE
The experience becomes more akin to pair-programming, and it gives CC the ability to interact with IDE tools, which is very useful. E.g. access to lint errors, your active file, etc.
14. Queue messages
You can keep sending messages while Claude Code is working, which queues them for the next turn. Useful when you already know what's next.
There's currently a bug where CC doesn't always see this message, but it usually works. Just be aware of it.
15. Compacting and session context length
Be very mindful of compacting. It reduces the noise in your conversation, but also leads to compacting away important context. Do it preemptively at natural stopping points, as compression leads to information loss.
16. Get a better PR template
This is more of a personal gripe with the template itself.
Use another PR template than the default. It seems like Claude 4/CC was instructed to use a specific template, but that template sucks. "Summary β Changes β Test plan" is OK but it's better to have a PR body tailored to your exact PR or project.
Beyond Coding
Claude Code can be used for more than just code.
Researching docs β writeup (e.g. to use for another sessions context)
Debugging (it's really good at this!)
Writing docs after completing features
Refactoring
Writing tests
Finding where X is done (e.g. in new codebases, or huge codebases you're unfamiliar with).
Using Claude Code in my Obsidian vault for extensive research into my notes (journals, thoughts, ideas, notes, ...)
Things to watch out for
Security when using tools
Be VERY careful about the external context you inject into the model, e.g. by fetching via MCPs or other means. Prompt injection is a real security concern. People can write malicious prompts in e.g. GitHub issues and have your agent leak unintended information or take unprecedented actions.
Vibing
I've still yet to see a case where full-on, automated vibe-coding for hours on end makes sense. Yes, it works, and you can do it, but I'd avoid it in production systems where people actively have to maintain code. Or, at least review the code yourself.
Model variability
Sometimes it feels like Anthropic is using quantized models depending on model demand. It's as if the model quality can vary over time. This could be a skill issue, but I've seen other users report similar experiences. While understandable, it doesn't feel great as a paying user.
Running Claude Code
I can't help but tinker and explore the tools I use, and I've found some interesting configurations to use with Claude Code.
Some of the environment variables I'm using aren't publicly documented yet, so this is your warning that they may be unstable.
Here's a bash function I use to launch Claude Code with optimized settings:
function ccv() {
local env_vars=(
"ENABLE_BACKGROUND_TASKS=true"
"FORCE_AUTO_BACKGROUND_TASKS=true"
"CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC=true"
"CLAUDE_CODE_ENABLE_UNIFIED_READ_TOOL=true"
)
local claude_args=()
if [[ "$1" == "-y" ]]; then
claude_args+=("--dangerously-skip-permissions")
elif [[ "$1" == "-r" ]]; then
claude_args+=("--resume")
elif [[ "$1" == "-ry" ]] || [[ "$1" == "-yr" ]]; then
claude_args+=("--resume" "--dangerously-skip-permissions")
fi
env "${env_vars[@]}" claude "${claude_args[@]}"
}CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC=true: Disables telemetry, error reporting, and auto-updatesENABLE_BACKGROUND_TASKS=true: Enables background task functionality for long-running commandsFORCE_AUTO_BACKGROUND_TASKS=true: Automatically sends long tasks to background without needing to confirmCLAUDE_CODE_ENABLE_UNIFIED_READ_TOOL=true: Unifies file reading capabilities, including Jupyter notebooks.
This gives you:
Automatic background handling for long tasks (e.g. your dev server)
No telemetry or unnecessary network traffic
Unified file reading
Easy switches for common scenarios (
-yfor auto-approve,-rfor resume)
Been deep in the Claude Code rabbit hole for weeks now and Iβm trying to build something specific but wondering if it already exists or if others have solved this.
My dream setup: Claude Code that acts like a senior dev who refuses to write a single line until theyβve researched the hell out of everything. Not just βlet me check the docsβ but likeβ¦ automatically spawning parallel research agents that crawl GitHub for similar implementations, compare multiple approaches, check security advisories, and then synthesize an unbiased βhereβs actually the best way to do this based on evidenceβ response.
Right now when I say βbuild me an auth system,β I want it to:
β’ Auto-trigger deep research mode (without me having to remember to use specific commands)
β’ Check how Next-Auth, Supabase, Clerk, etc. actually implement things
β’ Find the most starred/recent GitHub repos doing similar stuff
β’ Compare the approaches and tell me WHY one is better
β’ Save all this research to its memory so it never has to look it up again
β’ THEN start coding
And when it hits an error, instead of the dreaded βI apologize, let me try againβ loop, it should automatically search GitHub issues, Stack Overflow, wherever, until it finds the actual solution.
Iβve been experimenting with MCP servers (filesystem, brave-search, github) and custom hooks, but I feel like Iβm reinventing the wheel here. Has anyone built:
β’ Hooks that auto-detect when research is needed and trigger it? β’ Sub-agents specifically for parallel research tasks?
β’ MCPs that handle the βnever give up, always find another wayβ mentality?
β’ A CLAUDE.md setup that makes it think like a research-first developer?
Or even better - has someone packaged all this into a repo I can just clone? Iβve seen bits and pieces but nothing that ties it all together specifically for Claude Code.
Share your setups! Even if itβs just a clever hook or command you use. Iβm especially interested in how people handle the context management when doing deep research - do you use worktrees? Separate conversations? Some other magic?
Will compile everything shared here into a mega guide and share back with the community.
Claude Code $200 Plan
Claudia (Claude Code UI is usable to if you need GUI to be web based, but Claudia is better imo)
Context7
Built in Claude Code fetch
Good prompting, PRDs, mock-ups, and docs
You really do not need anything else
Edit: Many of you are asking for a repo so I will make an effort to get one up in the next couple days. All of this is a part of a work project at the moment, so I have to take some time to copy everything into a fresh project and scrub any identifying info. I will post the link here when it's up. You can also follow me and I will post it on my profile so you get notified. Thank you all for the kind comments. I'm happy to share this info with others since I don't get much chance to do so in my day-to-day.
Edit (final?): I bit the bullet and spent the afternoon getting a github repo up for you guys. Just made a post with some additional info here or you can go straight to the source:
π― Repository: https://github.com/diet103/claude-code-infrastructure-showcase
Quick tip from a fellow lazy person: You can throw this book of a post into one of the many text-to-speech AI services like ElevenLabs Reader or Natural Reader and have it read the post for you :)
Disclaimer
I made a post about six months ago sharing my experience after a week of hardcore use with Claude Code. It's now been about six months of hardcore use, and I would like to share some more tips, tricks, and word vomit with you all. I may have went a little overboard here so strap in, grab a coffee, sit on the toilet or whatever it is you do when doom-scrolling reddit.
I want to start the post off with a disclaimer: all the content within this post is merely me sharing what setup is working best for me currently and should not be taken as gospel or the only correct way to do things. It's meant to hopefully inspire you to improve your setup and workflows with AI agentic coding. I'm just a guy, and this is just like, my opinion, man.
Also, I'm on the 20x Max plan, so your mileage may vary. And if you're looking for vibe-coding tips, you should look elsewhere. If you want the best out of CC, then you should be working together with it: planning, reviewing, iterating, exploring different approaches, etc.
Quick Overview
After 6 months of pushing Claude Code to its limits (solo rewriting 300k LOC), here's the system I built:
Skills that actually auto-activate when needed
Dev docs workflow that prevents Claude from losing the plot
PM2 + hooks for zero-errors-left-behind
Army of specialized agents for reviews, testing, and planning Let's get into it.
Background
I'm a software engineer who has been working on production web apps for the last seven years or so. And I have fully embraced the wave of AI with open arms. I'm not too worried about AI taking my job anytime soon, as it is a tool that I use to leverage my capabilities. In doing so, I have been building MANY new features and coming up with all sorts of new proposal presentations put together with Claude and GPT-5 Thinking to integrate new AI systems into our production apps. Projects I would have never dreamt of having the time to even consider before integrating AI into my workflow. And with all that, I'm giving myself a good deal of job security and have become the AI guru at my job since everyone else is about a year or so behind on how they're integrating AI into their day-to-day.
With my newfound confidence, I proposed a pretty large redesign/refactor of one of our web apps used as an internal tool at work. This was a pretty rough college student-made project that was forked off another project developed by me as an intern (created about 7 years ago and forked 4 years ago). This may have been a bit overly ambitious of me since, to sell it to the stakeholders, I agreed to finish a top-down redesign of this fairly decent-sized project (~100k LOC) in a matter of two to three months...all by myself. I knew going in that I was going to have to put in extra hours to get this done, even with the help of CC. But deep down, I know it's going to be a hit, automating several manual processes and saving a lot of time for a lot of people at the company.
It's now six months later... yeah, I probably should not have agreed to this timeline. I have tested the limits of both Claude as well as my own sanity trying to get this thing done. I completely scrapped the old frontend, as everything was seriously outdated and I wanted to play with the latest and greatest. I'm talkin' React 16 JS β React 19 TypeScript, React Query v2 β TanStack Query v5, React Router v4 w/ hashrouter β TanStack Router w/ file-based routing, Material UI v4 β MUI v7, all with strict adherence to best practices. The project is now at ~300-400k LOC and my life expectancy ~5 years shorter. It's finally ready to put up for testing, and I am incredibly happy with how things have turned out.
This used to be a project with insurmountable tech debt, ZERO test coverage, HORRIBLE developer experience (testing things was an absolute nightmare), and all sorts of jank going on. I addressed all of those issues with decent test coverage, manageable tech debt, and implemented a command-line tool for generating test data as well as a dev mode to test different features on the frontend. During this time, I have gotten to know CC's abilities and what to expect out of it.
A Note on Quality and Consistency
I've noticed a recurring theme in forums and discussions - people experiencing frustration with usage limits and concerns about output quality declining over time. I want to be clear up front: I'm not here to dismiss those experiences or claim it's simply a matter of "doing it wrong." Everyone's use cases and contexts are different, and valid concerns deserve to be heard.
That said, I want to share what's been working for me. In my experience, CC's output has actually improved significantly over the last couple of months, and I believe that's largely due to the workflow I've been constantly refining. My hope is that if you take even a small bit of inspiration from my system and integrate it into your CC workflow, you'll give it a better chance at producing quality output that you're happy with.
Now, let's be real - there are absolutely times when Claude completely misses the mark and produces suboptimal code. This can happen for various reasons. First, AI models are stochastic, meaning you can get widely varying outputs from the same input. Sometimes the randomness just doesn't go your way, and you get an output that's legitimately poor quality through no fault of your own. Other times, it's about how the prompt is structured. There can be significant differences in outputs given slightly different wording because the model takes things quite literally. If you misword or phrase something ambiguously, it can lead to vastly inferior results.
Sometimes You Just Need to Step In
Look, AI is incredible, but it's not magic. There are certain problems where pattern recognition and human intuition just win. If you've spent 30 minutes watching Claude struggle with something that you could fix in 2 minutes, just fix it yourself. No shame in that. Think of it like teaching someone to ride a bike - sometimes you just need to steady the handlebars for a second before letting go again.
I've seen this especially with logic puzzles or problems that require real-world common sense. AI can brute-force a lot of things, but sometimes a human just "gets it" faster. Don't let stubbornness or some misguided sense of "but the AI should do everything" waste your time. Step in, fix the issue, and keep moving.
I've had my fair share of terrible prompting, which usually happens towards the end of the day where I'm getting lazy and I'm not putting that much effort into my prompts. And the results really show. So next time you are having these kinds of issues where you think the output is way worse these days because you think Anthropic shadow-nerfed Claude, I encourage you to take a step back and reflect on how you are prompting.
Re-prompt often. You can hit double-esc to bring up your previous prompts and select one to branch from. You'd be amazed how often you can get way better results armed with the knowledge of what you don't want when giving the same prompt. All that to say, there can be many reasons why the output quality seems to be worse, and it's good to self-reflect and consider what you can do to give it the best possible chance to get the output you want.
As some wise dude somewhere probably said, "Ask not what Claude can do for you, ask what context you can give to Claude" ~ Wise Dude
Alright, I'm going to step down from my soapbox now and get on to the good stuff.
My System
I've implemented a lot changes to my workflow as it relates to CC over the last 6 months, and the results have been pretty great, IMO.
Skills Auto-Activation System (Game Changer!)
This one deserves its own section because it completely transformed how I work with Claude Code.
The Problem
So Anthropic releases this Skills feature, and I'm thinking "this looks awesome!" The idea of having these portable, reusable guidelines that Claude can reference sounded perfect for maintaining consistency across my massive codebase. I spent a good chunk of time with Claude writing up comprehensive skills for frontend development, backend development, database operations, workflow management, etc. We're talking thousands of lines of best practices, patterns, and examples.
And then... nothing. Claude just wouldn't use them. I'd literally use the exact keywords from the skill descriptions. Nothing. I'd work on files that should trigger the skills. Nothing. It was incredibly frustrating because I could see the potential, but the skills just sat there like expensive decorations.
The "Aha!" Moment
That's when I had the idea of using hooks. If Claude won't automatically use skills, what if I built a system that MAKES it check for relevant skills before doing anything?
So I dove into Claude Code's hook system and built a multi-layered auto-activation architecture with TypeScript hooks. And it actually works!
How It Works
I created two main hooks:
1. UserPromptSubmit Hook (runs BEFORE Claude sees your message):
Analyzes your prompt for keywords and intent patterns
Checks which skills might be relevant
Injects a formatted reminder into Claude's context
Now when I ask "how does the layout system work?" Claude sees a big "π― SKILL ACTIVATION CHECK - Use project-catalog-developer skill" (project catalog is a large complex data grid based feature on my front end) before even reading my question
2. Stop Event Hook (runs AFTER Claude finishes responding):
Analyzes which files were edited
Checks for risky patterns (try-catch blocks, database operations, async functions)
Displays a gentle self-check reminder
"Did you add error handling? Are Prisma operations using the repository pattern?"
Non-blocking, just keeps Claude aware without being annoying
skill-rules.json Configuration
I created a central configuration file that defines every skill with:
Keywords: Explicit topic matches ("layout", "workflow", "database")
Intent patterns: Regex to catch actions ("(create|add).*?(feature|route)")
File path triggers: Activates based on what file you're editing
Content triggers: Activates if file contains specific patterns (Prisma imports, controllers, etc.)
Example snippet:
{
"backend-dev-guidelines": {
"type": "domain",
"enforcement": "suggest",
"priority": "high",
"promptTriggers": {
"keywords": ["backend", "controller", "service", "API", "endpoint"],
"intentPatterns": [
"(create|add).*?(route|endpoint|controller)",
"(how to|best practice).*?(backend|API)"
]
},
"fileTriggers": {
"pathPatterns": ["backend/src/**/*.ts"],
"contentPatterns": ["router\\.", "export.*Controller"]
}
}
}The Results
Now when I work on backend code, Claude automatically:
Sees the skill suggestion before reading my prompt
Loads the relevant guidelines
Actually follows the patterns consistently
Self-checks at the end via gentle reminders
The difference is night and day. No more inconsistent code. No more "wait, Claude used the old pattern again." No more manually telling it to check the guidelines every single time.
Following Anthropic's Best Practices (The Hard Way)
After getting the auto-activation working, I dove deeper and found Anthropic's official best practices docs. Turns out I was doing it wrong because they recommend keeping the main SKILL.md file under 500 lines and using progressive disclosure with resource files.
Whoops. My frontend-dev-guidelines skill was 1,500+ lines. And I had a couple other skills over 1,000 lines. These monolithic files were defeating the whole purpose of skills (loading only what you need).
So I restructured everything:
frontend-dev-guidelines: 398-line main file + 10 resource files
backend-dev-guidelines: 304-line main file + 11 resource files
Now Claude loads the lightweight main file initially, and only pulls in detailed resource files when actually needed. Token efficiency improved 40-60% for most queries.
Skills I've Created
Here's my current skill lineup:
Guidelines & Best Practices:
backend-dev-guidelines- Routes β Controllers β Services β Repositoriesfrontend-dev-guidelines- React 19, MUI v7, TanStack Query/Router patternsskill-developer- Meta-skill for creating more skills
Domain-Specific:
workflow-developer- Complex workflow engine patternsnotification-developer- Email/notification systemdatabase-verification- Prevent column name errors (this one is a guardrail that actually blocks edits!)project-catalog-developer- DataGrid layout system
All of these automatically activate based on what I'm working on. It's like having a senior dev who actually remembers all the patterns looking over Claude's shoulder.
Why This Matters
Before skills + hooks:
Claude would use old patterns even though I documented new ones
Had to manually tell Claude to check BEST_PRACTICES.md every time
Inconsistent code across the 300k+ LOC codebase
Spent too much time fixing Claude's "creative interpretations"
After skills + hooks:
Consistent patterns automatically enforced
Claude self-corrects before I even see the code
Can trust that guidelines are being followed
Way less time spent on reviews and fixes
If you're working on a large codebase with established patterns, I cannot recommend this system enough. The initial setup took a couple of days to get right, but it's paid for itself ten times over.
CLAUDE.md and Documentation Evolution
In a post I wrote 6 months ago, I had a section about rules being your best friend, which I still stand by. But my CLAUDE.md file was quickly getting out of hand and was trying to do too much. I also had this massive BEST_PRACTICES.md file (1,400+ lines) that Claude would sometimes read and sometimes completely ignore.
So I took an afternoon with Claude to consolidate and reorganize everything into a new system. Here's what changed:
What Moved to Skills
Previously, BEST_PRACTICES.md contained:
TypeScript standards
React patterns (hooks, components, suspense)
Backend API patterns (routes, controllers, services)
Error handling (Sentry integration)
Database patterns (Prisma usage)
Testing guidelines
Performance optimization
All of that is now in skills with the auto-activation hook ensuring Claude actually uses them. No more hoping Claude remembers to check BEST_PRACTICES.md.
What Stayed in CLAUDE.md
Now CLAUDE.md is laser-focused on project-specific info (only ~200 lines):
Quick commands (
pnpm pm2:start,pnpm build, etc.)Service-specific configuration
Task management workflow (dev docs system)
Testing authenticated routes
Workflow dry-run mode
Browser tools configuration
The New Structure
Root CLAUDE.md (100 lines) βββ Critical universal rules βββ Points to repo-specific claude.md files βββ References skills for detailed guidelines Each Repo's claude.md (50-100 lines) βββ Quick Start section pointing to: β βββ PROJECT_KNOWLEDGE.md - Architecture & integration β βββ TROUBLESHOOTING.md - Common issues β βββ Auto-generated API docs βββ Repo-specific quirks and commands
The magic: Skills handle all the "how to write code" guidelines, and CLAUDE.md handles "how this specific project works." Separation of concerns for the win.
Dev Docs System
This system, out of everything (besides skills), I think has made the most impact on the results I'm getting out of CC. Claude is like an extremely confident junior dev with extreme amnesia, losing track of what they're doing easily. This system is aimed at solving those shortcomings.
The dev docs section from my CLAUDE.md:
### Starting Large Tasks When exiting plan mode with an accepted plan: 1.**Create Task Directory**: mkdir -p ~/git/project/dev/active/[task-name]/ 2.**Create Documents**: - `[task-name]-plan.md` - The accepted plan - `[task-name]-context.md` - Key files, decisions - `[task-name]-tasks.md` - Checklist of work 3.**Update Regularly**: Mark tasks complete immediately ### Continuing Tasks - Check `/dev/active/` for existing tasks - Read all three files before proceeding - Update "Last Updated" timestamps
These are documents that always get created for every feature or large task. Before using this system, I had many times when I all of a sudden realized that Claude had lost the plot and we were no longer implementing what we had planned out 30 minutes earlier because we went off on some tangent for whatever reason.
My Planning Process
My process starts with planning. Planning is king. If you aren't at a minimum using planning mode before asking Claude to implement something, you're gonna have a bad time, mmm'kay. You wouldn't have a builder come to your house and start slapping on an addition without having him draw things up first.
When I start planning a feature, I put it into planning mode, even though I will eventually have Claude write the plan down in a markdown file. I'm not sure putting it into planning mode necessary, but to me, it feels like planning mode gets better results doing the research on your codebase and getting all the correct context to be able to put together a plan.
I created a strategic-plan-architect subagent that's basically a planning beast. It:
Gathers context efficiently
Analyzes project structure
Creates comprehensive structured plans with executive summary, phases, tasks, risks, success metrics, timelines
Generates three files automatically: plan, context, and tasks checklist
But I find it really annoying that you can't see the agent's output, and even more annoying is if you say no to the plan, it just kills the agent instead of continuing to plan. So I also created a custom slash command (/dev-docs) with the same prompt to use on the main CC instance.
Once Claude spits out that beautiful plan, I take time to review it thoroughly. This step is really important. Take time to understand it, and you'd be surprised at how often you catch silly mistakes or Claude misunderstanding a very vital part of the request or task.
More often than not, I'll be at 15% context left or less after exiting plan mode. But that's okay because we're going to put everything we need to start fresh into our dev docs. Claude usually likes to just jump in guns blazing, so I immediately slap the ESC key to interrupt and run my /dev-docs slash command. The command takes the approved plan and creates all three files, sometimes doing a bit more research to fill in gaps if there's enough context left.
And once I'm done with that, I'm pretty much set to have Claude fully implement the feature without getting lost or losing track of what it was doing, even through an auto-compaction. I just make sure to remind Claude every once in a while to update the tasks as well as the context file with any relevant context. And once I'm running low on context in the current session, I just run my slash command /update-dev-docs. Claude will note any relevant context (with next steps) as well as mark any completed tasks or add new tasks before I compact the conversation. And all I need to say is "continue" in the new session.
During implementation, depending on the size of the feature or task, I will specifically tell Claude to only implement one or two sections at a time. That way, I'm getting the chance to go in and review the code in between each set of tasks. And periodically, I have a subagent also reviewing the changes so I can catch big mistakes early on. If you aren't having Claude review its own code, then I highly recommend it because it saved me a lot of headaches catching critical errors, missing implementations, inconsistent code, and security flaws.
PM2 Process Management (Backend Debugging Game Changer)
This one's a relatively recent addition, but it's made debugging backend issues so much easier.
The Problem
My project has seven backend microservices running simultaneously. The issue was that Claude didn't have access to view the logs while services were running. I couldn't just ask "what's going wrong with the email service?" - Claude couldn't see the logs without me manually copying and pasting them into chat.
The Intermediate Solution
For a while, I had each service write its output to a timestamped log file using a devLog script. This worked... okay. Claude could read the log files, but it was clunky. Logs weren't real-time, services wouldn't auto-restart on crashes, and managing everything was a pain.
The Real Solution: PM2
Then I discovered PM2, and it was a game changer. I configured all my backend services to run via PM2 with a single command: pnpm pm2:start
What this gives me:
Each service runs as a managed process with its own log file
Claude can easily read individual service logs in real-time
Automatic restarts on crashes
Real-time monitoring with
pm2 logsMemory/CPU monitoring with
pm2 monitEasy service management (
pm2 restart email,pm2 stop all, etc.)
PM2 Configuration:
// ecosystem.config.jsmodule.exports = {
apps: [
{
name: 'form-service',
script: 'npm',
args: 'start',
cwd: './form',
error_file: './form/logs/error.log',
out_file: './form/logs/out.log',
},
// ... 6 more services
]
};Before PM2:
Me: "The email service is throwing errors" Me: [Manually finds and copies logs] Me: [Pastes into chat] Claude: "Let me analyze this..."
The debugging workflow now:
Me: "The email service is throwing errors" Claude: [Runs] pm2 logs email --lines 200 Claude: [Reads the logs] "I see the issue - database connection timeout..." Claude: [Runs] pm2 restart email Claude: "Restarted the service, monitoring for errors..."
Night and day difference. Claude can autonomously debug issues now without me being a human log-fetching service.
One caveat: Hot reload doesn't work with PM2, so I still run the frontend separately with pnpm dev. But for backend services that don't need hot reload as often, PM2 is incredible.
Hooks System (#NoMessLeftBehind)
The project I'm working on is multi-root and has about eight different repos in the root project directory. One for the frontend and seven microservices and utilities for the backend. I'm constantly bouncing around making changes in a couple of repos at a time depending on the feature.
And one thing that would annoy me to no end is when Claude forgets to run the build command in whatever repo it's editing to catch errors. And it will just leave a dozen or so TypeScript errors without me catching it. Then a couple of hours later I see Claude running a build script like a good boy and I see the output: "There are several TypeScript errors, but they are unrelated, so we're all good here!"
No, we are not good, Claude.
Hook #1: File Edit Tracker
First, I created a post-tool-use hook that runs after every Edit/Write/MultiEdit operation. It logs:
Which files were edited
What repo they belong to
Timestamps
Initially, I made it run builds immediately after each edit, but that was stupidly inefficient. Claude makes edits that break things all the time before quickly fixing them.
Hook #2: Build Checker
Then I added a Stop hook that runs when Claude finishes responding. It:
Reads the edit logs to find which repos were modified
Runs build scripts on each affected repo
Checks for TypeScript errors
If < 5 errors: Shows them to Claude
If β₯ 5 errors: Recommends launching auto-error-resolver agent
Logs everything for debugging
Since implementing this system, I've not had a single instance where Claude has left errors in the code for me to find later. The hook catches them immediately, and Claude fixes them before moving on.
Hook #3: Prettier Formatter
This one's simple but effective. After Claude finishes responding, automatically format all edited files with Prettier using the appropriate .prettierrc config for that repo.
No more going into to manually edit a file just to have prettier run and produce 20 changes because Claude decided to leave off trailing commas last week when we created that file.
β οΈ Update: I No Longer Recommend This Hook
After publishing, a reader shared detailed data showing that file modifications trigger <system-reminder> notifications that can consume significant context tokens. In their case, Prettier formatting led to 160k tokens consumed in just 3 rounds due to system-reminders showing file diffs.
While the impact varies by project (large files and strict formatting rules are worst-case scenarios), I'm removing this hook from my setup. It's not a big deal to let formatting happen when you manually edit files anyway, and the potential token cost isn't worth the convenience.
If you want automatic formatting, consider running Prettier manually between sessions instead of during Claude conversations.
Hook #4: Error Handling Reminder
This is the gentle philosophy hook I mentioned earlier:
Analyzes edited files after Claude finishes
Detects risky patterns (try-catch, async operations, database calls, controllers)
Shows a gentle reminder if risky code was written
Claude self-assesses whether error handling is needed
No blocking, no friction, just awareness
Example output:
βββββββββββββββββββββββββββββββββββββββ
π ERROR HANDLING SELF-CHECK
βββββββββββββββββββββββββββββββββββββββ
β οΈ Backend Changes Detected
2 file(s) edited
β Did you add Sentry.captureException() in catch blocks?
β Are Prisma operations wrapped in error handling?
π‘ Backend Best Practice:
- All errors should be captured to Sentry
- Controllers should extend BaseController
βββββββββββββββββββββββββββββββββββββββThe Complete Hook Pipeline
Here's what happens on every Claude response now:
Claude finishes responding β Hook 1: Prettier formatter runs β All edited files auto-formatted β Hook 2: Build checker runs β TypeScript errors caught immediately β Hook 3: Error reminder runs β Gentle self-check for error handling β If errors found β Claude sees them and fixes β If too many errors β Auto-error-resolver agent recommended β Result: Clean, formatted, error-free code
And the UserPromptSubmit hook ensures Claude loads relevant skills BEFORE even starting work.
No mess left behind. It's beautiful.
Scripts Attached to Skills
One really cool pattern I picked up from Anthropic's official skill examples on GitHub: attach utility scripts to skills.
For example, my backend-dev-guidelines skill has a section about testing authenticated routes. Instead of just explaining how authentication works, the skill references an actual script:
### Testing Authenticated Routes Use the provided test-auth-route.js script: `node scripts/test-auth-route.js http://localhost:3002/api/endpoint`
The script handles all the complex authentication steps for you:
Gets a refresh token from Keycloak
Signs the token with JWT secret
Creates cookie header
Makes authenticated request
When Claude needs to test a route, it knows exactly what script to use and how to use it. No more "let me create a test script" and reinventing the wheel every time.
I'm planning to expand this pattern - attach more utility scripts to relevant skills so Claude has ready-to-use tools instead of generating them from scratch.
Tools and Other Things
SuperWhisper on Mac
Voice-to-text for prompting when my hands are tired from typing. Works surprisingly well, and Claude understands my rambling voice-to-text surprisingly well.
Memory MCP
I use this less over time now that skills handle most of the "remembering patterns" work. But it's still useful for tracking project-specific decisions and architectural choices that don't belong in skills.
BetterTouchTool
Relative URL copy from Cursor (for sharing code references)
I have VSCode open to more easily find the files Iβm looking for and I can double tap CAPS-LOCK, then BTT inputs the shortcut to copy relative URL, transforms the clipboard contents by prepending an β@β symbol, focuses the terminal, and then pastes the file path. All in one.
Double-tap hotkeys to quickly focus apps (CMD+CMD = Claude Code, OPT+OPT = Browser)
Custom gestures for common actions
Honestly, the time savings on just not fumbling between apps is worth the BTT purchase alone.
Scripts for Everything
If there's any annoying tedious task, chances are there's a script for that:
Command-line tool to generate mock test data. Before using Claude code, it was extremely annoying to generate mock data because I would have to make a submission to a form that had about a 120 questions Just to generate one single test submission.
Authentication testing scripts (get tokens, test routes)
Database resetting and seeding
Schema diff checker before migrations
Automated backup and restore for dev database
Pro tip: When Claude helps you write a useful script, immediately document it in CLAUDE.md or attach it to a relevant skill. Future you will thank past you.
Documentation (Still Important, But Evolved)
I think next to planning, documentation is almost just as important. I document everything as I go in addition to the dev docs that are created for each task or feature. From system architecture to data flow diagrams to actual developer docs and APIs, just to name a few.
But here's what changed: Documentation now works WITH skills, not instead of them.
Skills contain: Reusable patterns, best practices, how-to guides Documentation contains: System architecture, data flows, API references, integration points
For example:
"How to create a controller" β backend-dev-guidelines skill
"How our workflow engine works" β Architecture documentation
"How to write React components" β frontend-dev-guidelines skill
"How notifications flow through the system" β Data flow diagram + notification skill
I still have a LOT of docs (850+ markdown files), but now they're laser-focused on project-specific architecture rather than repeating general best practices that are better served by skills.
You don't necessarily have to go that crazy, but I highly recommend setting up multiple levels of documentation. Ones for broad architectural overview of specific services, wherein you'll include paths to other documentation that goes into more specifics of different parts of the architecture. It will make a major difference on Claude's ability to easily navigate your codebase.
Prompt Tips
When you're writing out your prompt, you should try to be as specific as possible about what you are wanting as a result. Once again, you wouldn't ask a builder to come out and build you a new bathroom without at least discussing plans, right?
"You're absolutely right! Shag carpet probably is not the best idea to have in a bathroom."
Sometimes you might not know the specifics, and that's okay. If you don't ask questions, tell Claude to research and come back with several potential solutions. You could even use a specialized subagent or use any other AI chat interface to do your research. The world is your oyster. I promise you this will pay dividends because you will be able to look at the plan that Claude has produced and have a better idea if it's good, bad, or needs adjustments. Otherwise, you're just flying blind, pure vibe-coding. Then you're gonna end up in a situation where you don't even know what context to include because you don't know what files are related to the thing you're trying to fix.
Try not to lead in your prompts if you want honest, unbiased feedback. If you're unsure about something Claude did, ask about it in a neutral way instead of saying, "Is this good or bad?" Claude tends to tell you what it thinks you want to hear, so leading questions can skew the response. It's better to just describe the situation and ask for thoughts or alternatives. That way, you'll get a more balanced answer.
Agents, Hooks, and Slash Commands (The Holy Trinity)
Agents
I've built a small army of specialized agents:
Quality Control:
code-architecture-reviewer- Reviews code for best practices adherencebuild-error-resolver- Systematically fixes TypeScript errorsrefactor-planner- Creates comprehensive refactoring plans
Testing & Debugging:
auth-route-tester- Tests backend routes with authenticationauth-route-debugger- Debugs 401/403 errors and route issuesfrontend-error-fixer- Diagnoses and fixes frontend errors
Planning & Strategy:
strategic-plan-architect- Creates detailed implementation plansplan-reviewer- Reviews plans before implementationdocumentation-architect- Creates/updates documentation
Specialized:
frontend-ux-designer- Fixes styling and UX issuesweb-research-specialist- Researches issues along with many other things on the webreactour-walkthrough-designer- Creates UI tours
The key with agents is to give them very specific roles and clear instructions on what to return. I learned this the hard way after creating agents that would go off and do who-knows-what and come back with "I fixed it!" without telling me what they fixed.
Hooks (Covered Above)
The hook system is honestly what ties everything together. Without hooks:
Skills sit unused
Errors slip through
Code is inconsistently formatted
No automatic quality checks
With hooks:
Skills auto-activate
Zero errors left behind
Automatic formatting
Quality awareness built-in
Slash Commands
I have quite a few custom slash commands, but these are the ones I use most:
Planning & Docs:
/dev-docs- Create comprehensive strategic plan/dev-docs-update- Update dev docs before compaction/create-dev-docs- Convert approved plan to dev doc files
Quality & Review:
/code-review- Architectural code review/build-and-fix- Run builds and fix all errors
Testing:
/route-research-for-testing- Find affected routes and launch tests/test-route- Test specific authenticated routes
The beauty of slash commands is they expand into full prompts, so you can pack a ton of context and instructions into a simple command. Way better than typing out the same instructions every time.
Conclusion
After six months of hardcore use, here's what I've learned:
The Essentials:
Plan everything - Use planning mode or strategic-plan-architect
Skills + Hooks - Auto-activation is the only way skills actually work reliably
Dev docs system - Prevents Claude from losing the plot
Code reviews - Have Claude review its own work
PM2 for backend - Makes debugging actually bearable
The Nice-to-Haves:
Specialized agents for common tasks
Slash commands for repeated workflows
Comprehensive documentation
Utility scripts attached to skills
Memory MCP for decisions
And that's about all I can think of for now. Like I said, I'm just some guy, and I would love to hear tips and tricks from everybody else, as well as any criticisms. Because I'm always up for improving upon my workflow. I honestly just wanted to share what's working for me with other people since I don't really have anybody else to share this with IRL (my team is very small, and they are all very slow getting on the AI train).
If you made it this far, thanks for taking the time to read. If you have questions about any of this stuff or want more details on implementation, happy to share. The hooks and skills system especially took some trial and error to get right, but now that it's working, I can't imagine going back.
TL;DR: Built an auto-activation system for Claude Code skills using TypeScript hooks, created a dev docs workflow to prevent context loss, and implemented PM2 + automated error checking. Result: Solo rewrote 300k LOC in 6 months with consistent quality.
Hey everyone!
I've been trying out a few different setups for coding with Claude and wanted to see what others think. Do you guys find Claude + Cline (Claude Dev) or Claude + Cursor works better for writing code? Or do some of you actually prefer just using Claude Web Chat + Projects and copying code manually?
I'm also curious about how people use Claude when working on serious projects, not just hobby stuff. If youβve got a big codebase and youβre using Claude to help with actual issues, what's your workflow? How do you set things up? And if youβve got a big idea you're serious about turning into a startup, how would you use Claude to help build it from scratch?
From my own experience, breaking down big goals into small steps seems to work best. Claude does better focusing on one small task at a timeβif you ask it to do something huge all at once, it usually tries but doesnβt quite hit the mark. So Iβll usually start a Project and then break things down into lots of smaller chats, each for one small task. Seems to help a lot.
But honestly, I still feel like AI coding feedback is hit-or-miss. Half the time itβs awesome, but the other half, I end up thinking a human would do it faster. Iβve mainly been using Claudeβs Web version for generating code, but one major issue is that if I make any changes to the code, I have to manually feed those changes back to AI to keep it on track. Thatβs actually why Iβm considering switching to Cline or Cursorβthey seem like they might solve this issue since theyβre more integrated with the coding flow. Do they actually help with this?
Would love to hear your thoughts!
Quick pro-tip from a fellow lazy person: You can throw this book of a post into one of the many text-to-speech AI services like ElevenLabs Reader or Natural Reader and have it read the post for you :)
Edit: Many of you are asking for a repo so I will make an effort to get one up in the next couple days. All of this is a part of a work project at the moment, so I have to take some time to copy everything into a fresh project and scrub any identifying info. I will post the link here when it's up. You can also follow me and I will post it on my profile so you get notified. Thank you all for the kind comments. I'm happy to share this info with others since I don't get much chance to do so in my day-to-day.
Edit (final?): I bit the bullet and spent the afternoon getting a github repo up for you guys. Just made a post with some additional info here or you can go straight to the source:
π― Repository: https://github.com/diet103/claude-code-infrastructure-showcase
Disclaimer
I made a post about six months ago sharing my experience after a week of hardcore use with Claude Code. It's now been about six months of hardcore use, and I would like to share some more tips, tricks, and word vomit with you all. I may have went a little overboard here so strap in, grab a coffee, sit on the toilet or whatever it is you do when doom-scrolling reddit.
I want to start the post off with a disclaimer: all the content within this post is merely me sharing what setup is working best for me currently and should not be taken as gospel or the only correct way to do things. It's meant to hopefully inspire you to improve your setup and workflows with AI agentic coding. I'm just a guy, and this is just like, my opinion, man.
Also, I'm on the 20x Max plan, so your mileage may vary. And if you're looking for vibe-coding tips, you should look elsewhere. If you want the best out of CC, then you should be working together with it: planning, reviewing, iterating, exploring different approaches, etc.
Quick Overview
After 6 months of pushing Claude Code to its limits (solo rewriting 300k LOC), here's the system I built:
Skills that actually auto-activate when needed
Dev docs workflow that prevents Claude from losing the plot
PM2 + hooks for zero-errors-left-behind
Army of specialized agents for reviews, testing, and planning
Let's get into it.
Background
I'm a software engineer who has been working on production web apps for the last seven years or so. And I have fully embraced the wave of AI with open arms. I'm not too worried about AI taking my job anytime soon, as it is a tool that I use to leverage my capabilities. In doing so, I have been building MANY new features and coming up with all sorts of new proposal presentations put together with Claude and GPT-5 Thinking to integrate new AI systems into our production apps. Projects I would have never dreamt of having the time to even consider before integrating AI into my workflow. And with all that, I'm giving myself a good deal of job security and have become the AI guru at my job since everyone else is about a year or so behind on how they're integrating AI into their day-to-day.
With my newfound confidence, I proposed a pretty large redesign/refactor of one of our web apps used as an internal tool at work. This was a pretty rough college student-made project that was forked off another project developed by me as an intern (created about 7 years ago and forked 4 years ago). This may have been a bit overly ambitious of me since, to sell it to the stakeholders, I agreed to finish a top-down redesign of this fairly decent-sized project (~100k LOC) in a matter of a few months...all by myself. I knew going in that I was going to have to put in extra hours to get this done, even with the help of CC. But deep down, I know it's going to be a hit, automating several manual processes and saving a lot of time for a lot of people at the company.
It's now six months later... yeah, I probably should not have agreed to this timeline. I have tested the limits of both Claude as well as my own sanity trying to get this thing done. I completely scrapped the old frontend, as everything was seriously outdated and I wanted to play with the latest and greatest. I'm talkin' React 16 JS β React 19 TypeScript, React Query v2 β TanStack Query v5, React Router v4 w/ hashrouter β TanStack Router w/ file-based routing, Material UI v4 β MUI v7, all with strict adherence to best practices. The project is now at ~300-400k LOC and my life expectancy ~5 years shorter. It's finally ready to put up for testing, and I am incredibly happy with how things have turned out.
This used to be a project with insurmountable tech debt, ZERO test coverage, HORRIBLE developer experience (testing things was an absolute nightmare), and all sorts of jank going on. I addressed all of those issues with decent test coverage, manageable tech debt, and implemented a command-line tool for generating test data as well as a dev mode to test different features on the frontend. During this time, I have gotten to know CC's abilities and what to expect out of it.
A Note on Quality and Consistency
I've noticed a recurring theme in forums and discussions - people experiencing frustration with usage limits and concerns about output quality declining over time. I want to be clear up front: I'm not here to dismiss those experiences or claim it's simply a matter of "doing it wrong." Everyone's use cases and contexts are different, and valid concerns deserve to be heard.
That said, I want to share what's been working for me. In my experience, CC's output has actually improved significantly over the last couple of months, and I believe that's largely due to the workflow I've been constantly refining. My hope is that if you take even a small bit of inspiration from my system and integrate it into your CC workflow, you'll give it a better chance at producing quality output that you're happy with.
Now, let's be real - there are absolutely times when Claude completely misses the mark and produces suboptimal code. This can happen for various reasons. First, AI models are stochastic, meaning you can get widely varying outputs from the same input. Sometimes the randomness just doesn't go your way, and you get an output that's legitimately poor quality through no fault of your own. Other times, it's about how the prompt is structured. There can be significant differences in outputs given slightly different wording because the model takes things quite literally. If you misword or phrase something ambiguously, it can lead to vastly inferior results.
Sometimes You Just Need to Step In
Look, AI is incredible, but it's not magic. There are certain problems where pattern recognition and human intuition just win. If you've spent 30 minutes watching Claude struggle with something that you could fix in 2 minutes, just fix it yourself. No shame in that. Think of it like teaching someone to ride a bike, sometimes you just need to steady the handlebars for a second before letting go again.
I've seen this especially with logic puzzles or problems that require real-world common sense. AI can brute-force a lot of things, but sometimes a human just "gets it" faster. Don't let stubbornness or some misguided sense of "but the AI should do everything" waste your time. Step in, fix the issue, and keep moving.
I've had my fair share of terrible prompting, which usually happens towards the end of the day where I'm getting lazy and I'm not putting that much effort into my prompts. And the results really show. So next time you are having these kinds of issues where you think the output is way worse these days because you think Anthropic shadow-nerfed Claude, I encourage you to take a step back and reflect on how you are prompting.
Re-prompt often. You can hit double-esc to bring up your previous prompts and select one to branch from. You'd be amazed how often you can get way better results armed with the knowledge of what you don't want when giving the same prompt. All that to say, there can be many reasons why the output quality seems to be worse, and it's good to self-reflect and consider what you can do to give it the best possible chance to get the output you want.
As some wise dude somewhere probably said, "Ask not what Claude can do for you, ask what context you can give to Claude" ~ Wise Dude
Alright, I'm going to step down from my soapbox now and get on to the good stuff.
My System
I've implemented a lot changes to my workflow as it relates to CC over the last 6 months, and the results have been pretty great, IMO.
Skills Auto-Activation System (Game Changer!)
This one deserves its own section because it completely transformed how I work with Claude Code.
The Problem
So Anthropic releases this Skills feature, and I'm thinking "this looks awesome!" The idea of having these portable, reusable guidelines that Claude can reference sounded perfect for maintaining consistency across my massive codebase. I spent a good chunk of time with Claude writing up comprehensive skills for frontend development, backend development, database operations, workflow management, etc. We're talking thousands of lines of best practices, patterns, and examples.
And then... nothing. Claude just wouldn't use them. I'd literally use the exact keywords from the skill descriptions. Nothing. I'd work on files that should trigger the skills. Nothing. It was incredibly frustrating because I could see the potential, but the skills just sat there like expensive decorations.
The "Aha!" Moment
That's when I had the idea of using hooks. If Claude won't automatically use skills, what if I built a system that MAKES it check for relevant skills before doing anything?
So I dove into Claude Code's hook system and built a multi-layered auto-activation architecture with TypeScript hooks. And it actually works!
How It Works
I created two main hooks:
1. UserPromptSubmit Hook (runs BEFORE Claude sees your message):
Analyzes your prompt for keywords and intent patterns
Checks which skills might be relevant
Injects a formatted reminder into Claude's context
Now when I ask "how does the layout system work?" Claude sees a big "π― SKILL ACTIVATION CHECK - Use project-catalog-developer skill" (project catalog is a large complex data grid based feature on my front end) before even reading my question
2. Stop Event Hook (runs AFTER Claude finishes responding):
Analyzes which files were edited
Checks for risky patterns (try-catch blocks, database operations, async functions)
Displays a gentle self-check reminder
"Did you add error handling? Are Prisma operations using the repository pattern?"
Non-blocking, just keeps Claude aware without being annoying
skill-rules.json Configuration
I created a central configuration file that defines every skill with:
Keywords: Explicit topic matches ("layout", "workflow", "database")
Intent patterns: Regex to catch actions ("(create|add).*?(feature|route)")
File path triggers: Activates based on what file you're editing
Content triggers: Activates if file contains specific patterns (Prisma imports, controllers, etc.)
Example snippet:
{
"backend-dev-guidelines": {
"type": "domain",
"enforcement": "suggest",
"priority": "high",
"promptTriggers": {
"keywords": ["backend", "controller", "service", "API", "endpoint"],
"intentPatterns": [
"(create|add).*?(route|endpoint|controller)",
"(how to|best practice).*?(backend|API)"
]
},
"fileTriggers": {
"pathPatterns": ["backend/src/**/*.ts"],
"contentPatterns": ["router\\.", "export.*Controller"]
}
}
}The Results
Now when I work on backend code, Claude automatically:
Sees the skill suggestion before reading my prompt
Loads the relevant guidelines
Actually follows the patterns consistently
Self-checks at the end via gentle reminders
The difference is night and day. No more inconsistent code. No more "wait, Claude used the old pattern again." No more manually telling it to check the guidelines every single time.
Following Anthropic's Best Practices (The Hard Way)
After getting the auto-activation working, I dove deeper and found Anthropic's official best practices docs. Turns out I was doing it wrong because they recommend keeping the main SKILL.md file under 500 lines and using progressive disclosure with resource files.
Whoops. My frontend-dev-guidelines skill was 1,500+ lines. And I had a couple other skills over 1,000 lines. These monolithic files were defeating the whole purpose of skills (loading only what you need).
So I restructured everything:
frontend-dev-guidelines: 398-line main file + 10 resource files
backend-dev-guidelines: 304-line main file + 11 resource files
Now Claude loads the lightweight main file initially, and only pulls in detailed resource files when actually needed. Token efficiency improved 40-60% for most queries.
Skills I've Created
Here's my current skill lineup:
Guidelines & Best Practices:
backend-dev-guidelines- Routes β Controllers β Services β Repositoriesfrontend-dev-guidelines- React 19, MUI v7, TanStack Query/Router patternsskill-developer- Meta-skill for creating more skills
Domain-Specific:
workflow-developer- Complex workflow engine patternsnotification-developer- Email/notification systemdatabase-verification- Prevent column name errors (this one is a guardrail that actually blocks edits!)project-catalog-developer- DataGrid layout system
All of these automatically activate based on what I'm working on. It's like having a senior dev who actually remembers all the patterns looking over Claude's shoulder.
Why This Matters
Before skills + hooks:
Claude would use old patterns even though I documented new ones
Had to manually tell Claude to check BEST_PRACTICES.md every time
Inconsistent code across the 300k+ LOC codebase
Spent too much time fixing Claude's "creative interpretations"
After skills + hooks:
Consistent patterns automatically enforced
Claude self-corrects before I even see the code
Can trust that guidelines are being followed
Way less time spent on reviews and fixes
If you're working on a large codebase with established patterns, I cannot recommend this system enough. The initial setup took a couple of days to get right, but it's paid for itself ten times over.
CLAUDE.md and Documentation Evolution
In a post I wrote 6 months ago, I had a section about rules being your best friend, which I still stand by. But my CLAUDE.md file was quickly getting out of hand and was trying to do too much. I also had this massive BEST_PRACTICES.md file (1,400+ lines) that Claude would sometimes read and sometimes completely ignore.
So I took an afternoon with Claude to consolidate and reorganize everything into a new system. Here's what changed:
What Moved to Skills
Previously, BEST_PRACTICES.md contained:
TypeScript standards
React patterns (hooks, components, suspense)
Backend API patterns (routes, controllers, services)
Error handling (Sentry integration)
Database patterns (Prisma usage)
Testing guidelines
Performance optimization
All of that is now in skills with the auto-activation hook ensuring Claude actually uses them. No more hoping Claude remembers to check BEST_PRACTICES.md.
What Stayed in CLAUDE.md
Now CLAUDE.md is laser-focused on project-specific info (only ~200 lines):
Quick commands (
pnpm pm2:start,pnpm build, etc.)Service-specific configuration
Task management workflow (dev docs system)
Testing authenticated routes
Workflow dry-run mode
Browser tools configuration
The New Structure
Root CLAUDE.md (100 lines) βββ Critical universal rules βββ Points to repo-specific claude.md files βββ References skills for detailed guidelines Each Repo's claude.md (50-100 lines) βββ Quick Start section pointing to: β βββ PROJECT_KNOWLEDGE.md - Architecture & integration β βββ TROUBLESHOOTING.md - Common issues β βββ Auto-generated API docs βββ Repo-specific quirks and commands
The magic: Skills handle all the "how to write code" guidelines, and CLAUDE.md handles "how this specific project works." Separation of concerns for the win.
Dev Docs System
This system, out of everything (besides skills), I think has made the most impact on the results I'm getting out of CC. Claude is like an extremely confident junior dev with extreme amnesia, losing track of what they're doing easily. This system is aimed at solving those shortcomings.
The dev docs section from my CLAUDE.md:
### Starting Large Tasks When exiting plan mode with an accepted plan: 1.**Create Task Directory**: mkdir -p ~/git/project/dev/active/[task-name]/ 2.**Create Documents**: - `[task-name]-plan.md` - The accepted plan - `[task-name]-context.md` - Key files, decisions - `[task-name]-tasks.md` - Checklist of work 3.**Update Regularly**: Mark tasks complete immediately ### Continuing Tasks - Check `/dev/active/` for existing tasks - Read all three files before proceeding - Update "Last Updated" timestamps
These are documents that always get created for every feature or large task. Before using this system, I had many times when I all of a sudden realized that Claude had lost the plot and we were no longer implementing what we had planned out 30 minutes earlier because we went off on some tangent for whatever reason.
My Planning Process
My process starts with planning. Planning is king. If you aren't at a minimum using planning mode before asking Claude to implement something, you're gonna have a bad time, mmm'kay. You wouldn't have a builder come to your house and start slapping on an addition without having him draw things up first.
When I start planning a feature, I put it into planning mode, even though I will eventually have Claude write the plan down in a markdown file. I'm not sure putting it into planning mode necessary, but to me, it feels like planning mode gets better results doing the research on your codebase and getting all the correct context to be able to put together a plan.
I created a strategic-plan-architect subagent that's basically a planning beast. It:
Gathers context efficiently
Analyzes project structure
Creates comprehensive structured plans with executive summary, phases, tasks, risks, success metrics, timelines
Generates three files automatically: plan, context, and tasks checklist
But I find it really annoying that you can't see the agent's output, and even more annoying is if you say no to the plan, it just kills the agent instead of continuing to plan. So I also created a custom slash command (/dev-docs) with the same prompt to use on the main CC instance.
Once Claude spits out that beautiful plan, I take time to review it thoroughly. This step is really important. Take time to understand it, and you'd be surprised at how often you catch silly mistakes or Claude misunderstanding a very vital part of the request or task.
More often than not, I'll be at 15% context left or less after exiting plan mode. But that's okay because we're going to put everything we need to start fresh into our dev docs. Claude usually likes to just jump in guns blazing, so I immediately slap the ESC key to interrupt and run my /dev-docs slash command. The command takes the approved plan and creates all three files, sometimes doing a bit more research to fill in gaps if there's enough context left.
And once I'm done with that, I'm pretty much set to have Claude fully implement the feature without getting lost or losing track of what it was doing, even through an auto-compaction. I just make sure to remind Claude every once in a while to update the tasks as well as the context file with any relevant context. And once I'm running low on context in the current session, I just run my slash command /update-dev-docs. Claude will note any relevant context (with next steps) as well as mark any completed tasks or add new tasks before I compact the conversation. And all I need to say is "continue" in the new session.
During implementation, depending on the size of the feature or task, I will specifically tell Claude to only implement one or two sections at a time. That way, I'm getting the chance to go in and review the code in between each set of tasks. And periodically, I have a subagent also reviewing the changes so I can catch big mistakes early on. If you aren't having Claude review its own code, then I highly recommend it because it saved me a lot of headaches catching critical errors, missing implementations, inconsistent code, and security flaws.
PM2 Process Management (Backend Debugging Game Changer)
This one's a relatively recent addition, but it's made debugging backend issues so much easier.
The Problem
My project has seven backend microservices running simultaneously. The issue was that Claude didn't have access to view the logs while services were running. I couldn't just ask "what's going wrong with the email service?" - Claude couldn't see the logs without me manually copying and pasting them into chat.
The Intermediate Solution
For a while, I had each service write its output to a timestamped log file using a devLog script. This worked... okay. Claude could read the log files, but it was clunky. Logs weren't real-time, services wouldn't auto-restart on crashes, and managing everything was a pain.
The Real Solution: PM2
Then I discovered PM2, and it was a game changer. I configured all my backend services to run via PM2 with a single command: pnpm pm2:start
What this gives me:
Each service runs as a managed process with its own log file
Claude can easily read individual service logs in real-time
Automatic restarts on crashes
Real-time monitoring with
pm2 logsMemory/CPU monitoring with
pm2 monitEasy service management (
pm2 restart email,pm2 stop all, etc.)
PM2 Configuration:
// ecosystem.config.jsmodule.exports = {
apps: [
{
name: 'form-service',
script: 'npm',
args: 'start',
cwd: './form',
error_file: './form/logs/error.log',
out_file: './form/logs/out.log',
},
// ... 6 more services
]
};Before PM2:
Me: "The email service is throwing errors" Me: [Manually finds and copies logs] Me: [Pastes into chat] Claude: "Let me analyze this..."
The debugging workflow now:
Me: "The email service is throwing errors" Claude: [Runs] pm2 logs email --lines 200 Claude: [Reads the logs] "I see the issue - database connection timeout..." Claude: [Runs] pm2 restart email Claude: "Restarted the service, monitoring for errors..."
Night and day difference. Claude can autonomously debug issues now without me being a human log-fetching service.
One caveat: Hot reload doesn't work with PM2, so I still run the frontend separately with pnpm dev. But for backend services that don't need hot reload as often, PM2 is incredible.
Hooks System (#NoMessLeftBehind)
The project I'm working on is multi-root and has about eight different repos in the root project directory. One for the frontend and seven microservices and utilities for the backend. I'm constantly bouncing around making changes in a couple of repos at a time depending on the feature.
And one thing that would annoy me to no end is when Claude forgets to run the build command in whatever repo it's editing to catch errors. And it will just leave a dozen or so TypeScript errors without me catching it. Then a couple of hours later I see Claude running a build script like a good boy and I see the output: "There are several TypeScript errors, but they are unrelated, so we're all good here!"
No, we are not good, Claude.
Hook #1: File Edit Tracker
First, I created a post-tool-use hook that runs after every Edit/Write/MultiEdit operation. It logs:
Which files were edited
What repo they belong to
Timestamps
Initially, I made it run builds immediately after each edit, but that was stupidly inefficient. Claude makes edits that break things all the time before quickly fixing them.
Hook #2: Build Checker
Then I added a Stop hook that runs when Claude finishes responding. It:
Reads the edit logs to find which repos were modified
Runs build scripts on each affected repo
Checks for TypeScript errors
If < 5 errors: Shows them to Claude
If β₯ 5 errors: Recommends launching auto-error-resolver agent
Logs everything for debugging
Since implementing this system, I've not had a single instance where Claude has left errors in the code for me to find later. The hook catches them immediately, and Claude fixes them before moving on.
Hook #3: Prettier Formatter
This one's simple but effective. After Claude finishes responding, automatically format all edited files with Prettier using the appropriate .prettierrc config for that repo.
No more going into to manually edit a file just to have prettier run and produce 20 changes because Claude decided to leave off trailing commas last week when we created that file.
β οΈ Update: I No Longer Recommend This Hook
After publishing, a reader shared detailed data showing that file modifications trigger <system-reminder> notifications that can consume significant context tokens. In their case, Prettier formatting led to 160k tokens consumed in just 3 rounds due to system-reminders showing file diffs.
While the impact varies by project (large files and strict formatting rules are worst-case scenarios), I'm removing this hook from my setup. It's not a big deal to let formatting happen when you manually edit files anyway, and the potential token cost isn't worth the convenience.
If you want automatic formatting, consider running Prettier manually between sessions instead of during Claude conversations.
Hook #4: Error Handling Reminder
This is the gentle philosophy hook I mentioned earlier:
Analyzes edited files after Claude finishes
Detects risky patterns (try-catch, async operations, database calls, controllers)
Shows a gentle reminder if risky code was written
Claude self-assesses whether error handling is needed
No blocking, no friction, just awareness
Example output:
βββββββββββββββββββββββββββββββββββββββ
π ERROR HANDLING SELF-CHECK
βββββββββββββββββββββββββββββββββββββββ
β οΈ Backend Changes Detected
2 file(s) edited
β Did you add Sentry.captureException() in catch blocks?
β Are Prisma operations wrapped in error handling?
π‘ Backend Best Practice:
- All errors should be captured to Sentry
- Controllers should extend BaseController
βββββββββββββββββββββββββββββββββββββββThe Complete Hook Pipeline
Here's what happens on every Claude response now:
Claude finishes responding β Hook 1: Prettier formatter runs β All edited files auto-formatted β Hook 2: Build checker runs β TypeScript errors caught immediately β Hook 3: Error reminder runs β Gentle self-check for error handling β If errors found β Claude sees them and fixes β If too many errors β Auto-error-resolver agent recommended β Result: Clean, formatted, error-free code
And the UserPromptSubmit hook ensures Claude loads relevant skills BEFORE even starting work.
No mess left behind. It's beautiful.
Scripts Attached to Skills
One really cool pattern I picked up from Anthropic's official skill examples on GitHub: attach utility scripts to skills.
For example, my backend-dev-guidelines skill has a section about testing authenticated routes. Instead of just explaining how authentication works, the skill references an actual script:
### Testing Authenticated Routes Use the provided test-auth-route.js script: node scripts/test-auth-route.js http://localhost:3002/api/endpoint
The script handles all the complex authentication steps for you:
Gets a refresh token from Keycloak
Signs the token with JWT secret
Creates cookie header
Makes authenticated request
When Claude needs to test a route, it knows exactly what script to use and how to use it. No more "let me create a test script" and reinventing the wheel every time.
I'm planning to expand this pattern - attach more utility scripts to relevant skills so Claude has ready-to-use tools instead of generating them from scratch.
Tools and Other Things
SuperWhisper on Mac
Voice-to-text for prompting when my hands are tired from typing. Works surprisingly well, and Claude understands my rambling voice-to-text surprisingly well.
Memory MCP
I use this less over time now that skills handle most of the "remembering patterns" work. But it's still useful for tracking project-specific decisions and architectural choices that don't belong in skills.
BetterTouchTool
Relative URL copy from Cursor (for sharing code references)
I have VSCode open to more easily find the files Iβm looking for and I can double tap CAPS-LOCK, then BTT inputs the shortcut to copy relative URL, transforms the clipboard contents by prepending an β@β symbol, focuses the terminal, and then pastes the file path. All in one.
Double-tap hotkeys to quickly focus apps (CMD+CMD = Claude Code, OPT+OPT = Browser)
Custom gestures for common actions
Honestly, the time savings on just not fumbling between apps is worth the BTT purchase alone.
Scripts for Everything
If there's any annoying tedious task, chances are there's a script for that:
Command-line tool to generate mock test data. Before using Claude code, it was extremely annoying to generate mock data because I would have to make a submission to a form that had about a 120 questions Just to generate one single test submission.
Authentication testing scripts (get tokens, test routes)
Database resetting and seeding
Schema diff checker before migrations
Automated backup and restore for dev database
Pro tip: When Claude helps you write a useful script, immediately document it in CLAUDE.md or attach it to a relevant skill. Future you will thank past you.
Documentation (Still Important, But Evolved)
I think next to planning, documentation is almost just as important. I document everything as I go in addition to the dev docs that are created for each task or feature. From system architecture to data flow diagrams to actual developer docs and APIs, just to name a few.
But here's what changed: Documentation now works WITH skills, not instead of them.
Skills contain: Reusable patterns, best practices, how-to guides Documentation contains: System architecture, data flows, API references, integration points
For example:
"How to create a controller" β backend-dev-guidelines skill
"How our workflow engine works" β Architecture documentation
"How to write React components" β frontend-dev-guidelines skill
"How notifications flow through the system" β Data flow diagram + notification skill
I still have a LOT of docs (850+ markdown files), but now they're laser-focused on project-specific architecture rather than repeating general best practices that are better served by skills.
You don't necessarily have to go that crazy, but I highly recommend setting up multiple levels of documentation. Ones for broad architectural overview of specific services, wherein you'll include paths to other documentation that goes into more specifics of different parts of the architecture. It will make a major difference on Claude's ability to easily navigate your codebase.
Prompt Tips
When you're writing out your prompt, you should try to be as specific as possible about what you are wanting as a result. Once again, you wouldn't ask a builder to come out and build you a new bathroom without at least discussing plans, right?
"You're absolutely right! Shag carpet probably is not the best idea to have in a bathroom."
Sometimes you might not know the specifics, and that's okay. If you don't ask questions, tell Claude to research and come back with several potential solutions. You could even use a specialized subagent or use any other AI chat interface to do your research. The world is your oyster. I promise you this will pay dividends because you will be able to look at the plan that Claude has produced and have a better idea if it's good, bad, or needs adjustments. Otherwise, you're just flying blind, pure vibe-coding. Then you're gonna end up in a situation where you don't even know what context to include because you don't know what files are related to the thing you're trying to fix.
Try not to lead in your prompts if you want honest, unbiased feedback. If you're unsure about something Claude did, ask about it in a neutral way instead of saying, "Is this good or bad?" Claude tends to tell you what it thinks you want to hear, so leading questions can skew the response. It's better to just describe the situation and ask for thoughts or alternatives. That way, you'll get a more balanced answer.
Agents, Hooks, and Slash Commands (The Holy Trinity)
Agents
I've built a small army of specialized agents:
Quality Control:
code-architecture-reviewer- Reviews code for best practices adherencebuild-error-resolver- Systematically fixes TypeScript errorsrefactor-planner- Creates comprehensive refactoring plans
Testing & Debugging:
auth-route-tester- Tests backend routes with authenticationauth-route-debugger- Debugs 401/403 errors and route issuesfrontend-error-fixer- Diagnoses and fixes frontend errors
Planning & Strategy:
strategic-plan-architect- Creates detailed implementation plansplan-reviewer- Reviews plans before implementationdocumentation-architect- Creates/updates documentation
Specialized:
frontend-ux-designer- Fixes styling and UX issuesweb-research-specialist- Researches issues along with many other things on the webreactour-walkthrough-designer- Creates UI tours
The key with agents is to give them very specific roles and clear instructions on what to return. I learned this the hard way after creating agents that would go off and do who-knows-what and come back with "I fixed it!" without telling me what they fixed.
Hooks (Covered Above)
The hook system is honestly what ties everything together. Without hooks:
Skills sit unused
Errors slip through
Code is inconsistently formatted
No automatic quality checks
With hooks:
Skills auto-activate
Zero errors left behind
Automatic formatting
Quality awareness built-in
Slash Commands
I have quite a few custom slash commands, but these are the ones I use most:
Planning & Docs:
/dev-docs- Create comprehensive strategic plan/dev-docs-update- Update dev docs before compaction/create-dev-docs- Convert approved plan to dev doc files
Quality & Review:
/code-review- Architectural code review/build-and-fix- Run builds and fix all errors
Testing:
/route-research-for-testing- Find affected routes and launch tests/test-route- Test specific authenticated routes
The beauty of slash commands is they expand into full prompts, so you can pack a ton of context and instructions into a simple command. Way better than typing out the same instructions every time.
Conclusion
After six months of hardcore use, here's what I've learned:
The Essentials:
Plan everything - Use planning mode or strategic-plan-architect
Skills + Hooks - Auto-activation is the only way skills actually work reliably
Dev docs system - Prevents Claude from losing the plot
Code reviews - Have Claude review its own work
PM2 for backend - Makes debugging actually bearable
The Nice-to-Haves:
Specialized agents for common tasks
Slash commands for repeated workflows
Comprehensive documentation
Utility scripts attached to skills
Memory MCP for decisions
And that's about all I can think of for now. Like I said, I'm just some guy, and I would love to hear tips and tricks from everybody else, as well as any criticisms. Because I'm always up for improving upon my workflow. I honestly just wanted to share what's working for me with other people since I don't really have anybody else to share this with IRL (my team is very small, and they are all very slow getting on the AI train).
If you made it this far, thanks for taking the time to read. If you have questions about any of this stuff or want more details on implementation, happy to share. The hooks and skills system especially took some trial and error to get right, but now that it's working, I can't imagine going back.
TL;DR: Built an auto-activation system for Claude Code skills using TypeScript hooks, created a dev docs workflow to prevent context loss, and implemented PM2 + automated error checking. Result: Solo rewrote 300k LOC in 6 months with consistent quality.
Hey everyone, mostly a lurker but I've used claude code for a week now, and have upgraded to the max subscription tier but I'm still wondering on how to actually setup a project properly, vibecoding and all.
I have a website I've made, its prospects are kind of wanting to be a functioning website, signup/login features and what not but the code has turned a mess lol and I want to restart but properly.
Does anyone have a comprehensive guide on doing so? I will be setting up my project on github and using git for pull/push requests - still a newbie, but someone mentioned github actions which kind of intrigued me.
And of course theres also problems of claude just not listening, ive added gemini MCP but that disconnects every now and then - not sure if anyone else had that problem, restarting claude fixes it but I just have a lot of code smells, I have added commands of /project:changes and /project:restore but it feels like they do nothing, claude barely listens to my standards and security headlines which are clearly listed in the CLAUDE.md file.
I just need help ya'll
Hi everyone,
Iβm moving from Cursor to Claude Code, and Iβd love to hear about your setup recommendations.
With Cursor, everything comes bundled in one app, but now Iβm running Claude Code in the terminal. How do you handle things like autocomplete and other features?
Do you stick with Cursor on the minimum plan, use something like Continue.dev, or another setup entirely? Iβd really appreciate hearing your ideas and experiences.
Thanks!
I feel like I'm not using Claude Code to it's potential! I've only just discovered "Happy Engineering" to use Claude on my phone/tablet and don't really use many MCP Servers or other. I'm developing a bunch of things from web applications to agents in LangChain and Claude has been a trusty servent but I'm wanting to take it to the next level.
The only plugin I've ever used is this to break down specs - https://github.com/pimzino/claude-code-spec-workflow?tab=readme-ov-file#readme I'm not using any agents currently above and beyond what this plugin installs.
I've since found through this website a directory of Claude Goodness - https://www.claude-hub.com/ and one of the first things listed is something called Claude-Flow which looks like an impressive amount of confusion - ruvnet/claude-flow: π The leading agent orchestration platform for Claude. Deploy intelligent multi-agent swarms, coordinate autonomous workflows, and build conversational AI systems. Features enterprise-grade architecture, distributed swarm intelligence, RAG integration, and native Claude Code support via MCP protocol. Ranked #1 in agent-based frameworks. looks like it might be powerful, have no idea what the docs are telling me though.
I pay for Claude Max so I'm not too concerned about token usage, I only work on one project at a time.
I wanted to ask the community what setups you have and what you would describe as a much needed tool, plugin or MCP server?
Hi everyone! Iβve been using claude-code-cli quite a lot lately and I really like the workflow, but with a Pro account, Iβm hitting the 5-hour usage limit much faster than expected. -_-
I mostly use it for:
refactoring
bug fixing
planning and implementing new features
I suspect Iβm wasting tokens in ways I donβt fully realize... so I wanted to ask the community:
Do you have practical tricks or good habits to reduce unnecessary token usage?
Any prompting strategies that work well?
Ways to avoid re-sending too much context every time?
CLI flags, workflows, or tooling that helped you stay within limits?
Things you stopped doing once you noticed they were token-expensive?
Thanks in advance!
Hey everyone!
I'm starting a new fullstack web project from scratch - still in the design phase with just high-level specs, no code yet. Want to use Claude Code from the beginning but not sure about the best approach.
Anyone have experience with this? Looking for advice on:
How to configure Claude Code when you're starting with zero codebase
Which MCP servers are actually useful during the planning/architecture phase
Any tools or workflows that work well for going from specs to code with Claude
Best practices for fullstack development (backend APIs, frontend, database design, etc.)
I've seen people mention different MCP servers but most tutorials assume you already have a project running. Since I'll be handling both frontend and backend, wondering if there are specific setups that help Claude understand the full architecture better.
What's your setup when using Claude Code for greenfield fullstack projects?
Thanks!