fix(consult): read the live skill tree instead of a hash-pinned snapshot
Independent Staging Quality Gate / validate (push) Successful in 9m18s
Independent Staging Quality Gate / publish (push) Has been cancelled

Manual SKILL.md updates were blocked by registry sha256 and a byte-equal versions/ gate. Consult now loads the operator-maintained tree; rectification and personal-report stay hashed.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Jesse_Chen
2026-08-19 10:25:55 +08:00
co-authored by Cursor
parent 233c728176
commit d35828e76d
14 changed files with 315 additions and 109 deletions
+4 -4
View File
@@ -8,7 +8,7 @@ Jyotisha 是 `yinduzhanxing` 的聊天式消费者 Web 前端。它使用 Next.j
Browser
-> Next.js /api/consult
-> Mastra agent
-> 按问题语义加载 jyotish-vedic-astrology Skill
-> 绑定 live jyotish-vedic-astrology Skill 方法摘录
-> consultation tool
-> Python /api/consultation_workflow
```
@@ -51,7 +51,7 @@ MODEL_PROVIDER_CONFIG_ENCRYPTION_KEY=<strict-base64-32-byte-key>
## Skill 如何触发
不需要输入 `/skill` 命令。Mastra 会先把 Skill 的 `name``description` 提供给模型;当用户问题与印度占星、解盘、推运、Dasha、Transit、Nakshatra、Yoga 等语义匹配时,Agent 会按需加载完整 Skill,再调用计算工具
不需要输入 `/skill` 命令。解盘 Agent 在启动时从 live skill 树绑定运行时方法摘录,再调用计算工具;模型没有「先激活 skill」这一步
例如,先在“个人资料”中保存出生信息,然后直接发送:
@@ -63,7 +63,7 @@ MODEL_PROVIDER_CONFIG_ENCRYPTION_KEY=<strict-base64-32-byte-key>
```text
用户问题
-> Mastra 识别并加载 jyotish-vedic-astrology
-> 已绑定的 live jyotish-vedic-astrology 方法
-> Agent 依据 Skill 选择工作流
-> run-jyotish-consultation
-> Python consultation_workflow
@@ -72,7 +72,7 @@ MODEL_PROVIDER_CONFIG_ENCRYPTION_KEY=<strict-base64-32-byte-key>
必须配置可用的模型 Key 才会进入这条链路。没有配置模型时,`/api/models` 返回 `503`,聊天框会停止发送;`/api/consult` 也会在预扣点数前拒绝未知或不可用模型。成功咨询始终由 Mastra Agent 生成流式回答。
仓库根目录的主 `SKILL.md` 通过 `skills/jyotish-vedic-astrology/` 这个 Mastra 兼容目录加载。该目录名必须与 Skill frontmatter 中的 `name` 一致。生产部署时需确保 `SKILL.md``references/``scripts/``assets/` 一起存在;如果目录结构不同,请设置 `JYOTISH_SKILL_PATH`
仓库根目录的主 `SKILL.md` 通过 `skills/jyotish-vedic-astrology/` 加载。该目录名必须与 Skill frontmatter 中的 `name` 一致。咨询读这份 live 目录,不校验 sha256、不钉版本;更新 skill 后重启 web 即可。部署时需确保 `SKILL.md``references/``scripts/``assets/` 一起存在;如果目录结构不同,请设置 `JYOTISH_SKILL_PATH`生时纠正和个人报告仍使用哈希锁定的版本包。
## 本地启动