Examples
The example catalog is a set of executable behavior contracts — each app teaches a specific containment or verification behavior, with fixtures proving the unsafe paths too.
Tarski’s examples are not demos — they are executable behavior contracts. Each one teaches a specific platform behavior, and each proves its unsafe paths with fixtures, not only its happy paths. Browse and install them with the CLI:
tarski examples list
tarski examples install
Choose by what you need to learn
| You want to learn | Example |
|---|---|
| First-app authoring | Appointment booking |
| Recursive derivation and remediation gates | Incident response |
| Sensitive evidence and human review | Medical intake |
| External provider effects and replay | Price watch |
| Plugin-driven collection, offer history, blob archival | Google Shopping Price Monitor |
| LLM proposal containment | Car dealership chat (live / deterministic) |
| Multi-agent shared reality | Multi-agent live, incident response |
| Agent worldview reads, budgets, multi-hop loops | Incident response |
| Consent- and policy-gated agent reads | Medical intake |
| Your first declared query | Appointment booking |
| Consuming the query API externally | Price watch |
| Entity declarations and optimistic concurrency | Team Tasks |
| Verified end-user identity and tenant scoping | Member Portal, Team Tasks |
| Full-stack SDK consumption (React over serve) | Team Tasks web/ |
Highlights
Appointment booking is the tutorial app: invariants prevent double holds and double
bookings, and its first declared query (queries/booking-status.ta, exposed
studio, api) comes with a real tarski query booking-status transcript in its README.
Incident response is the flagship agent-read example: compound blast-radius queries
exposed to agents, a query budget of 2 enforced by decision rules with PM-readable denial
reasons ("budget_exhausted", "no_open_session"), and a backstop invariant that makes
over-approval an impossible state. Its fixtures prove multi-hop assessments, denied reads,
and failed reads.
Medical intake shows sensitive-evidence handling: candidate extraction with clinician
review, PHI projection boundaries, and consent-gated agent reads — the patient-history
query approves only when the worldview holds
medical.patient_consent(patient_id, "agent_history_review").
Car dealership chat ships in two canonical variants: car-dealership-chat-live uses a
live OpenAI model (requires OPENAI_API_KEY; a missing credential surfaces as a visible
warning, never a silent deterministic fallback) and car-dealership-chat-det replays
deterministic provider scripts for stable containment demos. Both share the same shape:
chat becomes evidence, assistant replies and offers enter via proposal.*, decisions
accept or reject, and policy-gated intents drive external sends.
Team Tasks is the collaborative-SaaS reference: tasks and comments as
entity declarations, tenant-scoped access facts, fail-closed
same-version conflicts, and a full React frontend under web/ consuming the published
@tarski/client package — reads are row-filtered projection calls, writes are
policy-gated observation appends with version-carrying idempotency keys, and live updates
arrive over a single declared-query subscription.
Member Portal is the identity-enabled example: verified IdP tokens become actor
context at ingress, the access.* account plane gates session starts and appends, tenant
notices are row-filtered per verified tenant, and fixtures cover revoked accounts,
contested sessions, and cross-tenant scoping.