New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add instructions on running llava-v1.6-mistral-7b #1115
base: main
Are you sure you want to change the base?
Conversation
FWIW I've pushed what I think are these patches to huggingface here |
Perhaps I'm doing something wrong, but these patches result in
|
i didnt observe this using the chair example. Try deleting the pad related additions? i actually dont have a concrete evidence saying pad is even necessary. |
Yea pad seem to be extra as they use unk as pad, so i guess should delete the pad related entries and set pad token id in various files to 0 (unk) |
@RonanKMcGovern thanks for posting the patched version on huggingface! Quick question: did you update to include @aliencaocao 's recent pad solution? |
Yeah pad is included but actually that is a bad idea and breaks generation.
Actually I’m not sure the patches are needed, rather, the loading script
from the evaluation file needs to be used to load the model. It’s messy.
There’s a vid I put on Trelis YouTube showing a bit on training. Probably
there are other better ways too.
…On Sat 2 Mar 2024 at 22:35, Rylan Schaeffer ***@***.***> wrote:
@RonanKMcGovern <https://github.com/RonanKMcGovern> thanks for posting
the patched version on huggingface! Quick question: did you update to
include @aliencaocao <https://github.com/aliencaocao> 's recent pad
solution?
—
Reply to this email directly, view it on GitHub
<#1115 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ASVG6CSPUZ2Q2WJ6MXKR4W3YWJH2JAVCNFSM6AAAAABDCVGQ52VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSNZUHEZDONZVGM>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
@RonanKMcGovern can you link the video? |
… On Sun 3 Mar 2024 at 06:38, Rylan Schaeffer ***@***.***> wrote:
@RonanKMcGovern <https://github.com/RonanKMcGovern> can you link the
video?
—
Reply to this email directly, view it on GitHub
<#1115 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ASVG6CRL7DW33JOXE66MNOTYWLAMXAVCNFSM6AAAAABDCVGQ52VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSNZVGA3DGNBVGE>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Thanks, the same applies to solving ”Cannot launch SGLang demo on llava-v1.5-13b“ |
After many hours of debugging, I finally got llava-v1.6-mistral-7b to work fully on SGLang inference backend.
This PR adds the relevant instructions to README.md, which references a PR I made on Hugging Face containing all the patches needed to make loading work.
Closes #1114
Closes #1112
Closes #1179
Also closes (from SGLang repo: sgl-project/sglang#128 )
Summary of patches:
added_tokens.json
and put:this was from https://huggingface.co/SurfaceData/llava-v1.6-vicuna-7b-processor/blob/main/added_tokens.json which is linked by sgl-project/sglang#127 (comment)
in
config.json
, changeLlavaMistralForCausalLM
toLlavaLlamaForCausalLM
,"model_type": "llava_mistral"
, to"model_type": "llava"
this was from [Bug] liuhaotian/llava-v1.6-mistral-7b doesn't load sgl-project/sglang#128 (comment)
change
generation config.json
to add a line before thetransformer_version
:"pad_token_id": 32001,
Add
preprocessor_config.json
from https://huggingface.co/SurfaceData/llava-v1.6-vicuna-7b-processor/blob/main/preprocessor_config.jsonspecial_token_map.json
addthis was from https://huggingface.co/SurfaceData/llava-v1.6-vicuna-7b-processor/blob/main/special_tokens_map.json
tokenizer_config.json
change to https://huggingface.co/SurfaceData/llava-v1.6-vicuna-7b-processor/blob/main/tokenizer_config.jsonDiffs:
and
But need to keep the
"chat_template"
row from original one (vicuna one dont have)