com um clique
customer-email-assist
// 用 connector-first、最少 token 的方式审阅 Gmail 客户支持线程。适用于 Codex 需要通过 Codex Gmail connector 读取 Gmail、把清洗后的消息导入本地 SQLite 问题队列、先执行确定性的清洗和分类、只把模型调用保留给 JSON-only 的消息理解和草稿字段生成,并支持 dashboard 审阅、客户审批与排队回复处理的时候。
// 用 connector-first、最少 token 的方式审阅 Gmail 客户支持线程。适用于 Codex 需要通过 Codex Gmail connector 读取 Gmail、把清洗后的消息导入本地 SQLite 问题队列、先执行确定性的清洗和分类、只把模型调用保留给 JSON-only 的消息理解和草稿字段生成,并支持 dashboard 审阅、客户审批与排队回复处理的时候。
Review Gmail customer-support threads with a minimal-token, connector-first workflow. Use when Codex needs to read Gmail through the Codex Gmail connector, import cleaned messages into a local SQLite issue queue, apply deterministic cleanup and classification first, reserve model usage for JSON-only message understanding and draft-field generation, and support dashboard review, customer approval, and queued reply handling for a local single-operator support workflow.
Preview-first local file organizer. Scan a user-named folder, classify files into category subfolders using readable rules, write a preview Markdown report and JSON plan, execute confirmed moves with persistent SQLite state, and reverse moves with undo. Use when a user asks Codex to organize Downloads, sort a messy folder into Invoices/Receipts/School/Images/Software/PDFs subfolders, propose a folder structure before moving anything, or undo a previous organization run.
Persistent product price tracking for natural-language product requests. Use when a user asks to watch, track, monitor, compare, or report prices for a product, especially with a target price or threshold such as "Watch MacBook Pro M3 14-inch and tell me if it drops below $1200." Supports source discovery, Playwright/browser product checks, SQLite history, threshold comparison, and Markdown price reports.
Plan and inspect prompt-cache behavior for long-running Claude agent loops. Use when a user wants to split stable tool, system, and history context into cacheable layers, compare captured cache metadata, estimate cost impact from supplied pricing inputs, or keep durable memory outside the cached prefix.
Capture local or explicitly provided web knowledge sources into cited Markdown notes. Use when a user asks Codex to watch a research folder, register local folders for later scans, summarize new or modified local Markdown/TXT/PDF/DOCX files, capture a provided URL, maintain SQLite state for personal knowledge capture, or generate searchable source-grounded daily notes.
Scan local cleanup targets, apply readable cleanup rules, produce a preview report, and execute approved cleanup actions with logs. Use when a user asks Codex to clean up their computer, empty old Trash items, find duplicated Downloads files, review local storage clutter, or propose safe file cleanup actions before making changes.
| name | customer-email-assist |
| description | 用 connector-first、最少 token 的方式审阅 Gmail 客户支持线程。适用于 Codex 需要通过 Codex Gmail connector 读取 Gmail、把清洗后的消息导入本地 SQLite 问题队列、先执行确定性的清洗和分类、只把模型调用保留给 JSON-only 的消息理解和草稿字段生成,并支持 dashboard 审阅、客户审批与排队回复处理的时候。 |
使用这个技能来操作 customer-email-assist-starter 示例,并尽量减少
模型 token 消耗。
CUSTOMER_EMAIL_ASSIST_POLICY_PATHCUSTOMER_EMAIL_ASSIST_DB_PATH正常工作流中的 Gmail 认证应通过 Codex Gmail connector 完成。不要要求用户 为了常规使用配置本地 Google OAuth 环境变量。
只在以下两种场景使用模型 token:
不要把模型调用用于 Gmail 抓取、HTML 清理、引用历史移除、签名裁剪、 客户匹配、SQLite 写入、分析统计、过滤、分页或发送队列执行。
相对于该入门项目目录解析路径。
npm run setup-local
tsx scripts/customer-email-assist.ts import-prepared-batch --input /tmp/prepared-inbound.json
tsx scripts/customer-email-assist.ts persist-understanding --input /tmp/understanding.json
tsx scripts/customer-email-assist.ts prepare-draft-batch --policy "$CUSTOMER_EMAIL_ASSIST_POLICY_PATH" --out /tmp/draft-batch.json
tsx scripts/customer-email-assist.ts render-save-drafts --input /tmp/draft-fields.json
newer_than:1d -in:spam -in:trash -category:promotions。/tmp/prepared-inbound.json,格式为 PreparedInboundItem[]。
gmailThreadId、gmailLastInboundMessageId、subject、
cleanBody、receivedAt 和 customer 字段。import-prepared-batch --input <file>。
understand。
gmailThreadIdgmailLastInboundMessageIdcustomerEmailcustomerNamesubjectreceivedAtoriginalMessageTextclassificationsummaryurgencyactionSuggestionpersist-understanding --input <file>。prepare-draft-batch --policy <file>。
draft-fields。
issueIdclassificationdraftFields.customerNamedraftFields.acknowledgementdraftFields.nextStepdraftFields.policyEvidencedraftFields.signoffrender-save-drafts --input <file>。approved_to_send 的 issue,使用 Codex
Gmail connector 创建或发送回复,然后把 issue 标记为 resolved。仓库仍保留直接 Gmail API adapter,供明确需要 standalone local integration 的团队使用。它属于高级路径,不应作为默认设置展示。
高级变量:
CUSTOMER_EMAIL_ASSIST_GMAIL_LABELGOOGLE_CLIENT_IDGOOGLE_CLIENT_SECRETCUSTOMER_EMAIL_ASSIST_OPERATOR_EMAILGOOGLE_REDIRECT_URIdashboard 的 Connect Gmail 按钮会在 Google consent callback 之后把
refresh token 写入本地状态。GOOGLE_REFRESH_TOKEN 仍可作为手动兜底变量,
但不是 web-app 流程必需项。
高级命令:
npm run sync:oauth
tsx scripts/customer-email-assist.ts prepare-inbound-batch --out /tmp/prepared-inbound.json
tsx scripts/customer-email-assist.ts apply-send-queue
当这个高级本地 OAuth 路径已连接时,dashboard 的 Approve & Send 动作会在
undo 倒计时结束后立即执行确定性的发送路径。没有 OAuth 连接时,dashboard
会把 issue 保持在 approved_to_send,而不是尝试未认证的发送。
prepare-draft-batch 选出的
政策证据行。handoff_required
案例放进自动发送路径。