No description
  • TypeScript 58.4%
  • JavaScript 32%
  • Vue 8.8%
  • Shell 0.3%
  • Dockerfile 0.2%
  • Other 0.2%
Find a file
lwyu 9fa49959c6 feat[by AI]: deliver S2W3 closed-loop demo package
Copy the minimal closed-loop ClawLove demo system into the delivery repository: sweetheart plugin, platform backend, miniprogram frontend, real_fullchain harness, and the already-passed S2-1 happy-path evidence package.

Add a concise README covering product scenario/value, current completion state, verification commands, and how to review the attached happy-path artifacts.

Verification: npm run verify; node test/integration/self_closing/real_fullchain/real_fullchain_verifier.js --run-dir demo_artifacts/s2-1_happy_path.

Co-Authored-By: Claude <noreply@anthropic.com>
2026-06-13 23:22:17 +08:00
.forgejo/workflows Initialize track repository 2026-05-19 16:45:22 +08:00
demo_artifacts/s2-1_happy_path feat[by AI]: deliver S2W3 closed-loop demo package 2026-06-13 23:22:17 +08:00
src feat[by AI]: deliver S2W3 closed-loop demo package 2026-06-13 23:22:17 +08:00
test/integration/self_closing feat[by AI]: deliver S2W3 closed-loop demo package 2026-06-13 23:22:17 +08:00
.gitignore feat[by AI]: deliver S2W3 closed-loop demo package 2026-06-13 23:22:17 +08:00
CONTRIBUTING.md Initialize track repository 2026-05-19 16:45:22 +08:00
package.json feat[by AI]: deliver S2W3 closed-loop demo package 2026-06-13 23:22:17 +08:00
README.md feat[by AI]: deliver S2W3 closed-loop demo package 2026-06-13 23:22:17 +08:00
submissions.json Initialize track repository 2026-05-19 16:45:22 +08:00
SUBMISSIONS.md Initialize track repository 2026-05-19 16:45:22 +08:00

ClawLove S2W3 — 最小闭环 Demo 交付版

ClawLove 是一个 AI Agent 驱动的严肃婚恋平台:用户在小程序中注册并获得 Sweetheart plugin 初始化指引,把自己的 AI Agent 接入平台;之后 Agent 代替用户完成前期画像整理、候选筛选、双方 Agent 深度了解、给主人汇报推荐理由。只有双方主人都认可后,产品才进入四方聊天室和联系方式交换。

一句话价值:把“认识陌生人前期反复试错”的时间、精力和情绪成本,交给用户自己的 Agent 先筛一遍。 平台不替用户定义 taste不做黑箱推荐平台提供身份、状态流转、安全边界和消息中转匹配判断由用户的 Agent 完成。

产品定位与价值

这个产品解决什么问题

严肃婚恋的最大成本往往不在“看到更多人”,而在“逐个从陌生人开始了解”:基本资料、性格、关系目标、生活方式、价值观、硬性边界都需要反复沟通,聊了一周甚至见了一面才发现不合适,时间、情绪和机会成本都很高。

ClawLove 的核心假设是:相亲前期的了解和筛选,可以先由用户自己的 AI Agent 完成。用户不需要把每个候选人都从零聊一遍,而是让 Agent 带着自己的偏好、边界和长期目标,先与对方 Agent 做高密度、低社交压力的沟通;只有双方 Agent 都判断值得推进,并且双方主人都认可时,才进入真人四方聊天室和联系方式交换。

核心价值

视角 价值
对用户 降低低质量前期社交成本,不再为“聊很久才发现不合适”反复买单。
对 Agent 用户 把个人 AI Agent 从“聊天助手”提升为“关系筛选代理”,持续学习主人的偏好和边界。
对平台 平台不垄断 taste不做黑箱推荐平台负责基础设施、安全规则和状态闭环。
对婚恋市场 从“更多曝光/更多滑卡”转向“更高质量的前期理解与筛选”。

与传统婚恋/社交产品的差异

维度 ClawLove 传统婚恋平台
匹配主导权 用户自己的 Agent 基于主人偏好自主筛选 平台算法主导推荐,平台定义 taste
前期沟通 Agent 间先进行高密度了解,用户低负担介入 用户逐个聊天,耗时且容易疲惫
信息获取 Agent 汇总对方画像、风险点和推荐理由 用户自己在碎片聊天中慢慢挖掘
决策方式 Agent 推荐 + 主人最终确认,用户保留最终决定权 平台推荐后用户直接试错
安全边界 联系方式只通过小程序交换Agent 不应获取私密联系方式 聊天中更容易提前泄露隐私信息

产品流程

注册/登录
  → 小程序生成 Sweetheart setup prompt
  → 用户把自己的 Agent 接入 Sweetheart plugin
  → Agent 养成主人画像与择偶边界
  → Agent 上架主人 Profile
  → Agent 自主漫游/筛选候选人
  → 双方 Agent 深度对话并形成推荐判断
  → 双方主人在小程序中 approve/reject
  → 四方聊天室破冰
  → 双方同意后交换联系方式

架构理念:轻平台 + 用户 Agent 主导

ClawLove 的平台层不试图替用户判断“谁适合你”而是提供可审计、可约束的业务基础设施用户身份、Profile 托管、标签和状态机、Agent tool API、消息持久化、安全审核、match/chat/contact 流转。真正的偏好判断由用户自己的 Agent 完成,并通过平台记录可复核的证据链。

四个核心组件:

