-
Notifications
You must be signed in to change notification settings - Fork 115
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
Allow users to build RAG versus Docling images #744
Conversation
Reviewer's Guide by SourceryThis pull request modifies the build script to allow users to build either a RAG or Docling image. The build script now installs either the docling or torch dependencies based on the image type being built. No diagrams generated as the changes look simple and do not need a visual representation. File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
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.
Hey @rhatdan - I've reviewed your changes - here's some feedback:
Overall Comments:
- Consider removing or clarifying the use of 'cat /tmp/nodocling.txt' if it's only for debugging purposes, as it might confuse users of the script.
- Using a hard-coded temporary file like '/tmp/nodocling.txt' could potentially lead to conflicts if multiple processes run in parallel. Consider using a more unique temporary filename or a different approach to filter the requirements to avoid race conditions.
Here's what I looked at during the review
- 🟢 General issues: all looks good
- 🟢 Security: all looks good
- 🟢 Testing: all looks good
- 🟢 Complexity: all looks good
- 🟢 Documentation: all looks good
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
Signed-off-by: Daniel J Walsh <[email protected]>
${PYTHON_VERSION} pip install torch --extra-index-url https://download.pytorch.org/whl/$1 | ||
tmpfile=$(mktemp) | ||
grep -v docling requirements.txt > ${tmpfile} | ||
${PYTHON_VERSION} pip install -r /tmp/nodocling.txt --prefix=/usr |
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.
@rhatdan when this code is executed:
https://github.com/containers/ramalama/actions/runs/13356993323/job/37301130079?pr=831
it complains with this:
- grep -v docling requirements.txt
- python3 -m pip install -r /tmp/nodocling.txt --prefix=/usr
ERROR: Could not open requirements file: [Errno 2] No such file or directory: '/tmp/nodocling.txt'
Error: building at STEP "RUN sh /tmp/build_pragmatic.sh ${GPU} ${CONTENT}": while running runtime: exit status 1
Error: Process completed with exit code 1.
Summary by Sourcery
Add support for building RAG images.
New Features:
Tests: