See llms.txt for all machine-readable content.
This workflow downloads a syllabus PDF from Google Drive, extracts and cleans the text, uses Google Gemini to identify assignments and due dates, then creates Google Calendar events for deadlines and study sessions and logs all created events to Google Sheets.
Get Syllabus PDF
Change the fileId and cachedResultName to point to different syllabi each term. You can keep a fixed Drive folder and simply update the selected file in the node UI. Ensure the file remains a PDF with actual text content.
Clean Syllabus Text
Extend the cleanText function to remove institution-specific headers or footer lines. For example, add more cleaned = cleaned.replace(...) rules for school logos, repeated disclaimers, or term banners.
Parse Assignments And Deadlines
Modify the prompt to adapt to your institution or terminology, or to request additional fields, such as weightage or exam type. Keep the JSON structure strict to avoid parsing issues.
Normalize Deadlines
Update the courseName logic to derive the course name from the syllabus text or another field, rather than using the existing default like “Class 10.” You can also change the priority thresholds or add more categories.
Generate Weekly Study Tasks
Change the study session logic by editing the sessionLengthHours and the scheduling logic. For example, you can replace the single-session code with a loop that creates multiple sessions by splitting a.estimated_hours into several blocks before the due date. The current implementation uses const sessionLengthHours = Math.min(a.estimated_hours || 3, 2).
Create Assignment Events / Create Study Session Events
Choose separate calendars for deadlines and study sessions, change event start times, or enrich the description with more context such as estimated_hours or a direct link to course materials.
Prepare Events For Sheet
Adjust the normalize function to parse additional metadata from event descriptions or to match different description formats if you change the calendar nodes.
| Issue | Possible Cause | Solution |
|---|---|---|
| Workflow runs but no assignments are created | Gemini response is not valid JSON or assignments array is empty | Check the Parse Assignments And Deadlines node output, adjust the prompt, and verify that the syllabus text includes clear assignment lines. |
| Normalize Deadlines throws “Failed to parse Gemini JSON” | Model output contains extra text or code fences around JSON | Ensure the prompt enforces JSON-only output, and keep the markdown fence removal logic in Normalize Deadlines. |
| Calendar events appear with wrong or missing dates | due_date is missing or not converted to ISO format | Verify due_date values in the Gemini output and the toISO function in Normalize Deadlines; adjust parsing rules if your dates use a different format. |
| No rows are added to Google Sheets | Google Sheets credentials, documentId, or sheetName are incorrect | Reconnect Google Sheets credentials, confirm the spreadsheet and tab IDs, and test Append row in sheet with sample data. |
| All events show up as unknown in Debug Summary | Prepare Events For Sheet cannot classify events as assignment_deadline or study_session | Inspect event descriptions and summaries to ensure they contain the keyword patterns used in normalize, or update the classification logic. |
| Study sessions do not align with expected dates | Generate Weekly Study Tasks uses a fixed offset of two days before due_date | Modify the baseDate logic and sessionLengthHours to match your desired spacing or to generate multiple sessions. |
| Image-only syllabus PDFs produce empty or poor text | Extract From File cannot read text from scanned or image-based PDFs | Use text-based PDFs only, or add an OCR step outside the current workflow design to convert images into text before processing. |
If you need assistance setting up this workflow, adapting it to a different syllabus format or extending it with additional add-ons, you can reach out to WeblineIndia for implementation support, customization and hiring n8n developers. Whether you want to add more study session logic, integrate other calendar systems or build related academic automation workflows, our expert help is always available to get this template fit your environment and scale with your needs.