darktable-mcp
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": false
} |
| experimental | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| view_photosA | Browse photos in the user's darktable library. Filter by filename substring, minimum star rating, or both. Returns id, filename, absolute file path, and rating per match — the path can be passed straight into export_images. Requires darktable to be running with the darktable-mcp Lua plugin installed (see darktable-mcp install-plugin). |
| rate_photosB | Apply a star rating to one or more photos in the user's darktable library. Requires darktable to be running with the darktable-mcp Lua plugin installed. |
| import_batchA | Register a folder as a film roll in the user's darktable library. Useful when you've copied photos from a card or external drive and want darktable to know about them. Returns the count of newly-imported photos. Requires darktable to be running with the darktable-mcp Lua plugin installed. |
| list_stylesA | List all darktable styles (presets) installed on the user's system. Returns name and description for each. Required discovery step before calling apply_preset, since style names must match exactly. Requires darktable to be running with the darktable-mcp Lua plugin installed. |
| apply_presetA | Apply a darktable style (preset) to one or more photos. The preset_name must exactly match a style name from list_styles. Returns counts of applied and missed photos. Requires darktable to be running with the darktable-mcp Lua plugin installed. |
| import_from_cameraA | Use when a camera or memory card is physically connected. Detects the camera via libgphoto2 and copies all photos to a local directory, then returns the destination path. Copying alone does not put the photos in the library: follow up with import_batch on that destination path to register them as a film roll. Files are written one subdirectory per camera folder or card, prefixed with the camera's identity (e.g. /Nikon_D850_sn_30014567_store_00010001_DCIM_100NCD80/DSC_0001.NEF), because camera filenames repeat across folders, across the two cards of a dual-slot body, and across bodies importing into the same destination. Import the destination recursively. A file that would collide with a different photo already on disk is kept alongside it as -2., never overwritten. This holds for two bodies of the same model that report no serial number and therefore share a subdirectory: before skipping files a destination appears to already hold, such a camera is asked for a small sample of them and the bytes are compared, so a second body's photos are kept rather than dropped. Re-running is cheap: a body with a serial number transfers nothing it already delivered. Any file the card lists that does not reach the destination is reported by name. Cost: this tool runs to completion synchronously and does not return early. A full card can take many minutes, up to the 1 hour default timeout, which is longer than most MCP clients wait for a single request. Progress is observable while it runs by tailing the .import.log file in the destination directory. |
| extract_previewsA | Extract auto-rotated JPEG previews from a directory of raw files (NEF/CR2/ARW/DNG/etc) for vision-based rating. Each preview is rotated upright via EXIF orientation and resized to max_dim (default 1024). A smaller thumb_dim (default 384) is also written for token-efficient first-pass culling. Returns a list of items with preview paths plus an EXIF summary (ISO, shutter, focal, aperture, datetime) per file. The scan is recursive, and the output tree mirrors the source tree, so raws with the same filename in different subdirectories get distinct previews. Read the preview path from each item rather than assuming /.jpg. |
| apply_ratings_batchA | Write XMP sidecars (xmp:Rating) for a batch of {stem: rating} pairs. Each sidecar sits next to its raw file at .xmp and is picked up automatically by darktable on import. Rating range: -1 (reject), 0 (unrated), 1-5 (stars). Each rating is also appended to /ratings.jsonl for replay/audit. An existing sidecar is never replaced: only its rating value is rewritten, so darktable edit history survives. A sidecar with no recognisable rating is skipped with an error rather than overwritten. |
| open_in_darktableA | Launch the darktable GUI on a folder. The folder is registered as a film roll on first launch and XMP sidecars are picked up automatically. The lighttable opens already filtered via the official |
| export_imagesA | Export photos to JPEG/PNG/TIFF via darktable-cli. Pass absolute file paths in photo_ids — the |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 10 tools
Most tools map cleanly to a distinct resource+action (import, browse, rate, style, export, preview, GUI launch). The one genuine overlap is rate_photos vs apply_ratings_batch — both write star ratings, one via the running darktable library and one via XMP sidecars for pre-import files — and view_photos vs extract_previews both surface photos, though the rich descriptions clarify the library-browsing vs file-preview distinction.
All tools are snake_case and verb-first, following a readable verb_noun convention (view_photos, list_styles, export_images, extract_previews). Minor deviations: import_from_camera and open_in_darktable use prepositional phrases, and the 'batch' suffix appears in both import_batch and apply_ratings_batch with slightly different grammatical roles, but the overall pattern stays predictable.
Ten tools is well-scoped for the domain: two import paths, library browsing, two rating mechanisms, style discovery/application, preview extraction, export, and GUI launch. Each tool occupies a distinct step in the photo-management workflow and none feels like filler.
The end-to-end pipeline is covered: copy from camera → register film roll → browse → rate → apply style → export, plus an alternative XMP-sidecar rating path that darktable picks up on launch. Missing operations like metadata editing, style creation, photo deletion, and richer library search (tags, dates) are workable gaps rather than dead ends.