All posts
·4 min read

Let Claude Code Manage Your AI Prompts

AI coding tools like Claude Code and Codex can pull, edit, and publish prompts through the Montage CLI. Your AI engineer can manage your AI prompts.


There's a compelling loop emerging in AI development: using AI to manage AI.

With the Montage CLI, AI coding tools like Claude Code, OpenAI Codex, and Cursor can pull prompts from Montage, edit them, and publish new versions, all through terminal commands. No dashboard needed.

The Setup

Install the Montage CLI and authenticate:

npm install -g @montage-sh/cli
montage login

That's it. Any tool that can run terminal commands can now manage your prompts.

How It Works with Claude Code

Tell Claude Code what you want to change, and it handles the rest:

You: "Pull the customer-support-agent prompt and make the
     tone warmer and more conversational"

Claude Code:
$ montage pull customer-support-agent
$ # reads and edits the prompt file
$ montage push
$ montage publish customer-support-agent \
    --message "Warmer, more conversational tone"

Claude Code understands the prompt content, makes thoughtful edits, and publishes with a descriptive commit message. The change is live in production immediately.

Why This Matters

1. AI Tools Understand Context

When you ask Claude Code to "make this prompt better for handling refund requests," it doesn't just do string replacement. It reads the full prompt, understands the support context, and makes nuanced changes: adding escalation paths, adjusting the tone for sensitive topics, including relevant policy reminders.

This is harder to do in a web editor. It's natural in a conversation with an AI assistant.

2. Batch Operations

Need to update the tone across all 15 of your prompts? That's tedious in a dashboard. With Claude Code:

You: "Pull all prompts and update them to use a more
     concise, direct tone. Remove unnecessary filler
     phrases."

Claude Code:
$ montage pull
$ # edits each prompt file
$ montage push
$ montage publish --all --message "Concise tone update"

3. Code-Aware Prompt Changes

The real power is when prompt changes need to coordinate with code changes. Claude Code can:

  1. Read your application code to understand how a prompt is used
  2. Pull the prompt from Montage
  3. Edit both the prompt and the code in sync
  4. Push the prompt changes and commit the code changes
You: "The support agent prompt uses {{accountTier}} but our
     code sends {{planName}}. Fix both sides."

Claude Code:
$ montage pull customer-support-agent
$ # renames {{accountTier}} to {{planName}} in the prompt
$ montage push
$ # also updates the compile() call in src/api/support.ts

4. Review Before Publishing

You can also use Claude Code for prompt review:

You: "Pull the onboarding prompt and tell me if there are
     any issues with it"

Claude Code:
$ montage pull onboarding-welcome
$ # reads the prompt
> The prompt has a few issues:
> 1. It references {{companyName}} but never explains what
>    the company does, which could confuse the model
> 2. The instruction "be helpful" is vague. Consider
>    specifying what "helpful" means in this context
> 3. There's no output format guidance, so responses
>    will vary in structure

Setting Up for Your Team

Add Montage CLI commands to your project's CLAUDE.md or .cursorrules file:

## Prompt Management

This project uses Montage for prompt management.

- Pull prompts: `montage pull --project acme-ai`
- Push changes: `montage push`
- Publish: `montage publish <prompt-slug> --message "description"`
- List prompts: `montage list`

When editing prompts, use the CLI rather than editing code strings.

With this in place, AI coding tools automatically use Montage when working with prompts. No manual instruction needed each time.

The Loop

The workflow becomes:

  1. Developer (or PM, via the dashboard) identifies a prompt that needs work
  2. They tell their AI coding tool what to change, in natural language
  3. The AI tool pulls the prompt, edits it intelligently, and publishes
  4. The change is live in production immediately
  5. If something's wrong, rollback is one click in the dashboard

This is faster than editing in a dashboard, more intelligent than find-and-replace, and more accessible than writing code. It's the best of both worlds: the convenience of a CLI, the intelligence of an AI, and the safety of a managed prompt platform.

Your AI engineer managing your AI prompts. It's a loop that just makes sense.

cliai-toolsclaude-code

Written by Jeremy Seicianu