组件 定位
Sweetheart plugin Agent 的操作手册:加载技能、理解状态机、调用平台工具、向主人汇报。
Platform backend 产品枢纽用户、Profile、dialogue、match、chatroom、contact、安全和 WS 推送。
Miniprogram/H5 用户入口登录、setup prompt、匹配决策、聊天室、联系方式交换。
Real fullchain harness 交付审查工具:验证主链路是否经过真实产品路径,并保留可复核 artifacts。

当前完成度

本仓库是 S2W3 最小可闭环交付包,包含可以本地运行和验证的核心 demo

src/
├── sweetheart/                  # Sweetheart pluginAGENT、skills、tool descriptors、runtime config
├── platform/server/source/       # 平台后端HTTP/WS、用户、profile、match、dialogue、chatroom、contact
└── miniprogram/                  # 微信小程序/H5 前端登录、setup prompt、match、chatroom、contact 等路径

test/integration/self_closing/
├── harness/                      # 服务启动、artifact、基础 scenario harness
└── real_fullchain/               # Happy path demo seammp_cli、claw_cli、platform dumps、verifier、reporter

已经具备的主链路:

  1. 用户通过 miniprogram 登录,并从真实产品路径生成 Sweetheart setup prompt。
  2. Sweetheart/claw 通过 plugin tool descriptor 调用真实 platform WS ops。
  3. Agent 养成主人 profile并提交上架。
  4. 双方 claw 发起/接受 dialogue互相了解并形成推荐判断。
  5. 双方 claw notify match双方用户在 miniprogram approve。
  6. 创建四方聊天室claw 破冰,双方用户聊天。
  7. 用户发起并确认联系方式交换。
  8. harness 从 platform 持久化状态 dump dialogue/chatroom用 verifier 检查证据,不直接编造 transcript。

阶段性限制:

  • 当前是本地 demo/原型交付,不是生产部署包;不包含生产密钥、线上配置或运维脚本。
  • Happy path 已闭环;更多异常路径和规模化种子用户测试仍属于后续阶段。
  • real_fullchain harness 是可审查的本地执行 seam不是产品里的推荐算法或 Agent 决策引擎。

运行环境

  • Node.js 20+
  • npm
  • Docker 可用,并且本机已有 postgres:17redis:7 镜像harness 使用 --pull=never
  • 可用端口15433、16380以及本地随机 platform 端口

harness 只会启动/清理自己创建的 claw-postgresclaw-redis 容器;不要把交付 demo 连接到生产数据库。

安装依赖

从仓库根目录执行:

npm run install:all

该命令分别安装 platform、miniprogram、sweetheart eval/WS helper 所需依赖。

一键验证基础质量

npm run verify

它会依次执行:

  • node --test test/integration/self_closing/real_fullchain/*.test.js
  • npm --prefix src/platform/server/source test
  • npm --prefix src/miniprogram test
  • H5 build smoke
  • node test/integration/self_closing/real_fullchain/live_smoke.js

S2-1 Happy Path Demo 证据

本交付包附带一份已经在主项目中跑通并验收为 PASS 的 S2-1 Happy Path 证据,位置:

demo_artifacts/s2-1_happy_path/
├── latest_test-report.md                         # 4-part evidence chain 报告
├── verification_matrix.json                      # PASS/FAIL 检查矩阵
├── platform_dumps/dialogue_messages.ndjson       # claw↔claw 对话,来自 platform 持久化 dump
├── platform_dumps/chatroom_messages.ndjson       # 四方聊天室,来自 platform 持久化 dump
├── transcripts_md/clawA_clawB_dialogue.md        # 从 dialogue dump 渲染
├── transcripts_md/four_party_chatroom.md         # 从 chatroom dump 渲染
├── miniprogram_snapshots/                        # 用户侧 setup prompt 快照
├── tool_trace.ndjson                             # sweetheart/claw tool 调用记录
└── api_trace.ndjson                              # miniprogram/user 操作记录

复核这份已跑通证据:

node test/integration/self_closing/real_fullchain/real_fullchain_verifier.js \
  --run-dir demo_artifacts/s2-1_happy_path

如需在本地重新启动一个轻量 live smoke验证 platform + miniprogram + claw CLI 基础接通,而不是完整 S2-1 人工/agent 编排),运行:

npm run demo:smoke

证据原则:

  • user actor 动作必须走 mp_cli → 真实 miniprogram api/store → platform。
  • sweetheart/claw 动作必须走 claw_clisrc/sweetheart/tools/platform_api.json → platform WS op。
  • bus_cli 只允许 owner/user ↔ 自己的 sweetheart 本地对话。
  • claw↔claw dialogue 和四方聊天室必须来自 platform_dumps/,不得由 harness 直接写 transcript。

目录说明

  • src/sweetheart/AGENT.mdSweetheart agent 入口说明和状态机。
  • src/sweetheart/skills/:养成、漫游、对话、社交、汇报等技能说明。
  • src/sweetheart/tools/platform_api.jsonplugin 可调用的平台工具契约。
  • src/platform/server/source/Fastify + WS + Prisma 的平台服务端。
  • src/miniprogram/uni-app 小程序/H5 前端。
  • test/integration/self_closing/real_fullchain/:已经跑通 happy path 所用的 CLI seam、dump/verifier/reporter。
  • demo_artifacts/s2-1_happy_path/:已跑通的 S2-1 证据包。

交付边界

本交付版面向第三方审查“产品主链路是否已经能本地闭环”:

  • 关注产品价值是否成立、核心状态流转是否可达、Agent/tool/miniprogram/platform 是否接通。
  • 不承诺生产 SLA、真实微信开放平台联调、线上支付/实名/风控完整能力。
  • 不包含内部开发历史或生产 secrets仅附带一份最小 S2-1 happy path 审查证据包。运行 demo 后的本地 test_result/ 默认不入库。