SiriCardKit AGENTS.md

SiriCardKit AGENTS.md is an instructions file for Codex, OpenCode from krispuckett/SiriCardKit. It costs 1,640 tokens per session, scanned A, original, MIT.

Repository instructions for building interactive Siri cards on iOS 26 and later with App Intents. They define how spoken commands, card rendering, and button actions must be separated.

In plain words
What is it for?
Use them when adding Siri snippet cards, spoken phrases, metadata, or controls to the SiriCardKit project. They also specify the required intent structure and rendering behavior.
Why use it?
They prevent common design and redraw problems, such as changing data while a card is only being displayed or presenting the card again from a button action. They also keep the card view independent from data stores and model calls.

Instructions file for CodexOpenCode

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add instructions/krispuckett/siricardkit/agents-md
Clone the repo
git clone --depth 1 https://github.com/krispuckett/SiriCardKit

Made for: Codex, OpenCode.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for SiriCardKit AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/krispuckett/siricardkit/agents-md.svg)](https://agentmods.dev/instructions/krispuckett/siricardkit/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/krispuckett/siricardkit/agents-md"><img src="https://agentmods.dev/badge/instructions/krispuckett/siricardkit/agents-md.svg" alt="Measured on agentmods" height="20"></a>
Per session 1,640 This file is loaded in full into every session.
When invoked 1,640 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.01640 $0.01640
Opus 5 $0.00820 $0.00820
Sonnet 5 $0.00328 $0.00328
Haiku 4.5 $0.00164 $0.00164

Measured 6d ago against content hash 4b91a88bc7a8, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

SiriCardKit AGENTS.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

AGENTS.md · 123 lines

How it starts

The opening of the file, as written. The whole thing — 123 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Agent rules for building Siri cards

You are building an interactive Siri snippet card (iOS 26+ App Intents). This repo contains a working reference implementation in Sources/CardKit/. Follow these rules exactly; each one was paid for with device debugging time. When a rule here conflicts with your prior knowledge, this file wins.

Architecture (non-negotiable)

  1. Three kinds of intent, three jobs:
    • The MAIN intent (DailyBriefIntent pattern): runs on the phrase, returns .result(dialog:snippetIntent:).
    • The SNIPPET intent (BriefSnippetIntent pattern): renders the card. Its perform() MUST be a pure read. The system re-runs it on every redraw. Set static var isDiscoverable: Bool { false }.
    • CONTROL intents (SnoozeIntent pattern): do the mutations. A background control returns plain .result() and the system re-runs the snippet intent automatically; never re-present the snippet from a control, and never point a button at the snippet intent itself.
  2. The card view holds only plain values passed in by the snippet intent. No stores, no queries, no model calls inside the view.
  3. Dialog is split: IntentDialog(full:supporting:). full is spoken, supporting is the one short line the sheet displays. Never let the sheet print a paragraph above a card that repeats it.
  4. Execution modes: data-only intents are .background; intents whose point is opening the app are .foreground(.immediate). If the host app has live navigation state, route warm launches through it and use a UserDefaults courier ONLY for cold launch, drained once after first frame.

Rendering (non-negotiable)

  1. NEVER use glassEffect, glassOrSolid, or any Liquid Glass API inside a snippet view. The Siri sheet is itself glass; nested glass makes real devices drop the whole card silently. The simulator will NOT show this failure. Use the kit's CardMaterial (plain gradients and strokes) instead. Transparency in the card reveals the system's own glass, which is the correct way to get a glass look; the kit's glass finish (finish: glass) is that way built in: a white frost, the whole foreground flipped to dark ink, zero glass API.
  2. Design for the light platter. Siri hosts the card on a milk-colored material. Any region of the card that fades toward transparent must not have text over it. Use CardMaterial.inkStops(): the shaped fade holds ink through all type and reaches zero only under the action wells. If a design needs text low on the card, raise CardMaterial.floor to 0.88. The ink's hue may be tinted (ink:) but never lightened: the kit clamps ink to the dark register so light text always survives, and on the glass finish it flips the foreground to dark ink for the same reason.
  3. Only Button(intent:) and Toggle(isOn:intent:) are interactive in a snippet. Button(action:) and gestures render but do nothing.
  4. Keep the card under roughly 340 points tall so the actions stay above the sheet's fold. Excerpt long text by whole sentences with BriefStore.cardExcerpt (budget 140 characters); never truncate mid-sentence and never rely on lineLimit alone.
  5. Fixed point sizes, not Dynamic Type styles: a snippet is a fixed canvas. Headline near 28 semibold, values 16 mono, labels 11 to 12 mono, body 15. Minimum text size is 11.
  6. Composition: one headline wins the glance; metric rows are label, value, unit on shared rails with values right-aligned in monospaced digits; stat columns come as one block of at most three cells and are the only element allowed near the headline's scale; at most one sentence of prose; at most two action wells, always last; the accent color appears exactly once (the state chip wears it when one exists, the eyebrow otherwise, and that is decided by the kit, not configured).

Read the full file on GitHub · 123 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 6d ago First seen · 123 lines · 1,640 tokens per session scan A 4b91a88bc7a8

Subscribe to this mod's changes

SiriCardKit AGENTS.md is an instructions file published in the GitHub repository krispuckett/SiriCardKit (56 stars, last pushed 12d ago), licensed MIT. It adds 1,640 tokens to every session, about $0.0082 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.