Skip to content

[scanner] site: tag-filtered indexes (/tags/<tag>/) - #139

Open
kubestellar-hive[bot] wants to merge 2 commits into
mainfrom
scanner/tag-indexes
Open

[scanner] site: tag-filtered indexes (/tags/<tag>/)#139
kubestellar-hive[bot] wants to merge 2 commits into
mainfrom
scanner/tag-indexes

Conversation

@kubestellar-hive

Copy link
Copy Markdown
Contributor

Adds two new statically-generated page templates and makes existing TagChip components clickable so a reader mid-incident with their RAG pipeline at 3am can click evals on an issue page and land on every featured-eval item across every issue.

Pages

  • /tags/ — landing page. Enumerates every distinct tag encountered on any featured item with an occurrence count. Sorted by count desc, then alpha.
  • /tags/<tag>/ — every featured item carrying <tag>, sorted date desc, then score desc. Shows title (linking to source), date (linking to /issues/<date>/), section, source, score bar, and summary excerpt.

Implementation notes

Straight from the issue:

  • Uses getCollection("issues") and flattens featured[].tags to drive both getStaticPaths() and the counts on /tags/.
  • Tags are the closed 13-tag vocabulary from the ranker prompt, but routing is data-driven — any tag that appears on a featured item gets its own page. Defensive against future vocabulary growth.
  • Appendix items intentionally excluded (they carry no tags — only featured items get the editorial treatment that includes tagging).
  • Hyphenated tags (tool-use, cost-latency) round-trip through Astro's default routing without URL encoding gymnastics.
  • Light + dark modes use existing --border / --accent CSS variables — no new theme tokens.

TagChip

Now a link by default (<a class="chip chip--link">). Callers that need a plain span (e.g. inside a larger clickable container) can pass static — no such caller exists today but the escape hatch is there.

Verification

Ran astro build locally against the existing test issue. Output:

  • /tags/agents/index.html generated with the featured item listed and score bar rendered.
  • /tags/index.html generated with agents (1) link.
  • Issue-page chips render as <a class="chip chip--link" href="/tags/agents/">agents</a>.

Pitfalls addressed

  • Statically generated at build time — no runtime computation.
  • Hyphenated tags round-trip cleanly.
  • No appendix leakage.

Fixes #7

Adds two new statically-generated page templates and makes existing
TagChip components clickable so a reader mid-incident with their RAG
pipeline at 3am can click `evals` on an issue page and land on every
featured-eval item across every issue.

Pages:

  /tags/                — landing page. Enumerates every distinct tag
                          encountered on any featured item with an
                          occurrence count. Sorted by count desc,
                          then alpha.
  /tags/<tag>/          — every featured item carrying <tag>, sorted
                          date desc, then score desc. Shows title,
                          date (linking back to the issue), section,
                          source, score bar, and summary.

Implementation notes (from the issue):

  - Uses `getCollection("issues")` and flattens `featured[].tags`
    to drive both getStaticPaths and the counts on /tags/.
  - Tags are the closed 13-tag vocabulary from the ranker prompt,
    but the routing is data-driven — any tag that appears on a
    featured item gets its own page. Defensive against future
    vocabulary growth.
  - Appendix items intentionally excluded (they carry no tags —
    only featured items get the editorial treatment that includes
    tagging).
  - Hyphenated tags (`tool-use`, `cost-latency`) round-trip through
    Astro's default routing without URL encoding gymnastics.
  - Light and dark modes use existing --border / --accent CSS
    variables; no new theme tokens.

TagChip is now a link by default (`<a class="chip chip--link">`).
Callers that need a static chip (e.g. inside a larger clickable
container) can pass `static` — I didn't find any such caller in the
current codebase, but the escape hatch is there.

Verified with `astro build`: the existing test issue produces
`/tags/agents/index.html`, `/tags/index.html`, and the issue-page
chips render as `<a class="chip chip--link" href="/tags/agents/">`.

Fixes #7
@kubestellar-hive kubestellar-hive Bot added the hold PR is on hold — do not merge label Jul 14, 2026
@github-actions

Copy link
Copy Markdown

Coverage report

This PR does not seem to contain any modification to coverable code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

hold PR is on hold — do not merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

site: tag-filtered indexes (/tags/<tag>/)

1 participant