Skip to main content
Safdar.
HomeAboutProjectsBlogContact
Resume
Safdar.

AI Engineer & Full Stack Developer building intelligent systems.

Quick Links

  • Home
  • About
  • Projects
  • Blog
  • Contact
  • Privacy Policy

Connect

safdarayub@gmail.com

Kohat District, KP, Pakistan

© 2026 Safdar Ayub. All rights reserved.RSS Feed
  1. Home
  2. Projects
  3. Personal AI Employee
Back to Projects
Platinum TierAI Agents

Personal AI Employee — Hybrid Cloud-Local Autonomous Agent

A 24/7 autonomous AI agent that monitors Gmail, WhatsApp, and filesystem — drafts responses on a cloud VM while you're offline, then executes with your approval when you reconnect.

Last updated March 2026

View on GitHub

Overview

A hybrid cloud-local autonomous AI agent that evolved through four architectural tiers (Bronze → Silver → Gold → Platinum). The system monitors multiple sources (Gmail, WhatsApp, filesystem), processes tasks through a git-synced Obsidian vault pipeline, and executes actions via MCP servers with human-in-the-loop safety gates.

The cloud VM (Ubuntu 24.04) runs 24/7, detecting emails and drafting responses. When the local laptop reconnects, a 60-second git-sync cycle pulls pending actions for human approval. This hybrid architecture enables true offline tolerance — the agent works while you sleep.

The Four Tiers

TierNameWhat It Does
BronzeFile Watcher + Vault ProcessingFilesystem monitoring via Watchdog, YAML-frontmatter metadata, risk-based routing
SilverMulti-Source Orchestration4 watchers (filesystem, Gmail, WhatsApp, scheduled), centralized priority queue, PM2 management
GoldMCP Servers + External Integrations4 FastMCP servers, circuit breaker pattern, correlation ID tracking, health monitoring
PlatinumHybrid Cloud-LocalCloud VM drafting + local execution, 60-second git-sync, offline tolerance, live verified demo

4 MCP Servers

ServerPurposeHITL Level
fte-emailDraft, send, search emails via Gmail APIRoutine / Sensitive
fte-socialPost to Facebook, Instagram, Twitter/XSensitive / Routine
fte-odooOdoo 19 ERP — invoices, payments, summariesRoutine / Critical
fte-documentsGenerate reports and CEO briefingsRoutine

Key Engineering Patterns

  • Circuit breaker pattern (3 failures → 300s cooldown)
  • Correlation IDs: corr-YYYYMMDD-HHMMSS-XXXX
  • Risk-based action routing (routine/sensitive/critical)
  • Dry-run defaults for safety
  • Atomic claim-by-move concurrency (prevents duplication)
  • Stale detection (>48h pending, >7d rejected)
  • Secrets isolation (3 layers: .gitignore, pre-commit hook, cloud audit)
  • 21 Architecture Decision Records (ADRs)

Live Demo (Verified March 12, 2026)

Correlation ID: corr-2026-03-12-d16b3470

StepEventAgent
1Test email sent to GmailUser
2Gmail watcher detected (120s poll)Cloud VM
3Orchestrator drafted → Pending_Approval/Cloud VM
4Git-sync pushed to remoteCloud VM
5Local git pull fetched fileLocal
6User moved to Approved/Local
7Approval watcher sent via Gmail APILocal
8File moved to Done/ (status: completed)Local
Tech Stack
PythonFastMCPClaude CodeGmail OAuth2PlaywrightPM2Git-syncDocker

Interested in similar work?

I build AI agents, full-stack applications, and cloud-native systems. Let's discuss your next project.

Get in Touch

Other Projects

CareerCoach Pakistan screenshot
Platinum TierSaaS Products
CareerCoach Pakistan

Full-stack SaaS — paste a job description, answer 10 AI-generated questions in English or Urdu, and get instant scored feedback. Subscription billing, Google auth, transactional email, and analytics included.

Next.js 16SupabaseStripeGroq AIResend
View DetailsGitHub
AI/ML Job Market Intelligence Pipeline screenshot
ML Pipelines
AI/ML Job Market Intelligence Pipeline

End-to-end ML pipeline that scrapes RemoteOK, clusters jobs with K-Means + TF-IDF, classifies seniority across 3 models, generates LLM market insights via Groq LLaMA 3.3 70B, and pushes automated reports to Google Sheets — all from one API call.

Pythonscikit-learnFastAPIPostgreSQLGroq API
View DetailsGitHub
BusBot Pakistan screenshot
Platinum TierAI Applications
BusBot Pakistan

Pakistan's first AI-powered public bus guide — speak in Urdu, get your route. Built for Google AI Seekho 2026 competition, covering Lahore, Karachi, and Islamabad with community-driven route data.

ReactGemini 3 FlashFirebase FirestoreWeb Speech APIGoogle Cloud Run
View DetailsGitHub