update-ai-sdk

update-ai-sdk is a cursor rule for Cursor from giselles-ai/giselle. It costs 11 tokens per session (585 once invoked), scanned A, original, Apache-2.0.

A maintenance guide for updating the AI SDK, a TypeScript toolkit for building applications that use different AI providers.

In plain words
What is it for?
Use it to check versions of the core SDK and provider packages, update pnpm catalog entries, and keep workspace dependencies aligned.
Why use it?
It explains how to find outdated AI SDK packages and update their shared versions in a pnpm workspace.

Cursor rule for Cursor

Written for Cursor: installed under .cursor/.

Good fit Use it to check versions of the core SDK and provider packages, update pnpm catalog entries, and keep workspace dependencies aligned.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/giselles-ai/giselle/update-ai-sdk
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.

Clone the repo
git clone --depth 1 https://github.com/giselles-ai/giselle

Made for: Cursor.

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 update-ai-sdk

README.md
[![agentmods](https://agentmods.dev/badge/rules/giselles-ai/giselle/update-ai-sdk/github.svg)](https://agentmods.dev/rules/giselles-ai/giselle/update-ai-sdk)
Your own site
<a href="https://agentmods.dev/rules/giselles-ai/giselle/update-ai-sdk"><img src="https://agentmods.dev/badge/rules/giselles-ai/giselle/update-ai-sdk/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for update-ai-sdk

Your own site · 80×15
<a href="https://agentmods.dev/rules/giselles-ai/giselle/update-ai-sdk"><img src="https://agentmods.dev/badge/rules/giselles-ai/giselle/update-ai-sdk.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 11 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 585 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.00011 $0.00585
Opus 5 $0.00005 $0.00293
Sonnet 5 $0.00002 $0.00117
Haiku 4.5 $0.00001 $0.00059

Measured 10d ago against content hash 99ac2dbb2201, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

update-ai-sdk 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 10d 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.

Origin

Copies of this mod

1 near-identical copy found in the catalogue:

.cursor/rules/update-ai-sdk.mdc · 87 lines

How it starts

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

Updating AI SDK in Giselle

This document provides a step-by-step guide for updating the AI SDK packages in this project.

What is AI SDK

The AI SDK is a TypeScript toolkit for building AI-powered applications using frameworks like Next.js, React, Svelte, Vue and Node.js runtimes. It provides a unified interface for working with different AI providers.

Package namespaces include ai and @ai-sdk/{provider} (such as @ai-sdk/openai, @ai-sdk/anthropic, etc.).

Step 1: Check current AI SDK versions

Check which AI SDK packages need to be updated:

pnpm outdated -r --json

Look for entries with ai and @ai-sdk/* in the results.

Step 2: Update catalog entries

This project uses pnpm's "Catalogs" feature to define dependency version ranges as reusable constants. These constants can be referenced in package.json files.

Update the catalog entries in pnpm-workspace.yaml:

catalog:
  "ai": 4.2.9              # Update to latest version
  "@ai-sdk/openai": 1.3.6   # Update to latest version
  "@ai-sdk/anthropic": 1.2.4 # Update to latest version
  "@ai-sdk/google": 1.2.5   # Update to latest version
  "@ai-sdk/react": 1.2.5    # Update to latest version
  "@ai-sdk/fal": 0.1.1      # Update if needed

Step 3: Install updated packages

Run the installation command to update all packages:

pnpm i

Step 4: Build the SDK

After fixing type issues, build the SDK:

pnpm build-sdk

When you see these errors, record them and seek guidance on how to address each specific case.

Step 5: Verify types

Run the type checking command to ensure there are no remaining type errors:

pnpm check-types

When you see these errors, record them and seek guidance on how to address each specific case.

Step 6: Test the application

Run the application and request user to make sure everything works as expected:

pnpm dev

Troubleshooting

If you encounter peer dependency warnings, they may be safely ignored if the application works correctly. However, if you encounter runtime errors, you may need to:

Read the full file on GitHub · 87 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. 10d ago First seen · 87 lines · 11 tokens per session scan A 99ac2dbb2201

Subscribe to this mod's changes

update-ai-sdk is a cursor rule published in the GitHub repository giselles-ai/giselle (555 stars, last pushed 8d ago), licensed Apache-2.0. It adds 11 tokens to every session and 585 once invoked, about $0.0001 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.