A sandbox for testing knowledge base retrieval by selecting a KB, running a query, and inspecting returned chunks.
/utilities/testing/kb
Optional query parameter ?kb=<kbId> pre-selects the KB on load (used when navigating from a KB's detail page).
"Retrieval" for title and breadcrumb
[Retrieval] (page title / breadcrumb)
┌─────────────────────────────────────────────────────────────┐
│ Knowledge Base │
│ [Selected KB button] [Select KB] │
└─────────────────────────────────────────────────────────────┘
(no selection) (KB selected)
┌──────────────┐ ┌──────────────────────────────────────┐
│ Select a │ → │ Query panel │
│ KB above │ │ │
└──────────────┘ └──────────────────────────────────────┘
The selected KB is shown in the top selector button (icon + name). If no KB is selected, the page shows a placeholder prompt to select one.
Sends a query to the test endpoint and displays returned chunks ranked by relevance.
┌─────────────────────────────────────────────────────────────┐
│ Query │
│ │
│ ┌───────────────────────────────────────────────────────┐ │
│ │ Enter your query… (textarea, min 3 rows) │ │
│ └───────────────────────────────────────────────────────┘ │
│ │
│ ▸ Parameters (collapsible) │
│ Top K [ 5 ] │
│ Threshold [ 0.7 ] │
│ [Query →] │
│ │
│ Result │
│ ┌───────────────────────────────────────────────────────┐ │
│ │ Chunks: 4 Latency: 87 ms │ │
│ │ ┌─────────────────────────────────────────────────┐ │ │
│ │ │ #1 [0.94] doc-id │ │ │
│ │ │ "The quick brown fox…" │ │ │
│ │ ├─────────────────────────────────────────────────┤ │ │
│ │ │ #2 [0.81] doc-id │ │ │
│ │ │ "Lorem ipsum dolor…" │ │ │
│ │ ├─────────────────────────────────────────────────┤ │ │
│ │ │ #3 [0.67] doc-id │ │ │
│ │ │ "Sit amet consectetur…" │ │ │
│ │ └─────────────────────────────────────────────────┘ │ │
│ └───────────────────────────────────────────────────────┘ │
└─────────────────────────────────────────────────────────────┘
Behavior:
No results.POST /api/workspaces/[workspaceId]/kbs/[id]/testRuns retrieval against the selected KB and returns ranked chunks with latency. If the KB endpoint is unavailable or the request fails, an error is returned.