Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
ccran
/
auto-prompt
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
11820367
authored
Sep 14, 2025
by
ccran
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 发票重新生成
parent
404532bf
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
main.py
+1
-1
util.py
+1
-1
No files found.
main.py
View file @
11820367
...
...
@@ -50,7 +50,7 @@ if __name__ == "__main__":
default
=
"dataset/发票审查.json"
,
help
=
"val dataset path"
,
)
parser
.
add_argument
(
"--prompt_path"
,
type
=
str
,
default
=
"prompt/发票审查.txt"
,
help
=
"prompts dir"
)
parser
.
add_argument
(
"--prompt_path"
,
type
=
str
,
default
=
"prompt/发票审查
-init
.txt"
,
help
=
"prompts dir"
)
parser
.
add_argument
(
"--output_dir"
,
type
=
str
,
default
=
"output_dir"
,
help
=
"Path to output dir"
)
...
...
util.py
View file @
11820367
...
...
@@ -18,7 +18,7 @@ def eval_sample(item, eval_fn, model):
try
:
response
=
model
(
x
)
eval_output_variable
=
eval_fn
(
inputs
=
dict
(
prediction
=
response
,
ground_truth_answer
=
y
))
return
1
if
'
正确
'
in
eval_output_variable
.
value
else
0
return
1
if
'
你的判断结果为[正确]
'
in
eval_output_variable
.
value
else
0
except
Exception
as
e
:
print
(
'error in eval_sample: '
,
e
)
return
0
...
...
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