Baidu's ERNIE multimodal team has released a specialized vector graphics model, "ERNIE Unlimited SVG," which can progressively reconstruct photos, screenshots, floor plans, part drawings, and paper structure diagrams into editable SVG vector code. The model is built on DeepSeek-OCR and uses a mixture-of-experts architecture, with about 3B total parameters and only about 0.5B activated per token. It supports global reasoning over 2048×2048 images.

SVG records lines, color blocks, coordinates, font styles, and layer occlusion relationships as code. It can be rendered directly into high-definition images and is also easy to check and modify item by item. Traditional models often need more than 10,000 tokens to generate a complete SVG for a complex image, making long-context processing slow and costly.
Runs locally, open source under MIT license
Unlimited-SVG first compresses an entire 2048×2048 image into just 1,024 visual tokens via DeepEncoder, while preserving details such as small text, fine lines, and precise spatial coordinates. The decoder relies on sparse activation computation, maintaining real-time generation even when tokens exceed 10,000. This allows SVG conversion of complex long sequences to be completed on a compact, locally deployable model, reducing reliance on cloud APIs.
The model is released under the MIT license and offers two inference methods: Transformers and vLLM. Its code and weights are available on GitHub and HuggingFace, along with an online demo. The official recommendation: when processing images that require precise geometry and text consistency, such as CAD drawings, use a lower sampling temperature; for natural scenes and photos, you can raise it appropriately to avoid repeated strokes and improve diversity.
Join Now