Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
wangsen
MinerU
Commits
20bfa58b
Commit
20bfa58b
authored
Jul 03, 2025
by
myhloli
Browse files
fix: correct typos in parameter names in fast_api.py for consistency
parent
dec4fdef
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
9 deletions
+9
-9
mineru/cli/fast_api.py
mineru/cli/fast_api.py
+9
-9
No files found.
mineru/cli/fast_api.py
View file @
20bfa58b
...
@@ -34,10 +34,10 @@ async def parse_pdf(
...
@@ -34,10 +34,10 @@ async def parse_pdf(
formula_enable
:
bool
=
Form
(
True
),
formula_enable
:
bool
=
Form
(
True
),
table_enable
:
bool
=
Form
(
True
),
table_enable
:
bool
=
Form
(
True
),
server_url
:
Optional
[
str
]
=
Form
(
None
),
server_url
:
Optional
[
str
]
=
Form
(
None
),
re
u
turn_md
:
bool
=
Form
(
True
),
return_md
:
bool
=
Form
(
True
),
re
u
turn_middle_json
:
bool
=
Form
(
False
),
return_middle_json
:
bool
=
Form
(
False
),
return_model_output
:
bool
=
Form
(
False
),
return_model_output
:
bool
=
Form
(
False
),
re
u
turn_content_list
:
bool
=
Form
(
False
),
return_content_list
:
bool
=
Form
(
False
),
return_images
:
bool
=
Form
(
False
),
return_images
:
bool
=
Form
(
False
),
start_page_id
:
int
=
Form
(
0
),
start_page_id
:
int
=
Form
(
0
),
end_page_id
:
int
=
Form
(
99999
),
end_page_id
:
int
=
Form
(
99999
),
...
@@ -98,11 +98,11 @@ async def parse_pdf(
...
@@ -98,11 +98,11 @@ async def parse_pdf(
server_url
=
server_url
,
server_url
=
server_url
,
f_draw_layout_bbox
=
False
,
f_draw_layout_bbox
=
False
,
f_draw_span_bbox
=
False
,
f_draw_span_bbox
=
False
,
f_dump_md
=
re
u
turn_md
,
f_dump_md
=
return_md
,
f_dump_middle_json
=
re
u
turn_middle_json
,
f_dump_middle_json
=
return_middle_json
,
f_dump_model_output
=
return_model_output
,
f_dump_model_output
=
return_model_output
,
f_dump_orig_pdf
=
False
,
f_dump_orig_pdf
=
False
,
f_dump_content_list
=
re
u
turn_content_list
,
f_dump_content_list
=
return_content_list
,
start_page_id
=
start_page_id
,
start_page_id
=
start_page_id
,
end_page_id
=
end_page_id
,
end_page_id
=
end_page_id
,
)
)
...
@@ -128,16 +128,16 @@ async def parse_pdf(
...
@@ -128,16 +128,16 @@ async def parse_pdf(
if
os
.
path
.
exists
(
parse_dir
):
if
os
.
path
.
exists
(
parse_dir
):
if
re
u
turn_md
:
if
return_md
:
data
[
"md_content"
]
=
get_infer_result
(
".md"
)
data
[
"md_content"
]
=
get_infer_result
(
".md"
)
if
re
u
turn_middle_json
:
if
return_middle_json
:
data
[
"middle_json"
]
=
get_infer_result
(
"_middle.json"
)
data
[
"middle_json"
]
=
get_infer_result
(
"_middle.json"
)
if
return_model_output
:
if
return_model_output
:
if
backend
.
startswith
(
"pipeline"
):
if
backend
.
startswith
(
"pipeline"
):
data
[
"model_output"
]
=
get_infer_result
(
"_model.json"
)
data
[
"model_output"
]
=
get_infer_result
(
"_model.json"
)
else
:
else
:
data
[
"model_output"
]
=
get_infer_result
(
"_model_output.txt"
)
data
[
"model_output"
]
=
get_infer_result
(
"_model_output.txt"
)
if
re
u
turn_content_list
:
if
return_content_list
:
data
[
"content_list"
]
=
get_infer_result
(
"_content_list.json"
)
data
[
"content_list"
]
=
get_infer_result
(
"_content_list.json"
)
if
return_images
:
if
return_images
:
image_paths
=
glob
(
f
"
{
parse_dir
}
/images/*.jpg"
)
image_paths
=
glob
(
f
"
{
parse_dir
}
/images/*.jpg"
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment