name: email-triage version: 1.0.1 description: IMAP email scanning and triage with AI classification via a local Ollama LLM. Scans unread emails, categorizes them as urgent, needs-response, informational, or spam, and surfaces important messages for agent consumption. Works standalone with heuristic fallback — Ollama optional but recommended. metadata: openclaw: requires: bins: ["python3"]
Scan your IMAP inbox, classify emails into priority categories, and surface the ones that need attention. Uses a local LLM (Ollama) for intelligent classification with a rule-based heuristic fallback when Ollama is unavailable.
| Icon | Category | Description |
|---|---|---|
| 🔴 | urgent |
Outages, security alerts, legal, payment failures, time-critical |
| 🟡 | needs-response |
Business inquiries, questions, action items requiring a reply |
| 🔵 | informational |
Receipts, confirmations, newsletters, automated notifications |
| ⚫ | spam |
Marketing, promotions, unsolicited junk |
All configuration is via environment variables:
| Variable | Required | Default | Description |
|---|---|---|---|
IMAP_HOST |
✅ | — | IMAP server hostname |
IMAP_PORT |
— | 993 |
IMAP port (SSL) |
IMAP_USER |
✅ | — | IMAP username / email address |
IMAP_PASS |
✅ | — | IMAP password or app-specific password |
EMAIL_TRIAGE_STATE |
— | ./data/email-triage.json |
Path to the JSON state file |
OLLAMA_URL |
— | http://127.0.0.1:11434 |
Ollama API endpoint |
OLLAMA_MODEL |
— | qwen2.5:7b |
Ollama model for classification |
发现更多技能插件,请访问7w4.net。
EMAIL_TRIAGE_STATE (default: ./data/email-triage.json) — Persistent state file tracking classified emails and surfacing status# Scan inbox and classify new unread emails
python3 scripts/email/email-triage.py scan
# Scan with verbose output (shows each classification)
python3 scripts/email/email-triage.py scan --verbose
# Dry run — scan and classify but don't save state
python3 scripts/email/email-triage.py scan --dry-run
# Show unsurfaced important emails (urgent + needs-response)
python3 scripts/email/email-triage.py report
# Same as report but JSON output (for programmatic use)
python3 scripts/email/email-triage.py report --json
# Mark reported emails as surfaced (so they don't appear again)
python3 scripts/email/email-triage.py mark-surfaced
# Show triage statistics
python3 scripts/email/email-triage.py stats
report surfaces only unsurfaced urgent and needs-response emails, sorted by priority.mark-surfaced flags reported emails so they won't appear in future reports.scan periodically, then report --json to check for items needing attention.scan → report --json → act on results → mark-surfaced.这个 Skill 能帮你自动整理收件箱,把邮件分成紧急、需要回复、信息和垃圾四类,用 AI 分类还能学习你的偏好。文档清晰、配置灵活,但没有自动化测试可能在复杂场景下出现意外问题。总体来说是个实用的邮件管理工具,核心功能做得不错,部分细节还有改进空间。