Back to .md Directory

NexusTime: Intelligent Multi-Calendar Scheduler

Describes a client-side SPA that parses.ics files, ranks meeting slots by fuzzy availability, and drafts invites via Gemini API.

May 2, 2026
0 downloads
0 views
ai rag gemini
View source

What this file does

Describes a client-side SPA that parses.ics files, ranks meeting slots by fuzzy availability, and drafts invites via Gemini API.

When to use it

  • Building a multi-calendar scheduling tool with privacy-first browser processing
  • Adding fuzzy availability scoring (not just free/busy) to a meeting scheduler
  • Integrating Gemini API for context-aware meeting invitation generation
  • Creating a visual heat map of participant availability from.ics files

Assumes this stack

React 18TypeScriptTailwind CSSGemini API@google/genai

NexusTime: Intelligent Multi-Calendar Scheduler

Abstract

NexusTime is a lightweight, client-side Single Page Application (SPA) designed to solve the "availability tetris" problem. By ingesting standard .ics calendar files (common in Outlook, Google, Apple), it algorithmically determines optimal meeting slots. Unlike binary "free/busy" tools, NexusTime provides a fuzzy availability score, ranking time slots based on how many participants can attend. It features a clean, mobile-first UI and leverages Google's Gemini API to draft context-aware meeting invitations based on the selected slot.


Detailed Analysis & Architecture

1. Core Philosophy

  • Privacy First: All calendar parsing and logic happen in the browser. No calendar data is sent to a server.
  • Resilience: Handles imperfect data by offering "best possible" matches, not just perfect matches.
  • Simplicity: Drag-and-drop interface with immediate visual results.

2. Architecture

  • Frontend Framework: React 18 with TypeScript for type-safe logic.
  • Styling: Tailwind CSS for rapid, responsive, and aesthetic UI development.
  • State Management: React useState and useMemo for filtering and sorting slots efficiently.
  • Services:
    • IcsParser: A regex-based service to extract VEVENT data (Start, End, Summary) from raw text files.
    • SchedulerEngine: A time-bucket algorithm. It discretizes the timeline into 15-minute chunks, calculates a "heat map" of availability, and aggregates chunks into viable meeting slots.
    • GeminiService: Utilizes @google/genai to generate professional meeting invites or analyze schedule conflicts.

3. Features

  1. Multi-File Ingestion: Accepts multiple .ics files, assigning a unique color/identity to each.
  2. Dynamic Duration: User can adjust meeting length (e.g., 30m, 60m), instantly recalculating available slots.
  3. Availability Ranking:
    • Tier 1 (Green): 100% of calendars are free.
    • Tier 2 (Yellow): >75% of calendars are free.
    • Tier 3 (Orange): >50% of calendars are free.
  4. Conflict Visualization: Clearly shows who is missing in a partial match.
  5. GenAI Invitation: One-click generation of a meeting email draft using the chosen time and context.

4. Implementation Steps

  1. Scaffolding: Setup React DOM and Tailwind.
  2. Data Layer: Create strict TypeScript interfaces for Calendar, Event, and TimeSlot.
  3. Parser Logic: Implement a robust .ics reader that normalizes dates (handling UTC/Z timezones).
  4. Scheduling Algorithm: Implement the intersection logic to find and rank gaps.
  5. UI Components:
    • Uploader: File input.
    • Controls: Duration slider.
    • Results: Masonry or Grid layout of time cards.
  6. Integration: Connect Gemini API for the "Draft Invite" feature.

What's inside

Abstract, philosophy, architecture, 5 features, 6 implementation steps, and 3 service descriptions.

Change this for your project

  • Replace @google/genai with your own Gemini SDK import if different
  • Replace IcsParser regex patterns if your.ics files use non-standard date formats
  • Replace GeminiService prompt template with your own meeting draft wording

Where it goes

Keep it in your repository where the agent or team that needs it will read it.

Worth borrowing

  • Discretizing time into 15-minute chunks for a heat map of availability
  • Tiered availability ranking (100%, >75%, >50%) to handle partial matches gracefully

Related Documents