Guide ›

AI agents and MCP

Updated

On the Mac, RAF Film Lab can be driven by an AI agent such as Claude or Codex. The agent searches your library, looks at your photos, changes their looks, recipes and edits, culls, files them into albums and exports them, through the same paths as the app itself. Every change shows in the app as it happens, syncs like your own, and can be undone.

What you can ask

Agents are good at the work the editor makes tedious: anything rule-based, done to many photos, or done by looking and adjusting again and again.

Ask in your own words; you don't need to name the app. RAF Film Lab tells connected agents that it holds your photo library, so a request about your photos, imports, ratings, albums, looks or recipes goes to it.

Sample prompts

Finding and looking

Looks and edits

Culling and organising

Cameras and recipes

Exporting and undoing

If the agent looks somewhere else

Coding agents such as Codex and Claude Code can also read the files in the folder they're working in. Given a bare file name like “DSCF1234”, Codex may search that folder instead. Saying photo (“my photo DSCF1234”) is usually enough; naming RAF Film Lab always is.

To settle it for good, tell your agent app once. Add this line to its standing instructions: ~/.codex/AGENTS.md for Codex, ~/.claude/CLAUDE.md for Claude Code, or your personal or project instructions in Claude Desktop:

My photos are in RAF Film Lab. For anything about my photos, use its tools, not files on disk.

The agent sees each photo through previews the app renders for it, so it judges what the photo looks like, not just its settings.

Agents connect over the Model Context Protocol (MCP), an open standard supported by Claude Desktop, Claude Code, Codex and many other AI apps. The MCP server is part of the Mac app. On iPhone and iPad, the same actions are available in Shortcuts.

Turning agents on

Agents are off until you turn them on. Open Settings (⌘,) and find Agents:

Connecting Claude, Codex and other clients

RAF Film Lab comes with a small program, raffilmlab-mcp, inside the app. AI apps start it to talk to the library, and it opens RAF Film Lab in the background if it isn't running. Settings › Agents has buttons that copy the exact setup for wherever your app is installed; use those rather than typing the path. Pick your agent app:

Claude Code

Click Copy Claude Code Command and run it in Terminal. With RAF Film Lab in Applications, it is:

claude mcp add --scope user raf-film-lab -- "/Applications/RAF Film Lab.app/Contents/Helpers/raffilmlab-mcp"

--scope user makes the library available in every project. Check it with claude mcp list, or /mcp inside Claude Code.

Claude Desktop

Click Copy MCP Server Config (JSON). In Claude Desktop, open Settings › Developer › Edit Config, which opens claude_desktop_config.json, and add the server to mcpServers:

{
    "mcpServers": {
      "raf-film-lab": {
        "command": "/Applications/RAF Film Lab.app/Contents/Helpers/raffilmlab-mcp"
      }
    }
  }

If the file already has other servers, add raf-film-lab beside them. Quit and reopen Claude Desktop; RAF Film Lab's tools then appear under the tools menu in a chat.

Codex

OpenAI's Codex, in the terminal, the Codex app or the IDE extension, runs local MCP servers too. In Terminal, run:

codex mcp add raf-film-lab -- "/Applications/RAF Film Lab.app/Contents/Helpers/raffilmlab-mcp"

Or add the server to ~/.codex/config.toml yourself:

[mcp_servers.raf-film-lab]
  command = "/Applications/RAF Film Lab.app/Contents/Helpers/raffilmlab-mcp"

Every Codex app reads the same file, so this sets them all up. Check it with codex mcp list, or /mcp inside Codex.

The ChatGPT app can't connect. It reaches MCP servers only over the internet, and RAF Film Lab's server stays on your Mac. Use Codex with your ChatGPT account instead.

Cursor

Add the server to ~/.cursor/mcp.json to have it in every project, or to .cursor/mcp.json in one project:

