You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
None of the APIs in swagger can be called, and the parameter validation is incorrect, but the UI interface works fine:
curl -X 'POST'
'http://10.26.176.91:5001/v1alpha/convert/file'
-H 'accept: application/json'
-H 'Content-Type: multipart/form-data'
-F 'do_code_enrichment=false'
-F 'pipeline=standard'
-F 'ocr_engine=easyocr'
-F 'images_scale=2'
-F 'pdf_backend=dlparse_v4'
-F 'picture_description_local={"repo_id":"HuggingFaceTB/SmolVLM-256M-Instruct","prompt":"Describe this image in a few sentences.","generation_config":{"do_sample":false,"max_new_tokens":200}}'
-F 'do_picture_description=false'
-F 'from_formats=docx'
-F 'force_ocr=false'
-F 'image_export_mode=embedded'
-F 'do_ocr=true'
-F 'page_range=1,20'
-F 'do_table_structure=true'
-F 'ocr_lang=en'
-F 'include_images=true'
-F 'do_formula_enrichment=false'
-F 'table_mode=accurate'
-F 'picture_description_api={"url":"http://localhost:8000/v1/chat/completions","headers":{},"params":{"max_completion_tokens":200,"model":"HuggingFaceTB/SmolVLM-256M-Instruct"},"timeout":20,"prompt":"Describe this image in a few sentences."}'
-F '[email protected];type=application/vnd.openxmlformats-officedocument.wordprocessingml.document'
-F 'abort_on_error=false'
-F 'to_formats=md'
-F 'return_as_file=false'
-F 'do_picture_classification=false'
-F 'document_timeout=604800'
Error: Unprocessable Entity
{
"detail": [
{
"type": "int_parsing",
"loc": [
"body",
"page_range",
0
],
"msg": "Input should be a valid integer, unable to parse string as an integer",
"input": "1,20"
},
{
"type": "missing",
"loc": [
"body",
"page_range",
1
],
"msg": "Field required",
"input": [
"1,20"
]
},
{
"type": "model_attributes_type",
"loc": [
"body",
"picture_description_local"
],
"msg": "Input should be a valid dictionary or object to extract fields from",
"input": "{"repo_id":"HuggingFaceTB/SmolVLM-256M-Instruct","prompt":"Describe this image in a few sentences.","generation_config":{"do_sample":false,"max_new_tokens":200}}"
},
{
"type": "model_attributes_type",
"loc": [
"body",
"picture_description_api"
],
"msg": "Input should be a valid dictionary or object to extract fields from",
"input": "{"url":"http://localhost:8000/v1/chat/completions","headers":{},"params":{"max_completion_tokens":200,"model":"HuggingFaceTB/SmolVLM-256M-Instruct"},"timeout":20,"prompt":"Describe this image in a few sentences."}"
}
]
}
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
None of the APIs in swagger can be called, and the parameter validation is incorrect, but the UI interface works fine:
curl -X 'POST'
'http://10.26.176.91:5001/v1alpha/convert/file'
-H 'accept: application/json'
-H 'Content-Type: multipart/form-data'
-F 'do_code_enrichment=false'
-F 'pipeline=standard'
-F 'ocr_engine=easyocr'
-F 'images_scale=2'
-F 'pdf_backend=dlparse_v4'
-F 'picture_description_local={"repo_id":"HuggingFaceTB/SmolVLM-256M-Instruct","prompt":"Describe this image in a few sentences.","generation_config":{"do_sample":false,"max_new_tokens":200}}'
-F 'do_picture_description=false'
-F 'from_formats=docx'
-F 'force_ocr=false'
-F 'image_export_mode=embedded'
-F 'do_ocr=true'
-F 'page_range=1,20'
-F 'do_table_structure=true'
-F 'ocr_lang=en'
-F 'include_images=true'
-F 'do_formula_enrichment=false'
-F 'table_mode=accurate'
-F 'picture_description_api={"url":"http://localhost:8000/v1/chat/completions","headers":{},"params":{"max_completion_tokens":200,"model":"HuggingFaceTB/SmolVLM-256M-Instruct"},"timeout":20,"prompt":"Describe this image in a few sentences."}'
-F '[email protected];type=application/vnd.openxmlformats-officedocument.wordprocessingml.document'
-F 'abort_on_error=false'
-F 'to_formats=md'
-F 'return_as_file=false'
-F 'do_picture_classification=false'
-F 'document_timeout=604800'
Error: Unprocessable Entity
{
"detail": [
{
"type": "int_parsing",
"loc": [
"body",
"page_range",
0
],
"msg": "Input should be a valid integer, unable to parse string as an integer",
"input": "1,20"
},
{
"type": "missing",
"loc": [
"body",
"page_range",
1
],
"msg": "Field required",
"input": [
"1,20"
]
},
{
"type": "model_attributes_type",
"loc": [
"body",
"picture_description_local"
],
"msg": "Input should be a valid dictionary or object to extract fields from",
"input": "{"repo_id":"HuggingFaceTB/SmolVLM-256M-Instruct","prompt":"Describe this image in a few sentences.","generation_config":{"do_sample":false,"max_new_tokens":200}}"
},
{
"type": "model_attributes_type",
"loc": [
"body",
"picture_description_api"
],
"msg": "Input should be a valid dictionary or object to extract fields from",
"input": "{"url":"http://localhost:8000/v1/chat/completions","headers":{},"params":{"max_completion_tokens":200,"model":"HuggingFaceTB/SmolVLM-256M-Instruct"},"timeout":20,"prompt":"Describe this image in a few sentences."}"
}
]
}
Beta Was this translation helpful? Give feedback.
All reactions