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

feat: Add functionality to incorporate directly markdown content (as string) when inserting documents #96

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

Conversation

ThomasDelsart
Copy link

This PR introduces the ability to directly pass markdown content as input when inserting documents into the database. Previously, only file paths (e.g., PDF) were supported, but with this change, users can now input a markdown string directly, making the process more flexible.

Changes:

  1. New Method: Created a method to generate a Document object from markdown content.
  2. Modified insert_document Function: Updated the insert_document function to include markdown content.
  3. Updated the Readme to explain the new feature

This change improves the workflow for users who need to insert markdown content directly, without requiring it to be written to a file first.

Testing:
This PR has been tested locally with a local setup.
Markdown data is correctly stored in the local sqlite database with the insert document functionality.

@ThomasDelsart ThomasDelsart added the enhancement New feature or request label Feb 17, 2025
@ThomasDelsart ThomasDelsart linked an issue Feb 17, 2025 that may be closed by this pull request
@ThomasDelsart ThomasDelsart changed the title Add functionality to incorporate directly markdown content when inserting documents feat: Add functionality to incorporate directly markdown content (as string) when inserting documents Feb 17, 2025
@ThomasDelsart
Copy link
Author

I did not add any tests for the insert_document markdown functionality to avoid disrupting any existing tests on the testing document (raglite_test_config fixture). However, I can add a test if needed.

Copy link

@rchretien rchretien left a comment

Choose a reason for hiding this comment

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

LGTM!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add ability to insert Markdown directly (not via Path)
4 participants