Skip to main content
Full-Stack AI Productivity Platform
Source-Verified Implementation

Stelix Command Center

AI productivity command center unifying Gmail and Google Calendar with a Groq-powered multi-step tool-calling agent in Next.js and Express.

Role: Full-Stack Developer
Stelix Command Center Interface Preview

Project Overview

Stelix Command Center is an AI-powered communication and scheduling platform engineered to eliminate context switching between email inboxes and calendar applications.

Built with Next.js 16, Express 5, PostgreSQL, Drizzle ORM, and Google OAuth 2.0, the platform connects directly with Gmail and Google Calendar through Corsair integrations.

A conversational AI assistant powered by Groq's high-speed Llama models interprets natural language instructions into multi-step tool calls, enabling users to read emails, draft replies, check schedule availability, and create calendar events from one unified interface.

The Problem & Motivation

  • Knowledge workers spend significant time context switching back and forth between email threads and calendar tabs to negotiate meeting times, verify dates, and send invites.
  • Standard email and calendar clients treat communication and scheduling as separate silos, requiring repetitive manual copy-pasting of event details and attendee emails.
  • The technical goal was to engineer a unified workspace with an AI tool-calling assistant that helps automate communication workflows while keeping actions inspectable by the user.

Architectural Solution

  • Architected a decoupled system: a high-speed Next.js 16 frontend paired with a modular Express 5 TypeScript backend running PostgreSQL and Drizzle ORM.
  • Implemented Google OAuth 2.0 integration requesting scoped authorization for Gmail and Google Calendar APIs via the Corsair framework.
  • Developed an AI Agent service using the Groq SDK that parses natural-language prompts into structured tool executions for email search, draft generation, calendar inspection, and event scheduling.
  • Built a persistent conversation and activity feed that displays tool execution results alongside email threads and calendar timelines.

Technology Stack & Evidence

Technologies categorized by source verification and documented implementation scope:

Frontend Client

Next.js 16 (App Router)
React 19
Tailwind CSS 4
Radix UI Primitives
React Hook Form
Zod

Backend Service & APIs

Express 5
Node.js 22
TypeScript
Corsair SDK
Google Auth Library
Winston Logger

AI & Tool Orchestration

Groq SDK (Llama 3.3 70B)
Structured Tool Calling
Multi-turn Context Loop

Database & Persistence

PostgreSQL
Drizzle ORM
drizzle-kit
Docker Compose

Architecture & System Flow

1

Frontend Workspace (client)

Next.js 16
React 19
Tailwind CSS 4
Radix UI

Interactive command center housing the unified email client, calendar view, and persistent assistant chat drawer.

2

Backend Gateway (server)

Express 5
TypeScript
Helmet
Cookie Parser

REST API handling authentication, user session cookies, error handling, and routing between agent and Google services.

3

AI Agent Engine

Groq SDK
Llama 3.3 70B
Function Calling

Autonomous agent loop analyzing intent, selecting appropriate tool definitions, and formatting tool results for conversational feedback.

4

Integration & Persistence Layer

Corsair SDK
Google APIs
Drizzle ORM
PostgreSQL

Scoped OAuth 2.0 communication with Google Cloud services paired with relational storage for users, accounts, and session metadata.

Core Implemented Features

Natural-Language Tool-Calling Agent

Interprets complex requests like 'Find emails from John and schedule a 30-min sync tomorrow' into structured, sequential API executions.

Unified Gmail Inbox & Thread Reader

Full inbox synchronization allowing users to read message threads, search by keyword or sender, and compose outgoing emails directly.

Google Calendar Event Management

Direct calendar synchronization to view upcoming schedules, check conflicts, and create or update calendar events.

Persistent Chat & Activity History

Preserves conversation threads and audit logs of agent-executed actions with PostgreSQL persistence.

Technical Challenges & Trade-Offs

01.Reliable Multi-Step AI Tool Calling with Groq

Challenge

Natural language prompts often involve multi-part tasks (e.g., read an email, parse a date, create an event, send a reply) where single-step LLM calls fail or hallucinate parameters.

Engineering Approach

Implemented an iterative agent loop that evaluates tool-call requests against strict Zod schemas, executes functions sequentially, and feeds tool outputs back to the model until completion.

Result

Structured, step-by-step tool invocation with clear conversational feedback for each action taken.

02.Managing Scoped Google OAuth Credentials

Challenge

Handling combined Gmail modify and Google Calendar access requires robust token storage and graceful error handling when tokens expire.

Engineering Approach

Leveraged Corsair integrations with secure server-side credential isolation and structured error boundary middleware to prevent session drops.

Result

Smooth user authentication and reliable access to Google APIs across active sessions.

03.Preventing Context Window Blowup During Thread Parsing

Challenge

Raw email threads and HTML bodies contain massive metadata, headers, and CSS that rapidly consume LLM context windows.

Engineering Approach

Built sanitization pre-processors that strip boilerplate MIME wrappers, extract plain-text messages, and truncate non-essential historical quotes before passing content to the agent.

Result

Substantially reduced token consumption and faster response times from Groq inference.

Key Engineering Takeaways

Engineered an interactive AI tool-calling workflow connecting natural-language requests to Google Workspace APIs (Gmail and Google Calendar).
Learned strategies for token minimization and data sanitization when piping unstructured communication into LLMs.
Recognized the practical boundaries of OAuth token lifecycles and the importance of user-in-the-loop confirmation before irreversible email or calendar actions.
Deepened expertise with Next.js 16 and Express 5 decoupled full-stack architectures.