Skip to content

Docs: global policy support for LLM Providers and Proxies#353

Merged
ashera96 merged 1 commit into
wso2:mainfrom
ashera96:main
Jul 23, 2026
Merged

Docs: global policy support for LLM Providers and Proxies#353
ashera96 merged 1 commit into
wso2:mainfrom
ashera96:main

Conversation

@ashera96

Copy link
Copy Markdown
Contributor

Purpose

This pull request updates and clarifies the documentation for rate limiting and guardrail policy scopes in the AI Workspace. The main improvements are clearer explanations of global vs. per-resource policy behavior, updated diagrams and examples, and better cross-referencing between relevant sections.

Documentation improvements for policy scope and behavior:

  • Added a new "Policy Scope: Global vs. Per Resource" section to policies/overview.md, detailing the difference between global and per-resource policies for both rate limits and guardrails, including tables and evaluation order.
  • Clarified in llm-providers/manage-provider.md how provider-wide (global) and per-resource rate limits work, including counter behavior, evaluation order, and added a diagram to illustrate configuration modes.
  • Expanded the explanation of guardrail attachment and evaluation order in both llm-providers/manage-provider.md and policies/guardrails/overview.md, emphasizing that global guardrails run before per-resource guardrails and referencing the new policy scope documentation. [1] [2]

General maintenance:

  • Updated the last_updated metadata in all affected files to reflect the latest changes. [1] [2] [3]

@coderabbitai

coderabbitai Bot commented Jul 21, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 8d88dcca-4eb9-485a-98ce-f2689ca4426b

📥 Commits

Reviewing files that changed from the base of the PR and between 5a3f9d1 and c09cc17.

⛔ Files ignored due to path filters (1)
  • en/docs/assets/img/ai-gateway/standalone-ai-workspace/llm-provider/rate-limiting-tab.png is excluded by !**/*.png
📒 Files selected for processing (3)
  • en/docs/next/ai-workspace/llm-providers/manage-provider.md
  • en/docs/next/ai-workspace/policies/guardrails/overview.md
  • en/docs/next/ai-workspace/policies/overview.md
🚧 Files skipped from review as they are similar to previous changes (3)
  • en/docs/next/ai-workspace/policies/guardrails/overview.md
  • en/docs/next/ai-workspace/policies/overview.md
  • en/docs/next/ai-workspace/llm-providers/manage-provider.md

📝 Walkthrough

Summary

  • Updated AI Workspace documentation to introduce clearer policy scope guidance for global vs per-resource configurations.
  • Clarified rate-limiting behavior, including provider-wide shared counters, hard-ceiling evaluation, and request evaluation order (global first, then per-resource).
  • Expanded guardrails documentation to specify how evaluation order works across provider vs proxy and global vs per-resource levels.
  • Refreshed related pages with updated cross-references/examples/diagrams and updated last_updated metadata.

Walkthrough

Updated AI Workspace documentation to describe global and per-resource policy scopes, rate-limit counter behavior, and guardrail evaluation order. Provider documentation now explains Provider-wide hard ceilings, shared counters, request-attempt counting, HTTP 429 responses, and global-before-resource guardrail evaluation. Document metadata dates were updated to 2026-07-21.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning It covers the purpose and high-level changes, but most required template sections like checklist, goals, approach, release note, and tests are missing. Fill in the template sections, especially Checklist, Goals, Approach, User stories, Release note, Documentation, Tests, Security checks, and other applicable fields.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly matches the docs changes about global policy support for LLM providers and proxies.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 4

🤖 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/next/ai-workspace/llm-providers/manage-provider.md`:
- Around line 169-170: Update the rate-limiting mode description in the provider
configuration documentation to state that only the Backend section supports
these configurable modes. Do not imply that Per Consumer is currently available;
label it as planned only if that matches the surrounding documentation.

In `@en/docs/next/ai-workspace/policies/guardrails/overview.md`:
- Line 50: Update the guardrail evaluation description to reconcile “all of them
are evaluated” with intervention behavior: state that applicable guardrails run
in the documented provider/proxy and global/per-resource order, and explicitly
document whether evaluation stops or continues after an earlier guardrail
intervenes.

In `@en/docs/next/ai-workspace/policies/overview.md`:
- Around line 77-83: Revise the policy-ordering explanation in the request flow
section to explicitly scope “global policies → per-resource policies” to each
provider or proxy, matching the terminology and precedence described in the
guardrails overview. Clarify that this is not a single ordering across all
provider and proxy levels, while preserving the existing rate-limit behavior
explanation.
- Around line 79-81: Specify the fenced code block language as text for the
ASCII flow diagram in the policy overview, changing the opening fence to ```text
while leaving the diagram content and closing fence unchanged.
🪄 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: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 879325d2-8f5f-4651-bcc5-8034295851c6

📥 Commits

Reviewing files that changed from the base of the PR and between 2355eac and 5a3f9d1.

⛔ Files ignored due to path filters (1)
  • en/docs/assets/img/ai-gateway/standalone-ai-workspace/llm-provider/rate-limiting-tab.png is excluded by !**/*.png
📒 Files selected for processing (3)
  • en/docs/next/ai-workspace/llm-providers/manage-provider.md
  • en/docs/next/ai-workspace/policies/guardrails/overview.md
  • en/docs/next/ai-workspace/policies/overview.md

Comment thread en/docs/next/ai-workspace/llm-providers/manage-provider.md
Comment thread en/docs/next/ai-workspace/policies/guardrails/overview.md
Comment thread en/docs/next/ai-workspace/policies/overview.md Outdated
Comment thread en/docs/next/ai-workspace/policies/overview.md Outdated
Krishanx92
Krishanx92 previously approved these changes Jul 21, 2026
@ashera96
ashera96 merged commit 3a487c0 into wso2:main Jul 23, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants