Feature Summary
This feature enables automatic organization of documents in Google Drive by scanning the root folder for PDF, DOCX, and TXT files, using an AI-powered keyword extractor to determine a meaningful “bucket” name based on each filename, creating that folder if it doesn’t already exist, and then moving the file into that folder—fully hands-off once configured.
Related to milestone 8
Possible Solutions/Approaches
- One implementation is the current Python script:
- Authenticate with Google Drive via OAuth.
- List all untrashed files in the root.
- Download each file locally.
- Call the OpenAI API (GPT-3.5-Turbo) with a prompt that suggests an existing or new keyword based on the filename.
- Create or locate the corresponding Drive folder.
- Move the file into that folder and clean up the local temp file.
- A previously considered alternative was purely rule-based grouping (e.g. regex on course codes, dates, etc.), but it lacked flexibility for ad-hoc or unlabeled filenames.
- The current extension-based solution uses the file extension (
.pdf, .docx, .txt) to filter which files to process, making it easy to add or ignore new types by adjusting the extension list.
Relevant User Stories
- As a user, I want my loose documents to be automatically grouped into meaningful folders, so I don’t have to manually sort dozens of files each week.
- As a developer, I want a clear, extensible script that I can customize with additional file types or smarter AI prompts without rewriting the core Drive logic.
Acceptance Criteria (Key Requirements)
Feature Summary
This feature enables automatic organization of documents in Google Drive by scanning the root folder for PDF, DOCX, and TXT files, using an AI-powered keyword extractor to determine a meaningful “bucket” name based on each filename, creating that folder if it doesn’t already exist, and then moving the file into that folder—fully hands-off once configured.
Related to milestone 8
Possible Solutions/Approaches
.pdf,.docx,.txt) to filter which files to process, making it easy to add or ignore new types by adjusting the extension list.Relevant User Stories
Acceptance Criteria (Key Requirements)
token.pickle.