{
    "mcpServers": {
      "raf-film-lab": {
        "type": "stdio",
        "command": "/Applications/RAF Film Lab.app/Contents/Helpers/raffilmlab-mcp"
      }
    }
  }

It then appears in Cursor's MCP settings, where you can switch it on and off.

VS Code (GitHub Copilot)

Run MCP: Open User Configuration from the Command Palette (⇧⌘P), or use .vscode/mcp.json for one project, and add:

{
    "servers": {
      "raf-film-lab": {
        "type": "stdio",
        "command": "/Applications/RAF Film Lab.app/Contents/Helpers/raffilmlab-mcp"
      }
    }
  }

VS Code calls the top-level key servers, not mcpServers. Use Copilot Chat in Agent mode to reach the tools.

Antigravity

Google's Antigravity CLI (agy), which replaced Gemini CLI, reads servers from ~/.gemini/config/mcp_config.json, or .agents/mcp_config.json in one project. Servers no longer go in Gemini CLI's settings.json.

{
    "mcpServers": {
      "raf-film-lab": {
        "command": "/Applications/RAF Film Lab.app/Contents/Helpers/raffilmlab-mcp"
      }
    }
  }

Check it with /mcp inside agy. In the Antigravity app, add the same entry from MCP Servers in the agent panel's … menu.

Other MCP clients

Any client that runs local (stdio) MCP servers works. Give it the helper's path as the command, with no arguments. The server speaks MCP protocol versions 2024-11-05, 2025-03-26 and 2025-06-18.

What agents can do

What an agent can do depends on what you allow in Settings. Photo ids come from search_photos, and changes can take up to 500 photos at once.

ToolWhat it does
View Only
search_photosFind photos by rating, flag, label, album, look, the film the camera recorded, camera, import date, last import or file name.
get_photoOne photo's details, lens and exposure, in-camera recipe and edits, and whether its develop is up to date.
render_previewThe photo as it looks now, up to 1024 pixels, or without its edits.
compareBefore and after, side by side.
list_looks, list_recipes, list_albumsThe looks, your saved recipes and your albums.
list_changesWhat agents have changed this session.
list_cameras, get_cameraThe cameras your photos were taken with, and what a model has: sensor, processor, the film simulations it has and the ones RAF Film Lab adds.
get_recipeA saved recipe and a link to share it.
read_camera_slotsThe custom settings (C1–C7) of a camera plugged in over USB, each as a recipe.
analyze_photosMeasure photos for culling: exposure and clipping, focus, faces and whether eyes look open, Vision's aesthetics score, and what's in the frame. All on your Mac.
group_similarFind bursts and near-duplicates: frames taken close together that look alike.
get_develop_statusFollow a develop: photos done and left, the one under way, and why it's paused or what failed.
read_recipeRead a recipe from a .recipe file, an X RAW Studio profile, or a picture of a recipe or its QR code.
View and Edit
set_lookDevelop photos with another look, keeping the rest of their recipe and their edits.
set_recipe_settingsChange in-camera settings: Dynamic Range, tone, colour, Color Chrome, grain, white balance and shift, push and pull.
apply_recipeApply a saved recipe (by name), a recipe link, or a recipe written out as text, keeping each photo's own push/pull.
create_recipe, update_recipeSave a new recipe, from a photo, another recipe, a link or text, or rename one and change its settings.
import_camera_slotsSave a plugged-in camera's custom settings as recipes.
save_recipe_to_cameraPut a saved recipe in one of the camera's custom settings. What the slot held is backed up first.
adjustChange edits: exposure, contrast, highlights, shadows, temperature and tint, vibrance, saturation, the HSL mixer, colour grading, effects, detail, straighten and crop. Values can be set, or added to each photo's own.
add_mask, update_mask, remove_maskEdit part of a photo: the subject, sky, background, people, a person or a face, a linear or radial gradient, or a colour or brightness range. Photos without what a mask selects, such as no sky, are left alone.
set_curveSet the tone curve, overall or for red, green or blue.
copy_edits, reset_editsCopy groups of one photo's edits to others, or take edits back to none.
save_snapshot, restore_snapshotKeep a photo's look and edits under a name, and go back to it.
make_virtual_copyA second version of a photo to edit apart from the first.
auto_tone, auto_straightenThe editor's Auto buttons, on many photos.
set_rating, set_flag, set_labelStars, pick or reject, and colour labels.
add_to_album, remove_from_albumFile photos into albums, making an album by name if needed.
create_album, rename_albumMake an album, or rename one.
list_import_folder, import_photosSee the RAFs in your import folder and import them, as the Import button does.
develop_photosDevelop photos' recipes on your Mac, or in the Fujifilm camera that shot them when it's plugged in, as the Develop panel does. Photos already developed with their recipe are skipped.
control_developPause, resume or stop a develop, or try its failed photos again.
undoTake back the last change.
View, Edit and Export
export_photosExport as JPEG, HEIC or 16-bit TIFF, at full size or smaller, into your export folder.
get_export_status, cancel_exportFollow or stop an export.
export_recipeWrite a saved recipe as a .recipe file, or an X RAW Studio profile for one camera, into your export folder.
View, Edit, Export and Delete
delete_album, delete_recipe, delete_snapshotDelete an album (its photos stay), a saved recipe, or a snapshot.
remove_photosTake photos out of the library, as Remove from Library does. The agent has to confirm, and this can't be undone.

