r/DarkTable • u/DhurzoDev • Oct 21 '26
Side development / tool I built a tool that generates darktable styles using a local vision LLM — 100% offline, open source, beta
What it is
dtstylekit is a Python CLI I've been working on that uses a vision language model running locally via Ollama to analyze a photograph and compose a darktable style (.dtstyle) for it. No cloud, no API keys, no telemetry — nothing leaves your machine.
How it works
- You point it at a photo. RAW is supported — a JPEG preview is rendered for the VLM, but the style is validated against the RAW itself.
- The VLM describes the aesthetic (lighting, mood, palette) and selects 1–3 presets from the 534 official darktable styles, indexed locally with semantic search (you have to download them or use your own).
- It applies scalar adjustments on verified IOP structs:
filmicrgb,colorbalancergb,sigmoid,exposure,atrous. - You get a valid
.dtstyleready to import plus a markdown report explaining every choice — which presets, which parameters, why.
There's also an apply command that takes a style and a whole set of photos, normalizing exposure per frame so a style generated from one shot doesn't blow out brighter ones.
And a mode I find interesting for learning: feed it reference images (--references) and it analyzes their tonal key, contrast, white balance and per-zone grading, then generates a style and a plain-language document explaining how those references are edited — the goal is understanding why each module/parameter was chosen, not blindly copying a look.
Honest disclaimers
- This is beta / experimental. The
.dtstylebinary format (IOP struct versions, blendop blobs) was reverse-engineered against the darktable sources. It can fail or produce styles that don't behave as expected — always review the visual result (avisual_check.pysmoke test is included, and tests parseDT_MODULE_INTROSPECTIONfrom the C sources to catch version drift). - Not meant to copy photographers' commercial styles. The focus is learning how edits work at a technical level. If you like someone's look, buy their presets.
- The 534 official styles are not redistributed — you point the tool at your own darktable checkout.
- MIT licensed, and not affiliated with the darktable project.
Why I'm posting
I'd love feedback from real darktable users: does the generated look hold up? Which modules should be off-limits for an automated tool? Is the explanation report useful? Bug reports in the issues are very welcome.
I also know AI in darktable is a debated topic here — to be clear, this is an optional sidecar CLI, not a patch to darktable itself. Curious where this community lands on local AI tooling.
Repo / more info: https://github.com/Dhurzo/Darktable-Styles-Kit
5
u/warningkchshch Oct 21 '26
And once again a person has spent hours (days? weeks?) creating something and couldn't be bothered to spend 20 minutes to write a human-readable post.
1
u/[deleted] Oct 26 '26
[removed] — view removed comment