Align style guide with AI-assisted authoring workflow#6
Merged
Conversation
- Add AGENTS.md as the machine-readable companion to style-guide.md; coding agents auto-load it on session start. - Rewrite list-formatting, bold, headings, terminology, and link sections in style-guide.md with explicit Do/Don't pairs and a one-rule decision for list-item punctuation. - Add new subsections derived from recurring inline-review patterns in recent polkadot-docs PRs: Code Identifiers in Prose, Identifier Consistency Within a Document, Image File Naming, and a "no redundant subheadings above lead-in lists" rule. - Add explicit Banned Phrases table covering filler and LLM clichés (delve, leverage, seamless, robust, "it's important to note", etc.). - Add Em Dash / En Dash and Contractions guidance. - Replace the existing 🟢/🔴 example markers with text labels, since the guide bans emojis. - Add .vale.ini and a starter styles/PaperMoon/ rule set so the high-friction rules (banned phrases, terminology, emojis, link text, placeholders) are enforced mechanically. - Update README.md and checklist.md to point at the new files and add review-derived checklist items.
Three follow-up fixes after running `vale .` from repo root: - Add `Vocab = PaperMoon` as a core directive (must be above any syntax-specific section per Vale's parser). Without this the vocab file at styles/config/vocabularies/PaperMoon/accept.txt was never loaded, so Vale's built-in spelling rule flagged domain words. - Exclude AGENTS.md, style-guide.md, and checklist.md from style checks. They describe the rules and intentionally contain examples of banned content (e.g., the Banned Phrases table lists the words the rule bans). Subjecting them to their own rules is circular. - Drop `Packages = Google` from the default config and document how to re-enable. Keeps the lint offline-runnable; teams can opt back in by adding the package and running `vale sync`. - Extend the PaperMoon accept vocab with common technical terms (repo, MkDocs, devcontainer, linter, etc.) that Vale's built-in spelling check otherwise flags. `vale .` from repo root now exits 0 with no errors, warnings, or suggestions across all linted files.
These conventions previously lived only in the agentic-docs-writers style-enforcer mirror. Upstreaming them here so that mirror can be deleted without losing any rule (single source of truth): - supermajority spelling (one word). - Define every acronym on first use in each article. - Hyphenated identifiers and runtime/network profile names (paseo-next, westend-next) keep canonical casing on every mention; rephrase rather than capitalize at sentence start. - A numbered step label ending in a colon already counts as punctuated — no trailing period. - Rocket emoji (🚀) prohibition extended to HTML templates/banners/UI for blockchain projects (speculative-hype brand nuance). Added to both AGENTS.md and style-guide.md. vale . passes clean.
eshaben
reviewed
May 19, 2026
Inline review on AGENTS.md, with the same changes mirrored into
style-guide.md, checklist.md, and README.md per the reviewer's note
("apply previous comments here too"):
List item punctuation (AGENTS.md:30)
- Rewrite rule 1 to follow the Google developer documentation style
guide explicitly: single-word, verbless, code-font, and link-text
items take no end punctuation; mixed lists must be rewritten for
parallel construction or all-punctuated for consistency.
- Add description-list capitalization: capitalize both the term and
the first letter of the description.
Bold for emphasis (AGENTS.md:68)
- Allow italics for emphasis (consistent with style-guide.md Italics
section). Stronger callouts use an admonition.
Em dash / Links (AGENTS.md:158-159, 164)
- Drop the manual `{target=\_blank}` instruction — the MkDocs plugin
handles it automatically. Strip the attribute from all in-repo
examples; note the plugin in its place.
Contractions (AGENTS.md:170)
- Switch all `Don't:` comparison labels to `Do not:` so the style
guide practices what it preaches on the no-contractions rule.
Conceptual heading rule (AGENTS.md:102)
- Left as-is per reviewer's "this one is fine".
Terminology — runtime/network profile names (AGENTS.md:198)
- Distinguish identifier usage (backticked, canonical casing:
`paseo-next`, `westend-next`) from prose mention of the same
network (title case, no backticks: "Paseo Next", "Westend Next").
Image file naming (AGENTS.md:251, 312; checklist.md:53; style-guide.md)
- Rename pattern from `<topic>-<number>.webp` to
`<filename>-<number>.webp`.
Pre-output checklist target_blank (AGENTS.md:304)
- Drop the manual `target=_blank` check; note the plugin handles it.
Alt text (AGENTS.md:312)
- Allow empty `alt=""` for purely decorative images per Google's
guidance. Keep non-empty alt required for informative images.
checklist.md
- Strip bold-for-emphasis from the intro line (line 5) — italics
instead.
- Replace the bold-emphasis check with guidance to use italics or
an admonition.
- Drop the manual target_blank instruction; remove the attribute
from the recommended/not-recommended link examples.
README.md
- Reformat the Files list as proper description-list bullets
(`**Term**: Description.`) with capitalized descriptions.
`vale .` exits 0 clean.
Contributor
Author
|
Addressed the inline review in c0b23d1. Per your note on style-guide.md:1 to apply your comments throughout, the same fixes are mirrored across AGENTS.md, style-guide.md, checklist.md, and README.md.
|
Collaborator
|
Cool, looks good on my end. Let me know when it gets kicked out of draft mode |
Contributor
Author
Thank you @eshaben - it is out of draft now. |
eshaben
approved these changes
May 21, 2026
Collaborator
eshaben
left a comment
There was a problem hiding this comment.
Not sure the vale configs belong in this repo as they're quite polkadot specific. But you can make adjustments later if needed.
eshaben approved the PR with the note that the configs felt Polkadot-specific. PaperMoon's style guide serves multiple customers, so the canonical repo should not carry one ecosystem's product names or pallet identifiers. This commit makes everything customer-agnostic; no rule changes, only example substitutions. Vale vocab (styles/config/vocabularies/PaperMoon/accept.txt) - Remove customer-specific product/protocol names: Polkadot, Kusama, Moonbeam, Moonriver, Moonbase, parachain, parachains, relay chain, Substrate. Each customer's own docs repo can extend the vocab with its ecosystem terms; the canonical accept list stays cross-cutting (dApp, TestNet, MainNet, JSON-RPC, Web3, EVM, WASM, etc.). AGENTS.md - Link examples now reference a generic "project's faucet" at example.com instead of the Moonbase Alpha faucet. - Rule 11 (hyphenated identifiers) drops the runtime/network profile framing and the `paseo-next` / `westend-next` examples; the rule itself is the same (identifier-form vs prose-form), just framed generically. - Oxford comma example: "red, white, and blue" instead of "Polkadot, Kusama, and Moonbeam". - Code identifier examples switch from `session.purgeKeys`, `StakingOperator`, "staker"/"validator"/"stash" to `auth.getUserId`, `RoleManager`, "author"/"editor"/"writer". - Image filename examples: `dashboard-overview-01.webp`, `user-permissions-01.webp` instead of `key-management-01.webp`, `staking-operator-proxy-01.webp`. style-guide.md - Same neutralization, mirrored. checklist.md - Recommended/not-recommended link examples use a generic faucet URL and prose. - Identifier consistency examples switch to `getUserId` / `get_user_id` and author/editor/writer. vale . exits 0 clean.
Contributor
Author
|
Good catch on the Polkadot-flavored content — neutralized in 08a1a5a:
No rule changes — only example substitutions. |
eshaben
reviewed
May 21, 2026
The MkDocs plugin handles new-tab behavior automatically — calling it out in the style guide, AGENTS.md, and the checklist is internal tooling noise rather than house style. Removes the rule from all four spots flagged in review.
brunopgalvao
added a commit
to polkadot-developers/polkadot-docs
that referenced
this pull request
May 26, 2026
papermoonio/documentation-style-guide#6 dropped the manual {target=\_blank} rule after review (the MkDocs plugin handles opening external links in a new tab automatically). The project-specific override in this file still said it was "enforced", which now contradicts canonical. Update to mirror the canonical guidance: the plugin handles it, do not add manually.
brunopgalvao
added a commit
to polkadot-developers/polkadot-docs
that referenced
this pull request
Jun 2, 2026
* docs: adopt PaperMoon styleguide via AGENTS.md + Vale lint Pilot adoption of the agent-loadable PaperMoon documentation styleguide: - AGENTS.md at repo root pointing at the canonical papermoonio/documentation-style-guide/AGENTS.md. Coding agents (Claude Code, Cursor, Codex, etc.) load AGENTS.md automatically when they open this repository, so authoring sessions pick up the documentation rules without manual context wiring. - .vale.ini and styles/PaperMoon/ mirroring the styleguide repo's Vale rules: banned phrases (delve, leverage, seamless, robust, "it's important to note", "in summary", "currently", etc., simply, just, easily, obviously), terminology substitutions (ERC-20, JSON-RPC, dApp, TestNet, MainNet), emoji ban, descriptive link text, INSERT_ placeholder format, first-person plural warning, and the no-exclamation rule. Vocab accept-list seeds Polkadot-specific terms. - .github/workflows/vale.yml runs Vale on changed markdown files in every PR. Scoped to added/modified .md files only (not the full tree) so existing tech debt does not fail the workflow; the gate applies to net-new content. Refresh process: when the styleguide repo updates, copy .vale.ini and styles/ over again. The pointer in AGENTS.md always resolves to the latest canonical source. * Pull Vale rules from canonical styleguide at CI time Eliminates the duplicated rule files this PR previously carried: styles/PaperMoon/*.yml and styles/config/vocabularies/PaperMoon/accept.txt were copies of the canonical files in papermoonio/documentation-style-guide, so the lint rules drifted any time the canonical updated. Architecture now: - scripts/sync-styleguide-vale.sh clones the styleguide repo and copies styles/PaperMoon/ and the PaperMoon vocab into local styles/ before linting. Run it locally before `vale .`; CI runs it automatically. - .gitignore excludes the synced directories so they are never committed. - styles/config/vocabularies/Polkadot/accept.txt holds the project's own vocab (Polkadot, Kusama, Paseo, parachain, etc.) — these are ecosystem-specific terms that the canonical PaperMoon vocab intentionally does not carry. - .vale.ini now loads both vocabs (Vocab = PaperMoon, Polkadot) and references the synced styles directory. - .github/workflows/vale.yml adds a sync step before invoking Vale. Result: the canonical PaperMoon styleguide repo is the only place PaperMoon lint rules live. polkadot-docs carries only what is genuinely project-specific (Polkadot vocab, project overrides, the CI workflow). * Align target=_blank guidance with updated canonical styleguide papermoonio/documentation-style-guide#6 dropped the manual {target=\_blank} rule after review (the MkDocs plugin handles opening external links in a new tab automatically). The project-specific override in this file still said it was "enforced", which now contradicts canonical. Update to mirror the canonical guidance: the plugin handles it, do not add manually. * Disable Vale.Spelling; enforce house style only The spell-checker arrived with the base Vale style and flags an endless tail of valid tool/package names on a technical docs repo with no typo-catching benefit worth the vocab-curation toil. Keep the curated PaperMoon house-style rules plus Vale.Repetition and Vale.Terms. * Address review: non-blocking Vale check + move sync script to .github/scripts - Vale CI is now advisory (fail_on_error: false, reporter github-pr-check): findings surface in the Checks tab instead of blocking merge or posting inline review comments. Still reruns on every push so the check status tracks the latest commit. Addresses noise concerns from the prior Vale run (#38). - Move sync-styleguide-vale.sh from scripts/ to .github/scripts/ alongside the other CI scripts; update all references.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This is a draft that rewrites the PaperMoon style guide so it's loadable, enforceable, and unambiguous for AI-assisted authoring workflows — and reduces the manual review friction the team has been seeing on AI-generated PRs.
The intent is to keep the existing substance, make ambiguous rules concrete, fold in the patterns reviewers actually flag, and ship an agent-loadable companion plus a mechanical lint layer.
Keep / drop / add
Keep + improve — every existing section survives. High-friction sections were rewritten with explicit
Do:/Don't:example pairs:Don'texamples for emphasis-bolding in prose; clarifies bold is only for UI elements and description-list terms.TestNet/MainNet(previously only in the checklist) moved into the style guide proper.{target=\_blank}rule into external vs. same-page-internal, with examples.✅/❌/🟢/🔴/⚠️markers; standardizes on textDo:/Don't:labels.Drop
🟢/🔴emoji markers in the existing variable-conventions examples — replaced with text labels, since the guide itself forbids emojis.Add (data-driven from your last two months of PR reviews on
polkadot-developers/polkadot-docs):AGENTS.md— agent-loadable, rule-first companion. Coding agents auto-loadAGENTS.mdfrom a repo root, so downstream docs repos that reference it get the rules applied on every authoring session. Vendor-neutral; not coupled to any specific tool.delve,leverage,seamless,robust,it's important to note,simply,currently,etc., and the rest).stakingRcClient.purge_keys, herepurgeKeys. Worth usingpurgeKeyseverywhere.")<topic>-<number>.webprule made explicit. (eshaben CHANGES_REQUESTED on #1575: "the images aren't using the correct format. They should be<filename>-<number>.webp. This helps us when we do reorgs.")###directly above a list that's already introduced by a sentence ending in:. Reviewers strip them. (nhussein11 on #1575.)**Term**: Description.form and drift back to plain bullets. (eshaben on #1575: "Pls update rest of list items to use this same format.").vale.ini+styles/PaperMoon/— starter Vale config covering banned phrases (hard ban + discouraged), terminology substitutions (ERC-20, JSON-RPC, dApp, TestNet, MainNet), emoji ban, first-person plural, link text, placeholder format, and an accept-list vocabulary. Lets the high-friction rules be enforced mechanically in CI rather than caught in prose review.What this is meant to fix
Across the last 21 PRs on
polkadot-docsfrom this author, the recurring inline-review categories were:Every one of those now has either an explicit rule (with Do/Don't example) in the style guide, a corresponding agent-loadable rule in
AGENTS.md, or a mechanical Vale check — and most have all three.Test plan
vale .from repo root succeeds against the style guide itself (i.e., the guide doesn't violate its own rules). Verified: exit 0, 0 errors / 0 warnings / 0 suggestions across all linted files (rule-source files excluded as they intentionally contain examples of banned content).polkadot-docs) tries adoptingAGENTS.mdand the Vale config on a single PR as a pilot — see docs: adopt PaperMoon styleguide via AGENTS.md + Vale lint polkadot-developers/polkadot-docs#1678 (draft): addsAGENTS.mdpointing here,.vale.ini+styles/PaperMoon/, and a changed-files-scoped Vale CI workflow.Note: absorbs 5 rules from the orchestrator (single-source consolidation)
The latest commit adds five PaperMoon house conventions that previously lived only in a downstream agent's inline style mirror:
supermajorityspelling, define-acronyms-on-first-use, hyphenated-identifier / runtime-network-profile casing (e.g.paseo-next), the "step label ending in a colon counts as punctuated" list nuance, and extending the rocket-emoji (🚀) prohibition to banners/UI for blockchain projects. Centralizing them here lets that downstream mirror be deleted entirely, so these rules have exactly one home. Added to bothAGENTS.mdandstyle-guide.md;vale .still passes clean.Marking draft so the team can iterate on rule wording, lint severities, and the
AGENTS.mdconvention before merging.