⚠️ Transparency Note
This agent runs on Google Gemini. While the logic is robust, it builds on a public LLM. For production use with sensitive client data, I recommend deploying on an Enterprise Instance for GDPR compliance. For this demo, please use pseudonyms and estimated figures.
📋 Executive Summary
- Problem: "The Fact-Find" — the unbillable 2 hours spent qualifying leads.
- Solution: A "Service-Led Diagnostic" Agent that reasons, qualifies, and produces a brief.
- Mechanism: "Integrity Gate" logic that rejects bad fits instead of selling.
- Deliverables: Customizable Gemini Gem + Confidential Analyst Brief template.
- Time to Build: 24 Hours (vs ~5 Days for a custom React app).
The Setup
In professional services, there is a hidden killer of profitability: The Fact-Find.
We usually call it "onboarding" or "discovery," but let’s call it what it really is: a 2-hour interrogation where you ask the same 20 questions ("What's your budget?", "Who are your competitors?") to figure out if a client is even worth working with.
If you do this manually, it burns hours of senior partner time. If you delegate it to a junior, they miss the nuance.
I decided to automate myself out of this loop. Not with a static form, but with an AI Agent that could reason.
Table of Contents
Part 1: The Methodology Stack
Building an agent isn't just "writing a prompt." It follows a product development lifecycle:
| Layer | Component | Purpose |
|---|---|---|
| 1. Identity Core | System Instructions | Define the role (Senior Analyst) and the tone (Direct, Professional). |
| 2. Logic Gates | Conditional Routing | "If revenue < $10k, ask X. If > $100k, ask Y." |
| 3. Integrity Layer | Ethical Constraints | Force the agent to say "No" if the client isn't a fit. |
| 4. Output Formatter | Markdown Template | Ensure the final brief is a structured document, not a chat log. |
Part 2: What I Actually Built
A functional "Senior Intake Analyst" that operates autonomously.
💎 The Gemini Gem
- Dynamic Context: Adapts questions based on industry (Gym vs. E-com).
- Base-Rate Logic: Fills in gaps when users don't know their numbers ("Industry avg is 20%, is that close?").
- Hard-coded Ethics: Rejects clients who need operational help, not marketing scales.
📄 The Deliverable
- Current State Analysis
- Unit Economics Review
- Gap Identification
- Go/No-Go Recommendation
Part 3: The Time Breakdown
How I collapsed a week of R&D into 24 hours:
Drafted the "System Identity". First version was a disaster—sycophantic and hallucinated pricing. Realized "chat" is not "logic".
Pivoted to hard specifications. Wrote the "Integrity Gate" logic. Hard-coded the sequential questioning rule ("Ask one thing at a time").
Tested against a live case study (Davin Choo). The agent failed to recognize his time constraints, so I programmed a new rule: "Check capacity before suggesting ads."
Finalized the output template. Published the Gem.
Part 4: The Integrity Gate
This is the most critical innovation. An AI that always says "Yes" is useless as a consultant.
I explicitly programmed it to not sell. If a lead has bad unit economics, the Agent is hard-coded to say: "Winston's services may not be the right fit at this stage." This builds more trust than any sales pitch.
Part 5: ROI vs Traditional Dev
The "Junior Marketer" question: Could I have just done this with a Typeform?
| Feature | Typeform / Custom App | Gemini Gem |
|---|---|---|
| Build Time | 5 Days (Concept -> Code -> debug) | 24 Hours (Prompt -> Iterate) |
| Logic | Static Branches (If A then B) | Semantic Reasoning ("That margin looks low...") |
| Maintenance | High (Code changes required) | Zero (Natural language updates) |
| Cost | Dev Time + Hosting | $0 (Free Tier) |
💡 The Unlock
The bottleneck isn't "encoding" the logic anymore. The bottleneck is knowing the logic in the first place. If you have the domain expertise, the implementation cost is now near-zero.
Part 6: What This Doesn't Prove
🚫 Limitations
- Hallucination Risk: It's an LLM. It can simulate reasoning, but it can still make up facts if not grounded.
- Privacy: This public demo is not for trade secrets. Enterprise usage requires private instances.
- Integration: It currently lives in Gemini. It doesn't auto-sync to a CRM (yet).
Part 7: What You Can Steal
To build your own diagnostic agent, use this Prompt Structure:
🧬 The "Consultant" System Prompt
- [IDENTITY]: "You are a Senior Analyst. You are skeptical, direct, and protective of the user's P&L."
- [CONTEXT]: "The user is likely a small business owner. They may not know their numbers."
- [RULES]:
- Never ask more than 1 question at a time.
- Always validate the previous answer.
- If [Margin < 20%], trigget [Warning Protocol].
- [OUTPUT]: "At the end, generate a markdown report using THIS template..."
The Bottom Line
I thought replacing my intake process would take a week of coding. It took a day of thinking.
The leverage isn't that AI writes the code. The leverage is that AI allows your logic to become software without the code step.
View the Portfolio Case Study →
📚 Further Reading
- The AI Bionic Layer — Why logic is the new coding.
- The 2-Day Efficiency Trap — Why systems beat brute force.