Repository navigation
[BugFix] Fix MammothModa2 Text-to-Image Bug - #4299
Conversation
Signed-off-by: menjiantong <menjiantong@foxmail.com>
Signed-off-by: menjiantong <menjiantong@foxmail.com>
Signed-off-by: menjiantong <menjiantong@foxmail.com>
|
Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits. |
| self.tokenizer_class = "MammothUTokenizer" | ||
| self.architectures = ["Mammothmoda2Model"] | ||
|
|
||
| super().__init__(**kwargs) |
There was a problem hiding this comment.
Consider adding a regression test that verifies get_text_config() returns the correct nested text_config. This would prevent similar AttributeError issues in the future.
There was a problem hiding this comment.
Thanks for the feedback! I'll add a regression test.
| def ar2dit( | ||
| source_outputs: list[Any], | ||
| prompts: OmniTokensPrompt | TextPrompt | None = None, | ||
| prompts: OmniTokensPrompt | TextPrompt | list | None = None, |
There was a problem hiding this comment.
The type annotation list | None is broad. Consider using list[OmniTokensPrompt | TextPrompt] | None for better type safety, or adding a runtime isinstance check to validate the list contents.
There was a problem hiding this comment.
I'll fix this and push an update shortly.
75993f5 to
0e547c5
Compare
|
@hsliuustc0106 I've addressed your comments and ut are passing. ptal, thanks. |
|
@wtomin @SamitHuang PTAL |
wtomin
left a comment
There was a problem hiding this comment.
I think this fix looks good to me.
|
@yenuo26 I think this error message |
Signed-off-by: menjiantong <menjiantong@foxmail.com> Co-authored-by: menjiantong <menjiantong@foxmail.com> Co-authored-by: Didan Deng <33117903+wtomin@users.noreply.github.com>

Before submitting: run the precheck-pr skill with code agent for a self-check against project conventions — catches dead code, missing benchmarks, and title format issues.
PLEASE FILL IN THE PR DESCRIPTION HERE ENSURING ALL CHECKLIST ITEMS (AT THE BOTTOM) HAVE BEEN CONSIDERED.
Purpose
fix #4298
Test Plan
1*A800 80G
Test Result
Essential Elements of an Effective PR Description Checklist
supported_models.mdandexamplesfor a new model. Please runmkdocs serveto sync the documentation editions to./docs.BEFORE SUBMITTING, please read https://github.com/vllm-project/vllm-omni/blob/main/CONTRIBUTING.md
(anything written below this line will be removed by GitHub Actions)