- 30 Apr, 2025 1 commit
-
-
Wang Yubo authored
I have updated the `/file_parse` endpoint in `app.py` to correctly handle boolean and string parameters when they are sent via `multipart/form-data` requests (commonly used for file uploads). Previously, these parameters were not being properly parsed because FastAPI expects them to be passed as query or JSON body parameters by default. ### Changes Made: - Added `Form(...)` to all non-file parameters (`parse_method`, `is_json_md_dump`, `output_dir`, and return flags like `return_layout`, etc.). - This ensures that FastAPI correctly reads these fields from form-data, allowing clients to send both files and structured configuration options in the same request. ### Why This Change Was Needed: - When using `requests.post(..., data=data, files=files)`, the `data` dictionary is sent as form-encoded data. - Without explicitly declaring these fields with `Form(...)`, FastAPI does not bind them correctly, leading to default values always being used (e.g., `False` for boolean flags). - This change allows the API to accurately reflect the client's intent and enables features like `return_layout`, `return_images`, etc., to work as expected. This update improves compatibility with HTTP clients that rely on standard form-based file upload mechanisms while preserving the existing behavior of the API.
-
- 21 Apr, 2025 1 commit
-
-
myhloli authored
- Add '.jpeg' to the list of supported image extensions in app.py and read_api.py - Update projects READMEs to indicate that web_demo is deprecated
-
- 14 Mar, 2025 2 commits
-
-
JesseChen1031 authored
-
JesseChen1031 authored
-
- 14 Feb, 2025 6 commits
- 03 Jan, 2025 1 commit
-
-
yzz authored
-
- 12 Dec, 2024 1 commit
-
-
icecraft authored
-
- 24 Nov, 2024 1 commit
-
-
icecraft authored
-
- 27 Sep, 2024 1 commit
-
-
myhloli authored
Add the web_api project to the lists of projects in both the English and Chinese README.md files, providing a brief description and linking to the project's documentation. Ensure that the formatting and style are consistent with the existing project entries.
-
- 09 Sep, 2024 1 commit
-
-
quincyqiang authored
* features@add mineru gpu&web_api * features@update api
-