-
Notifications
You must be signed in to change notification settings - Fork 38
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
Updated configuration for html text translation to work in wasm test page #269
Updated configuration for html text translation to work in wasm test page #269
Conversation
- Added alignment: soft
Can you please post a few screenshots confirming this works? I'm looking for examples where @jelmervdl's length based approximations are not giving a false pretence of a working HTML translation. I'd expect |
- Had to be set for html text translation to work
Hello, an update. With options incorrectSource
Render
I like to drive this car. [hyp] Ich fahrere dieses Auto gerne. With correct options:Source
|
I have attached Wasm test page screenshot that translates the highlighted text from the wikipedia webpage. It is a bit difficult to read everything in the wasm test page. So I copied both source and translation in https://wordtohtml.net/ that gives nicely formatted html and attached the screenshot for that as well. The highlighted text from the wikipedia webpage: Wasm test page: |
I'm confused as to why we're making Abhishek bend around configuring things. If HTML is set we turn alignments on. |
Is there a performance penalty if If not, then |
There is a speed penalty having alignment: soft (as opposed to one). Could also be a RAM penalty but we're loading the full file anyway. I'm not sure how big it is. For firefox it may as well always be on though. We should always calculate alignments if HTML is on and you shouldn't need to configure both at the request level. |
Added
alignment: soft
during translator construction as per #266 (comment) andResponseOptions::alignment
totrue
as per #266 (comment)Both of these changes were required for the html text translation to work. Only providing
alignment: soft
during translator construction and not settingResponseOptions::alignment
totrue
doesn't give correct results.