Gmail Detective Forensic Analysis
Check if Gmail Detective has been run before by looking for Gmail Detective Analysis.
If exists and fresh (< 30 days): Show you know them, offer to re-run or proceed with existing.
If stale (> 30 days): Suggest refreshing. If declined, use existing.
If no analysis exists: Proceed to forensic collection.
Ask permission with time estimate: "I'll do a deep forensic analysis of your inbox.
This takes 5-10 minutes but gives me comprehensive understanding of your contacts,
communication patterns, life timeline, and more. Want me to proceed?"
Wait for confirmation before continuing.
Say 'Starting forensic collection...' then run the code.
Check the code output. If success is false or counts are 0, tell the user:
"Couldn't connect to Gmail right now. Check your connection and try again."
Verify all three output files were written. If any missing, stop and report the error.
Use your task tool to run these 5 tasks in parallel as subagents:
Extract Profile From Gmail Detective → writes
User Profile
Reconstruct Life Timeline → writes
Gmail Detective Timeline
Analyze Relationship Network → writes
People Directory
Analyze Communication Patterns → writes
Gmail Detective Patterns
Analyze Writing Style → writes
Writing Style
Wait for all to complete before proceeding.
Present your forensic findings following the wow presentation guide.
Lead with 1-2 genuine insights that show you understand them:
- Inner circle discoveries (who matters most by longevity-first scoring)
- Dormant-important contacts (relationships worth rekindling)
- Timeline highlights (major life events detected)
- Behavioral personality (morning/night, initiator/responder)
Summarize what was added to their knowledge:
- Gmail Detective analysis (contacts, clusters, metrics)
- User profile facts
- Life timeline
- Communication patterns
- Writing style
- Key people entities
End with: "I'll use all of this to personalize how I help you going forward."
You MUST use a todo list to complete these steps in order. Never move on to one step if you haven't completed the previous step. If you have multiple read steps in a row, read them all at once (in parallel).
Add all steps to your todo list now and begin executing.
## Steps
1. Check if Gmail Detective has been run before by looking for `documents/gmail-detective-analysis.json`.
If exists and fresh (< 30 days): Show you know them, offer to re-run or proceed with existing.
If stale (> 30 days): Suggest refreshing. If declined, use existing.
If no analysis exists: Proceed to forensic collection.
2. Ask permission with time estimate: "I'll do a deep forensic analysis of your inbox.
This takes 5-10 minutes but gives me comprehensive understanding of your contacts,
communication patterns, life timeline, and more. Want me to proceed?"
Wait for confirmation before continuing.
3. Say 'Starting forensic collection...' then run the code.
4. [Gather Arguments: Gmail Detective Forensic Collection] The next step has the following requirements for arguments, do not proceed until you have all the required information:
- `analysisOutputPath`: documents/gmail-detective-analysis.json
- `relationshipsOutputPath`: documents/gmail-detective-relationships.json
- `writingSamplesOutputPath`: session/detective-writing-samples.json
5. [Run Code: Gmail Detective Forensic Collection]: Call `run_script` with:
```json
{
"file": {
"path": https://sk.ills.app/code/gmail.detective.collect/preview,
"args": [
"analysisOutputPath",
"relationshipsOutputPath",
"writingSamplesOutputPath"
]
},
"packages": null
}
```
6. Check the code output. If success is false or counts are 0, tell the user:
"Couldn't connect to Gmail right now. Check your connection and try again."
7. Verify all three output files were written. If any missing, stop and report the error.
8. Use your task tool to run these 5 tasks in parallel as subagents:
- `skills/sauna/[skill_id]/references/recipes/gmail.detective.profile.md` → writes `documents/user/[personal|work|goals|interests].md`
- `skills/sauna/[skill_id]/references/recipes/gmail.detective.timeline.md` → writes `documents/gmail-detective-timeline.md`
- `skills/sauna/[skill_id]/references/recipes/gmail.detective.relationships.md` → writes `documents/entities/people/*.md`
- `skills/sauna/[skill_id]/references/recipes/gmail.detective.behavior.md` → writes `documents/gmail-detective-patterns.md`
- `skills/sauna/[skill_id]/references/recipes/context.style.analyze.md` → writes `documents/user/writing_style.md`
Wait for all to complete before proceeding.
9. [Read Gmail Detective Forensic Presentation]: Read the documentation in: `skills/sauna/[skill_id]/references/gmail.detective.wow.md` (How to present forensic findings)
10. Present your forensic findings following the wow presentation guide.
Lead with 1-2 genuine insights that show you understand them:
- Inner circle discoveries (who matters most by longevity-first scoring)
- Dormant-important contacts (relationships worth rekindling)
- Timeline highlights (major life events detected)
- Behavioral personality (morning/night, initiator/responder)
Summarize what was added to their knowledge:
- Gmail Detective analysis (contacts, clusters, metrics)
- User profile facts
- Life timeline
- Communication patterns
- Writing style
- Key people entities
End with: "**I'll use all of this to personalize how I help you going forward.**"