Skip to content

v1.1.0

Latest

Choose a tag to compare

@henrybit henrybit released this 25 Oct 01:17

中文

Feature-1.1.0(修复dmg包无证书签名导致下载后显示损坏,无法使用问题)

版本:1.1.0
相对:1.0.0 的小版本功能更新
说明:只记录本版新增与行为变化,完整基线见 Feature-1.0.0.md。


本版主题

把正在运行的桌面客户端开放给外部智能体:其他 Agent 宿主通过可安装 Skill 和本机 MCP,操作 本应用里已经连上的会话,而不是自带数据库驱动。密码和连接串不离开本机。


新增能力

本机 MCP 服务

  • 应用启动后在 127.0.0.1 打开网关,令牌写到 ~/.hidatalinker/agent/endpoint.json(权限 600)。
  • 默认关闭。关闭后调用返回 MCP service is turned off in HiDataLinker settings;端口保持监听,再次打开即可恢复,不必重启应用。
  • 成功调用记入环形审计(最近 40 条)。

设置与活动条开关

  • 设置对话框顶部增加 MCP 服务 区块:说明、本机端口、苹果风格 Switch。
  • 底部活动条使用同一开关和同一状态;开启后轨道与文案为绿色「已开启」,关闭为灰色「已关闭」。
  • 浏览器预览里开关禁用,提示在桌面版操作。

只读工具目录

外部智能体可调用:

list_connections · connect · list_databases · list_tables · list_views · list_indexes · list_triggers · list_routines · get_columns · get_ddl · preview_table · query

约束:

  • 连接列表只给 id、名称、引擎、主机、端口、是否已连接,不含密码。
  • connect 只使用已保存密码,不接受密码参数。
  • query / preview_table 只允许单条只读语句(SELECT / WITH / EXPLAIN / SHOW / DESCRIBE 等);写入、导出文件、FOR UPDATE 等会被拒绝。
  • 预览行数上限 1,000。

Skill 与 MCP 进程

  • 仓库内 skills/hidatalinker-db/:触发条件、工具说明、安全约束、MCP 启动脚本。
  • 独立二进制 agent-mcp 走 stdio,把工具调用转到本机网关;桌面主程序同时支持 --agent-mcp。
  • Cargo.toml 指定 default-run = "app",避免与 agent-mcp 并存时 tauri dev 找不到主程序。

会话联动

智能体执行 connect 后,界面对象树通过 agent-session-changed 刷新,人与 Agent 看到同一组会话。


本版未纳入

写操作、Dump、迁移、连接增删改仍不走 MCP。后续若增加 mutate,需要应用内审批。

English

Feature-1.1.0 (Fixed the issue where the DMG package lacked a certificate signature, causing it to show as damaged and unusable after download)

Version: 1.1.0
Relation: Minor functional update relative to 1.0.0
Note: Only records new additions and behavioral changes for this version; see Feature-1.0.0.md for the complete baseline.


Version Theme

Exposing the running desktop client to external agents: Other Agent hosts operate on the sessions already connected in this application via installable Skills and local MCP, rather than bringing their own database drivers. Passwords and connection strings never leave the local machine.


New Capabilities

Local MCP Service

  • Opens a gateway on 127.0.0.1 after application startup, writing the token to ~/.hidatalinker/agent/endpoint.json (with 600 permissions).
  • Disabled by default. When disabled, calls return MCP service is turned off in HiDataLinker settings; the port remains listening, and turning it back on recovers functionality without restarting the application.
  • Successful calls are recorded in a ring buffer audit log (last 40 entries).

Settings and Status Bar Switch

  • Added an MCP Service section at the top of the settings dialog, containing a description, local port, and an Apple-style switch.
  • The bottom status bar uses the same switch and status; when enabled, the track and text show green as "Enabled", and when disabled, grey as "Disabled".
  • The switch is disabled in browser previews, with a prompt to operate in the desktop version.

Read-Only Tool Directory

External agents can call:

list_connections · connect · list_databases · list_tables · list_views · list_indexes · list_triggers · list_routines · get_columns · get_ddl · preview_table · query

Constraints:

  • The connection list provides only ID, name, engine, host, port, and connection status, excluding passwords.
  • connect uses only saved passwords and does not accept password parameters.
  • query / preview_table allow only single read-only statements (SELECT / WITH / EXPLAIN / SHOW / DESCRIBE, etc.); writes, file exports, FOR UPDATE, etc., will be rejected.
  • Maximum preview row limit is 1,000.

Skill and MCP Process

  • skills/hidatalinker-db/ in the repository: trigger conditions, tool descriptions, security constraints, and MCP startup scripts.
  • The standalone binary agent-mcp operates via stdio, forwarding tool calls to the local gateway; the main desktop application also supports --agent-mcp.
  • Cargo.toml specifies default-run = "app" to prevent tauri dev from failing to find the main program when coexisting with agent-mcp.

Session Synchronization

After the agent executes connect, the UI object tree refreshes via agent-session-changed, allowing humans and agents to view the same set of sessions.


Excluded from This Version

Write operations, dumps, migrations, and adding/deleting/modifying connections still do not go through MCP. If mutate is added in the future, in-app approval will be required.