Why Prickles
— Terry Pratchett

One canon. Every codebase.

Software craft principles too prickly to b*gger up — in any language, by any developer, with any tool.

§1

Why Prickles?

Two reasons.

  1. I like hedgehogs. My wife loves hedgehogs — she used to work at the Shepreth Hedgehog Hospital , who do good work. Support them if you can.
  2. Hedgehogs are prickly — and code rules should be too. They should spike you if you mistreat them. The collective noun for a group of hedgehogs is a prickle.

    One prickle (pillar) is a group of tenets (hedgehogs), so this site is many Prickles! You see what I did there? 😂

§2

Why now?

After decades of mentoring engineers, the conversation has always been the same:

  • Name this so it says what it does
  • Remove the comment
  • Split this function
  • Move this to where it belongs
  • Etc

None of it is new — some of these ideas have been around for fifty years — but the audience just changed.

Welcome to the team, our new junior developer: the LLM. What is this new team member trained on? Decades of code written without best practice in mind, by millions of developers, and whacked on the internet. What do we end up with? Code that hangs together — and immediate technical debt. How do we solve it? Prickles.

§3

What's here?

All the coding concepts that have helped me in my career and are now helping me use LLMs effectively. Each tenet is one I've been using, backed up with research, references, counter-arguments, and examples.

With these in place and enforced correctly, I'm getting code that's right first time, without PR iterations and wasted effort. I hope you will too.

Each pillar (prickle) of tenets (hedgehogs) is categorised so you can find what you need. If you don't agree, or want to dig deeper, there should be enough here to convince you. If you still don't agree, discuss it here. I'm happy to learn when I'm wrong and update the canon. This is a living spec; it changes as LLMs do.

§4

What isn't here?

No design patterns — refactoring.guru and others have already done that incredibly well. No engagement bait, no judgement, and no paywalls. Just a single place to store a helpful canon of information for using AI better.

If you can chip in toward the hosting and the LLM bills that produce this, please do. That's it.

§5

Where to start?

Go to the home page, click on the Foundations pillar (prickle), and start reading.

Don't want to read? Go to the implementation page and follow the instructions for your use case. I'd strongly recommend reading at least a little, though — it will help in the long run.

§6

Have feedback?

If you disagree with anything, let me know. The canon is an evolving document and can change. I just need a good reason.