-
Notifications
You must be signed in to change notification settings - Fork 339
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
android app token to string issue #484
Comments
Hi! Just to clarify, is android app generating different tokens compared to python example or is it decoding tokens to string incorrectly? |
Dear @vraspar Hello. It's an issue with token decoding. Unlike English, the Phi model contains only a few Korean tokens, so generating a single Korean character often requires a combination of multiple tokens. I resolved the issue where the decoded string from a token wasn’t output by storing it and combining it with the next token before outputting. However, this is a temporary workaround. In |
@j0h0k0i0m Could you share the prompt you're using with the phi3.5 model? And what you expect as the returned decoded string? cc @wenbingl |
@baijumeswani Hello, the prompt format I used is as follows: Thanks. |
Hello. I am trying to run phi-3.5 ONNX on Android. I'm reaching out because I'm not sure how to resolve the issue related to token to string conversion. This occurs when I instruct it to output in a different language, and I confirm through the logs that the output is not being generated.
When I execute the phi 3.5 tokenizer in Python, the output is
안녕하세요!
, but the android output is안하세요!
.I want to decode three tokens([238, 136, 152]) to obtain the correct results. I would appreciate any guidance on how to achieve this.
Thank you.
The text was updated successfully, but these errors were encountered: