Skip to content

fix(proxy): align dsh config and runtime compatibility - #1241

Open
Jane-o-O-o-O wants to merge 2 commits into
TencentCloud:feat/server_teamfrom
Jane-o-O-o-O:fix/dsh-config-compatibility
Open

fix(proxy): align dsh config and runtime compatibility#1241
Jane-o-O-o-O wants to merge 2 commits into
TencentCloud:feat/server_teamfrom
Jane-o-O-o-O:fix/dsh-config-compatibility

Conversation

@Jane-o-O-o-O

@Jane-o-O-o-O Jane-o-O-o-O commented Sep 2, 2026

Copy link
Copy Markdown

Description | 描述

完善 dsh 与 TencentDB Agent Memory 的配置和运行时兼容性:

  • 使用 dsh 当前的 agent-default-model namespace,并对 settings.yaml 做受管字段增量合并,保留用户配置。
  • 按最新版 dsh version: 1 / refs schema 写入凭据,安全迁移旧版扁平凭据并保留 records、注释和其他 key。
  • 同时过滤句点和冒号形式的 runtime-context,支持从 text/file 多模态 content 中提取真实用户文本。
  • 将 dsh 的表单能力与记忆能力解耦:no-form/headless/minimal profile 会优先恢复 session binding、使用 header 身份,或在身份唯一时自动选择 Agent;身份解析成功后继续启用注入、L0、mem 命令和 Skill 抽取。
  • 增加经过业务用户鉴权的 dsh Files API 透明代理,支持上传、列表、查询、删除以及带 /v1/不带 /v1 两种 baseURL。
  • 使用 Node 内置 Zstandard 逐帧解压 dsh session,支持 dsh 的 concatenated frames,移除外部 zstd/unzstd 依赖和 64 MiB 子进程 buffer 限制。

Related Issue | 关联 Issue

N/A

Change Type | 修改类型

  • Bug fix | Bug 修复
  • New feature | 新功能
  • Documentation update | 文档更新
  • Code optimization | 代码优化

Self-test Checklist | 自测清单

  • Verified locally | 本地验证通过
  • Existing user config and credentials are preserved
  • dsh current credentials parser accepts the generated document
  • No local contributor report is included in the PR

验证命令:

node --test agents/skills/setup-proxy/merge-dsh-config.test.mjs
node --experimental-strip-types --test agents/asset-import.test.ts
cd MemoryProxy && npm test -- --run
bash -n agents/setup-proxy.sh
bash -n agents/skills/setup-proxy/setup-proxy.sh

结果:

  • 配置合并:7/7
  • Zstandard concatenated-frame 解压:1/1
  • MemoryProxy runtime/Files/no-form 回归测试:20/20
  • 两份 Bash 脚本语法检查通过
  • 使用当前 dsh parseCredentialsDocument 对合并结果做了额外解析验证

Additional Notes | 其他说明

  • 继续保留原有 .bak.<timestamp> 备份机制。
  • PROXY_USER_KEY 通过子进程环境传递,不进入 Node 命令行参数。
  • 未知凭据版本、重复字段和不支持安全修改的行内 YAML 会明确失败,并保持原文件不变。
  • 完整 npm run typecheck 仍受目标分支已有类型错误阻塞(SessionInitResult.resetFlowSessionInfo 收窄、workspace alias 等);本次新增文件没有出现在剩余错误中。

Signed-off-by: Jin Zhangzheng <179437561+Jane-o-O-o-O@users.noreply.github.com>
@Jane-o-O-o-O
Jane-o-O-o-O force-pushed the fix/dsh-config-compatibility branch from f781941 to f37bac5 Compare September 2, 2026 03:47
@Jane-o-O-o-O Jane-o-O-o-O changed the title fix(proxy): preserve existing dsh config and default model fix(proxy): align dsh config and runtime compatibility Sep 2, 2026
Signed-off-by: Jin Zhangzheng <179437561+Jane-o-O-o-O@users.noreply.github.com>
@Jane-o-O-o-O
Jane-o-O-o-O force-pushed the fix/dsh-config-compatibility branch from 463eda4 to d50b57a Compare September 2, 2026 04:50
@Maxwell-Code07

Copy link
Copy Markdown
Collaborator

Thank you so much for your attention and contribution! We will arrange an internal review for this PR shortly, and all feedback will be shared right here in the discussion.

@Jane-o-O-o-O

Copy link
Copy Markdown
Author

Thank you for your reply. I believe this update is highly valuable and can help more users of TencentDB-Agent-Memory and deepseek-harness optimize their overall user experience and get more out of these tools.

@Maxwell-Code07

Copy link
Copy Markdown
Collaborator

Thank you so much for your attention and contribution! We will arrange an internal review for this PR shortly, and all feedback will be shared right here in the discussion.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants