Skip to content

Conversation

@staghado
Copy link
Contributor

@staghado staghado commented Oct 15, 2025

Purpose

This PR adds support for LightOnOCR: a SOTA 1B OCR VLM built on top of Mistral3 ViT and Qwen3 LM decoder.

Test Plan

Test Result


Essential Elements of an Effective PR Description Checklist
  • The purpose of the PR, such as "Fix some issue (link existing issues this PR will resolve)".
  • The test plan, such as providing test command.
  • The test results, such as pasting the results comparison before and after, or e2e results
  • (Optional) The necessary documentation update, such as updating supported_models.md and examples for a new model.
  • (Optional) Release notes update. If your change is user facing, please update the release notes draft in the Google Doc.

staghado and others added 4 commits October 15, 2025 14:12
Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
- Updated `supported_models.md` to include `LightOnOCRForConditionalGeneration`.
- Implemented `run_lightonocr` function in `vision_language.py` for handling LightOnOCR model requests.
- Registered LightOnOCR in the model registry for example usage.

Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
@github-actions
Copy link

👋 Hi! Thank you for contributing to the vLLM project.

💬 Join our developer Slack at https://slack.vllm.ai to discuss your PR in #pr-reviews, coordinate on features in #feat- channels, or join special interest groups in #sig- channels.

Just a reminder: PRs would not trigger full CI run by default. Instead, it would only run fastcheck CI which starts running only a small and essential subset of CI tests to quickly catch errors.

You ask your reviewers to trigger select CI tests on top of fastcheck CI.

Once the PR is approved and ready to go, your PR reviewer(s) can run CI to test the changes comprehensively before merging.

To run CI, PR reviewers can either: Add ready label to the PR or enable auto-merge.

If you have any questions, please reach out to us on Slack at https://slack.vllm.ai.

🚀

@mergify
Copy link

mergify bot commented Oct 15, 2025

Documentation preview: https://vllm--26916.org.readthedocs.build/en/26916/

@mergify mergify bot added documentation Improvements or additions to documentation new-model Requests to new models labels Oct 15, 2025
Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request adds support for the LightOnOCR model. The implementation is well-structured and follows the existing patterns for multimodal models within the vLLM project. I have identified one high-severity issue in the example script related to an unused function parameter, which could be misleading. My review includes a code suggestion to address this by adhering to a common Python convention for unused variables, which will improve code clarity.

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request adds support for the LightOnOCR model. The changes include updating documentation, adding an example, and implementing the model logic. The implementation is based on the Mistral3/Pixtral architecture. My review identified a critical bug in the input parsing logic that could lead to a crash, and a high-severity issue in token processing that might result in incorrect behavior. I have provided suggestions to address these issues. The other changes appear to be correct.

@vrdn-23
Copy link
Contributor

vrdn-23 commented Oct 15, 2025

Apologies if this obvious, but I can't seem to find the model on Huggingface. Could you provide a link to where the model is hosted?

@staghado
Copy link
Contributor Author

That's normal as the model is not released yet! This PR aims to add support for it so it's supported from the launch day. I can also provide more info if needed or provide a dummy model for testing the code.

@DarkLight1337
Copy link
Member

Thanks for adding your implementation to vLLM! Made some initial comments.

staghado and others added 6 commits October 16, 2025 09:51
…rted_models.md

Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
…mples

Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>

Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
Co-authored-by: Cyrus Leung <cyrus.tl.leung@gmail.com>
Signed-off-by: Said Taghadouini <84044788+staghado@users.noreply.github.com>
Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
… registry

Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
@staghado
Copy link
Contributor Author

Thanks for the quick feedback!
I tried to address the different points, let me know if there is something else to fix!

@DarkLight1337
Copy link
Member

/gemini review

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces support for the LightOnOCR model, a 1B parameter OCR Vision Language Model. The changes span documentation, examples, and the core model implementation, which appears to be well-integrated and follows the existing patterns for similar multimodal models in the repository. I've identified one critical issue in the new model implementation that could lead to a server crash under certain conditions and have provided a code suggestion to address it.

Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
Copy link
Member

@DarkLight1337 DarkLight1337 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the quick turnaround, have you verified that the model works correctly? If so then we can merge it.

Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
@staghado
Copy link
Contributor Author

I have verified by launching the model locally and it still works as before 🚀

Copy link
Member

@DarkLight1337 DarkLight1337 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM then, thanks for adding this!

@DarkLight1337 DarkLight1337 added this to the v0.11.1 milestone Oct 16, 2025
@DarkLight1337 DarkLight1337 enabled auto-merge (squash) October 16, 2025 14:05
@github-actions github-actions bot added the ready ONLY add when PR is ready to merge/full CI is needed label Oct 16, 2025
@staghado
Copy link
Contributor Author

staghado commented Oct 16, 2025

I have one final hf_to_vllm_mapper issue to fix to ensure the Transformers impl also can load the weights from the same repo!
cc @DarkLight1337

@DarkLight1337
Copy link
Member

Sure, tell me when that's done

Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
@staghado
Copy link
Contributor Author

it should be good now, thanks for waiting!

@DarkLight1337 DarkLight1337 enabled auto-merge (squash) October 16, 2025 15:34
Signed-off-by: Cyrus Leung <cyrus.tl.leung@gmail.com>
@DarkLight1337 DarkLight1337 merged commit 3aeb19a into vllm-project:main Oct 17, 2025
54 checks passed
Zhuul pushed a commit to Zhuul/vllm that referenced this pull request Oct 17, 2025
Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
Signed-off-by: Said Taghadouini <84044788+staghado@users.noreply.github.com>
Co-authored-by: Cyrus Leung <cyrus.tl.leung@gmail.com>
lywa1998 pushed a commit to lywa1998/vllm that referenced this pull request Oct 20, 2025
Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
Signed-off-by: Said Taghadouini <84044788+staghado@users.noreply.github.com>
Co-authored-by: Cyrus Leung <cyrus.tl.leung@gmail.com>
albertoperdomo2 pushed a commit to albertoperdomo2/vllm that referenced this pull request Oct 23, 2025
Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
Signed-off-by: Said Taghadouini <84044788+staghado@users.noreply.github.com>
Co-authored-by: Cyrus Leung <cyrus.tl.leung@gmail.com>
Signed-off-by: Alberto Perdomo <aperdomo@redhat.com>
alhridoy pushed a commit to alhridoy/vllm that referenced this pull request Oct 24, 2025
Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
Signed-off-by: Said Taghadouini <84044788+staghado@users.noreply.github.com>
Co-authored-by: Cyrus Leung <cyrus.tl.leung@gmail.com>
xuebwang-amd pushed a commit to xuebwang-amd/vllm that referenced this pull request Oct 24, 2025
Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
Signed-off-by: Said Taghadouini <84044788+staghado@users.noreply.github.com>
Co-authored-by: Cyrus Leung <cyrus.tl.leung@gmail.com>
Signed-off-by: xuebwang-amd <xuebwang@amd.com>
xuebwang-amd pushed a commit to xuebwang-amd/vllm that referenced this pull request Oct 24, 2025
Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
Signed-off-by: Said Taghadouini <84044788+staghado@users.noreply.github.com>
Co-authored-by: Cyrus Leung <cyrus.tl.leung@gmail.com>
Signed-off-by: xuebwang-amd <xuebwang@amd.com>
0xrushi pushed a commit to 0xrushi/vllm that referenced this pull request Oct 26, 2025
Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
Signed-off-by: Said Taghadouini <84044788+staghado@users.noreply.github.com>
Co-authored-by: Cyrus Leung <cyrus.tl.leung@gmail.com>
Signed-off-by: 0xrushi <6279035+0xrushi@users.noreply.github.com>
0xrushi pushed a commit to 0xrushi/vllm that referenced this pull request Oct 26, 2025
Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
Signed-off-by: Said Taghadouini <84044788+staghado@users.noreply.github.com>
Co-authored-by: Cyrus Leung <cyrus.tl.leung@gmail.com>
Signed-off-by: 0xrushi <6279035+0xrushi@users.noreply.github.com>
rtourgeman pushed a commit to rtourgeman/vllm that referenced this pull request Nov 10, 2025
Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
Signed-off-by: Said Taghadouini <84044788+staghado@users.noreply.github.com>
Co-authored-by: Cyrus Leung <cyrus.tl.leung@gmail.com>
Zhathw pushed a commit to Zhathw/vllm that referenced this pull request Nov 12, 2025
Signed-off-by: Said Taghadouini <taghadouinisaid@gmail.com>
Signed-off-by: Said Taghadouini <84044788+staghado@users.noreply.github.com>
Co-authored-by: Cyrus Leung <cyrus.tl.leung@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation new-model Requests to new models ready ONLY add when PR is ready to merge/full CI is needed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants