AgentStack
Browse Sign in
Browse Why AgentStack Sell Docs
Sign in
SKILL verified MIT Self-run

Rule Writing

skill-bcgen-skills-rule-writing · by BCGen

Creates, edits, or removes a single project rule in the agent's native rule format, enforcing a non-discoverability admission filter and a hard rule budget with provenance stamping. Use when the user asks to add, change, or delete a project rule, or when another skill hands over a drafted rule.

No reviews yet
0 installs
44 views
0.0% view→install

Install

$ agentstack add skill-bcgen-skills-rule-writing

✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

View the full security report →

Verified badge

Passed review? Show it. Paste this badge into your README, it links to the public security report.

AgentStack Verified badge Links to your public security report.
[![AgentStack Verified](https://agentstack.voostack.com/badges/verified.svg)](https://agentstack.voostack.com/security/report/skill-bcgen-skills-rule-writing)

Reliability & compatibility

Security review passed
0 installs to date
no reviews yet
2mo ago

Declared compatibility

Claude CodeClaude Desktop

Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.

Preview Execution monitoring

We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.

How agent discovery & health will work →
Are you the author of Rule Writing? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

Rule Writing

The single write path for rule files. One invocation = one rule added, edited, or removed. Full format details, budgets, and dialect mapping live in [references/rule-format-spec.md](references/rule-format-spec.md) — read it before writing.

Step 1 — Understand the request

Collect: the rule text (draft from the user or a calling skill), its scope (project-wide or specific paths), and its evidence. If the intent is unclear, ask one question with a recommended answer.

Step 2 — Admission filter

Reject the draft, stating which test failed, unless it is at least one of:

  • Non-discoverable from the repo (landmine, tribal convention), or
  • Mistake-correcting with observed evidence.

Hard rejections: restates linter/formatter/typechecker config; restates something readable from the code; vague virtue ("write clean code"). Offer to rewrite a rejected draft into a passing, verifiable form when possible.

Step 3 — Detect the target

Look for .claude/ (Claude Code), .cursor/ (Cursor), AGENTS.md (fallback). Zero or multiple candidates → ask one question, recommending AGENTS.md as the portable default. Emit the dialect per the spec.

Step 4 — Enforce the budget

Compute resident usage per the spec (entry file + unscoped rules; content lines only). Then:

  • < 80% → proceed.
  • ≥ 80% → warn with the numbers; prefer path-scoping this rule if its

subject maps to specific files.

  • = 100% or would exceed → refuse, list removal/merge candidates

(stale provenance, overlapping subjects), and only write if the user removes or merges one in the same operation.

Step 5 — Write (itemized only)

  • Add: create the rule file (or one ### entry inside the AGENTS.md

managed block). Never touch neighboring content.

  • Edit / remove: modify or delete exactly the named rule.
  • Stamp the provenance comment (date · task · evidence · via).
  • Rules ≤ 20 content lines; split or tighten anything longer.
  • Never rewrite a whole file or block wholesale.

Step 6 — Report

One short confirmation: rule path, scope (resident or path-scoped), and budget usage after the write (e.g. "resident 92/150 lines"). If invoked by another skill (e.g. retro), also return the rule path so the caller can update its records.

Mistakes to refuse

| Request | Response | | --- | --- | | "Add these 5 rules at once" | One rule per invocation — propose an order | | "Just append it, skip the filter" | Filter is non-negotiable; explain why | | "Rewrite the rules file to be cleaner" | Itemized edits only; offer per-rule merges | | A rule duplicating an existing one | Point to the existing rule; offer an edit instead |

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

  • Author: BCGen
  • Source: BCGen/skills
  • License: MIT
  • Homepage: https://skills.sh/BCGen/skills

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet, be the first.

Versions

  • v0.1.0 Imported from the upstream source.