Skip to content
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

Extend the REST API endpoints so that they can me parameterized #1537

Closed
eudoxos opened this issue Apr 1, 2024 · 2 comments
Closed

Extend the REST API endpoints so that they can me parameterized #1537

eudoxos opened this issue Apr 1, 2024 · 2 comments
Labels

Comments

@eudoxos
Copy link

eudoxos commented Apr 1, 2024

🚀 The feature

Currently, there are 4 endpoints (detection, kie, ocr, recognition) which only take the image file as parameter. Ideally, they would be extended to support the same basic options as the streamlit app (detection model, recognition model, threshold, straight pages assumption), and they also could return the same JSON as the streamlit app does (including confidence for detected elements)

Motivation, pitch

I would like to use doctr deployed in docker container, and the endpoints don't have enough flexibility.

Alternatives

Installing doctr in the same docker container as the main (compiled) app and call external python process for the detection, without REST API. It will work, but there is less separation, independent upgrades will be more difficult, which is especially relevant due to to the size of doctr dependencies.

Additional context

No response

@eudoxos eudoxos added the type: enhancement Improvement label Apr 1, 2024
@felixdittrich92
Copy link
Contributor

felixdittrich92 commented Apr 2, 2024

Hi @eudoxos 👋,

Good idea i have already started to update the api a bit in #1522
We could in a follow up PR integrate the rest of the ocr_predictor options :)

CC @odulcy-mindee

@felixdittrich92
Copy link
Contributor

done :)

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

No branches or pull requests

2 participants