@bitforgehq/ai-instructions
v1.1.3
Published
AI coding instruction files and CLI for syncing standards
Readme
@bitforgehq/ai-instructions
AI coding instruction files, IDE rules, and CLI tool for syncing standards to consumer projects.
Installation
bun add -D @bitforgehq/ai-instructionsUsage
CLI Tool
The standards CLI syncs two things to your project:
- Instructions (
AI_GUIDE.md) →.ai/folder - IDE rules (e.g. Cursor rules) → IDE-specific directories
Web Projects
bunx standards sync-ai --type webIonic Projects
bunx standards sync-ai --type ionicControlling IDE Rules
By default, rules for all supported IDEs are synced. Use --ide to target a specific one:
# Sync only Cursor rules
bunx standards sync-ai --type web --ide cursor
# Explicitly sync all IDE rules
bunx standards sync-ai --type web --ide allPackage.json Script
Add to your package.json:
{
"scripts": {
"standards:sync": "standards sync-ai --type web"
}
}For Ionic projects:
{
"scripts": {
"standards:sync": "standards sync-ai --type ionic"
}
}Then run:
bun run standards:syncWhat Gets Synced
Instructions → .ai/
AI_GUIDE.md— Comprehensive engineering principles and guidelines
IDE Rules
Rules are synced to each IDE's expected directory:
| IDE | Target directory | Files |
| ------- | ------------------ | ----------------------------- |
| Cursor | .cursor/rules/ | cursor-instructions.mdc |
| Claude | . (project root) | CLAUDE.md |
| GitHub | .github/ | copilot-instructions.md |
More IDEs can be added in the future (Windsurf, etc.) by adding rule files under rules/<ide>/.
Adding Rules for a New IDE
To add support for a new IDE:
- Create a directory under
rules/<ide-name>/with the rule files in whatever format that IDE expects - Register the IDE in
bin/standards.jsby adding an entry to theIDE_TARGETSmap with thesourceDirandtargetDir - That's it — the CLI will pick it up automatically
Updating
To update standards in your project, run the sync command again. All files are overwritten with the latest versions.
Examples
See examples/consumer-web/ and examples/consumer-ionic/ for complete setup examples.
