Add test document with deliberate style guide violations - #392
Conversation
📝 WalkthroughWalkthroughAdded a guide for configuring API rate limiting. The guide covers prerequisites, policy settings, supported and unsupported options, gateway behavior, backend support, and deployment timing. ChangesAPI rate-limiting documentation
Estimated code review effort: 1 (Trivial) | ~3 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 16
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@en/docs/style-test.md`:
- Line 13: Update the prose in the rate-limiting description to replace “~5
minutes” with “about 5 minutes” and “&” with “and,” without changing the
surrounding wording.
- Line 34: Update the sentence in the deprecated-fields guidance to reference
the correct source explicitly, or remove it if no valid reference exists; do not
use the ambiguous phrase “the table above.”
- Around line 29-32: Update the table section in en/docs/style-test.md by adding
a complete introductory sentence before the table and wrapping the literal field
names Quota and Burst in backticks in the table rows.
- Line 43: Update the deployment instruction in the style-test content to say
“Deploy the policy to apply the change.” Remove the ambiguous numeric date and
vague “shortly after” wording; only use a spelled-out month if a date is
required.
- Line 21: Update the gateway behavior sentence in en/docs/style-test.md to
state that exceeding the rate limit returns HTTP `429 Too Many Requests`,
formatting the status code as inline code and removing the unrelated `200`
health-response wording.
- Around line 8-11: Update the introductory passage in en/docs/style-test.md by
removing “Let's begin.”, addressing the reader as “You must,” and splitting the
prerequisite, routing, quota evaluation, and authentication information into
separate sentences, each under 26 words.
- Around line 3-4: Update the introductory text in the rate-limiting guide to
replace promotional terms such as “powerful,” “seamless,” and “really easy” with
concise, factual descriptions of the policy engine’s behavior, and remove the
exclamation mark.
- Line 1: Update the headings in en/docs/style-test.md to use sentence case,
change the heading at line 16 from level four to level three so it follows the
existing ## hierarchy, and replace the spaced en dash at line 23 with an em dash
without surrounding spaces. Apply the same heading-style corrections to the
additional referenced locations.
- Line 1: Update the guide title and the referenced wording in the sections
around lines 3-4 and 26-27 to remove time-dependent terms such as “new,”
“currently,” and “now.” Use timeless language that directly describes the
supported rate-limiting behavior.
- Line 1: Add the repository-standard frontmatter block before the H1 title in
style-test.md, including valid values for title, description, canonical_url,
md_url, tags, author or authors, last_updated, and content_type. Preserve the
existing “Configuring Rate Limiting For Your New API” heading after the
frontmatter.
- Around line 40-41: Remove the sentence promising MongoDB and Redis backend
support from the guide near the existing “click here” text; retain only
documentation for currently available capabilities, without adding replacement
claims.
- Around line 18-19: Update the policy documentation references in the
procedure, field table, and required-fields prose to match the contract defined
by Limits, Limits[].Count, and Limits[].Duration instead of quota, burst, and
backend. Ensure the table and the statement about the number of required fields
consistently describe all three documented contract fields.
- Around line 18-19: Rewrite the policy-creation sentence as a numbered list
with three steps: open the Policies pane, select Add policy, and configure the
quota, burst limit, and backend. Bold each UI element and use the Oxford comma
in the final list.
- Line 25: Rewrite the sentence in en/docs/style-test.md to use active voice and
replace the comma splice with a grammatically correct construction, preserving
the meaning that an administrator—not the API publisher—applies the policy.
- Around line 39-40: Update the documentation sentence so “click here” is
replaced with descriptive link text that identifies the linked content, and
format the UI label “Save” in bold. Preserve the surrounding quota and MongoDB
wording.
- Around line 36-37: Update the image markup in the documentation by adding a
standalone introductory sentence, renaming the referenced asset from the generic
img1.png to a descriptive filename, and adding concise sentence-case alt text.
Remove the prohibited inline alignment styles while preserving the image
dimensions and intended content.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: c6a22620-8ecb-488b-95a8-aab6e84e514c
📒 Files selected for processing (1)
en/docs/style-test.md
| @@ -0,0 +1,43 @@ | |||
| # Configuring Rate Limiting For Your New API | |||
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win
Use sentence-case headings and valid heading levels.
Use sentence case for every heading. Change the heading on Line 16 from #### to ###; it skips a level after ##. Replace the en dash on Line 23 with an em dash without surrounding spaces.
Proposed heading fixes
-# Configuring Rate Limiting For Your New API
+# Configuring rate limiting for your API
-## What The User Should Know Before Starting
+## Before you start
-#### Example 1: Configuring A Basic Policy
+### Example 1: Configuring a basic policy
-## Advanced Configuration – Optional
+## Advanced configuration—optionalAlso applies to: 6-6, 16-16, 23-23
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@en/docs/style-test.md` at line 1, Update the headings in
en/docs/style-test.md to use sentence case, change the heading at line 16 from
level four to level three so it follows the existing ## hierarchy, and replace
the spaced en dash at line 23 with an em dash without surrounding spaces. Apply
the same heading-style corrections to the additional referenced locations.
Sources: Coding guidelines, Path instructions, Linters/SAST tools
📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win
Remove timeless language from the guide.
The terms new, currently, and now make the documentation age. Use timeless wording that describes the supported behavior directly.
Also applies to: 3-4, 26-27
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@en/docs/style-test.md` at line 1, Update the guide title and the referenced
wording in the sections around lines 3-4 and 26-27 to remove time-dependent
terms such as “new,” “currently,” and “now.” Use timeless language that directly
describes the supported rate-limiting behavior.
Sources: Coding guidelines, Path instructions
🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win
Add the required frontmatter before the title.
This file lacks title, description, canonical_url, md_url, tags, author or authors, last_updated, and content_type. Add repository-valid values before the H1.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@en/docs/style-test.md` at line 1, Add the repository-standard frontmatter
block before the H1 title in style-test.md, including valid values for title,
description, canonical_url, md_url, tags, author or authors, last_updated, and
content_type. Preserve the existing “Configuring Rate Limiting For Your New API”
heading after the frontmatter.
Source: Path instructions
| This guide currently explains how to configure rate limiting. The new policy engine now gives | ||
| you a powerful, seamless way to protect backends, and it's really easy! |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win
Remove promotional wording.
Replace powerful, seamless, and really easy with specific behavior. Avoid the exclamation mark in technical documentation.
🧰 Tools
🪛 LanguageTool
[style] ~4-~4: As an alternative to the over-used intensifier ‘really’, consider replacing this phrase.
Context: ...mless way to protect backends, and it's really easy! ## What The User Should Know Before S...
(EN_WEAK_ADJECTIVE)
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@en/docs/style-test.md` around lines 3 - 4, Update the introductory text in
the rate-limiting guide to replace promotional terms such as “powerful,”
“seamless,” and “really easy” with concise, factual descriptions of the policy
engine’s behavior, and remove the exclamation mark.
Sources: Coding guidelines, Linters/SAST tools
| Let's begin. The user must have an API already published in the Developer Portal, and the | ||
| request is routed by the API Gateway to the backend after the policy engine evaluates every | ||
| incoming call against the configured quota, which means that throughput limits are applied | ||
| before authentication happens in most standard deployment topologies. |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win
Address the reader directly and split the long sentence.
Replace The user must with You must. Remove Let's begin. and separate the prerequisite, routing, quota evaluation, and authentication statements into sentences shorter than 26 words.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@en/docs/style-test.md` around lines 8 - 11, Update the introductory passage
in en/docs/style-test.md by removing “Let's begin.”, addressing the reader as
“You must,” and splitting the prerequisite, routing, quota evaluation, and
authentication information into separate sentences, each under 26 words.
Sources: Coding guidelines, Path instructions
| incoming call against the configured quota, which means that throughput limits are applied | ||
| before authentication happens in most standard deployment topologies. | ||
|
|
||
| Rate limiting is simply a way to cap traffic. It takes ~5 minutes to set up & requires no |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win
Replace shorthand symbols in prose.
Use about 5 minutes instead of ~5 minutes, and use and instead of &.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@en/docs/style-test.md` at line 13, Update the prose in the rate-limiting
description to replace “~5 minutes” with “about 5 minutes” and “&” with “and,”
without changing the surrounding wording.
Source: Coding guidelines
| Creating a policy involves opening the Policies pane, selecting Add policy, and then | ||
| configuring the quota, the burst limit and the backend. |
There was a problem hiding this comment.
🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win
Align the documented fields with the policy contract.
The guide names quota, burst, and backend, but en/docs/cloud/ai-workspace/policies/other-policies/basic-rate-limit.md defines Limits, Limits[].Count, and Limits[].Duration. The table lists two fields, while Line 39 claims three required fields. Update the procedure, table, and prose consistently.
Also applies to: 29-32, 39-40
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@en/docs/style-test.md` around lines 18 - 19, Update the policy documentation
references in the procedure, field table, and required-fields prose to match the
contract defined by Limits, Limits[].Count, and Limits[].Duration instead of
quota, burst, and backend. Ensure the table and the statement about the number
of required fields consistently describe all three documented contract fields.
📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win
Document the procedure as numbered steps.
The sentence hides a three-step procedure. Use an ordered list, format UI elements as bold, and add the Oxford comma.
Proposed procedure format
-Creating a policy involves opening the Policies pane, selecting Add policy, and then
-configuring the quota, the burst limit and the backend.
+1. Open the **Policies** pane.
+2. Select **Add policy**.
+3. Configure the supported fields.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@en/docs/style-test.md` around lines 18 - 19, Rewrite the policy-creation
sentence as a numbered list with three steps: open the Policies pane, select Add
policy, and configure the quota, burst limit, and backend. Bold each UI element
and use the Oxford comma in the final list.
Sources: Coding guidelines, Path instructions
| | Quota | The request count | | ||
| | Burst | The burst ceiling | | ||
|
|
||
| For the deprecated fields, see the table above. |
There was a problem hiding this comment.
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win
Fix the invalid table reference.
The table does not identify any deprecated fields. Point to the correct reference, or remove this sentence. Avoid the ambiguous phrase the table above.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@en/docs/style-test.md` at line 34, Update the sentence in the
deprecated-fields guidance to reference the correct source explicitly, or remove
it if no valid reference exists; do not use the ambiguous phrase “the table
above.”
Source: Coding guidelines
| <img src="../assets/img/img1.png" width="700" height="420" | ||
| style="margin-left: 40px; text-align: center" /> |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win
Make the image accessible and compliant.
The image has no alt text, uses the generic filename img1.png, and contains prohibited inline alignment styles. Introduce the image with a standalone sentence before the tag, rename the file descriptively, and add concise sentence-case alt text.
Proposed image markup
-<img src="../assets/img/img1.png" width="700" height="420"
- style="margin-left: 40px; text-align: center" />
+<img src="../assets/img/rate-limit-policy-configuration.png"
+ alt="Rate-limit policy configuration panel with supported fields and a Save button." />🧰 Tools
🪛 markdownlint-cli2 (0.23.1)
[warning] 36-36: Images should have alternate text (alt text)
(MD045, no-alt-text)
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@en/docs/style-test.md` around lines 36 - 37, Update the image markup in the
documentation by adding a standalone introductory sentence, renaming the
referenced asset from the generic img1.png to a descriptive filename, and adding
concise sentence-case alt text. Remove the prohibited inline alignment styles
while preserving the image dimensions and intended content.
Sources: Coding guidelines, Path instructions, Linters/SAST tools
| The panel shows the three required fields and the Save button. To learn more about quotas, | ||
| click here. This feature will eventually support MongoDB backends, and we're considering |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win
Replace click here with descriptive link text.
The sentence has no visible link target and violates the link-text rule. Link a meaningful phrase, and format the UI label as Save.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@en/docs/style-test.md` around lines 39 - 40, Update the documentation
sentence so “click here” is replaced with descriptive link text that identifies
the linked content, and format the UI label “Save” in bold. Preserve the
surrounding quota and MongoDB wording.
Sources: Coding guidelines, Path instructions
| click here. This feature will eventually support MongoDB backends, and we're considering | ||
| adding Redis support soon. |
There was a problem hiding this comment.
🎯 Functional Correctness | 🟠 Major | ⚡ Quick win
Remove unreleased backend promises.
The guide says MongoDB support will arrive and Redis support is under consideration. Do not document future or unreleased capabilities. Remove this sentence or move it to a dated release note after support ships.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@en/docs/style-test.md` around lines 40 - 41, Remove the sentence promising
MongoDB and Redis backend support from the guide near the existing “click here”
text; retain only documentation for currently available capabilities, without
adding replacement claims.
Sources: Coding guidelines, Path instructions
| click here. This feature will eventually support MongoDB backends, and we're considering | ||
| adding Redis support soon. | ||
|
|
||
| Deploy the policy on 01/02/2026 and the change goes live shortly after. |
There was a problem hiding this comment.
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win
Use a timeless, unambiguous deployment instruction.
01/02/2026 can mean January 2, 2026, or February 1, 2026. Both dates are before July 31, 2026. Replace the dated instruction and vague phrase shortly after with Deploy the policy to apply the change. If a dated event is required, spell out the month.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@en/docs/style-test.md` at line 43, Update the deployment instruction in the
style-test content to say “Deploy the policy to apply the change.” Remove the
ambiguous numeric date and vague “shortly after” wording; only use a spelled-out
month if a date is required.
Sources: Coding guidelines, Path instructions
Test PR
Close without merging. This page is deliberately broken.
Purpose
Tests the style rules added since #380 — frontmatter, multimedia metadata, and heading hierarchy.
Approach
Adds
en/docs/style-test.mdwith 32 planted violations. 30 are unchanged from #380; the newones are a skipped heading level, a non-descriptive image file name, and absent frontmatter.
Checklist
N/A — the checklist items are deliberately violated as test fixtures.
Security checks
Related PRs