AI Pulse
← Projects · 1-week

Personal Workflow Distiller

Use a frontier model to shadow your daily digital work for a week and produce a fine-tuned system prompt that turns a local Ollama model into your personal assistant.

Difficulty: 1-week | Stack: Python, Ollama (Llama 3.2 3B or Phi-4-mini), Claude API (claude-opus-4 for distillation), SQLite, FastAPI, Jinja2

Who this is for

Individual creators and knowledge workers who want a private, offline-capable personal agent trained on their actual behavior — not generic assistant defaults

Build steps

  1. Build a lightweight logger that captures your interactions across email (via IMAP), calendar (via .ics export), and browser history for 5–7 days into a local SQLite database — no cloud upload
  2. Write a batch distillation script that sends chunked logs to Claude Opus with a prompt asking it to extract behavioral patterns: how you prioritize tasks, your writing tone, recurring decision frameworks, and time preferences
  3. Synthesize extracted patterns into a structured system prompt template (YAML-driven) that encodes your personal workflow as Ollama model instructions
  4. Wrap Ollama with a FastAPI server that serves a minimal web UI for inbox triage, draft generation, and daily planning — all routed through your distilled system prompt
  5. Add a weekly re-distillation cron job that diffs your new behavioral logs against the existing system prompt and proposes updates for your review before applying them

Risks

  • Local log collection touches sensitive data (email, calendar); a single misconfigured file permission could expose personal information — treat storage encryption as non-negotiable from day one
  • Small local models (3B–7B parameters) will struggle to honor complex distilled system prompts faithfully; you may need to simplify patterns significantly or step up to a 14B+ model with higher RAM requirements
  • Behavioral distillation from one week of logs may overfit to an atypical week — the agent could confidently replicate vacation-week behavior as if it were your normal workflow