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.
PR Overview
This issue is linked to the issue #36 and focuses on implementing the functionality to take text_input from the user through the medium of Google Docs, it uses the support of Google Docs API which leverages its functionality to fetch the content from the specified doc.
Implementation Details:
a. Flask App: A Flask application is implemented to handle POST requests and respond with the content fetched from Google Docs.
b. URL Parser: A URL parser is implemented to identify the document ID from the provided Google Docs URL. This ID is essential for accessing the document's content via the Google Docs API.
c. Google Docs API Integration: The Google Docs API is utilized to retrieve the content of the specified document using the obtained document ID.
d. Content Scraping: Once the content is obtained from the Google Docs API, it is scraped to extract the text content. This involves navigating through the document's children nodes to extract relevant text.
e. Data Parsing: The extracted text content is parsed to the required models for further processing which in returns the generated pairs of Question and Answers and are then parsed into a locally set storage.
f. Question-Answer Pair Generation: The parsed text data is used to generate question-answer pairs. This process likely involves using models or algorithms designed for this purpose.
g. Rendering: The generated question-answer pairs are rendered within a model, likely an HTML file named
question_generator.html
, for user interaction or display.h. Credentials: Also you will have to place a seperate file
service_account_key.json
which contains our obtained credentials and the json file can be obtained from the Google developer console after enabling the Docs API.Current State:
Screencast.from.2024-03-29.13-26-29.webm