[Bug]: Word Count Guardrail missing from the Add Guardrail list under the default category filter
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 71
- Forks
- 111
- Avg merge
- 1d 14h
- Merged PRs (30d)
- 110
Description
Please select the area the issue is related to
AI Workspace
Please select the aspect the issue is related to
Aspect/API (API backends, definitions, contracts, interfaces, OpenAPI), Aspect/UI (Frontend layouts, components, styling)
Description
On an App LLM Proxy's Guardrails & Policies tab, clicking Add under Global Guardrails & Policies opens a catalog panel with a Categories filter (defaulting to AI). Under that default filter, Word Count Guardrail never appears — not by scrolling, and not by typing its name into the search box.
Root cause: the panel fetches the catalog with a hardcoded limit=40. The AI category currently has 43 policies, returned alphabetically, so the last 3 — Token Based Ratelimit, URL Guardrail, Word Count Guardrail — fall past the cutoff and are silently dropped. The search box only filters the already-fetched 40 items client-side, so it can never surface one that didn't make the batch, no matter what's typed.
Suggested fix:
- Wire the search box to the catalog API's own
searchparam (server-side), instead of filtering the already-fetched page client-side. - Add pagination: load the next page via the API's existing
offsetsupport as the user scrolls to the bottom of the list (infinite scroll), instead of a one-shot capped fetch — so no category is silently truncated regardless of how large it grows.
Steps to Reproduce
- On any App LLM Proxy, go to Guardrails & Policies → Add (under Global Guardrails & Policies).
- Leave Categories on the default AI filter.
- Search
Word Count, or scroll the full list — no result; the list ends at "Time-Based Model Routing". - Switch Categories to Guardrails instead — Word Count Guardrail now appears.
Severity Level of the Issue
Severity/Critical (Core functionality is broken but there is a workaround. Need urgent attention)
Environment Details (with versions)
- AI Workspace console at
ai-workspace.bijira.dev - Observed 2026-09-09
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the missing Word Count Guardrail from the Guardrails & Policies tab with the default AI category, then trace the catalog API request used by the Add panel. Inspect how the search parameter and offset are handled, and verify that server-side search plus scrolling through additional pages makes all AI policies discoverable, including Word Count Guardrail.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- openapi
- Domain
- api, frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 65/100