Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to config function_params when function_name == 'ranking' #111

Open
channing2222 opened this issue Dec 20, 2024 · 1 comment
Open

How to config function_params when function_name == 'ranking' #111

channing2222 opened this issue Dec 20, 2024 · 1 comment

Comments

@channing2222
Copy link

when I run the exampel 《Rating Movie Reviews (Scoring task)》, and change config_default.yml like this:

eval:
function_name: 'ranking'
num_large_errors: 4
num_boundary_predictions : 0
error_threshold: 0.5

but function_params is needded
elif config.function_name == 'ranking':
return utils.set_ranking_function(config.function_params)
else:

how to config function_params?
thanks

@Eladlev
Copy link
Owner

Eladlev commented Dec 20, 2024

Observe that when using the generation pipeline you should run:
https://github.com/Eladlev/AutoPrompt/blob/main/run_generation_pipeline.py

After the pipeline fits the ranking function, then in these lines (52-54)

generation_config_params.eval.function_params = ranker_config_params.predictor.config

We define the function config params (you can see there the exact format)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants