Contextual Next Step Chips Generator (sliderule/next-step-chips.ts)

WhyBuddy · client/src/pages/sliderule/next-step-chips.ts · typescript · MIT
chat, ui, ai, automation, lang:typescript

Generates contextual follow-up suggestion chips from model todo states without extra LLM calls. Reuse in chat interfaces to provide accurate task-driven prompts.

// Source: https://github.com/xiaojilele-glitch/WhyBuddy | License: MIT | Copyright 2026
// Provided via justclaw.it.com; keep this notice with the code.
/**
 * 后续建议 chips —— 「这一轮做完了,下一步能干嘛」。
 *
 * ## 病(2026-09-14,用户对照 Manus 截图第 3 件)
 *
 * Manus 跑完给两条**针对刚做出来的东西**的下一步,点一下就接着派工:
 *
 *     为工单队列添加多维度筛选功能,支持按优先级、状态和分配人进行快速过滤。
 *     在对话线程的回复框中集成富文本编辑器,支持文本格式化、插入图片和添加附件。
 *
 * 我们这边输入条那排提示返回的是**写死的四条**——
 * 「路线对比一下」「澄清权限边界」「分析安全风险」「生成可行性报告」——
 * 跟这一轮做了什么毫无关系。所以每张截图里都是同样那两个。
 *
 * ## 数据从哪来:模型自己写的待办,不是再问一次模型
 *
 * `controlTodo` 是模型用 `todo_write` 自己列的活儿清单,本来就在 state 里。
 * 真机那一趟存的是:
 *
 *     in_progress  补丁前端:中文文案、极简样式、侧栏筛选 + 宽列表
 *     pending      核对认证与用户隔离的待办 API / SQLite
 *     pending      project_exec 跑 check/build/test 并修复
 *     pending      保留运行后申请 project_verify 并读取验证结果
 *
 * 针对这个工程、模型自己

... (truncated -- full source via MCP)

See the full source, get the GitHub permalink, and search for more like it.

Get a free API key