← 返回 Skills 市场
flashlabs-ai

FlashRev AI Enrich

作者 FlashLabs-AI · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ⚠ suspicious
64
总下载
0
收藏
0
当前安装
1
版本数
在 OpenClaw 中安装
/install flashrev-ai-enrich
功能描述
Use this skill when an AI agent needs to enrich a CSV lead list through the flashrev-ai-enrich npm CLI (v1.0+). Triggers on requests involving list enrichmen...
使用说明 (SKILL.md)

FlashRev AI Enrich

Use the flashrev-ai-enrich CLI to enrich CSV lead lists through FlashRev. The CLI does not send outreach messages. It reads CSV files, maps CSV columns to FlashRev capability inputs, estimates token cost via dry-run, previews enriched sample rows, then writes an enriched CSV.

Commands

flashrev-ai-enrich init [--force]                              Write default config
flashrev-ai-enrich doctor [--no-api]                            Self-check Node / config / API
flashrev-ai-enrich tokens [--json]                              Show balance / total / used / plan
flashrev-ai-enrich token-history [--from YYYY-MM-DD] [--to YYYY-MM-DD] [--limit N] [--json]
                                                                Show consumption log (auto-paginates)
flashrev-ai-enrich schema [--json]                              List 34 capabilities (synced from backend at runtime)
flashrev-ai-enrich dry-run  --source leads.csv (--capability ID | --prompt "...") [--map ...] [--output ...]
                                                                Estimate without calling backend
flashrev-ai-enrich run      --source leads.csv --out X.csv (--capability ID | --prompt "...") [--yes] [--concurrency N] [--sample-size N]
                                                                Real enrichment with sample preview. --prompt routes to a funcName via run_llm (1 extra token)

