Skip to content

feat: Upload a folder to knowledgebase #17026

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Silow9
Copy link

@Silow9 Silow9 commented Mar 28, 2025

Summary

Made modification to make the system support uploading a folder so that the system recursively retrieves all files within the folder and sequentially adds them to the upload list. Add a button to upload the folder.
Remember to modify the Knowledge Configuration and NGINX_CLIENT_MAX_BODY_SIZE in the file named .env.example in main menu to ensure the uploading is allowed for size limitation.
This function requires the Web Browser supporting HTMLInputElement.webkitdirectory. Currently supported in Chrome, Firefox and Edge.

Fixes: #14240 (comment)

Screenshots

image
image

Before After
image image

Checklist

Important

Please review the checklist below before submitting your pull request.

  • This change requires a documentation update, included: Dify Document
  • I understand that this PR may be closed in case there was no previous discussion or issues. (This doesn't apply to typos!)
  • I've added a test for each change that was introduced, and I tried as much as possible to make a single atomic change.
  • I've updated the documentation accordingly.
  • I ran dev/reformat(backend) and cd web && npx lint-staged(frontend) to appease the lint gods

Sorry, something went wrong.

Made modification to make the system support uploading a folder so that the system recursively retrieves all files within the folder and sequentially adds them to the upload list. Add a button to upload the folder.
By the way, remember to modify the Knowledge Configuration and NGINX_CLIENT_MAX_BODY_SIZE in the file named .env.example in main menu to ensure the uploading is allowed for size limitation.
@dosubot dosubot bot added size:M This PR changes 30-99 lines, ignoring generated files. 💪 enhancement New feature or request 📚 documentation Improvements or additions to documentation labels Mar 28, 2025
@Silow9 Silow9 changed the title Update index.tsx fix: Uploading a folder to knowledgebase Mar 28, 2025
@Silow9 Silow9 changed the title fix: Uploading a folder to knowledgebase fix: Upload a folder to knowledgebase Mar 28, 2025
@Silow9 Silow9 changed the title fix: Upload a folder to knowledgebase feat: Upload a folder to knowledgebase Apr 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
📚 documentation Improvements or additions to documentation 💪 enhancement New feature or request size:M This PR changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support Bulk Folder Import for Knowledge Base Management
1 participant