Dev.to AI 🤖 Ai 👁 0

I got tired of repeating the same AI coding instructions, so I built ai-rules

I’ve been using AI coding agents more and more, and one thing kept annoying me: I was repeating the same instructions every session. Things like: keep diffs small don’t fetch data directly inside React components follo

I’ve been using AI coding agents more and more, and one thing kept annoying me:
I was repeating the same instructions every session.
Things like:

  • keep diffs small
  • don’t fetch data directly inside React components
  • follow the existing architecture
  • add tests when behavior changes
  • don’t introduce new patterns unless needed
  • explain risky changes before making them At first, I handled this with big instruction files like AGENTS.md. That works for a while, but it has two problems:
  • The file keeps growing.
  • Most of the instructions are irrelevant to the current task. If I’m asking the agent to change a React component, it probably doesn’t need my rules about commit messages, backend handlers, database migrations, or release notes. And if I work across multiple projects, I either copy those instructions around or rewrite them again. So I built ai-rules. ## What ai-rules does ai-rules is a small local-first CLI for personal AI coding rules. Rules live as Markdown files in:

bash
~/.config/ai-rules/rules/
📰 Read the original article on Dev.to AI

Originally published by Dev.to AI. Aggregated on AIWithGhost for educational purposes — full credit and traffic to the original publisher.