openclaw-executive-assistant-local
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseOpenClaw Executive Assistant (Local)
OpenClaw 本地执行助理
Overview
概述
This project provides a local-first OpenClaw workflow system for building AI-powered executive assistant capabilities. It focuses on three core operations:
- Data intake review - Transform unknown files into structured intake reports
- Operational memory - Convert work residue into daily logs and weekly summaries
- Offline communications triage - Process exported emails into action lists
All operations use local files only, produce reviewable markdown artifacts, and require no live integrations.
本项目提供一个本地优先的OpenClaw工作流系统,用于构建AI驱动的执行助理能力。它专注于三个核心操作:
- 数据收集审核 - 将未知文件转换为结构化的收集报告
- 操作记忆 - 将工作残留内容转换为每日日志和每周总结
- 离线通讯分类处理 - 将导出的邮件处理为行动清单
所有操作仅使用本地文件,生成可审核的Markdown产物,无需实时集成。
Repository Structure
仓库结构
code-along/
├── INDEX.md
├── 01-data-intake-review/
│ ├── incoming/ # Files to inspect
│ ├── prompts/ # Prompt templates
│ ├── outputs/ # Generated reports
│ └── expected/ # Reference outputs
├── 02-operational-memory/
│ ├── inbox/ # Notes and work residue
│ ├── prompts/ # Daily/weekly prompts
│ ├── outputs/ # Generated logs
│ └── schedule/ # Cron examples
├── 03-offline-communications-triage/
│ ├── eml/ # Exported email files
│ ├── prompts/ # Triage prompts
│ ├── outputs/ # Triage reports
│ └── expected/ # Reference outputs
└── mission-control/ # Dashboard (optional)code-along/
├── INDEX.md
├── 01-data-intake-review/
│ ├── incoming/ # 待检查文件
│ ├── prompts/ # 提示词模板
│ ├── outputs/ # 生成的报告
│ └── expected/ # 参考输出
├── 02-operational-memory/
│ ├── inbox/ # 笔记和工作残留内容
│ ├── prompts/ # 每日/每周提示词
│ ├── outputs/ # 生成的日志
│ └── schedule/ # Cron示例
├── 03-offline-communications-triage/
│ ├── eml/ # 导出的邮件文件
│ ├── prompts/ # 分类处理提示词
│ ├── outputs/ # 分类处理报告
│ └── expected/ # 参考输出
└── mission-control/ # 控制面板(可选)Exercise 1: Data Intake Review
练习1:数据收集审核
Purpose
目标
Transform unknown files in an folder into a trustworthy intake report.
incoming/将文件夹中的未知文件转换为可信的收集报告。
incoming/Workflow
工作流
- Place files to review:
bash
undefined- 放置待审核文件:
bash
undefinedAdd files to the incoming folder
将文件添加到incoming文件夹
cp ~/Downloads/unknown-file.pdf code-along/01-data-intake-review/incoming/
2. **Use the intake review prompt:**
The prompt template is in `prompts/intake-review.md`. Pass it to your AI assistant along with the contents of `incoming/`:
```markdowncp ~/Downloads/unknown-file.pdf code-along/01-data-intake-review/incoming/
2. **使用收集审核提示词:**
提示词模板位于`prompts/intake-review.md`。将其与`incoming/`中的内容一起传递给你的AI助理:
```markdownIntake Review Prompt
收集审核提示词
You are an executive assistant performing a data intake review.
Review all files in the incoming/ folder and produce a report that includes:
- File inventory (name, type, size, date)
- Content summary for each file
- Suggested categorization
- Action items or next steps
- Priority flags (urgent, routine, archive)
Output format: Markdown
Output location: outputs/intake-review.md
3. **Expected output structure:**
```markdown你是一名执行助理,正在进行数据收集审核。
审核incoming/文件夹中的所有文件并生成一份报告,内容包括:
- 文件清单(名称、类型、大小、日期)
- 每个文件的内容摘要
- 建议分类
- 行动项或下一步操作
- 优先级标记(紧急、常规、存档)
输出格式:Markdown
输出位置:outputs/intake-review.md
3. **预期输出结构:**
```markdownData Intake Review
数据收集审核
Generated: YYYY-MM-DD
生成时间:YYYY-MM-DD
Summary
摘要
- Total files: X
- Urgent items: Y
- Requires action: Z
- 文件总数:X
- 紧急项:Y
- 需要处理:Z
File Inventory
文件清单
[filename.ext]
[filename.ext]
- Type: Document/Image/Data
- Size: XXX KB
- Date: YYYY-MM-DD
- Summary: Brief content description
- Category: Work/Personal/Archive
- Action: Review/File/Respond
- Priority: High/Medium/Low
[Repeat for each file]
- 类型: 文档/图片/数据
- 大小: XXX KB
- 日期: YYYY-MM-DD
- 摘要: 内容简要描述
- 分类: 工作/个人/存档
- 操作: 审核/归档/回复
- 优先级: 高/中/低
[每个文件重复上述内容]
Recommended Actions
建议操作
- ...
- ...
undefined- ...
- ...
undefinedExercise 2: Operational Memory
练习2:操作记忆
Purpose
目标
Convert daily work residue into structured logs and weekly summaries.
将日常工作残留内容转换为结构化日志和每周总结。
Daily Log Workflow
每日日志工作流
- Add work residue to inbox:
bash
undefined- 将工作残留内容添加到收件箱:
bash
undefinedAdd notes, snippets, or quick captures
添加笔记、片段或快速记录
echo "Met with design team - new mockups ready" > code-along/02-operational-memory/inbox/note-$(date +%Y%m%d).txt
2. **Use the daily log prompt** (`prompts/daily-log.md`):
```markdownecho "与设计团队会面 - 新原型已准备好" > code-along/02-operational-memory/inbox/note-$(date +%Y%m%d).txt
2. **使用每日日志提示词**(`prompts/daily-log.md`):
```markdownDaily Log Prompt
每日日志提示词
You are an executive assistant creating a daily work log.
Review all items in the inbox/ folder from today and produce:
- Date header
- Wins - Completed items
- Progress - Items in motion
- Blockers - Issues or delays
- Tomorrow - Planned next actions
- Notes - Observations or reminders
Output format: Markdown
Output location: outputs/daily-log.md
Filename pattern: daily-YYYY-MM-DD.md
3. **Expected daily log output:**
```markdown你是一名执行助理,正在创建每日工作日志。
审核收件箱文件夹中今天的所有内容并生成:
- 日期标题
- 成果 - 已完成事项
- 进展 - 进行中事项
- 障碍 - 问题或延迟
- 明日计划 - 预计下一步操作
- 备注 - 观察或提醒
输出格式:Markdown
输出位置:outputs/daily-log.md
文件名格式:daily-YYYY-MM-DD.md
3. **预期每日日志输出:**
```markdownDaily Log: 2026-05-11
每日日志:2026-05-11
Wins
成果
- ✅ Completed data intake review system
- ✅ Shipped v2.1 of client dashboard
- ✅ 完成数据收集审核系统
- ✅ 交付客户端仪表板v2.1
Progress
进展
- 🔄 OpenClaw workshop prep (80% complete)
- 🔄 Q2 planning document (draft stage)
- 🔄 OpenClaw研讨会准备(完成80%)
- 🔄 Q2规划文档(草稿阶段)
Blockers
障碍
- ⚠️ Waiting on legal review for contract
- ⚠️ Need API keys from DevOps
- ⚠️ 等待合同的法律审核
- ⚠️ 需要从DevOps获取API密钥
Tomorrow
明日计划
- Finalize workshop slides
- Review Q2 budget proposal
- Team sync at 2pm
- 最终确定研讨会幻灯片
- 审核Q2预算提案
- 下午2点团队同步会议
Notes
备注
- Design team shared new mockups in Figma
- Consider async standup format for remote team
undefined- 设计团队在Figma中分享了新原型
- 考虑为远程团队采用异步站立会议格式
undefinedWeekly Summary Workflow
每周总结工作流
Use the weekly hype prompt ():
prompts/weekly-hype.mdmarkdown
undefined使用每周总结提示词():
prompts/weekly-hype.mdmarkdown
undefinedWeekly Hype Prompt
每周总结提示词
You are an executive assistant creating a weekly summary.
Review all daily logs from this week (outputs/daily-*.md) and produce:
- Week of [date range]
- Highlights - Major wins and milestones
- Momentum - Projects advancing
- Attention needed - Recurring blockers
- Next week focus - Priorities for the week ahead
- Metrics (optional) - Quantifiable progress
Output format: Markdown
Output location: outputs/weekly-hype.md
Filename pattern: weekly-YYYY-Www.md
undefined你是一名执行助理,正在创建每周总结。
审核本周所有每日日志(outputs/daily-*.md)并生成:
- [日期范围] 周
- 亮点 - 主要成果和里程碑
- 推进情况 - 进展中的项目
- 需要关注 - 反复出现的障碍
- 下周重点 - 本周优先事项
- 指标(可选)- 可量化的进展
输出格式:Markdown
输出位置:outputs/weekly-hype.md
文件名格式:weekly-YYYY-Www.md
undefinedAutomation Example
自动化示例
Schedule daily log generation with cron (see ):
schedule/cron-examples.mdbash
undefined使用cron安排每日日志生成(参见):
schedule/cron-examples.mdbash
undefinedRun daily at 6pm
每天下午6点运行
0 18 * * * cd ~/openclaw-assistant && ./generate-daily-log.sh
0 18 * * * cd ~/openclaw-assistant && ./generate-daily-log.sh
generate-daily-log.sh example:
generate-daily-log.sh示例:
#!/bin/bash
DATE=$(date +%Y-%m-%d)
AI_PROMPT=$(cat code-along/02-operational-memory/prompts/daily-log.md)
#!/bin/bash
DATE=$(date +%Y-%m-%d)
AI_PROMPT=$(cat code-along/02-operational-memory/prompts/daily-log.md)
Pass inbox contents and prompt to your AI CLI tool
将收件箱内容和提示词传递给你的AI CLI工具
ai-cli "$AI_PROMPT" --context "code-along/02-operational-memory/inbox/*" \
ai-cli "$AI_PROMPT" --context "code-along/02-operational-memory/inbox/*" \
> "code-along/02-operational-memory/outputs/daily-$DATE.md"
> "code-along/02-operational-memory/outputs/daily-$DATE.md"
undefinedundefinedExercise 3: Offline Communications Triage
练习3:离线通讯分类处理
Purpose
目标
Process exported email files into structured action lists.
将导出的邮件文件处理为结构化行动清单。
Workflow
工作流
- Export emails to .eml format:
bash
undefined- 将邮件导出为.eml格式:
bash
undefinedPlace exported emails in the eml/ folder
将导出的邮件放置在eml/文件夹中
cp ~/exported-emails/*.eml code-along/03-offline-communications-triage/eml/
2. **Use the email triage prompt** (`prompts/email-triage.md`):
```markdowncp ~/exported-emails/*.eml code-along/03-offline-communications-triage/eml/
2. **使用邮件分类处理提示词**(`prompts/email-triage.md`):
```markdownEmail Triage Prompt
邮件分类处理提示词
You are an executive assistant performing email triage.
Review all .eml files in the eml/ folder and produce:
- Urgent - Requires immediate response
- Action Required - Needs response (24-48h)
- FYI - Informational, no action needed
- Delegate - Should be handled by someone else
- Archive - Safe to file away
For each email include:
- From/Subject
- Brief summary
- Suggested response or action
- Priority level
Output format: Markdown
Output location: outputs/email-triage.md
3. **Expected triage output:**
```markdown你是一名执行助理,正在进行邮件分类处理。
审核eml/文件夹中的所有.eml文件并生成:
- 紧急 - 需要立即回复
- 需要处理 - 需要回复(24-48小时内)
- 仅供参考 - 信息性内容,无需操作
- 委派 - 应由其他人处理
- 存档 - 可安全归档
每封邮件需包含:
- 发件人/主题
- 简要摘要
- 建议回复或操作
- 优先级
输出格式:Markdown
输出位置:outputs/email-triage.md
3. **预期分类处理输出:**
```markdownEmail Triage Report
邮件分类处理报告
Generated: YYYY-MM-DD HH:MM
生成时间:YYYY-MM-DD HH:MM
Urgent (Response Today)
紧急(今日回复)
From: client@example.com | Re: Production Issue
发件人:client@example.com | 主题:生产环境问题
- Summary: Database timeout errors affecting users
- Action: Coordinate with DevOps for immediate fix
- Priority: 🔴 Critical
- 摘要: 数据库超时错误影响用户
- 操作: 与DevOps协调立即修复
- 优先级: 🔴 严重
Action Required (24-48h)
需要处理(24-48小时内)
From: legal@company.com | Re: Contract Review
发件人:legal@company.com | 主题:合同审核
- Summary: Q2 vendor contract needs signature
- Action: Review terms, sign if acceptable
- Priority: 🟡 High
- 摘要: Q2供应商合同需要签署
- 操作: 审核条款,如可接受则签署
- 优先级: 🟡 高
FYI (No Action)
仅供参考(无需操作)
From: team@company.com | Re: Weekly Newsletter
发件人:team@company.com | 主题:每周通讯
- Summary: Company updates and team wins
- Action: None - informational
- Priority: 🟢 Low
- 摘要: 公司更新和团队成果
- 操作: 无 - 仅作信息参考
- 优先级: 🟢 低
Delegate
委派
From: recruiter@agency.com | Re: Candidate Pipeline
发件人:recruiter@agency.com | 主题:候选人管道
- Summary: Three candidates ready for interviews
- Action: Forward to hiring manager Sarah
- Priority: 🟡 Medium
- 摘要: 三名候选人准备好面试
- 操作: 转发给招聘经理Sarah
- 优先级: 🟡 中
Archive
存档
[Emails that can be filed with no action]
undefined[可归档无需操作的邮件]
undefinedCommon Patterns
通用模式
Pattern 1: Copy-Paste Workflow
模式1:复制粘贴工作流
markdown
1. Open AI assistant (Claude, ChatGPT, etc.)
2. Copy prompt from prompts/*.md
3. Attach or paste relevant files from incoming/inbox/eml/
4. Run generation
5. Save output to outputs/*.md
6. Review and edit as neededmarkdown
1. 打开AI助理(Claude、ChatGPT等)
2. 复制prompts/*.md中的提示词
3. 附加或粘贴incoming/inbox/eml/中的相关文件
4. 运行生成
5. 将输出保存到outputs/*.md
6. 根据需要审核和编辑Pattern 2: Scripted Automation
模式2:脚本化自动化
bash
#!/bin/bashbash
#!/bin/bashautomated-intake.sh
automated-intake.sh
PROMPT=$(cat code-along/01-data-intake-review/prompts/intake-review.md)
FILES=$(ls code-along/01-data-intake-review/incoming/*)
PROMPT=$(cat code-along/01-data-intake-review/prompts/intake-review.md)
FILES=$(ls code-along/01-data-intake-review/incoming/*)
Use your AI CLI tool of choice
使用你选择的AI CLI工具
ai-cli "$PROMPT" --files "$FILES" > outputs/intake-review-$(date +%Y%m%d).md
ai-cli "$PROMPT" --files "$FILES" > outputs/intake-review-$(date +%Y%m%d).md
undefinedundefinedPattern 3: Scheduled Heartbeat
模式3:定时执行
bash
undefinedbash
undefinedAdd to crontab
添加到crontab
Daily log at 6pm weekdays
工作日每天下午6点生成每日日志
0 18 * * 1-5 cd ~/openclaw-assistant && ./daily-log.sh
0 18 * * 1-5 cd ~/openclaw-assistant && ./daily-log.sh
Weekly summary Friday at 5pm
每周五下午5点生成每周总结
0 17 * * 5 cd ~/openclaw-assistant && ./weekly-summary.sh
undefined0 17 * * 5 cd ~/openclaw-assistant && ./weekly-summary.sh
undefinedConfiguration
配置
Environment Setup
环境设置
Create a file for AI API configuration:
.envbash
undefined创建文件用于AI API配置:
.envbash
undefined.env
.env
ANTHROPIC_API_KEY=${ANTHROPIC_API_KEY}
OPENAI_API_KEY=${OPENAI_API_KEY}
AI_MODEL=claude-3-5-sonnet-20241022
undefinedANTHROPIC_API_KEY=${ANTHROPIC_API_KEY}
OPENAI_API_KEY=${OPENAI_API_KEY}
AI_MODEL=claude-3-5-sonnet-20241022
undefinedPrompt Customization
提示词自定义
Edit prompt files to match your workflow:
bash
undefined编辑提示词文件以匹配你的工作流:
bash
undefinedCustomize intake review categories
自定义收集审核分类
nano code-along/01-data-intake-review/prompts/intake-review.md
nano code-along/01-data-intake-review/prompts/intake-review.md
Adjust daily log sections
调整每日日志章节
nano code-along/02-operational-memory/prompts/daily-log.md
nano code-along/02-operational-memory/prompts/daily-log.md
Modify email triage buckets
修改邮件分类处理分组
nano code-along/03-offline-communications-triage/prompts/email-triage.md
undefinednano code-along/03-offline-communications-triage/prompts/email-triage.md
undefinedTroubleshooting
故障排除
Issue: AI output not matching expected format
问题:AI输出不符合预期格式
Solution: Add explicit format instructions to prompts:
markdown
CRITICAL: Output must be valid Markdown with exactly these sections:
- Summary
- File Inventory
- Recommended Actions
Use ## for section headers. Use - for bullet lists.解决方案: 在提示词中添加明确的格式说明:
markdown
重要提示:输出必须为有效的Markdown,且包含以下章节:
- 摘要
- 文件清单
- 建议操作
使用##作为章节标题,使用-作为项目符号列表。Issue: Large files causing context limits
问题:大文件导致上下文限制
Solution: Process in batches:
bash
undefined解决方案: 分批处理:
bash
undefinedSplit incoming files into chunks
将incoming文件拆分为多个批次
for file in incoming/*.pdf; do
Process individually
echo "Processing $file..."
done
undefinedfor file in incoming/*.pdf; do
单独处理
echo "正在处理$file..."
done
undefinedIssue: Automation script not running
问题:自动化脚本未运行
Solution: Check cron logs and permissions:
bash
undefined解决方案: 检查cron日志和权限:
bash
undefinedView cron logs
查看cron日志
grep CRON /var/log/syslog
grep CRON /var/log/syslog
Ensure scripts are executable
确保脚本可执行
chmod +x *.sh
chmod +x *.sh
Test script manually
手动测试脚本
./daily-log.sh
undefined./daily-log.sh
undefinedIssue: Email .eml parsing errors
问题:邮件.eml解析错误
Solution: Ensure proper export format from email client. Most clients support "Save as .eml" or "Export to file" options. If parsing fails, extract plain text first:
bash
undefined解决方案: 确保从邮件客户端正确导出格式。大多数客户端支持“另存为.eml”或“导出到文件”选项。如果解析失败,先提取纯文本:
bash
undefinedExtract text from .eml
从.eml中提取文本
grep -A 1000 "^$" email.eml | tail -n +2 > email.txt
undefinedgrep -A 1000 "^$" email.eml | tail -n +2 > email.txt
undefinedIntegration Tips
集成技巧
With Obsidian/Notion
与Obsidian/Notion集成
bash
undefinedbash
undefinedSymlink outputs to your notes folder
将输出目录符号链接到你的笔记文件夹
ln -s ~/openclaw-assistant/code-along/02-operational-memory/outputs ~/Obsidian/Daily-Logs
undefinedln -s ~/openclaw-assistant/code-along/02-operational-memory/outputs ~/Obsidian/Daily-Logs
undefinedWith Git for Versioning
使用Git进行版本控制
bash
undefinedbash
undefinedTrack generated logs
跟踪生成的日志
cd code-along/02-operational-memory/outputs
git init
git add daily-.md weekly-.md
git commit -m "Daily log archive"
undefinedcd code-along/02-operational-memory/outputs
git init
git add daily-.md weekly-.md
git commit -m "每日日志存档"
undefinedWith Markdown Viewers
与Markdown查看器集成
bash
undefinedbash
undefinedServe outputs as local site
将输出作为本地站点提供
cd code-along
python -m http.server 8000
cd code-along
python -m http.server 8000
undefinedundefinedBest Practices
最佳实践
- Review before archiving - Always human-review AI outputs before filing
- Consistent naming - Use ISO date formats (YYYY-MM-DD) in filenames
- Regular cleanup - Archive old logs monthly to keep folders manageable
- Prompt iteration - Refine prompts based on output quality over time
- Local-first - Keep sensitive data local; only upload sanitized examples
- 存档前审核 - 在归档前始终人工审核AI输出
- 命名一致 - 文件名使用ISO日期格式(YYYY-MM-DD)
- 定期清理 - 每月归档旧日志以保持文件夹整洁
- 提示词迭代 - 根据输出质量随时间优化提示词
- 本地优先 - 敏感数据保持本地存储;仅上传经过清理的示例