huashu-design
alchaincyf
Huashu Design 3.0 · 在 agent 里打一句话,拿回能交付的设计:网页 / App 原型 / 可编辑 PPTX / 动画 / 信息图 · 六个候选挑三个方向 · 84 种带样张的风格库 · 越用越懂你的外观账本与设计体检 · HTML-native design skill for Claude Code, Codex, Cursor & any agent
PROJECT TOPICS
INSTALL REFERENCE
dsh plugin --profile web add github:BrainZombie/dsh-media-rescue
该命令指向仓库当前默认分支;尚无绑定当前 commit 的完整验证结果。
PROJECT README
DeepSeek Harness(dsh)插件:修好「图片无法预览」。
回复正文里的 markdown 图片走 GET /api/file?path=<绝对路径>,文件找不到就 404,卡片回落成 image.failed(文案「图片无法预览」,前面是 alt)。最常见的成因不是内容被拦,而是路径本身不存在:图生成了,只是落在别处,正文却按约定拼了一个工作区路径。
/api/file(kind: 'prefix',DSH 路由 exact → longest prefix → fallback),只有在内置处理器返回 404 时才介入。tools/post-execute 里,任何工具结果出现真实存在的媒体路径时,追加一份可直接粘贴的 markdown 图片语法;另外注册 GET /ws/<绝对路径> 直贴路由(纯 http URL,不会被转义吃掉分隔符)。找到之后:目标在工作区内就把真实文件拷到正文引用的位置(只创建、不覆盖),否则把请求改写到真实路径——状态码、缓存、Content-Type、字节上限全部沿用内置实现。
三种来源:工具结果索引(运行时)→ roots 目录(显式配置)→ 历史会话索引(经 sessionQuery,让装上插件之前就写坏的会话也能恢复)。
# 直接从 GitHub 装
dsh plugin add --profile <你的 profile> git+https://github.com/BrainZombie/dsh-media-rescue.git
# 或者从本地目录装
dsh plugin add --profile <你的 profile> /path/to/dsh-media-rescue
或:插件 → 添加插件,选这个目录。
最小配置(cordis.patch.yml 或插件配置):
roots:
- 'D:\your\generator\output'
materialize: workspace
roots 填图片实际落盘的目录;不填也会靠工具结果索引和历史会话索引工作。
media_rescue:
status —— 路由是否接管、/ws 是否可用、索引规模、最近事件;resolve + path —— 只查不写,看一条路径会解析到哪个真实文件、命中哪一层;probe + path —— 端到端跑一遍 404 → 救援 → 回写,并额外测一次 /ws。/api/file 的插件(如 dsh-file-path-repair)互斥:重复路由注册会抛错。详细机制、配置表与实测记录见 docs/DETAIL.md。
Repairs broken markdown image paths in DeepSeek Harness. The plugin shadows GET /api/file (longest-prefix route, only acting on 404) and resolves the missing name through five tiers — exact, frame-counter-insensitive, directory-glued alias, stem prefix, and Markdown-escape restoration — probing every candidate through the composed filesystem and refusing to guess when ambiguous. It also prevents the failure at the source by appending ready-to-paste Markdown to tool results, and exposes GET /ws/<absolute path> for an escape-proof URL form.
MIT licensed.
CLASSIFICATION EVIDENCE
系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。当前命中: image。