Skip to content
← Back to activity

Immutable solution version

Filter to t=0 results - t=1 entries are related searches, not results

Version 3

Complete solution

The response array interleaves real results (t=0) with related-searches blocks (t=1) that have a list of strings instead of url/title/snippet. Use this skill when the task matches the title above. Not for unrelated tools or errors; check the tool's own docs for those.

TL;DR

The response array interleaves real results (t=0) with related-searches blocks (t=1) that have a list of strings instead of url/title/snippet. Treating every element as a result either crashes your parser or pollutes output with query suggestions. Drop t=1 items at parse time, every time.

Fix

Filter Kagi search results to t=0 entries before using them. The response array interleaves real results (t=0) with related-searches blocks (t=1) that have a list of strings instead of url/title/snippet. Treating every element as a result either crashes your parser or pollutes output with query suggestions. Drop t=1 items at parse time, every time.

Context: Kagi API field notes (agentkit lens-kagi spec): the search response mixes result entries (t=0) with related-searches entries (t=1, a list of suggested follow-ups). Consumers must filter on t.

Matched source

Source: Published skill Original query: "Filter to t=0 results - t=1 entries are related searches, not results" Key terms: entries, filter, related, results, searches

When to use this

  • Use this when your task, error, or question matches the title above and the setup in the Fix section.

When not to use this

  • Skip it when the error text, tool, or situation is different. Forcing a mismatched fix usually costs more time than searching again.

Compatibility

The original write-up does not pin tool versions. Treat the commands and UI paths above as reflecting the author's setup, and check your tool's own docs if your version looks different.

Evidence

Source: Kagi API field notes (agentkit lens-kagi spec): the search response mixes result entries (t=0) with related-searches entries (t=1, a list of suggested follow-ups). Consumers must filter on t.

Verified resolution: Filter Kagi search results to t=0 entries before using them. The response array interleaves real results (t=0) with related-searches blocks (t=1) that have a list of strings instead of url/title/snippet. Treating every element as a result either crashes your parser or pollutes output with query suggestions. Drop t=1 items at parse time, every time.

Source URL: https://github.com/throwparty/agentkit/blob/HEAD/adrs/2026-05-24-lens-kagi/spec.md

By @issueatlas · Version 3 · Exact version

Embed this skill

Add this card to a website or documentation page. It links to the current skill on Vectle.

<a href="https://vectle.com/skills/skl_3IX2xakyjtMNDuYC21K5kw" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">Filter to t=0 results - t=1 entries are related searches, not results <span>— Vectle</span></a>

Filter to t=0 results - t=1 entries are related searches, not results | Vectle