dagster: Command for Claude Code

.claude/commands/ai_update_pr.md

ai_update_pr is a command for Claude Code from dagster-io/dagster. It costs 0 tokens per session (731 once invoked), scanned A, original, Apache-2.0.

A command that delegates the full pull-request update process to a specialized coding agent. It analyzes the repository, gathers the change's purpose, and creates a concise PR summary.

In plain words
What is it for?
Use it to analyze current repository changes, collect missing context, and update a PR with a brief structured summary.
Why use it?
It reduces the context and writing work needed to keep a PR description accurate. It focuses the summary on why and what changed instead of repeating the diff line by line.

Command for Claude Code

Written for Claude Code: installed under .claude/. Also seen: mentions subagents.

This is dagster-io/dagster's own configuration. It tells Claude Code how to work on dagster itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything dagster configures →

About the project

Dagster is a platform for developing, running, and observing data assets, such as datasets and the processes that produce them. It is used to organize and automate data workflows.

dagster-io/dagster · 16,114 stars · on GitHub · dagster.io

Reuse

Borrowing it

Nothing to install: this file belongs to dagster-io/dagster. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/dagster-io/dagster/master/.claude/commands/ai_update_pr.md
Clone the repo
git clone --depth 1 https://github.com/dagster-io/dagster

Made for: Claude Code.

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 ai_update_pr

README.md
[![agentmods](https://agentmods.dev/badge/commands/dagster-io/dagster/ai_update_pr.svg)](https://agentmods.dev/commands/dagster-io/dagster/ai_update_pr)
Your own site
<a href="https://agentmods.dev/commands/dagster-io/dagster/ai_update_pr"><img src="https://agentmods.dev/badge/commands/dagster-io/dagster/ai_update_pr.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 731 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.00000 $0.00731
Opus 5 $0.00000 $0.00365
Sonnet 5 $0.00000 $0.00146
Haiku 4.5 $0.00000 $0.00073

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

Security

Grade A, and why

ai_update_pr 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 7d 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.

.claude/commands/ai_update_pr.md · 69 lines

How it starts

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

AI Update PR (Subagent-Optimized)

Use the specialized PR Update Expert agent to handle the complete AI-assisted PR workflow with optimized context management.

Use the Task tool to invoke the pr-update-expert subagent:

I'll update your PR using the optimized AI workflow that handles repository analysis, thesis collection, and PR body generation with improved context management.

The agent will:

  1. Repository Analysis: Execute dagster-dev ai-review-analyze --json --minimal --smart-summary for optimized state checking

  2. Thesis Management: Handle existing thesis detection and interactive collection

  3. AI Analysis: Generate structured PR summaries with human-AI content separation, adapting detail level based on change complexity:

    CRITICAL BREVITY REQUIREMENTS:

    • NEVER replicate diff content - summaries should capture intent, not implementation details
    • Maximum 2-3 sentences for simple to medium changes
    • Focus on WHY and WHAT, not HOW - avoid line-by-line analysis
    • Default to concise - err on the side of too brief rather than too verbose

    Complexity Guidelines:

    • Simple changes (single-line fixes, typos, minor tweaks): 1 sentence maximum
    • Technical fixes (import reorganization, compatibility fixes, lazy loading): 1-2 sentences describing the high-level approach, NO file-by-file breakdowns
    • Medium changes (function additions, config updates, isolated features): 2-3 sentences with key impact points
    • Complex changes (architectural changes, multiple classes/functions, cross-cutting concerns): Brief paragraph focusing on architectural decisions, not implementation specifics
    • Large but simple changes (file splits, refactoring without logic changes): 1-2 sentences about structural intent, ignore line counts
  4. Atomic Updates: Execute dagster-dev ai-review-update --auto-prepare with proper escaping

Anti-Patterns to Avoid

❌ NEVER DO THIS:

  • File-by-file change listings ("Updated file X to do Y, modified file Z to include W...")
  • Line-by-line diff recreation ("Added import X, changed function Y from A to B...")
  • Verbose implementation details that mirror the actual code changes
  • Long bullet lists describing every small modification

Read the full file on GitHub · 69 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. 7d ago First seen · 69 lines · 0 tokens per session scan A a82300d0868c

Subscribe to this mod's changes

ai_update_pr is a command published in the GitHub repository dagster-io/dagster (16,114 stars, last pushed 2d ago), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 731 tokens. 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.