Agents never change your original RAF files, and read files only from the import folder you choose. They can't paint brush masks or heal spots: those need a hand on the photo.

Looks and recipes

A new look or recipe is developed again in the background, on your Mac, the way Develop with Film Lab does, so the library and exports show it. Previews show the change straight away, before that develop finishes. To get the camera's own render instead, plug in the camera that shot the photos with CONNECTION MODE set to USB RAW CONV./BACKUP RESTORE and ask the agent to develop in the camera: a change can develop there directly, or develop_photos can develop photos there afterwards. The develop shows in the Develop panel, where you can pause or stop it too.

Undo and safety

Exporting

Agents export only into a folder you choose: set Agents can to View, Edit and Export, then click Choose… beside Export Folder. Agents can make folders inside it, but can't write anywhere else.

Importing

Agents import only from a folder you choose: set Agents can to View and Edit or higher, then click Choose… beside Import Folder. A memory card or the folder your camera's photos land in works well.

Prompts and resources

Some clients offer MCP prompts as ready-made tasks, often from a menu or a / command:

Clients that support resources can attach photos and lists to a conversation: photo://{id} for a photo's details, photo://{id}/preview for its preview, and library://looks, library://albums and library://recipes.

Shortcuts and Siri

On iPhone, iPad and Mac, RAF Film Lab adds actions to the Shortcuts app: Find Photos, Set Look, Apply Recipe, Rate Photos, Flag Photos, Add Photos to Album, Export Photos and Undo Last Library Change. Chain them: find last import's picks, set them to a look, export them, and save the files wherever the next action puts them. Some work with Siri too, such as “Find photos in RAF Film Lab”.

Shortcuts don't depend on the Agents setting; you build them yourself. Their changes can be undone the same way.

Privacy

See the privacy policy.

Troubleshooting

“RAF Film Lab isn't accepting agents”

The agent couldn't reach the app. Check that Let AI agents use the library is on in Settings › Agents, then reconnect the server in your agent app (in Claude Code or Codex, /mcp; in Claude Desktop, restart it).

The agent says it can't change, export or delete

Raise Agents can in Settings › Agents. The agent is told, and sees the new tools.

“No export folder is set” or “No import folder is set”

Choose one beside Export Folder or Import Folder in Settings › Agents.

A preview doesn't show a recipe change yet in the library

The photo is still developing in the background. Its develop status in get_photo says developing until it's done, and exports wait for it.

Moved the app?

The helper's path changes with it. Copy the command or config from Settings › Agents again and update your agent app.