dsh-plugin-graphgpt
开发工具 活跃维护

dsh-plugin-graphgpt

BrucePayton/dsh-plugin-graphgpt

插件支持将经过校验的GraphGPT工作流直接作为原生工具集成使用,省去重复对接与配置步骤,让图分析相关任务的调用链路更短,使用体验更流畅。

0
Stars 标星
0
Forks 分支
0
Watchers 关注
0
Open Issues
JavaScript
主要语言
MIT
开源协议
12 KB
仓库大小
3 个月前
最后推送
一键安装扩展 / 插件指令
dsh plugin --profile web add github:BrucePayton/dsh-plugin-graphgpt
git clone https://github.com/BrucePayton/dsh-plugin-graphgpt.git
git clone git@github.com:BrucePayton/dsh-plugin-graphgpt.git
README.md main

dsh-plugin-graphgpt

CI
License: MIT

Expose validated GraphGPT YAML workflows as a native model-facing tool in DeepSeek Harness.

The plugin registers one narrowly scoped tool, graphgpt_workflow, with three actions:

  • validate checks a workflow and returns GraphGPT's JSON diagnostics.
  • inspect returns its normalized graph structure.
  • run executes it with JSON state input.

中文说明

Why this integration

DeepSeek Harness supplies the agent runtime and tool protocol. GraphGPT supplies declarative, versionable LangGraph generation and execution. Together, a Harness agent can invoke reusable graph workflows without receiving arbitrary shell access.

Requirements

  • Node.js ^22.19.0 or >=24
  • DeepSeek Harness / Cordis
  • Python 3.11+
  • graphgpt-builder==0.8.0

Install

Install GraphGPT and this plugin in the environment that runs DeepSeek Harness:

python -m pip install graphgpt-builder==0.8.0
pnpm add dsh-plugin-graphgpt

Until the npm package is published, install directly from GitHub:

pnpm add github:BrucePayton/dsh-plugin-graphgpt#v0.1.0

Add the plugin to your Cordis patch/configuration:

- id: graphgpt-workflow
  name: dsh-plugin-graphgpt
  config:
    root: /absolute/path/to/graphgpt/workflows
    command: [graphgpt]
    timeoutMs: 120000
    maxOutputChars: 50000

The command is an argument array, not a shell string. For an isolated runner it can also be configured as, for example, [uvx, --from, graphgpt-builder==0.8.0, graphgpt].

Copy examples/workflow.yaml and examples/nodes.py into the configured root for a minimal end-to-end example. A Harness agent can then call:

{
  "action": "run",
  "workflow": "workflow.yaml",
  "input": { "message": "DeepSeek Harness" }
}

The structured result contains ok, action, workflow, exitCode, stdout, stderr, and truncated.

Security model

The tool intentionally does not accept commands or CLI flags from the model. Deployment owners configure the executable, root, timeout, and combined output limit. Each requested workflow must:

  • be a relative path beneath the configured root;
  • resolve beneath that root after symlink resolution;
  • be a regular .yaml or .yml file.

The child process uses shell: false, propagates Harness cancellation, and enforces time/output bounds. GraphGPT's own module allowlist remains the execution-policy boundary for Python nodes. Only deploy reviewed workflows and dependencies. See SECURITY.md.

Development

pnpm install
pnpm run check
pnpm test
GRAPHGPT_E2E=1 pnpm test
pnpm run pack:check

The regular suite uses a fake executable to verify exact argv and working-directory behavior. The opt-in end-to-end test runs the included workflow with the real public GraphGPT package.

Compatibility

Component Tested version
DeepSeek Harness tool API @deepseek-ai/dsh-tools@0.1.1-rc.2
Cordis @deepseek-ai/cordis@4.0.1
GraphGPT graphgpt-builder==0.8.0
Node.js 22.19.0

Contributing

Issues and pull requests are welcome. Please read CONTRIBUTING.md. This independent community plugin is not an official DeepSeek product.

License

MIT