Skip to content

eloquentix/aurora

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Aurora

Your AI-powered morning email briefing. Deploy in 5 minutes, runs entirely in Google Apps Script — no server, no infrastructure, no ongoing maintenance.

Every morning, Aurora reads your Gmail inbox and Google Calendar, analyzes each email with an AI model of your choice, and delivers a structured briefing: today's schedule, summaries, action items with direct Gmail links, and one-click proposed replies.

Built by Eloquentix as an open-source demonstration of practical AI agents — simple enough to understand in an afternoon, useful enough to run every day.


What you get

A daily email that looks like this:

AURORA Wednesday, May 27 · 12 emails

Today's Schedule 10:00 AM Design review with Sarah 2:00 PM Standup

Overview Acme Corp is waiting on your proposal — deadline Friday. $24K payment from Looma landed overnight. Design call moved to 3pm.

Requires Your Attention (3)

Re: Proposal · Acme Corp · 9:14 AM Client followed up asking for the proposal by Friday. Budget approval expires end of month. → Send proposal by Thursday EOD

Proposed reply: "Hi Sarah, I'll have the proposal over to you by Thursday EOD." [Reply in Gmail] [Open Thread]

Worth Reading (5) Finance — $24,000 deposit from Looma Project · PNC balance: $96,678 Team — Andrei shared Opus 4.8 announcement

Skipped: 4 emails (2 newsletters, 2 promos)


How it works

Aurora is a small AI agent:

  1. Reads your Gmail inbox (last 20 hours) and Google Calendar
  2. Categorizes each email — action, FYI, or skip — with sub-categories
  3. Synthesizes the inbox into an executive overview with calendar context
  4. Delivers a newspaper-style HTML briefing to your inbox

The agent pattern is intentionally simple: a system prompt that defines the persona, a loop over emails that calls the AI, and a second call to synthesize the whole. The code is meant to be read and extended.

runBriefing()
  ├─ fetchRecentEmails()       reads Gmail via GmailApp
  ├─ fetchTodayEvents()        reads Google Calendar
  ├─ for each email:
  │    └─ analyzeEmail()       calls AI → JSON: category, summary, actions, reply
  ├─ generateOverallSummary()  AI synthesizes inbox + calendar
  ├─ verifyBriefing()          quality check on assembled output
  └─ buildBriefingHTML()       newspaper-style email with Gmail compose links

Supported AI Providers

Pick one — or switch anytime by changing a single config value.

Provider Model Free Tier
Claude (Anthropic) claude-sonnet-4-6 No — get key
OpenAI gpt-4o No — get key
Gemini (Google) gemini-2.5-flash Yesget key
Grok (xAI) grok-3 No — get key

Get started

Easiest way — no terminal required

→ Open Aurora in Google Apps Script

  1. Click the icon on the left sidebar
  2. Click the copy icon on the right — this saves a copy to your Google account
  3. Google will open your copy automatically in a new tab — bookmark it or keep the tab open

    If you lose it, go to script.google.com and look for "Copy of Aurora" in your projects list

Once copied, follow these steps:


Step 1 — Get a free Gemini API key

  1. Go to aistudio.google.com and sign in with your Google account
  2. Click "Get API key" on the left sidebar
  3. Click "Create API key" on the right side
  4. Copy the key that appears

Step 2 — Add your key to Aurora

  1. Click src/setup.gs in the left sidebar
  2. Replace PASTE_YOUR_GEMINI_KEY_HERE with the key you just copied
  3. Select setupProperties in the function dropdown → click ▶ Run
  4. Google will ask for permissions — approve everything

    If you see "Google hasn't verified this app" — click Advanced"Go to Aurora (unsafe)"Allow. This is normal for personal scripts and completely safe.


Step 3 — Test it (optional but recommended)

  1. Click src/main.gs in the left sidebar
  2. Select testBriefing in the dropdown → click ▶ Run
  3. Watch the Execution log as Aurora analyzes your last 5 emails
  4. Check your inbox — a real briefing email will arrive so you can see exactly what it looks like

Step 4 — Go live

  1. Select installTrigger in the dropdown → click ▶ Run (approve permissions again if asked)

That's it. Your briefing arrives tomorrow morning.


Developer way — clasp + git

If you want to run your own copy of the code, extend it, or contribute:

Prerequisites

  • A Google account (Gmail)
  • Node.js installed
  • An API key from any provider (Gemini has a free tier)

1. Clone and install clasp

git clone https://github.com/eloquentix/aurora.git
cd aurora
npm install -g @google/clasp
clasp login

2. Enable the Apps Script API

Visit script.google.com/home/usersettings and turn on Google Apps Script API.

3. Create and push

clasp create --type standalone --title "Aurora"
clasp push

Answer Yes when asked to overwrite the manifest.

4. Add your API key

Open src/setup.gs, paste your key, then:

clasp push

Go to script.google.com, open Aurora, click src/setup.gs, select setupPropertiesRun.

5. Test and go live

  • Run testBriefing() — check Execution Log, no email sent
  • Run installTrigger() — briefing arrives every morning at 7 AM

Configuration

Edit src/config.gs or set Script Properties to override without touching code.

Key Default Description
AI_PROVIDER claude Active provider: claude, openai, gemini, grok
AI_MODEL (provider default) Override model, e.g. gpt-4o, claude-opus-4-6
HOURS_BACK 20 Hours of inbox to scan
MAX_EMAILS 50 Cap per run (controls cost)
BRIEFING_HOUR 7 Hour to send the briefing (0–23)
PRIORITY_CONTACTS (empty) Comma-separated emails to highlight at the top
GMAIL_SEARCH (auto) Custom Gmail search query (default: newer_than:Xh in:inbox)
PERSONA_NAME Aurora Agent name in email subject and footer

Extending Aurora

The codebase is intentionally small and readable. Key extension points:

Switch providers — change AI_PROVIDER in setup.gs, re-run setupProperties().

Add a new provider — create src/providers/myprovider.gs with a single function, add one case to the switch in src/ai.gs. That's it.

Add memoryanalyzeEmail() in src/agent.gs is where you'd inject sender context before calling the AI. A future version might look up the sender in Firebase and prepend: "You've exchanged 12 emails with this person. Last topic: contract renewal."

Change the persona — edit SYSTEM_PROMPT in src/agent.gs.

Different delivery — replace GmailApp.sendEmail() in src/main.gs with a Slack webhook, Google Chat message, or push notification.


Project structure

src/
  main.gs              Entry points: runBriefing(), testBriefing(), installTrigger()
  agent.gs             The agent: persona, analysis loop, synthesis, verification
  ai.gs                Provider router — one callAI() for all providers
  providers/
    claude.gs          Anthropic Messages API
    openai.gs          OpenAI Chat Completions
    gemini.gs          Google Gemini
    grok.gs            xAI Grok (OpenAI-compatible)
  gmail.gs             Gmail reading + recipient role inference
  calendar.gs          Google Calendar integration
  briefing.gs          Newspaper-style HTML email with Gmail compose links
  config.gs            Config defaults + Script Properties bridge
  utils.gs             Shared utilities
  setup.gs             API key setup (paste your key, run once)

Built by Eloquentix

Eloquentix is a software consultancy that builds AI-powered products for US startups. We open-source the tools we build for ourselves.


License

MIT

About

AI-powered morning email briefing agent. Runs in Google Apps Script, supports Claude, OpenAI, Gemini, and Grok.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors