feat: create Jupyter notebook pipeline file based on main.py file#1134
Merged
peteryang1 merged 21 commits intomicrosoft:mainfrom Aug 5, 2025
Merged
feat: create Jupyter notebook pipeline file based on main.py file#1134peteryang1 merged 21 commits intomicrosoft:mainfrom
peteryang1 merged 21 commits intomicrosoft:mainfrom
Conversation
…t into pawang/generateNotebook
licong01-cloud
pushed a commit
to licong01-cloud/RD-Agent
that referenced
this pull request
Dec 13, 2025
…crosoft#1134) * First commit * isort * black * tweak prompt * fix for argparse * fix typo * add e2e * Add test files, clean * fix black settings * revert * fix trailing * remove extra * comment * small fix, updated prompt * Fix argparse * small improvements * fix for merge * fix for merge
yongbin4
pushed a commit
to yongbin4/RD-Agent
that referenced
this pull request
Mar 8, 2026
…crosoft#1134) * First commit * isort * black * tweak prompt * fix for argparse * fix typo * add e2e * Add test files, clean * fix black settings * revert * fix trailing * remove extra * comment * small fix, updated prompt * Fix argparse * small improvements * fix for merge * fix for merge
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Add support for a
NotebookConverterclass associated with the Pipeline coder, which is enabled with theDS_ENABLE_NOTEBOOK_CONVERSIONconfig. When the flag is enabled, additional prompt is passed to the Pipeline coder to add print statements in themain()function section which is used to properly split the .py file into .ipynb and re-attach outputs.Motivation and Context
.ipynb files can be useful for debugging after the agent has completed its execution loops. With this change we can generate both useful .py files and a reasonably formatted .ipynb file at the same time.
Known Limitations
RD-Agent/rdagent/utils/env.py
Line 550 in 512d08f
How Has This Been Tested?
Added unit tests in
test/notebook/test_util.pyScreenshots of Test Results (if appropriate):
Test Outputs
Types of changes
📚 Documentation preview 📚: https://RDAgent--1134.org.readthedocs.build/en/1134/