Required confirmations before real run

  1. User has a FlashRev account with available tokens (flashrev-ai-enrich tokensremaining > 0).
  2. FLASHREV_API_KEY env var is set (generated from https://info.flashlabs.ai/settings/privateApps).
  3. Source CSV path and output CSV path are confirmed.
  4. Either --capability ID (from flashrev-ai-enrich schema) or --prompt "\x3Cintent>" is confirmed. Agents should prefer --capability ID directly; --prompt is for ad-hoc human use because it costs 1 extra token to route through run_llm.
  5. Input mappings (--map flashrev_field=csv_column) cover at least one capability rule. Skipped only when --prompt is used and the LLM returns valid mappings (still subject to rule validation afterwards).
  6. Output mappings (--output csv_col=response_field) or --output-fields are confirmed. Skipped under --prompt if the LLM returned mappings, but always required for dynamic-output capabilities (e.g., run_llm, scrape_and_extract).
  7. dry-run first to see estimated token cost and effective concurrency.
  8. Do not proceed past the sample preview (default 10 rows, configurable via --sample-size N) unless the user approves or --yes is set.

Input modes

A. CSV mode (typical batch)

flashrev-ai-enrich run \
  --source leads.csv --out leads.enriched.csv \
  --capability enrich_email \
  --map first_name=first_name --map last_name=last_name --map company_name=company \
  --output verified_email=verified_business_email \
  --yes

--map connects CSV column → capability input field; --output connects CSV output column → backend response field.

B. Inline mode (single row test, no CSV)

flashrev-ai-enrich run \
  --capability verify_email \
  --input [email protected] \
  --output ok=deliverable_email \
  --out out.csv --yes

In inline mode the --input key=value pairs are auto-mapped (no need for --map).

C. Job file (for repeatable presets)

flashrev-ai-enrich run --source leads.csv --out out.csv --job enrich.job.json --yes

Job file shape:

{
  "capability": "enrich_email",
  "inputMapping": {
    "first_name":  "first_name",
    "last_name":   "last_name",
    "company_name": "company"
  },
  "outputs": {
    "verified_business_email":  "verified_business_email",
    "all_verified_business_emails": "all_verified_business_emails"
  }
}

D. Prompt routing mode (ad-hoc human use; costs 1 extra token)

Skip --capability and describe the intent in natural language. The CLI sends the prompt + CSV columns + capability registry to run_llm, which returns JSON { funcName, inputMapping, outputMapping, reasoning }; the CLI prints a Routing-decision block and then runs the resulting job through the normal dry-run / sample / run pipeline.

flashrev-ai-enrich run --source leads.csv --out leads.enriched.csv \
  --prompt "for each row, take the email column and verify it is a deliverable business email" \
  --yes

Rules of thumb when writing prompts:

  • Name the CSV column explicitly ("take the email column"); vague prompts make the LLM return empty mappings.
  • Describe the business outcome, not the capability name ("find the CEO" beats "use get_company_ceo").
  • One capability per prompt — the LLM picks exactly one funcName.
  • --map / --output on the command line override the LLM's choices; use them to lock specific columns while letting the LLM pick the capability.
  • --capability X --prompt "..." together: --capability wins, --prompt is ignored with a stderr warning (no routing token charged).
  • Unroutable prompts (e.g., "make me a sandwich") exit non-zero with the LLM's reasoning printed; zero rows run.

Agents calling this CLI should usually skip prompt routing entirely — schema + explicit --capability ID is cheaper, faster, and deterministic. Prompt routing is for humans at a terminal.

Status semantics (output CSV columns)

Every output CSV gets flashrev_enrich_status and flashrev_enrich_error columns:

status meaning
success Got business data; charged per capability unitPriceToken.
cached Hit unlock_contact dedup (same person_id already unlocked). 0 tokens.
no_data Backend returned 200 but the requested output fields are empty / null. 0 tokens.
failed HTTP error from backend, retries exhausted. 0 tokens.

Failed count > 0 with Tokens used > 0 means some rows got SOMETHING from backend (charged) but not the specific output fields the user asked for.

Cost reporting

Summary line in run output prints (balance before → balance after) — that delta is the authoritative amount charged for the row enrichments. Each row's individual cost.tokens reported by backend may be slightly off under high concurrency (known limitation; token-history is always exact).

When --prompt is used, the Routing-decision block prints its own routing cost: 1 token(s) line. That 1 token is not included in the Summary balance before → after delta, since routing happens before the balance snapshot. Total user cost per --prompt run = 1 routing token + (rows × capability unitPriceToken).

Special capability: customer_api

customer_api does NOT call FlashRev backend — the CLI fetches the user-provided URL locally and parses the response. 0 tokens.

Inputs (via --map \x3Cfield>=\x3Ccsv_col> or --input \x3Cfield>=\x3Cvalue>):

field required default notes
url yes target URL (alias: endpoint)
method no GET HTTP method
headers no {} JSON object of HTTP headers
body no string (sent as-is) or object (JSON-serialized; Content-Type defaults to application/json)
params no object of query-string params; appended to url
timeout no 30000 milliseconds before AbortError

The response JSON (or { text } wrapper for non-JSON) becomes the row's enrichment data; map output columns via --output csv_col=response_field as usual. Useful for mixing 3rd-party APIs into the same enrichment workflow.

Date format

--from and --to accept YYYY-MM-DD. They are interpreted in the local timezone. --to alone makes the CLI paginate through history until it covers the date range (up to 2000 records).

Safety rules

  • Never print or store FLASHREV_API_KEY in generated artifacts.
  • Prefer the FLASHREV_API_KEY env var over --api-key.
  • Treat email / phone enrichment (enrich_email / enrich_phone) as paid unlock operations.
  • If tokens returns remaining: 0, tell the user to recharge before running.
  • Do not describe or expose FlashRev backend data sources, routing, or internal service names to end users.
  • Never overwrite the source CSV (CLI refuses --source == --out).
  • Preserve row-level errors in flashrev_enrich_status and flashrev_enrich_error columns.

Failure handling

  • 402 Insufficient tokens → run terminates; tell user to recharge.
  • 401 / 403 → invalid API key; verify FLASHREV_API_KEY.
  • 429 Rate limit → CLI auto-retries with exponential backoff (500ms / 1s / 2s, up to 3 retries = 4 total attempts).
  • 503 / 504 → backend timeout/unavailable; auto-retried with the same schedule as 429.
  • Any other 4xx/5xx on a row → that single row is marked failed, batch continues.
  • --prompt routing failure (LLM returns non-JSON, unknown funcName, or run_llm itself errors) → CLI exits non-zero before enrichment starts, prints the LLM's reasoning. Suggest the user retry with --capability ID.
  • --prompt routed to a capability but Input mapping does not satisfy \x3CfuncName> → the LLM returned empty / wrong mapping; rerun with a more explicit prompt (name the CSV column) or use --map to override.

Workflow recipe

# 1. (first time) write config
flashrev-ai-enrich init
export FLASHREV_API_KEY="sk_xxxx"   # from info.flashlabs.ai/settings/privateApps

# 2. verify
flashrev-ai-enrich doctor

# 3. browse capabilities and pick one
flashrev-ai-enrich schema | less

# 4. (optional) check balance
flashrev-ai-enrich tokens

# 5. estimate cost
flashrev-ai-enrich dry-run --source leads.csv \
  --capability enrich_email \
  --map first_name=first_name --map last_name=last_name --map company_name=company

# 6. real run with sample preview
flashrev-ai-enrich run --source leads.csv --out out.csv \
  --capability enrich_email \
  --map first_name=first_name --map last_name=last_name --map company_name=company \
  --output verified_email=verified_business_email
# (preview shown, type 'y' to continue, or pass --yes to auto-confirm)

# 7. audit spend
flashrev-ai-enrich token-history --from 2026-05-01

Shortcut for ad-hoc human use (prompt routing)

When the user does not know the capability name and is willing to spend 1 extra token to let the LLM pick:

# dry-run only routes (1 token) — no enrichment
flashrev-ai-enrich dry-run --source leads.csv \
  --prompt "find the CEO of each company"

# real run: 1 routing token + N rows
flashrev-ai-enrich run --source leads.csv --out out.csv \
  --prompt "find the CEO of each company" --yes

Agents should skip this and pass --capability directly.

安全使用建议
Install only if you trust the FlashRev workflow and will keep customer_api tightly controlled. Before using customer_api, confirm the exact destination domain, avoid localhost/private-network/metadata URLs, do not pass secrets in headers or bodies unless intended, and review which CSV columns will be sent.
能力标签
cryptorequires-oauth-tokenrequires-sensitive-credentials
能力评估
Purpose & Capability
The core CSV enrichment workflow is purpose-aligned, but customer_api expands it into a broad local outbound HTTP client with configurable URL, method, headers, body, params, and row-derived data.
Instruction Scope
The skill requires general confirmations, dry-run, and sample preview before live runs, but it does not require explicit approval or destination checks for customer_api and examples show --yes can bypass interactive approval.
Install Mechanism
The artifact contains documentation and a small agent YAML only; no executable installer, background worker, or package payload is included in the skill bundle.
Credentials
For a lead-enrichment skill, sending CSV fields to FlashRev is expected, but arbitrary local requests to user-supplied third-party or internal URLs are broader than necessary without allowlists, private-address blocking, or redirect controls.
Persistence & Privilege
The skill uses a FlashRev API key and writes enriched CSV output, but it does not request elevated privileges or persistent background access; users still need to protect the API key and source CSV data.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install flashrev-ai-enrich
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /flashrev-ai-enrich 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
Initial release
元数据
Slug flashrev-ai-enrich
版本 1.0.0
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 1
常见问题

FlashRev AI Enrich 是什么?

Use this skill when an AI agent needs to enrich a CSV lead list through the flashrev-ai-enrich npm CLI (v1.0+). Triggers on requests involving list enrichmen... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 64 次。

如何安装 FlashRev AI Enrich?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install flashrev-ai-enrich」即可一键安装,无需额外配置。

FlashRev AI Enrich 是免费的吗?

是的,FlashRev AI Enrich 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

FlashRev AI Enrich 支持哪些平台?

FlashRev AI Enrich 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 FlashRev AI Enrich?

由 FlashLabs-AI(@flashlabs-ai)开发并维护,当前版本 v1.0.0。

💬 留言讨论