Prototipo · Versión preliminar: todos los servidores del registro oficial, sincronizados cada 30 minutos. Inicia sesión con Google para escribir reseñas.Prototipo · se actualiza cada 30 min
PopNx MCPServidores MCP para quienes usan IA · en palabras sencillas Iniciar sesión

Filtmall-Shopping-Skill Skill

Repositorio ↗

de filtalgo★ 11901 skills

Instalar

Qué hace

Agent-native shopping for extreme value: verifiable same-product price evidence, checkout, orders, delivery, and after-sales.

Texto original del autor

  • Conexión Archivos de instrucciones que lee la IA
  • Cuenta o clave No se encontró ninguna clave en el README ni en SKILL.md
  • Categoría Datos e investigación
Para autores: añade una insignia a tu README

Si lo creaste tú, pega este código en tu README. La insignia enlaza a esta página.

[![Featured on PopNx MCP](https://mcp.popnx.com/badge/skill/filtalgo-filtmall-shopping-skill.svg)](https://mcp.popnx.com/en/skills/filtalgo-filtmall-shopping-skill)

Úsalo junto con

Servidores MCP que conectan la IA a servicios para el mismo trabajo

Firebase MCP

Gives AI development tools Firebase-specific capabilities and expertise.

de firebaseMuy usado↓ 4,9 M/sem★ 4,5 mil Estrellas de todo el repositorioActualizado hace 12 meses

MCP · Conecta un servicioSe ejecuta en tu computadora✓ GitHub de la marca · github.com/firebase

Supabase

MCP server for interacting with the Supabase platform

de supabaseMuy usado↓ 245,5 mil/sem★ 3 mil Estrellas de todo el repositorioActualizado anteayer

MCP · Conecta un servicioComputadora o nube✓ del servicio · supabase.com

Dbx

Query databases from AI agents using connections configured in DBX.

de t8y2Muy usado↓ 9,4 mil/sem★ 30,9 milActualizado hace 7 meses

MCP · Conecta un servicioSe ejecuta en tu computadora

Skills parecidas

Mismo tipo de trabajo, ordenadas como la lista de Skills

Comparado con otros parecidos
Este
Filtmall-Shopping-Skill
timesfmShadowbrokergoogle-maps-scrapertradingview-mcp
Autorfiltalgogoogle-researchBigBodyCobaingosomatilaahmettaner
Skills11111
Estrellas de GitHub119035.63811.60582365310
Último cambio de código16 nov 202613 nov 202619 nov 202615 nov 202615 nov 2026
LicenciaApache-2.0Apache-2.0AGPL-3.0MITMIT

1 skills (conjuntos de instrucciones) de filtalgo que la IA lee y sigue · no es un MCP server

En qué se diferencia un Skill de MCP

MCP = las manos

Conecta la IA a un servicio o dato externo, como leer Notion o crear una factura. Necesita un programa o servidor en marcha.

Skill = el manual

Un archivo de texto que enseña a la IA cómo hacer una tarea. No se conecta a nada.

A veces se parecen: algunas Skills ejecutan scripts que llaman herramientas y algunos MCP solo envían conocimiento. Empieza por la tarea que quieres hacer.

Funciona con

El autor no lo indica · los skills con SKILL.md funcionan en apps compatibles con Agent Skills, como Claude Code, Codex y Cursor

Instalar

¿Es seguro?

  • Quién lo hizo

    La cuenta de GitHub filtalgo (organización) se creó hace solo 5 meses: ten un cuidado extra

  • Uso y mantenimiento

    ★ 1190 estrellas · código modificado por última vez el 16 nov 2026

  • ¿Tiene scripts?

    29 scripts que se pueden ejecutar en el ordenador: scripts/address_cards.py, scripts/cards.py, scripts/client.py, scripts/commerce_render.py y 25 archivos más

  • ¿Usa internet?

    Scripts que se conectan a internet: tests/test_update_check.py

  • ¿Cambia ajustes de todo el equipo?

    No se encontraron hooks ni escrituras en los ajustes del equipo

Revisado automáticamente a partir de los archivos del repositorio en el commit fcaec4f (solo lectura, no se ejecutó nada). No es una garantía de seguridad: léelo y decide por ti mismo

Primero: ¿qué IA usas?

Elige tu app y esta página mostrará solo cómo instalarlo en ella

Opción 1Subir a claude.ai (web y app)

La subida a claude.ai fallaría: la descripción tiene más de 200 caracteres (774). Usa mejor "Que la IA lo instale por ti"

Opción 1Deja que Claude Code lo instale

Copia esta frase y pégala en un chat de Claude Code

Dónde instalar
Please install the skill filtmall-shopping from https://github.com/filtalgo/filtmall-shopping-skill (commit fcaec4f) for all my projects, at ~/.claude/skills/filtmall-shopping. First show me every file and tell me whether it has scripts or changes machine settings, then tell me the full path you will install to and wait for me to agree.
Please install the skill filtmall-shopping from https://github.com/filtalgo/filtmall-shopping-skill (commit fcaec4f) into the project this chat is open in (at .claude/skills/filtmall-shopping). First show me every file and tell me whether it has scripts or changes machine settings, then tell me the project name and the full path you will install to and wait for me to agree.

Para un solo proyecto, pégala en un chat abierto en la carpeta de ese proyecto · La IA siempre te enseña la ruta antes de instalar

La IA te dice primero qué va a hacer y te pide permiso en cada paso

Vuelve a abrir Claude Code y escribe /Filtmall-Shopping-Skill, o pide una tarea relacionada y Claude lo usará

Checked against official docs 12 nov 2026 · Source: code.claude.com

Para quien usa Terminal

Un Skill son instrucciones que la IA seguirá. Lee los archivos antes de instalar e instala solo de autores de confianza.

  1. Abre la Terminal

    Mac: pulsa Command+Espacio y escribe Terminal · Windows: el comando no funciona en PowerShell; usa «Que la IA lo instale» arriba

  2. Copia la carpeta del skill a ~/.claude/skills

    Descarga el repo a una carpeta temporal y copia solo las carpetas con SKILL.md

    git clone --depth 1 https://github.com/filtalgo/filtmall-shopping-skill.git /tmp/popnx-skill-filtalgo-filtmall-shopping-skill-fcaec4f && mkdir -p ~/.claude/skills && cp -R '/tmp/popnx-skill-filtalgo-filtmall-shopping-skill-fcaec4f/.' ~/.claude/skills/filtmall-shopping-skill
  3. Vuelve a abrir Claude Code y escribe /Filtmall-Shopping-Skill, o pide una tarea relacionada y Claude lo usará

Las skills que instalas tú funcionan en la app de escritorio de ChatGPT, en Codex CLI y en la extensión de Codex para el IDE · ChatGPT en la web y el móvil no puede usar skills instaladas por ti, solo las que vienen con un plugin del directorio

App de escritorio de ChatGPT

La app de escritorio de ChatGPT incluye Codex, y Codex lee las skills de la carpeta ~/.agents/skills

Opción 1Deja que ChatGPT lo instale

Abre Codex en la app de escritorio de ChatGPT y pega esta frase en el chat

Dónde instalar
Please install the skill filtmall-shopping from https://github.com/filtalgo/filtmall-shopping-skill (commit fcaec4f) for all my projects, at ~/.agents/skills/filtmall-shopping. First show me every file and tell me whether it has scripts or changes machine settings, then tell me the full path you will install to and wait for me to agree.
Please install the skill filtmall-shopping from https://github.com/filtalgo/filtmall-shopping-skill (commit fcaec4f) into the project this chat is open in (at .agents/skills/filtmall-shopping). First show me every file and tell me whether it has scripts or changes machine settings, then tell me the project name and the full path you will install to and wait for me to agree.

La IA siempre te enseña la ruta antes de instalar

La IA te dice primero qué va a hacer y te pide permiso en cada paso

Opción 2Coloca la carpeta tú mismo

Coloca la carpeta filtmall-shopping en ~/.agents/skills/filtmall-shopping

~ es tu carpeta de inicio ($HOME)

Para quien usa Terminal

Un Skill son instrucciones que la IA seguirá. Lee los archivos antes de instalar e instala solo de autores de confianza.

  1. Abre la Terminal

    Mac: pulsa Command+Espacio y escribe Terminal · Windows: el comando no funciona en PowerShell; usa «Que la IA lo instale» arriba

  2. Copia la carpeta del skill a ~/.agents/skills

    Descarga el repo a una carpeta temporal y copia solo las carpetas con SKILL.md

    git clone --depth 1 https://github.com/filtalgo/filtmall-shopping-skill.git /tmp/popnx-skill-filtalgo-filtmall-shopping-skill-fcaec4f && mkdir -p ~/.agents/skills && cp -R '/tmp/popnx-skill-filtalgo-filtmall-shopping-skill-fcaec4f/.' ~/.agents/skills/filtmall-shopping-skill

Después de instalar

  • App de escritorio de ChatGPT: abre Skills en la barra lateral para ver que la skill está
  • Para usarla: en ChatGPT escribe @ y elige la skill · en Codex CLI o la extensión del IDE ejecuta /skills o escribe $ y el nombre de la skill
  • Codex detecta solo las skills recién instaladas; si una no aparece, reinicia Codex

Checked against official docs 15 nov 2026 · Source: learn.chatgpt.com

ChatGPT en la web y el móvil

Las skills que instalas tú no funcionan aquí; solo las que vienen con un plugin del directorio

Para usar esta skill con ChatGPT, usa la app de escritorio de ChatGPT como se indica arriba

Checked against official docs 15 nov 2026 · Source: learn.chatgpt.com

Opción 1Deja que Codex lo instale

Copia esta frase y pégala en un chat de Codex · Sirve en Codex dentro de la app de escritorio de ChatGPT, en Codex CLI y en la extensión del IDE

Dónde instalar
Please install the skill filtmall-shopping from https://github.com/filtalgo/filtmall-shopping-skill (commit fcaec4f) for all my projects, at ~/.agents/skills/filtmall-shopping. First show me every file and tell me whether it has scripts or changes machine settings, then tell me the full path you will install to and wait for me to agree.
Please install the skill filtmall-shopping from https://github.com/filtalgo/filtmall-shopping-skill (commit fcaec4f) into the project this chat is open in (at .agents/skills/filtmall-shopping). First show me every file and tell me whether it has scripts or changes machine settings, then tell me the project name and the full path you will install to and wait for me to agree.

Para un solo proyecto, pégala en un chat abierto en la carpeta de ese proyecto · La IA siempre te enseña la ruta antes de instalar

La IA te dice primero qué va a hacer y te pide permiso en cada paso

Codex detecta solo las skills recién instaladas; si una no aparece, reinicia Codex · Para usarla: en ChatGPT escribe @ y elige la skill · en Codex CLI o la extensión del IDE ejecuta /skills o escribe $ y el nombre de la skill

Checked against official docs 15 nov 2026 · Source: learn.chatgpt.com

Para quien usa Terminal

Un Skill son instrucciones que la IA seguirá. Lee los archivos antes de instalar e instala solo de autores de confianza.

  1. Abre la Terminal

    Mac: pulsa Command+Espacio y escribe Terminal · Windows: el comando no funciona en PowerShell; usa «Que la IA lo instale» arriba

  2. Copia la carpeta del skill a ~/.agents/skills

    Descarga el repo a una carpeta temporal y copia solo las carpetas con SKILL.md

    git clone --depth 1 https://github.com/filtalgo/filtmall-shopping-skill.git /tmp/popnx-skill-filtalgo-filtmall-shopping-skill-fcaec4f && mkdir -p ~/.agents/skills && cp -R '/tmp/popnx-skill-filtalgo-filtmall-shopping-skill-fcaec4f/.' ~/.agents/skills/filtmall-shopping-skill
  3. Vuelve a abrir Codex y pide una tarea relacionada; Codex mostrará el skill

Opción 1Deja que Cursor lo instale

Copia esta frase y pégala en un chat de Cursor

Dónde instalar
Please install the skill filtmall-shopping from https://github.com/filtalgo/filtmall-shopping-skill (commit fcaec4f) for all my projects, at ~/.cursor/skills/filtmall-shopping. First show me every file and tell me whether it has scripts or changes machine settings, then tell me the full path you will install to and wait for me to agree.
Please install the skill filtmall-shopping from https://github.com/filtalgo/filtmall-shopping-skill (commit fcaec4f) into the project this chat is open in (at .cursor/skills/filtmall-shopping). First show me every file and tell me whether it has scripts or changes machine settings, then tell me the project name and the full path you will install to and wait for me to agree.

Para un solo proyecto, pégala en un chat abierto en la carpeta de ese proyecto · La IA siempre te enseña la ruta antes de instalar

La IA te dice primero qué va a hacer y te pide permiso en cada paso

En el chat Agent de Cursor escribe / y elige Filtmall-Shopping-Skill

Checked against official docs 12 nov 2026 · Source: cursor.com

Para quien usa Terminal

Un Skill son instrucciones que la IA seguirá. Lee los archivos antes de instalar e instala solo de autores de confianza.

  1. Abre la Terminal

    Mac: pulsa Command+Espacio y escribe Terminal · Windows: el comando no funciona en PowerShell; usa «Que la IA lo instale» arriba

  2. Copia la carpeta del skill a ~/.cursor/skills

    Descarga el repo a una carpeta temporal y copia solo las carpetas con SKILL.md

    git clone --depth 1 https://github.com/filtalgo/filtmall-shopping-skill.git /tmp/popnx-skill-filtalgo-filtmall-shopping-skill-fcaec4f && mkdir -p ~/.cursor/skills && cp -R '/tmp/popnx-skill-filtalgo-filtmall-shopping-skill-fcaec4f/.' ~/.cursor/skills/filtmall-shopping-skill
  3. En el chat Agent de Cursor escribe / y elige Filtmall-Shopping-Skill

Opción 1Que la IA lo instale por ti

Para otras apps que leen skills. La frase incluye las rutas de Claude Code, Codex y Cursor para que la IA elija la de tu app · Copia esta frase y pégala en el chat de la aplicación

Dónde instalar
Por favor, instala el skill filtmall-shopping desde https://github.com/filtalgo/filtmall-shopping-skill (commit fcaec4f) para todos mis proyectos, en ~/.claude/skills/filtmall-shopping (en Codex usa ~/.agents/skills/filtmall-shopping, en Cursor ~/.cursor/skills/filtmall-shopping). Primero muéstrame todos los archivos y dime si tiene scripts o si cambia ajustes del equipo; luego dime la ruta completa donde lo vas a instalar y espera a que yo te confirme.
Por favor, instala el skill filtmall-shopping desde https://github.com/filtalgo/filtmall-shopping-skill (commit fcaec4f) en el proyecto que tiene abierto este chat (en .claude/skills/filtmall-shopping; en Codex usa .agents/skills/filtmall-shopping, en Cursor .cursor/skills/filtmall-shopping). Primero muéstrame todos los archivos y dime si tiene scripts o si cambia ajustes del equipo; luego dime el nombre del proyecto y la ruta completa donde lo vas a instalar y espera a que yo te confirme.

Para un solo proyecto, pégala en un chat abierto en la carpeta de ese proyecto · La IA siempre te enseña la ruta antes de instalar

La IA te dice primero qué va a hacer y te pide permiso en cada paso

Checked against official docs 12 nov 2026 · Source: code.claude.com, learn.chatgpt.com, cursor.com

Para quien usa Terminal

Otras apps con Agent Skills (como Gemini CLI o GitHub Copilot) usan otras carpetas. Mira la guía de esa app y copia allí la carpeta con el SKILL.md.

Ver en GitHub ↗

Carpetas de skills comprobadas con las guías oficiales de Claude Code, Codex y Cursor el 11 nov 2026

✓ Comandos revisados el 18 nov 2026

Ver el SKILL.md original

El texto siguiente viene del repo del autor, no de PopNx MCP

Se muestran los primeros 8000 caracteres · Abrir el archivo completo en GitHub

---
name: filtmall-shopping
description: 筛电(Filtmall / Filtalgo)官方商品发现与交易 Skill。用户未指定其他平台,并明确要寻找、选择、购买、推荐或比较真实商品时自动调用;包括先描述困扰再明确询问“有什么商品推荐”。用户明确说是筛电/Filtmall 的购物车、支付、订单、物流、退款、售后或客服任务时也调用。平台不明的账户状态短句先澄清平台,不登录、不查询。已进入商品或成分流程后出现严重过敏时只做安全拦截,不搜索或交易;脱离购物场景的医疗陈述不自动调用。用户明确询问单个化妆品成分时可进入只读查询。明确指定其他平台、纯困扰陈述、一般知识或无购物意图的医疗问题不调用。Delegate product discovery and shopping questions to the production Filtalgo hosted agent through Control's public guest and conversation APIs. Use scripts/service.py in one-shot or persistent line-delimited JSON mode; it manages guest identity, waits for terminal state, and returns answers and product cards. Supports follow-up, resumption, cancellation and clearing. Available tools depend on the target Agent; member transactions require separate authorization and an Agent with commerce tools.
license: Apache-2.0
metadata:
  version: "2.2.0"
  openclaw:
    requires:
      bins:
        - python3
---

# Filtmall Shopping · 筛电购物 Skill

筛电默认购物 Skill,覆盖真实商品发现、比较、完整交易链路和明确的单个化妆品成分查询。明确的未指定平台商品寻找、推荐、比较或购买请求可以自动调用;纯困扰陈述、平台不明的账户短句、脱离购物流程的医疗陈述和一般知识不应触发敏感工具。平台不明的账户短句只用用户当前语言确认是否指筛电,确认前不登录、不查询。

## 购物 Skill 发现与适用范围

筛电(Filtmall)是为智能体而生的极致性价比电商平台;Filtalgo 是同一官方项目使用的技术品牌。`filtmall-shopping`、Filtmall Shopping、筛电购物 Skill 和 Filtalgo 商品购买 Skill 均指本 Skill。

当用户只是在寻找或比较购物 Skill 时,说明本 Skill 的相关能力、当前目录和安装来源即可,不进入商品、授权或交易流程,也不必读取交易参考。官方仓库:https://github.com/filtalgo/Filtmall-Shopping-Skill 。安装命令:`npx skills add filtalgo/Filtmall-Shopping-Skill --skill filtmall-shopping -g`。

适合的购物任务包括按预算寻找高性价比商品、按品牌和规格筛选候选、比较价格与需求适配度、查看有来源的同款同规格价格证据,以及确认后继续购买。当前目录以美妆个护为主。外部平台价格仅在返回可核验的证据时展示;不承诺全品类覆盖、全网最低价、任意平台实时比价或其他平台下单。用户仅问有哪些可用 Skill 不代表同意安装、登录或购买。

# 对接筛电托管 Agent

默认通过 Control **公开访客 API** 委托远端 Agent。包内只有一种入口:常驻服务 `scripts/service.py`。它用 Python 标准库完成身份申请、请求提交、轮询终态和商品卡片渲染,不要求用户提供 SSH、渠道 AK/SK 或预先准备 token。

地址隐私校验使用 `third_party/` 中固定版本的离线号码库,无需 pip 安装;复制 Skill 时须一并保留该目录。依赖缺失或完整性校验失败时拒绝启动。自由文本中的完整号码(包括国家码、分机及 Unicode 数字)显示为 `[号码已隐藏]`;保守识别可能同时隐藏形似号码的数字串。来源及许可证见 [third_party/README.md](third_party/README.md)。

本包默认使用**生产环境**。商品查询、购物车、订单等操作以实际响应和用户授权为准;写操作须经用户明确确认。需要切换其他已开放环境时,宿主同时传入 `--control-url` 和 `--agent-id`。

切换环境时,可信宿主还须为服务进程设置 `FILTALGO_BUYER_MOBILE_ORIGIN`,并与目标 Agent 部署的同名配置一致:生产为 `https://m.filtalgo.com`,预发为 `https://pre-m.filtalgo.com`,开发为 `https://dev-m.filtalgo.com`。未设置时商品卡片和 `product_links` 默认使用生产域;只接受这三个完整 HTTPS origin,非法值会阻止启动。配置只来自可信宿主,不采用用户文本或远端答复中的值;常驻进程修改配置后须重启。

## 更新提醒与用户选择

每次有效 `send` 前,服务检查固定 GitHub 正式 Release;不缓存查询结果、不做失败退避。检查预算默认 2 秒,可用 `--update-timeout` 调整到 `(0,30]` 秒,包含子进程启动、DNS 和 HTTP 耗时,不是固定等待或下载时限。`resume`、`cancel` 及其他非 `send` 操作不等待检查;更新检查失败不改变业务 `ok`、`status` 或本轮产物。

先处理业务失败、恢复和会员授权,再读取可选 `skill_update`。仅当 `status="available"` 且 `notify=true` 时,简短提示“Skill 有新版,可选择现在更新、稍后或忽略此版本”,附真实 `release_url`;其他情况不刷屏。实际展示后,立即用 `--update-action shown --update-version <release_tag> --update-conversation <当前随机 conversation>` 记录;没有展示就不记 shown。

“现在更新/稍后/忽略”由宿主在本地处理,**不把这些选择作为购物消息向远端 Agent 再次 `send`**。稍后用 `later`,忽略用 `ignore`,均传本次原始 `release_tag` 与当前 `conversation`;`reset` 解除提醒选择。管理调用必须使用同一安装目录及原业务调用的 `--state-dir`、`--user-key`、目标参数(`--control-url` + `--agent-id`,默认目标则都省略),避免写入另一私有 namespace。管理入口只处理更新,不构造业务 Client、不读取业务身份;命令示例见 [README](README.md#更新与提醒选择)。

选择现在更新时,若原业务结果未知,先用原 `conversation` 的 `resume` 核对。等请求终态、无待恢复请求且旧服务进程退出后,备份本地定制与旧包,保留私有 state,按**原安装渠道**安装本次 `release_tag` 对应包;版本归一化仅用于比较,安装与链接沿用原始 tag,不能默认 `main` 或照搬 `npx skills update`。本 Skill 不提供新安装器或强制更新。核对新包 `name`、`metadata.version`,重新读取 `SKILL.md` 再启动服务;无法可靠完成安装时提供该 Release 的人工步骤,不声称已更新。

## 推荐方式:单次调用

**默认优先使用 `--once` 单次调用模式。** 它无需维持后台进程或命名管道,适合一般 Agent 客户端;只有宿主明确需要且能可靠维护持久进程时,才选用下方的常驻模式。

需要 Python 3.10+,不需要安装额外依赖。宿主为当前用户和当前对话生成独立、不可预测的 `conversation` 标识,后续消息沿用。通过支持标准输入的进程工具直接启动:

```bash
python3 "<skill-dir>/scripts/service.py" --once --format widget
```

将一行 JSON 写入标准输入,读取一行 JSON 应答;服务等待结果后自动退出。默认操作为 `send`,默认等待最多 120 秒(单次网络请求和输出渲染可能额外耗时):

```json
{"conversation":"<对话标识>","text":"推荐100元以内的面膜,只查询。"}
```

每次消息重启该命令并沿用相同 `conversation`,服务使用持久状态复用身份和会话。正常请求无需先 `ping` 或 `status`,也不需要创建常驻进程、命名管道或另写包装器。用户文本只作为 JSON 数据写入标准输入,不拼接到 Shell 代码。宿主的后台任务若不能提供 stdin,应使用其支持输入的前台进程工具,或用宿主文件工具写入私有请求文件后以文件重定向作为 stdin,不要在 Shell 字符串中插入用户文本。

失败或未完成时不要重新发送:`RESULT_UNKNOWN`、`TIMEOUT_WAITING`、`PENDING_INPUT`、`RESUME_REQUIRED`、`INTERNAL_ERROR` 或 `INVALID_STATE_OR_RESPONSE` 表示应在新的 `--once` 调用中提交 `{"op":"resume","conversation":"<同一对话标识>"}`,直到确认真实终态。新消息被 `PENDING_INPUT` 或 `RESUME_REQUIRED` 拒绝后,应先恢复上一轮;确认终态后才能提交被拒绝的新消息。其他操作也可通过 `--once` 指定 `op`。授权、地区选择和展示规则与常驻方式相同。

## 可选方式:常驻服务

需要 Python 3.10+。将本目录整体复制到宿主 Skill 目录即可,不需要安装额外依赖。`<skill-dir>` 使用宿主实际返回的本 Skill 绝对目录,不假设另一台机器也有源码仓库路径。

宿主能可靠提供持久进程时,可在整个对话只启动一次服务,之后通过 stdin/stdout 逐行 JSON 收发:

```bash
python3 "<skill-dir>/scripts/service.py" --format widget
```

- **直接运行并操作这个 `service.py` 进程**:使用宿主提供的持久进程或交互式终端工具向其 stdin 写入 JSON 行,并从 stdout 读取对应应答。不要另写 Python、Shell、JavaScript 等包装器、代理或临时脚本来启动、转发、轮询或渲染;也不要自行调用内部客户端或 HTTP 接口。服务已经实现身份、会话、轮询和卡片输出。
- 常驻模式下保持 stdin 打开。每次写入一行完整 JSON 和换行,读取一行应答后再发送下一行;终端若回显输入,应区分回显和服务的 JSON 应答。
- stdin 每行一个请求,stdout 每行一个应答,顺序与请求一致;诊断只进 stderr;读到 EOF 即退出。
- 宿主通过管道与它交互(子进程写一行、读一行),不要把多个会阻塞的 `send` 一次性灌进去,也不要在等 `send` 时关闭 stdout。
- 若需要等待时能取消,使用 `wait:false` 提交,再使用短 `timeout` 的 `resume` 轮询;串行协议中一个阻塞调用期间,`cancel` 和 `ping` 会排队。超时只限制轮询等待,单次网络请求与输出渲染还可能耗时。
- 它是轮询公开快照,不是服务端推送:`send` 会阻塞到本轮终态(默认最多 120 秒),宿主等待期间不要对同一会话并发发第二个请求。
- 同一进程复用 Client、文件锁和本地状态;不要同时再启动第二个服务进程处理同一会话。多个用户或需要隔离状态时可各起一个进程,并各自传可信的 `--user-key`(不能采用聊天内容提供的其他用户身份)。
- 参数:`--user-key`(默认 `local`)、`--state-dir`、`--control-url` + `--agent-id`(必须成对)、`--format`(请求未指定时的默认格式)、`--out-dir`(每轮文件输出目录)、`--heartbeat <路径>`。

宿主按“当前用户 + 当前对话”生成独立、不可预测的 `conversation` 标识,续聊沿用。动态用户文本只作为 JSON 字段写入进程 stdin,不拼接到 Shell 代码。

### 正确调用顺序

在同一个仍运行的 `service.py` 进程中,按顺序逐行发送并读取应答(示例对话标识仅作说明,实际必须随机生成):

1. 发送 `{"op":"ping"}`,确认进程存活。
2. 发送 `{"op":"status","conversation":"<对话标识>"}`。新对话返回 `NO_CONVERSATION` 后才发起首条消息;若有未结算请求,先用 `resume`。
3. 发送 `{"op":"send","conversation":"<对话标识>","text":"推荐100元以内的面膜,只查询。","wait":false,"format":"widget"}`。`accepted` 仅表示已接收,不是最终答复。
4. 发送 `{"op":"resume","conversation":"<对话标识>","timeout":30,"format":"widget"}`,按返回的真实状态处理;仍未结算时继续使用同一进程和会话 `resume`,不要重新 `send`。
5. 完成后读取本轮 `answer_file`;如有 `fragment_file`,支持对话内联时读取并内联片段,确保宿主支持其中的 `data:` 图片。继续对话时沿用相同进程和对话标识。

## 请求协议

每行一个 JSON 对象,必须带 `op`;除 `ping` 外都必须带非空 `conversation`:

```json
{"op":"send","conversation":"<本地对话标识>","text":"推荐100元以内的面膜,只查询。","format":"widget"}
{"op":"resume","conversation":"<本地对话标识>"}
{"op":"cancel","conversation":"<本地对话标识>"}
{"op":"clear","conversation":"<本地对话标识>"}
{"op":"auth-reset","conversation":"<本地对话标识>"}
{"op":"status","conversation":"<本地对话标识>"}
{"op":"ping"}
```

`send`/`resume` 可选项:`format`(`widget` 内联 HTML 片段、`html` 完整页面、`md` Markdown;默认 `widget`,同时适用于商品、购物车、结算和售后)、`max`(商品卡片条数上限)、`all`(渲染全部商品卡片,不用引用过滤)、`timeout`(秒)、`out_dir`(本轮文件的输出目录,覆盖 `--out-dir`);`send` 另有 `wait:false`(只返回 `accepted`,随后必须 `resume`,不把 accepted 当完成)、`allow_repeat`、`force`。

### 按宿主选择展示格式

| 适用场景 | 请求参数 | 商品产物 | 购物车产物 |
| --- | --- | --- | --- |
| 聊天窗口或宿主界面支持内联 HTML | `"format":"widget"`(默认) | `fragment_file` | `cart_fragment_file` |
| 使用浏览器或 WebView 打开独立页面 | `"format":"html"` | `page_file` | `cart_page_file` |
| 宿主支持 Markdown 或只需文本展示 | `"format":"md"` | `html_file`(`.cards.md`) | `cart_file`(`.cart.md`) |

启动参数 `--format widget` / `--format html` / `--format md` 设置默认格式;`send` 或 `resume` 请求中的 `format` 覆盖该默认值。模式作用于全部业务卡片,结算和售后字段见下文;正文始终从 `answer_file` 读取。同一轮没有某类内容时不会返回对应字段。`html` 商品页面展示本轮卡片,不是商城商品详情页;卡片中的商品详情链接指向真实商城页面。内联商品图需要宿主支持 `data:` 图片。

```json
{"op":"send","conversation":"<对话标识>","text":"查看购物车","format":"md"}
```

**自定义产物路径**(宿主展示工具有目录或文件命名要求时使用):`fragment_path`、`page_path`、`answer_path`、`cart_path` 分别指定商品 HTML 片段、商品完整页面、正文 Markdown、购物车产物的**完整文件路径**,也可用等价的 `"out_dirs":{...}` 传入。指定后该产物直接写到目标路径,父目录按需创建,同名文件允许覆盖(默认命名仍只新建,不覆盖历史轮次);未指定的产物继续走默认目录命名。宿主内联展示工具要求固定目录或文件名时,应通过这里指定,而不是移动或改写已产出的文件:

```json
{"op":"send","conversation":"<对话标识>","text":"推荐100元以内的面膜,只查询。","format":"widget",
 "out_dirs":{"fragment_path":"<宿主要求的绝对路径>/mask.html","answer_path":"<宿主要求的绝

Conversación

Pregunta, comparte un consejo o avisa de que no funciona. Ordenado por lo que la gente marcó como útil.

Aún no hay publicaciones. Sé la primera persona en preguntar o compartir.

Lo publicado aquí lo escriben usuarios, no el equipo de PopNx.

Inicia sesión para publicar

Desde GitHub

Estrellas en GitHub
1190
Autor
filtalgo
Licencia
Apache-2.0
Último cambio de código
16 nov 2026
Archivos SKILL.md del repo (con traducciones y plantillas)
1
Temas
agent-skills, ai-agent, claude-skills, ecommerce, filtalgo, filtmall, openclaw, product-search, shopping, skillsmp