Skip to content

fix: doc fixes#1477

Merged
Pratham-Mishra04 merged 1 commit intomainfrom
01-29-fix_doc_fixes
Feb 4, 2026
Merged

fix: doc fixes#1477
Pratham-Mishra04 merged 1 commit intomainfrom
01-29-fix_doc_fixes

Conversation

@Pratham-Mishra04
Copy link
Collaborator

Summary

Briefly explain the purpose of this PR and the problem it solves.

Changes

  • What was changed and why
  • Any notable design decisions or trade-offs

Type of change

  • Bug fix
  • Feature
  • Refactor
  • Documentation
  • Chore/CI

Affected areas

  • Core (Go)
  • Transports (HTTP)
  • Providers/Integrations
  • Plugins
  • UI (Next.js)
  • Docs

How to test

Describe the steps to validate this change. Include commands and expected outcomes.

# Core/Transports
go version
go test ./...

# UI
cd ui
pnpm i || npm i
pnpm test || npm test
pnpm build || npm run build

If adding new configs or environment variables, document them here.

Screenshots/Recordings

If UI changes, add before/after screenshots or short clips.

Breaking changes

  • Yes
  • No

If yes, describe impact and migration instructions.

Related issues

Link related issues and discussions. Example: Closes #123

Security considerations

Note any security implications (auth, secrets, PII, sandboxing, etc.).

Checklist

  • I read docs/contributing/README.md and followed the guidelines
  • I added/updated tests where appropriate
  • I updated documentation where needed
  • I verified builds succeed (Go and UI)
  • I verified the CI pipeline passes locally if applicable

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 3, 2026

Caution

Review failed

The pull request is closed.

📝 Walkthrough

Summary by CodeRabbit

  • New Features

    • Routing Rules: Dynamic, expression-based request routing.
    • Model Configs: CRUD for managing model-specific settings.
    • Provider Governance: Management of provider-level governance (budget/rate limits).
  • Documentation

    • Comprehensive Routing Rules docs with examples, integration guides, and UI/API usage.
    • Expanded API reference documenting new governance and model-config endpoints.
    • Enhanced filtering guide with per-request deny-all examples.

Walkthrough

Adds documentation for dynamic CEL-based routing rules, new OpenAPI paths and schemas for model configs and provider governance, a docs navigation entry, and a mintignore file to exclude generated OpenAPI artifacts. No runtime code or exported/public API implementations were modified.

Changes

Cohort / File(s) Summary
Build & Tooling
docs/.mintignore
New ignore file excluding openapi/paths/, openapi/schemas/, and openapi/openapi.yaml from mint tooling.
Site Navigation
docs/docs.json
Added providers/routing-rules entry under "Providers & Guides".
MCP Docs
docs/mcp/filtering.mdx
Added per-request filtering examples showing empty include-clients/include-tools blocks deny all MCP tools; added Gateway header and Go SDK context examples.
Provider Routing Docs
docs/providers/provider-routing.mdx, docs/providers/routing-rules.mdx
Added comprehensive Routing Rules documentation (CEL expressions, runtime flow, scope precedence, variables, examples, validation, UI/API/config guidance, integration with governance/load balancing, troubleshooting).
OpenAPI — Paths
docs/openapi/paths/management/governance.yaml, docs/openapi/paths/management/oauth.yaml
Added CRUD endpoints for model-configs and provider-governance (operationIds, params, request/response bodies, standard errors). Updated oauth-config-status 404 response reference to use ../../schemas/management/common.yaml#/ErrorResponse. Note: governance.yaml shows duplicated additions in the diff.
OpenAPI — Schemas
docs/openapi/schemas/management/governance.yaml
Introduced schemas for model configs and provider governance: ModelConfig, ModelConfigResponse, ListModelConfigsResponse, CreateModelConfigRequest, UpdateModelConfigRequest, ProviderGovernance, ProviderGovernanceResponse, ListProviderGovernanceResponse, UpdateProviderGovernanceRequest.
Core Formatting
core/schemas/account.go
Whitespace/formatting adjustments only; no type, tag, or exported signature changes.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Poem

🐇🌿
I hopped through docs where rules unfold,
CEL whispers paths of blue and gold,
Schemas and paths in tidy rows,
I nibble lines where routing grows,
A happy rabbit — docs all told.

