Skip to content

Can't load custom traineddata when not using full url #998

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

Open
ShammoJake opened this issue Jan 28, 2025 · 1 comment
Open

Can't load custom traineddata when not using full url #998

ShammoJake opened this issue Jan 28, 2025 · 1 comment

Comments

@ShammoJake
Copy link

ShammoJake commented Jan 28, 2025

Tesseract.js version (version number for npm/GitHub release, or specific commit for repo)
"tesseract.js": "^4.0.6",

Describe the bug
We are trying to load the custom language model (gdt_model_17) in the following way. But in the deployed server, when we use the shortened url ABC/login.html instead of the fully qualified url (ABC.abc.com/login.hml) the language loading fails. We tried manually providing the full url to the path, that gives CORS error.

Image

The worker files are being loaded properly.

Expected behavior
Language should load for shortened url.

Device Version:

  • Windows 11
  • Chrome browser
@hunxjunedo
Copy link

@jeromewu can I have a look at this ? I worked on a similar issue at Remotion a while ago.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants