lucida
Background removal that keeps what matters: glass, camouflage, text, glow and line art. BiRefNet fine-tune, MIT.
Lucida is an AI background remover fine tuned to handle glass, camouflage, text with shadows, glow effects, and illustrations better than general purpose tools.
Lucida is an AI model that removes the background from photos and images, similar to tools you may have used to make a product photo transparent. What sets it apart is that it is specifically tuned to handle the cases where most background removal tools fail: see through glass and liquids, subjects that blend into their surroundings like camouflage, text and logos with soft shadows, glowing effects, line art illustrations, and print style designs such as stickers and t-shirt graphics.
The model is a fine tuned version of an existing open model called BiRefNet, meaning the creator took that base model and retrained it further on a large set of images built specifically around these tricky cases. The README includes a detailed benchmark comparing Lucida against several other background removal tools, including a paid commercial service, across nine categories of difficult images, measuring how closely each tool's output matches a hand verified correct answer. According to that benchmark, Lucida comes out ahead on the overall average and by a wide margin on categories like camouflage, print design, and text with shadows, while a couple of specialist competing tools still do somewhat better on complex multi object scenes and on hair.
The model's weights are hosted on Hugging Face and can be loaded with the popular transformers library in a few lines of Python code, and there is also a free browser based demo that processes an image in a few seconds without installing anything.
For local use, the project can be installed with the uv Python package manager or with plain pip, and it includes a command line tool for removing the background from a single image, a small web service built with FastAPI that other programs can send images to over HTTP, and a Docker setup for running it in a container. It is also distributed as part of ComfyUI's official model collection, a popular tool among AI image generation hobbyists, so it can be dropped directly into a ComfyUI workflow.
The project is written in Python. Both the model weights and the code are released under the MIT license.
Where it fits
- Remove the background from a product photo with transparent glass or liquid without losing detail.
- Clean up a logo or text image with a soft drop shadow into a transparent PNG.
- Run a local HTTP service so other apps can send it images and get background removed results.
- Use the model inside a ComfyUI workflow via its official model collection.