Interface Lab
Back to knowledge
Knowledge Architecture RAG

Global Facet Index Contract

Sidebar facets for knowledge, asset, and style libraries should come from the full index, not only the current result subset; the results area explains the active query and filters.

Design Principle

Faceted navigation is both a retrieval control and an information-architecture map. If facets are derived only from the current result set, users lose adjacent categories after searching and RAG cannot reliably discover neighboring knowledge.

Large Theory

Library pages have two collections: the full library index and the current result set. The full index answers what structure exists here, while the current result set answers what this query matched. Sidebar categories, tags, types, licenses, platforms, and use cases should usually come from the full index; the result area explains the current result with count, active chips, matched excerpts, and empty recovery. This lets users narrow and also move sideways into adjacent categories.

Small Points

  1. Facet inventory comes from the full library or current scope, not only current filtered items.
  2. Active chips sit above results, can be removed one by one, and include reset all.
  3. Sidebar links preserve the query/tag/category that users intentionally keep instead of dropping context on every click.
  4. If facet counts react to the current query, expose loading, disabled, zero-count, or unavailable states clearly.
  5. Empty results show current constraints and offer remove-condition, view-all, submit-gap, or neighboring-category paths.
  6. RAG ingestion gives every entry category, tags, retrieval queries, and source fields so recall is not title-only.

Design Judgment

The contract works when a search still leaves the sidebar as a full knowledge map, the result area explains count and active filters, and users can remove query/category/tag independently.

Implementation Notes

Fetch items and allItems separately on the server: items uses query/filter/limit, while allItems uses the broad current-library scope. Compute categories and tags from allItems; show items.length and full-library count in the results area. Generate links through one query builder instead of hand-written strings. In the RAG schema preserve retrievalQueriesZh/En, category, tags, sourceLinks, and caseStudy.

Counterexamples/Risks

After search the sidebar has only one category; clearing category also drops the search term; result count lacks full-library context; empty results provide no condition removal; tags come from the current page of pagination instead of the full result set; synonyms have no retrieval query so agents miss the entry.

Case Study

NN/g describes facets as multi-dimensional filtering around different object attributes. A List Apart treats faceted navigation as a master pattern that shapes information architecture. Carbon Search and Empty states emphasize search scope, result state, and recovery paths. Applied to Interface-Lab, the knowledge sidebar must remain a full-library map while the result area explains the current query, so this entry directly constrains future knowledge, asset, and style-library implementations.

Source Links

NN/g Filters vs. Facets: https://www.nngroup.com/articles/filters-vs-facets/ A List Apart Faceted Navigation: https://alistapart.com/article/design-patterns-faceted-navigation/ Carbon Search Pattern: https://carbondesignsystem.com/patterns/search-pattern/ Carbon Empty States: https://carbondesignsystem.com/patterns/empty-states-pattern/ Azure AI Search Facets: https://learn.microsoft.com/en-us/azure/search/search-faceted-navigation

Agent Directive

Before generating a library page, distinguish allItems from filteredItems; sidebar facets default to the full index, and the result area must show count, active chips, empty recovery, and shareable URL state.