Skip to content

Add index pages to the web UI (closes #91) - #112

Merged
paulirwin merged 1 commit into
mainfrom
issue/91
Oct 27, 2026
Merged

paulirwin merged 1 commit into
mainfrom
issue/91

Conversation

@paulirwin

Copy link
Copy Markdown
Member

Closes #91.

Adds an Indexes page to the dashboard (/browse, linked from the header between Status and Search) and a page per index (/browse/{name}). Everything goes through the Azure SDK, like the Search page.

The pages live under /browse because /indexes and /indexes/{name} are the API's own routes.

What the pages show

  • Index list: each index with its document count, size on disk, key field, and the optional features it uses (scoring profiles, suggesters, semantic, vector), with links to its page and to Search.
  • Fields tab: every field and its attributes (retrievable, searchable, filterable, sortable, facetable, analyzer or vector dimensions). Subfields of complex fields are indented under their parent. Below the table: scoring profiles, suggesters, semantic configurations, vector profiles and CORS.
  • Documents tab: steps through documents one at a time (first / previous / next / last, or jump to a number), or looks one up by key. Each document has a JSON view. If the key field is sortable, documents come in key order. The tab and position are kept in the address bar.
  • Definition tab: the raw JSON the emulator returns for the index.

Emulator changes

  • New: GET /indexes/{name}/stats (SearchIndexClient.GetIndexStatisticsAsync). Returns documentCount, storageSize and vectorIndexSize.
    • storageSize is the combined size of the index's files, so it isn't comparable to Azure's figure.
    • vectorIndexSize is always 0, because vectors are stored in the same files.
    • The endpoint takes an index name, not an alias.
  • Fixed: GetIndexesAsync failed on any index with scoring-profile text weights. The listing used OData's serializer, which wrote the weights as [{}] and left out semantic configurations and other unmodelled properties. It now uses the same JSON as GET /indexes/{name}, with $select applied by hand. ListEndpoint_DoesNotYetIncludeUnmodelledProperties, which documented the old gap, is now ListEndpoint_IncludesTheFullDefinition.
  • Fixed: search=* returned 400 on an index with no searchable fields. A wildcard now matches every document, as in Azure.

Dashboard fixes

  • Selected tab on the Search page never showed as selected. Blazor renders a true bool attribute as aria-selected="", which neither the CSS nor screen readers treat as selected. aria-busy had the same problem. Both are now written as "true"/"false".
  • Shared error helper. The Search page's error-envelope parsing moved to Dashboard/ErrorEnvelope.cs so both pages show the emulator's message rather than the SDK's full exception dump.

Tests

  • Unit: field-table flattening, document JSON extraction, byte formatting, storage measurement, and a wildcard search on an index with no searchable fields.
  • Integration: the new routes (and that GET /indexes still answers with JSON), GetIndexesAsync returning full definitions, and GetIndexStatisticsAsync before and after uploading documents.
  • All suites pass locally: 1,106 unit, 253 integration, 8 Aspire.

🤖 Generated with Claude Code

Adds an Indexes page listing every index with its document count and
size on disk, and a page per index with tabs for its fields and
configuration, its documents (paged one at a time or looked up by key),
and its raw JSON definition. Both go through the Azure SDK.

Along the way:
- Implement GET /indexes/{name}/stats (index statistics).
- Serialize the index listing like the single-index route, so
  GetIndexesAsync no longer fails on scoring-profile text weights and
  the listing includes semantic configurations.
- search=* matches every document even when the index has no
  searchable fields.
- Render aria-selected and aria-busy as "true"/"false", so the selected
  tab on the Search page is styled and announced.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@paulirwin
paulirwin merged commit 60211dc into main Oct 27, 2026
5 checks passed
@paulirwin
paulirwin deleted the issue/91 branch October 27, 2026 15:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Web UI: View indexes

1 participant