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

Add runtime parameters to component initialization #873

Merged
merged 2 commits into from
Mar 4, 2021

Conversation

oryx1729
Copy link
Contributor

@oryx1729 oryx1729 commented Mar 3, 2021

Pipelines allow specifying components to configured with YAML files.

Currently, some parameters like top_k can be set dynamically for each query and are not available in the __init__() of components.

This PR adds the missing parameters to enable configuring them with Pipelines.

Breaking change

The top_k_answers parameter in RAGenerator is renamed to top_k for consistency across components.

@oryx1729 oryx1729 changed the title WIP: Add runtime configurable params in init Add runtime parameters like top_k in __init__ Mar 3, 2021
@oryx1729 oryx1729 changed the title Add runtime parameters like top_k in __init__ Add runtime parameters to component initialization Mar 3, 2021
@oryx1729 oryx1729 requested a review from tholor March 3, 2021 13:08
Copy link
Member

@tholor tholor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@oryx1729 oryx1729 merged commit 4b188b8 into master Mar 4, 2021
@oryx1729 oryx1729 deleted the component-params branch March 4, 2021 11:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants