Spaces:
Running
Running
add pytesseract
Browse files- ocr/api/message/views.py +1 -0
ocr/api/message/views.py
CHANGED
@@ -11,6 +11,7 @@ async def get_all_chat_messages(
|
|
11 |
file: UploadFile = File(...)
|
12 |
) -> OcrResponseWrapper[OcrResponse]:
|
13 |
try:
|
|
|
14 |
contents = await file.read()
|
15 |
if file.filename.endswith('.pdf'):
|
16 |
images = divide_images(contents)
|
|
|
11 |
file: UploadFile = File(...)
|
12 |
) -> OcrResponseWrapper[OcrResponse]:
|
13 |
try:
|
14 |
+
|
15 |
contents = await file.read()
|
16 |
if file.filename.endswith('.pdf'):
|
17 |
images = divide_images(contents)
|