Live data from Hacker News

Anatomy of the .claude/ folder

blog.dailydoseofds.com

171–180 of 312 posts

Re: Anatomy of the .claude/ folder

#171

Earlier quoted context omitted.

I agree with most of this, with one important exception: you should have some form of sandboxing in place before running any local AI agent. The easiest way to do that is with .claude/settings.json[0]. This is important no matter how experienced you are, but arguable the most important when you don't know what you're doing. 0: or if you don't want to learn about that, you can use Claude Code Web

Do people really run claude and other clis like this outside a container??

I'm sure most folks run Claude without isolation or sandboxing. It's a terrible idea, but even most professional software developers don't think much about security.

There many decent options (cloud VMs, local VMs, Docker, the built-in sandboxing). My point is just that folks should research and set up at least one of them before running an agent.

Re: Anatomy of the .claude/ folder

#173
post #83
post #62

The claim that "whatever you write in CLAUDE.md, Claude will follow" is doing a lot of heavy lifting. In practice CLAUDE.md is a suggestion, not a contract. Complex tasks and compaction will dilute the use of CLAUDE.md, especially once the context window runs out.

This is correct. All of these .md files are just blobs of text that the LLM matches against. They might increase the likelihood of something happening or not happening. They look to me like people actually want to build deterministic workflows, but blobs of text are the wrong approach for that. The right tool is code that controls the agent through specific states and validates the tool calls step by step.

That's not quite right. Claude treats certain md files very differently from others. See eg

https://claudefa.st/blog/guide/mechanics/claude-md-mastery

Re: Anatomy of the .claude/ folder

#174
I keep seeing these posts, and here's the most interesting thing, for me.

I get the best results with the least number of skills and unnecessary configuration in place.

People are spending way too much time over-prescribing these documents, but AI is like a competent but nervous adult. The more you give it, the dumber it gets.

Re: Anatomy of the .claude/ folder

#175

Earlier quoted context omitted.

Issue is that both harness and specific model matters a lot in what type of instruction works best, if you were to use Anthrophic's models together with the best way to do prompting with Codex and GPT models, you'd get a lot worse results compared to if you use GPT models with Codex, prompted in the way GPTs react best to them. I don't think people realize exactly how important the specific prompts are, with the same…

Having experimented with soft-linking AGENTS.md into CLAUDE.md and GEMINI.md, this lines up well with my experience. I now just let each time maintain it's own files and don't try to combine them. If it's something like my custom "## Agent Instructions" then I just copy-pasta and it's not been hard, and since that section is mostly identical I just treat AGENTS.md as the canonical and copy/paste any changes over to t…

If you create a CLAUDE.md with contents of @AGENTS.md that works and has the added benefit of allowing Claude specific instructions too, to be added below.

Re: Anatomy of the .claude/ folder

#176
post #132

Building your AI agent "toolkit" is becoming the equivalent of the perfect "productivity" setup where you spend your time reading blog posts, watching YouTube videos telling you how to be productive and creating habits and rituals...only to be overtaken by a person with a simple paper list of tasks that they work through. Plain Claude, ask it to write a plan, review plan, then tell it to execute still works the best…

Let me give you a counterexample. I'm working on a product for the national market, and i need to do all financial tasks, invoicing, submit to national fiscal databse etc. through a local accounting firm. So i integrate their API in the backend; this is a 100% custom API developed by this small european firm, with a few dozen restful enpoints supporting various accounting operations, and I need to use it programmatically to maintain sync for legal compliance. No LLM ever heard of it. It has a few hundred KB of HTML documentation that Claude can ingest perfectly fine and generate a curl command for, but i don't want to blow my token use and context on every interaction.

So I naturally felt the need to (tell Claude to) build a MCP for this accounting API, and now I ask it to do accounting tasks, and then it just does them. It's really ducking sweet.

Another thing I did was, after a particularly grueling accounting month close out, I've told Claude to extract the general tasks that we accomplished, and build a skill that does it at the end of the month, and now it's like having a junior accountant in at my disposal - it just DOES the things a professional would charge me thousands for.

So both custom project MCPs and skills are super useful in my experience.

Re: Anatomy of the .claude/ folder

#177
post #54

Earlier quoted context omitted.

Are there any good guides on how to write prompt files tailored to different agents? Would also be interested in examples of a CLAUDE.md file that works well in Claude, but works poorly with Codex.

Why would you settle for a guide when you can get a claude skill to do it for you? https://github.com/nidhinjs/prompt-master

Because that just does it for you, it doesn't help me understand how to write better prompts.

Actually, I can just read the skill with my own eyes and then I can also learn. So, thank you for sharing. It's interesting to read through what it suggests for different models - it fits for the ones I work with regularly, but there are many I don't know the strengths and weaknesses of.

Re: Anatomy of the .claude/ folder

#178
post #122

Earlier quoted context omitted.

Seriously, just use plan mode first and you get like 90% of the way there, with CC launching subagents that will generally do the right thing anyway. IMHO most of this “customize your config to be more productive” stuff will go away within a year, obsoleted by improved models and harnesses. Just like how all the lessons for how to use LLMs in code from 1-2 years ago are already long forgotten.

I loved all the dumb prompt “hacks” back then like “try saying please”

Modern "skills" and Markdown formats of the day are no different than "save the kittens". All of these practices are promoted by influencers and adopted based on wishful thinking and anecdata.

Re: Anatomy of the .claude/ folder

#179
post #132

Building your AI agent "toolkit" is becoming the equivalent of the perfect "productivity" setup where you spend your time reading blog posts, watching YouTube videos telling you how to be productive and creating habits and rituals...only to be overtaken by a person with a simple paper list of tasks that they work through. Plain Claude, ask it to write a plan, review plan, then tell it to execute still works the best…

This resonates with me. Sometimes I build up some artifacts within the context of a task, but these almost always get thrown away. There are primarily three reason I prefer a vanilla setup. 1. I have many and sometimes contradictory workflows: exploration, prototyping, bug fixing debugging, feature work, pr management, etc. When I'm prototyping, I want reward hacking, I don't care about tests or lint's, and it's the…

[flagged]

Re: Anatomy of the .claude/ folder

#180
post #178

Earlier quoted context omitted.

I loved all the dumb prompt “hacks” back then like “try saying please”

Modern "skills" and Markdown formats of the day are no different than "save the kittens". All of these practices are promoted by influencers and adopted based on wishful thinking and anecdata.

Uh, this couldn't be more false. I've implemented these from scratch at my company and rolled them out org-wide and I've yet to watch a youtube video and don't consume any influencers. Mostly by just using the tools and reading documentation - as any other technical tool.

Perhaps your blanket statement could be wrong, and I would encourage you to let your mind be a bit more open. The landscape here is not what it was 6 months ago. This is an undeniable fact that people are going to have to come to terms with pretty soon. I did not want to be in this spot, I was forced to out of necessity, because the stuff does work.

Post reply on HN