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.

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

Other Projects

Campaign Manager screenshot
Full Stack
Campaign Manager

A CRM prototype with contacts CRUD, audience segmentation rule builder, multi-step campaign wizard, and analytics dashboard — powered by Prisma and Turso.

Next.js 16TypeScriptTailwind CSSShadCN UIPrisma
View DetailsGitHub
AI Video Generation Agent screenshot
AI Agents
AI Video Generation Agent

Type a prompt, get a full 4-minute motion graphics video with narration — completely AI-generated.

TypeScriptReactRemotionClaude CodeGemini TTS
View DetailsGitHub
Flow screenshot
Full Stack
Flow

A todo app that evolved through 8 architectural phases — from console script to Kubernetes-deployed microservice with AI chatbot.

Next.jsFastAPISQLModelDockerKubernetes
View DetailsGitHub