MCPcopy Create free account
hub / github.com/internetarchive/openlibrary / process_facet_counts

Function process_facet_counts

openlibrary/plugins/worksearch/code.py:287–293  ·  view source on GitHub ↗
(
    facet_counts: dict[str, list],
)

Source from the content-addressed store, hash-verified

285
286
287def process_facet_counts(
288 facet_counts: dict[str, list],
289) -> dict[str, tuple[str, str, int]]:
290 for field, facets in facet_counts.items():
291 if field == "author_facet":
292 field = "author_key"
293 yield field, list(process_facet(field, web.group(facets, 2)))
294
295
296async def execute_solr_query_async(

Callers 1

from_solr_resultMethod · 0.85

Calls 2

process_facetFunction · 0.85
itemsMethod · 0.45

Tested by

no test coverage detected