Add emu3 support to the `transformers` backend
Is your feature request related to a problem? Please describe.
https://github.com/baaivision/Emu3
Describe the solution you'd like
Describe alternatives you've considered
Additional context
@mudler if you have some context to provide on the integration of this i could look into adding this
@mudler if you have some context to provide on the integration of this i could look into adding this
that'd be great! As now emu3 seems to be working directly with transformers it would not need an entire backend from scratch, but actually adapting the existing transformers one to support how to run emu3 models (see https://github.com/baaivision/Emu3?tab=readme-ov-file#quickstart for example). The transformer backend is here https://github.com/mudler/LocalAI/tree/master/backend/python/transformers
Hi @mudler 👋
I'd like to work on this feature. Before diving in, I wanted to confirm my approach:
Proposed Implementation:
-
Start with Emu3-Chat support (vision-language understanding) as the simpler path:
- Add new model type handler in the transformers backend
- Load main model (
BAAI/Emu3-Chat) + VisionTokenizer (BAAI/Emu3-VisionTokenizer) - Integrate
Emu3Processorviatrust_remote_code=True - Handle image inputs for the
Predictendpoint
-
Follow-up PR for Emu3-Gen (text-to-image generation):
- More complex due to
LogitsProcessorList, classifier-free guidance, and decoding vision tokens back to images - Would need integration with
GenerateImageendpoint or a new method
- More complex due to
Questions:
- Does this phased approach make sense, or would you prefer both capabilities in a single PR?
- Should this live in the existing
transformersbackend, or would a separateemu3backend be preferred given the multimodal complexity?
Let me know your thoughts!
Hi @MkDev11 - to be fair the emu3 suite is slightly out of my radar now, there are many more powerful models already available. I think there are more interesting issues to pick from the ones labeled as roadmap ( https://github.com/mudler/LocalAI/issues?q=state%3Aopen%20label%3Aroadmap ).
However, if you feel to take a stab at it I don't mind. I would prefer that we keep in transformers, or either the vllm backend the implementation, as it seems also vllm supports emu3 nowadays.
Thanks for letting me know.
On Wed, Feb 4, 2026 at 12:20 PM Ettore Di Giacinto @.***> wrote:
mudler left a comment (mudler/LocalAI#3685) https://github.com/mudler/LocalAI/issues/3685#issuecomment-3848198781
Hi @MkDev11 https://github.com/MkDev11 - to be fair the emu3 suite is slightly out of my radar now, there are many more powerful models already available. I think there are more interesting issues to pick from the ones labeled as roadmap ( https://github.com/mudler/LocalAI/issues?q=state%3Aopen%20label%3Aroadmap ).
However, if you feel to take a stab at it I don't mind. I would prefer that we keep in transformers, or either the vllm backend the implementation, as it seems also vllm supports emu3 nowadays.
— Reply to this email directly, view it on GitHub https://github.com/mudler/LocalAI/issues/3685#issuecomment-3848198781, or unsubscribe https://github.com/notifications/unsubscribe-auth/AWOUTY6UQ2RKN6EW4KNTRQ34KIS5TAVCNFSM6AAAAACT5GHIDOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTQNBYGE4TQNZYGE . You are receiving this because you were mentioned.Message ID: @.***>
This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 5 days.
This issue was closed because it has been stalled for 5 days with no activity.