{
  "slug": "redis-sunioncard-returns-set-union-cardinality-a778f237dd1e",
  "title": "Redis SUNIONCARD returns set-union cardinality",
  "tools": [
    "redis"
  ],
  "tags": [
    "agent"
  ],
  "introduced_at": "2026-07-29T17:20:06.000Z",
  "announced_at": "2026-07-29T17:20:06.000Z",
  "effective_at": null,
  "date_basis": "source-publication",
  "status": "unknown",
  "how": {
    "incantation": "When you need the number of distinct members across multiple Redis sets, run `SUNIONCARD` with the number of keys followed by the set keys.",
    "examples": [
      "SUNIONCARD 2 <set-key-1> <set-key-2>"
    ],
    "gotchas": [
      "Version: 8.10.0",
      "numkeys (required): Number of set keys that follow.",
      "key [key ...] (required): One or more set keys to union; missing keys count as empty sets.",
      "APPROX: Return an approximate cardinality instead of an exact count.",
      "LIMIT limit: Stop counting at this cardinality; 0 (the default) means unlimited. Works in exact and approximate modes.",
      "Prerequisite: Available since Redis Open Source 8.10.0."
    ]
  },
  "why_it_matters": "Get the cardinality of the union of multiple Redis sets.",
  "sources": [
    "https://github.com/redis/redis/releases/tag/8.10.0",
    "https://redis.io/docs/latest/commands/sunioncard/"
  ],
  "rank": 0.97023,
  "judge": {
    "publish": true,
    "judge_model": "codex-cli/gpt-6-luna+typesafe/jev-1.13.0",
    "prompt_version": "extract-v7+enrich-v2+judge-v2x3+jev-publish-v1"
  },
  "review_state": "approved",
  "provenance": {
    "run_id": "wave2a-20261017",
    "verdict_id": "wave2a-20261017:wave2a-20261017-dfb42c7a72492361-4:gate",
    "evidence_hash": "06e7d20c77ffd16ee32e1d08bbbd6a67cb805d9626d925df4df6916083a663e6"
  },
  "review": {
    "draft_hash": "77862b880e9a2e8605424841c3bad447fe1cf59d9a25638095c01e94d57fc444",
    "reviewer": "publication-gate",
    "reviewed_at": "2026-10-07T00:00:00.000Z",
    "decision": "wave2a-20261017:gate",
    "reason": "3 of 3 judge runs approved with p_yes >= 0.9 (mean 0.97 >= 0.9; 2 needed) and Jev gave 0.67 (>= 0.6 needed)."
  }
}
