-
Notifications
You must be signed in to change notification settings - Fork 16
feat: adding pipeline breakpoints #271
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
Conversation
* initial import from work done on haystack branch * adding missing Exception and code examples * adding missing Exception * David/pipeline testing (#254) * adding ByteStream example * serialising posixpath objects * fixing tests * fixing namespace import * fixing namespace import * adding examples to ruff check excludes * typo * test cases with loops * Add the last component's input to debug state * Revert "Add the last component's input to debug state" This reverts commit fb98b3d. * Add the last component's input to debug state (#256) * fix: fixing deserialisation issues - working version with Hybrid Pipeline tests (#257) * adding ByteStream example * serialising posixpath objects * fixing tests * fixing namespace import * fixing namespace import * adding examples to ruff check excludes * typo * adding verbosity to examples * fixing deserialisation issues * linting * Fix deserilzation errors in resuming (#258) * Fix deserilzation erros * Adding tests * adding tests * nit cleaning * adding debug_path to pipeline and tests for breakpoint/resume * working for all components in a Hybrid RAG * linting * linting * fixing tests * adding extra dependencies * fixing pyproject.toml * replacing tests model by a smaller one --------- Co-authored-by: David S. Batista <[email protected]> * fix: starting from clean state (#260) * wip: debugging more pipelines * wip: debugging more pipelines * adding more tests * cleaning * cleaning * cleaning * cleaning * cleaning * cleaning * typing * fix: removing all sender keys before serialisation (#261) * removing all sender keys * cleaning * cleaning * removing unused function * fixing header file issue * fix: hybrid pipeline working with stop/resume at each breakpoing (#262) * wip: debugging hybrids * wip: debugging hybrids * cleaning * ruffing * removing unused imports * Add a test file for loops * Fix major bugs in serialization (#266) * Fix issues with chat messages * Update the transform structure method to preserve data type of value * Fixed the issue with GeneratedAnswer * fix: `Adaptor` will need `unsafe=True` for the break/resume to work properly (#267) * adaptor needs unsafe=True + another extra list in a Joiner component * adding missing dependencies * triggering end2end tests for answers joiner pipeline * adding pipeline with list joiner tests * test: adding one more test with another Joiner (#268) * cleaning * marking tests as integration tests * nit documentation * fixing pipeline.py * PR comments * Remove passing component param to resume functions * Include load state in the resume process * Improve based on comments * Update haystack_experimental/core/pipeline/pipeline.py Co-authored-by: Sebastian Husch Lee <[email protected]> * only breaking at the exact visit number * moving imports to the top * Improvements * Improve deserialization * Fix linting * Add warning for unreached breakpoints * Fix typing issues * updating errors.py * Fix integration tests * skipping some tests under certain conditions --------- Co-authored-by: Amna Mubashar <[email protected]> Co-authored-by: Sebastian Husch Lee <[email protected]>
Pull Request Test Coverage Report for Build 14468881142Details
💛 - Coveralls |
…ing (#274) * ading missing code to deserialise and safeguard for resume state in RAG hybrid * tests passing for test_pipeline_breakpoints_answer_joiner * tests passing for test_pipeline_breakpoints_branch_joiner * tests passing for test_pipeline_breakpoints_list_joiner * tests passing for test_pipeline_breakpoints_loop * tests passing for test_pipeline_string_joiner * cleaning * skipping macOS tests for RAG hybrid * adding missed import
…iles (#275) * initial import * fixing tests * temporary removing delay and rerun from integration tests * temporary removing delay and rerun from integration tests * fixing windows tests * cleaning * reverting delay and rerun from integration tests * fixing tests
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks quite good to me already. I suggest mainly some changes to the tests and errors.py seems duplicated.
…spective tests (#277) * initial import * cleaning init * fixing errors.py duplication * fixing linting * fixing pipeline run time error * fixing pipeline run time error * fixing pipeline run time tests
* OpeanAI calls mocked * cleaning imports * adding a mocked TransformersSimilarityRanker * adding a mocked SentenceDocumentEmbedder * mocking rag hybrid pipeline components that make external calls * reverting skip on macOS due to pytorch/sentence-transformers lib * reverting skip on macOS due to pytorch/sentence-transformers lib * mocking all OpenAIChatGenerator calls in the pipeline breakpoint tests * reverting skip on macOS due to pytorch/sentence-transformers lib
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should remove the dependencies from pyproject.toml that are no longer needed in the tests. After that, I approve merging this PR taking into account it's experimental. My other comments don't have to be addressed before merging.
When we later merge this into the haystack repo, we should reuse mock_openai_chat_generator
instead of creating it multiple times. I understand that right now we return different replies so I am okay with keeping it as is in haystack-experimental. Other parts of the tests could be simplified too, such as the mock_run of the ranker https://github.com/deepset-ai/haystack-experimental/pull/271/files#diff-e44ef907c05488db310dbbea4b3d25ef2460679547b9aa2465115804f8e7432fR94 or the file path parsing with os.name == "nt"
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! 👍
Related Issues
Pipeline
checkpoints #269 for more detailsHow did you test it?
Checklist
fix:
,feat:
,build:
,chore:
,ci:
,docs:
,style:
,refactor:
,perf:
,test:
.