factor

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Factor Skill

Factor Skill

Overview

概述

Automates Factor operations including prepared meal browsing, box customization, and subscription management through browser automation. Note: Actual orders are not automated for security.
通过浏览器自动化实现Factor操作的自动化,包括预制餐浏览、餐盒定制和订阅管理。注意:出于安全考虑,实际下单操作未实现自动化。

Quick Install

快速安装

bash
curl -sSL https://canifi.com/skills/factor/install.sh | bash
Or manually:
bash
cp -r skills/factor ~/.canifi/skills/
bash
curl -sSL https://canifi.com/skills/factor/install.sh | bash
或者手动安装:
bash
cp -r skills/factor ~/.canifi/skills/

Setup

设置

Configure via canifi-env:
bash
undefined
通过canifi-env进行配置:
bash
undefined

First, ensure canifi-env is installed:

First, ensure canifi-env is installed:

canifi-env set FACTOR_EMAIL "your-email@example.com" canifi-env set FACTOR_PASSWORD "your-password"
undefined
canifi-env set FACTOR_EMAIL "your-email@example.com" canifi-env set FACTOR_PASSWORD "your-password"
undefined

Privacy & Authentication

隐私与认证

Your credentials, your choice. Canifi LifeOS respects your privacy.
你的凭据,由你掌控。 Canifi LifeOS 尊重你的隐私。

Option 1: Manual Browser Login (Recommended)

选项1:手动浏览器登录(推荐)

If you prefer not to share credentials with Claude Code:
  1. Complete the Browser Automation Setup using CDP mode
  2. Login to the service manually in the Playwright-controlled Chrome window
  3. Claude will use your authenticated session without ever seeing your password
如果你不想与Claude Code共享凭据:
  1. 使用CDP模式完成浏览器自动化设置
  2. 在Playwright控制的Chrome窗口中手动登录该服务
  3. Claude将使用你的已认证会话,全程不会获取你的密码

Option 2: Environment Variables

选项2:环境变量

If you're comfortable sharing credentials, you can store them locally:
bash
canifi-env set SERVICE_EMAIL "your-email"
canifi-env set SERVICE_PASSWORD "your-password"
Note: Credentials stored in canifi-env are only accessible locally on your machine and are never transmitted.
如果你愿意共享凭据,可以将其存储在本地:
bash
canifi-env set SERVICE_EMAIL "your-email"
canifi-env set SERVICE_PASSWORD "your-password"
注意:存储在canifi-env中的凭据仅可在你的本地机器上访问,绝不会被传输。

Capabilities

功能

  • Browse prepared meals
  • View nutritional info
  • Customize weekly selections
  • Track deliveries
  • View order history
  • Manage dietary preferences
  • Check meal plans
  • Skip or pause weeks
  • 浏览预制餐
  • 查看营养信息
  • 自定义每周餐品选择
  • 追踪配送进度
  • 查看订单历史
  • 管理饮食偏好
  • 查看餐食计划
  • 跳过或暂停某周的配送

Usage Examples

使用示例

Example 1: Browse Meals

示例1:浏览餐品

User: "What meals are available on Factor?"
Claude: I'll check the menu.
- Navigate to factor75.com
- View available meals
- List options by category
- Present with nutrition
User: "What meals are available on Factor?"
Claude: I'll check the menu.
- Navigate to factor75.com
- View available meals
- List options by category
- Present with nutrition

Example 2: Check Keto Options

示例2:查看生酮餐品选项

User: "Show me keto meals on Factor"
Claude: I'll find keto options.
- Navigate to menu
- Filter by keto
- List keto-friendly meals
- Present macros
User: "Show me keto meals on Factor"
Claude: I'll find keto options.
- Navigate to menu
- Filter by keto
- List keto-friendly meals
- Present macros

Example 3: Track Delivery

示例3:追踪配送

User: "When is my Factor delivery coming?"
Claude: I'll check your delivery.
- Navigate to orders
- Find upcoming delivery
- Check shipping status
- Report arrival date
User: "When is my Factor delivery coming?"
Claude: I'll check your delivery.
- Navigate to orders
- Find upcoming delivery
- Check shipping status
- Report arrival date

Example 4: View Nutrition

示例4:查看营养信息

User: "What are the calories in Factor meals?"
Claude: I'll check nutritional info.
- Browse meal options
- Gather calorie data
- List protein and carbs
- Present nutrition summary
User: "What are the calories in Factor meals?"
Claude: I'll check nutritional info.
- Browse meal options
- Gather calorie data
- List protein and carbs
- Present nutrition summary

Authentication Flow

认证流程

  1. Navigate to factor75.com via Playwright MCP
  2. Click Log In
  3. Enter email from canifi-env
  4. Enter password
  5. Handle 2FA if enabled (notify user via iMessage)
  6. Verify account access
  7. Maintain session cookies
  1. 通过Playwright MCP导航至factor75.com
  2. 点击“登录”
  3. 从canifi-env中读取邮箱并输入
  4. 输入密码
  5. 若启用了双因素认证(2FA),则通过iMessage通知用户
  6. 验证账户访问权限
  7. 保存会话Cookie

Error Handling

错误处理

  • Login Failed: Clear cookies, verify credentials
  • Session Expired: Re-authenticate automatically
  • 2FA Required: iMessage for verification code
  • Selection Deadline: Note cutoff
  • Meal Unavailable: Check alternatives
  • Delivery Issue: Check address
  • Plan Issue: Check subscription status
  • Dietary Filter Error: Reset filters
  • 登录失败:清除Cookie,验证凭据
  • 会话过期:自动重新认证
  • 需要双因素认证(2FA):通过iMessage发送验证码请求
  • 选择截止日期:提醒用户截止时间
  • 餐品无货:查看替代选项
  • 配送问题:检查收货地址
  • 计划问题:检查订阅状态
  • 饮食筛选错误:重置筛选条件

Self-Improvement Instructions

自我优化说明

When encountering new Factor features:
  1. Document new UI elements
  2. Add support for new meal types
  3. Log successful patterns
  4. Update for Factor changes
当遇到Factor的新功能时:
  1. 记录新的UI元素
  2. 添加对新餐品类型的支持
  3. 记录成功的操作模式
  4. 根据Factor的更新进行适配

Notes

注意事项

  • Prepared meals, no cooking needed
  • Orders not automated for security
  • Owned by HelloFresh
  • Various dietary plans (keto, paleo, etc.)
  • Heat and eat convenience
  • Chef-prepared meals
  • Weekly selection deadline
  • 预制餐品,无需烹饪
  • 出于安全考虑,未实现下单自动化
  • 隶属于HelloFresh
  • 提供多种饮食计划(生酮、原始人饮食等)
  • 加热即可食用,便捷省心
  • 由厨师精心制作
  • 每周餐品选择有截止日期