🚥 Pre-merge checks | ✅ 1 | ❌ 4
❌ Failed checks (3 warnings, 1 inconclusive)
Check name Status Explanation Resolution
Description check ⚠️ Warning The PR description contains only the template structure without any actual content, providing no meaningful information about the purpose, changes, or affected areas. Fill in all required sections with actual content describing the PR objectives, the specific changes made, type of change, affected areas, testing steps, and related issues.
Linked Issues check ⚠️ Warning The linked issue #123 requires Files API support for providers, but the actual changes in this PR focus on documentation updates for routing rules and governance schemas, which are unrelated to file API implementation. Verify the linked issue is correct. If file API support is required, ensure changes include endpoint implementations. If this PR is only for doc updates, link or create appropriate documentation-related issues.
Out of Scope Changes check ⚠️ Warning The PR introduces extensive documentation and OpenAPI schema changes for routing rules and model/provider governance features that appear unrelated to the linked issue about Files API support. Clarify the scope by either updating linked issues to match the actual changes (routing rules, governance schemas documentation) or removing unrelated changes from this PR.
Title check ❓ Inconclusive The title 'fix: doc fixes' is vague and generic, using non-descriptive terminology that does not convey specific information about the changeset. Revise the title to be more specific about the documentation changes, such as 'docs: add routing rules documentation and governance API schemas' to clearly summarize the main changes.
✅ Passed checks (1 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch 01-29-fix_doc_fixes

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

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In `@docs/providers/routing-rules.mdx`:
- Around line 875-890: The "Governance" Card in the Additional Resources block
uses a broken href (Card title "Governance" with href="/features/governance");
update that href to a valid governance page such as
"/features/governance/routing" or add an index/entry file for the
/features/governance directory so the existing link resolves, ensuring the Card
component's href points to a reachable route.
🧹 Nitpick comments (1)
docs/providers/routing-rules.mdx (1)

214-214: Clarify empty expression behavior.

The documentation states: "Empty expression → Rule always matches (use true/false for explicit behavior)."

An empty expression always matching could lead to unintended routing behavior if a user accidentally creates a rule with an empty CEL expression. Consider documenting whether:

  1. Empty expressions are validated/rejected at creation time
  2. If allowed, whether there's a warning shown to users
  3. The recommended approach (using explicit true is mentioned, but should empty expressions be blocked?)

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 4

🤖 Fix all issues with AI agents
In `@docs/mcp/filtering.mdx`:
- Around line 150-160: Update the example curl headers so they use empty header
values instead of the literal "[]"; replace the lines that show -H
"x-bf-mcp-include-clients: []" and -H "x-bf-mcp-include-tools: []" with
empty-value headers (e.g., -H "x-bf-mcp-include-clients:" and -H
"x-bf-mcp-include-tools:") because the header parser splits by comma and the
literal "[]" becomes a single token rather than an empty list.

In `@docs/providers/provider-routing.mdx`:
- Around line 1444-1449: Replace the bullet text "Capacity-aware routing: Switch
to fallback when budget/rate limits high" with a hyphenated compound adjective
and fix grammar—e.g., change the label to "Capacity-based failover" (or
"Capacity-aware failover") and update the description to "Switch to fallback
when budget/rate limits are high" so the phrase and verb agreement are correct;
locate the line containing the bullet text "Capacity-aware routing" to apply the
edit.

In `@docs/providers/routing-rules.mdx`:
- Around line 884-886: The "Governance" Card component (title="Governance")
currently states "Learn about governance layer (runs before routing rules)" but
earlier text says routing rules run before governance; update the card blurb to
reflect the correct precedence—either change the parenthetical to "(runs after
routing rules)" or rephrase to "Learn about the governance layer (applied after
routing rules determine provider selection)" so it matches the earlier sections
about routing rules executing first.
- Around line 329-334: Update the "Create Rule" response code in the docs to
match the OpenAPI spec and implementation: change the documented response from
`201 Created` to `200 OK` in the Create Rule example in routing-rules.mdx so it
matches the OpenAPI definition and the createRoutingRule implementation (which
returns the default 200); ensure the JSON example remains unchanged and the
status label text is updated to `200 OK`.

@Pratham-Mishra04 Pratham-Mishra04 force-pushed the 01-29-fix_doc_fixes branch 2 times, most recently from 06e5f4e to 66258fa Compare February 3, 2026 18:05
Copy link
Collaborator Author

Pratham-Mishra04 commented Feb 4, 2026

Merge activity

@Pratham-Mishra04 Pratham-Mishra04 changed the base branch from 02-03-fix_minor_routing_rules_fixes to graphite-base/1477 February 4, 2026 07:58
@Pratham-Mishra04 Pratham-Mishra04 changed the base branch from graphite-base/1477 to 02-03-fix_minor_routing_rules_fixes February 4, 2026 08:00
@Pratham-Mishra04 Pratham-Mishra04 changed the base branch from 02-03-fix_minor_routing_rules_fixes to graphite-base/1477 February 4, 2026 08:01
@Pratham-Mishra04 Pratham-Mishra04 changed the base branch from graphite-base/1477 to main February 4, 2026 08:02
@Pratham-Mishra04 Pratham-Mishra04 merged commit a45a433 into main Feb 4, 2026
10 checks passed
@Pratham-Mishra04 Pratham-Mishra04 deleted the 01-29-fix_doc_fixes branch February 4, 2026 08:04
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.

[Feature]: Configuring fallbacks on provider level Files API Support

1 participant