gmail-analyze
Skill2 starsChanged 3 months agoMITView on GitHub
Analyze Gmail inbox patterns to identify high-volume senders and suggest filter rules. Use when organizing email, creating automation rules, or understanding inbox composition. Works with personal Gmail accounts via gog CLI.
- Installs packages
1 other project uses a version of this.
Other versions1 project uses a version of this.
Word for word · 1
- CorentinLumineau/gmail-assistant★ 0100% same
Edited · 0
None found.
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository10 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- gmail-classifySkill
- gmail-filterSkill
- gmail-labelSkill
- gogSkill
- prj-drive-cleanupSkill
- prj-driveSkill
- prj-gmail-cleanupSkill
- prj-inboxSkill
The file
We split this skill into the rules it gives an agent
4 rules. About 0 are common, 4 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 24
If not authenticated, guide the user to run:
- Distinctive: line 129
If gog not installed: Provide installation instructions
- Distinctive: line 130
If not authenticated: Guide through OAuth setup
- Distinctive: line 131
If no emails found: Suggest widening the search period
≈ “Common” is an estimate: at least 1 in 5 of the 364,980 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Gmail Inbox Analyzer
Analyze inbox patterns and suggest intelligent filter rules using Pareto analysis.
Prerequisites Check
First, verify gog CLI is authenticated:
gog auth statusIf not authenticated, guide the user to run:
gog auth add their.email@gmail.comAnalysis Workflow
Step 1: Fetch Recent Emails
Fetch emails from the specified time period (default: 30 days):
gog gmail search 'newer_than:${DAYS}d' --jsonParse the JSON output to extract:
from- Sender emailsubject- Email subjectdate- Received datelabelIds- Applied labels
Step 2: Pattern Analysis
Analyze the fetched emails to identify:
- Top Sender Domains (Pareto: focus on top 20%)
- Group emails by sender domain
- Count frequency per domain
- Identify domains with 5+ emails
- Sender Categories
- Newsletters: substack, mailchimp, newsletter, digest
- Notifications: github, gitlab, jira, slack, notion
- Shopping: amazon, ebay, order, shipping
- Social: facebook, twitter, linkedin
- Volume Distribution
- Total emails analyzed
- Emails per day average
- Peak sending times
Step 3: Generate Suggestions
For each high-volume pattern, suggest:
| Domain | Count | Suggested Label | Filter Criteria | Confidence |
| substack.com | 45 | Newsletters | from:@substack.com | High |
| github.com | 32 | Notifications | from:@github.com | High |
Step 4: Present Results
Output a formatted report:
## Inbox Analysis Report
**Period**: Last {days} days
**Total Emails**: {count}
**Unique Senders**: {unique}
### Top 10 Sender Domains
1. example.com - 142 emails (28%)
2. github.com - 89 emails (18%)
...
### Suggested Filters
| Priority | Pattern | Label | Est. Impact |
|----------|---------|-------|-------------|
| 1 | from:@newsletter.com | Newsletters | 45 emails/month |
| 2 | from:@github.com | Notifications | 32 emails/month |
### Recommended Actions
1. Create "Newsletters" label and filter
2. Create "Notifications" label with auto-archive
3. ...
Would you like me to create these filters? Use `/gmail-filter` to proceed.Arguments
$ARGUMENTS- Number of days to analyze (default: 30)
Example Usage
User: /gmail-analyze 60Analyzes the last 60 days of email.
Output Format
Always provide:
- Summary statistics
- Top senders table
- Suggested filters with confidence levels
- Clear next steps
Error Handling
- If gog not installed: Provide installation instructions
- If not authenticated: Guide through OAuth setup
- If no emails found: Suggest widening the search period
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

