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

Refactor Pipeline peripherals #2253

Merged
merged 9 commits into from
Mar 3, 2022
Merged

Refactor Pipeline peripherals #2253

merged 9 commits into from
Mar 3, 2022

Conversation

tstadel
Copy link
Member

@tstadel tstadel commented Feb 25, 2022

Proposed changes:

  • move config helper methods to new module pipelines.config
  • move CodeGen and EvalReportGen to new module pipelines.utils
  • disassemble to_code tests into get_config and CodeGen tests
  • fix missing Pipeline import in to_code
  • decouple peripherals from actual Pipeline class, interfaces are pipeline_config or networkx graph
  • use networkx for dependency processing

Status (please check what you already did):

  • First draft (up for discussions & feedback)
  • Final code
  • Added tests

@tstadel tstadel requested a review from ZanSara February 25, 2022 19:08
@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

Copy link
Contributor

@ZanSara ZanSara left a comment

Choose a reason for hiding this comment

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

Great improvements! Also very happy about the tests 🤩 I left a few comments for some improvements here and there, but mostly minor stuff.

I just wished I was more explicit when I said where exactly I was going to mess with the Pipeline loading and validation part, because these changes are going to result in a hot mess of merge conflicts with my Pipeline validation PR 🥲 I'd rather merge yours first, mine is not ready yet: but I might need some help to deal with the damage later 😂

haystack/pipelines/config.py Show resolved Hide resolved
haystack/pipelines/config.py Show resolved Hide resolved
haystack/pipelines/config.py Show resolved Hide resolved
haystack/pipelines/config.py Show resolved Hide resolved
haystack/pipelines/config.py Outdated Show resolved Hide resolved
haystack/pipelines/utils.py Outdated Show resolved Hide resolved
rest_api/controller/file_upload.py Outdated Show resolved Hide resolved
test/test_pipeline.py Show resolved Hide resolved
test/test_pipeline.py Show resolved Hide resolved
test/test_pipeline.py Outdated Show resolved Hide resolved
@tstadel tstadel requested a review from ZanSara March 3, 2022 10:53
Copy link
Contributor

@ZanSara ZanSara left a comment

Choose a reason for hiding this comment

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

LGTM 👍 Just learned about the match parameter of pytest.raises(), I'm going to make use of it!

@tstadel tstadel added journey:advanced topic:pipeline type:refactor Not necessarily visible to the users labels Mar 3, 2022
@tstadel tstadel merged commit f7a0162 into master Mar 3, 2022
@tstadel tstadel deleted the add_pipeline_utils branch March 3, 2022 13:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic:pipeline type:refactor Not necessarily visible to the users
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants