Back to home

pengyue-polaron

deepseek-harness-genui

Code-first generative UI for DeepSeek Harness

Stars
4
Language
TypeScript
Created
Aug 14, 2026
Updated
Aug 15, 2026

Introduction

DeepSeek Harness GenUI

English | 简体中文

Node.js License

A task becomes an interface, saved choices return to the task, and later actions wait for approval

DeepSeek Harness GenUI is a runtime interface layer for Agent tasks. When text gets in the way, the Agent can make the current task grow a focused UI—to explain a difficult relationship, collect a complex decision, or operate a connected tool.

Built for the task

Generated from the current context and shown Inline, in Canvas, or on localhost. No separate app to design or deploy.
Choices return to the task

Saved selections, inputs, drafts, and progress remain available for a later Agent turn to read.
Connected to real tools

Calls to declared Harness/MCP tools and declared credential-free public HTTPS endpoints run only after task-scoped approval.

The interface is not the output. It is part of the conversation.

In that conversation, the UI can be Agent output, structured user input, and—after approval—an entry point to real tools.

What Changes

What it createsWhat happens next
App builderA standalone app to keep or shareThe app becomes the product
MCP AppsA prepared UI shipped by a tool authorThe UI stays attached to that tool
DeepSeek Harness GenUIThe interface missing from the current taskSaved state returns to the Agent, and approved tools can continue the work

When an Interface Helps

It does two jobs: make difficult relationships visible, and turn awkward text-based choices into direct manipulation.

Pick calendar slots

Turn candidate availability into a short list of useful 90-minute writing blocks.

The interface saves the three choices to the task. A later calendar action remains separate and asks for approval.
English interface for choosing three writing slots
Explore photosynthesis

Move light, carbon dioxide, temperature, and stomatal controls to find the limiting step.

The diagram changes with the controls, making each variable's effect easier to explore than to describe.
English interactive photosynthesis model with four causal controls
Trace a code path

Ask from the CLI for a source-grounded explanation of a real project flow.

The result is a local explorer with files, functions, branches, and the path selected by the user.
English source-grounded code path explorer returned from a CLI request

Plain questions, rewriting, summaries, and simple lists stay in prose.

Inline & Canvas

The same app can sit inside the answer or open beside the conversation.

InlineCanvas
An interactive code path shown inline in a DeepSeek Harness conversationThe DeepSeek Harness sidebar, conversation, and code-path explorer visible together in the right-side Canvas
A compact control or focused choice.More room without covering the conversation.

Inline, Canvas, full screen, and localhost read and write the same task state. Selections and inputs saved by the interface remain available to later Agent turns.

CLI Example

The terminal profile returns a localhost app. A follow-up can refer to the path already selected in that app.

❯ Explain how a generated app reaches the permission-gated runtime in this
  repository. Build an interactive code-path explorer and return a localhost URL.

  I mapped src/tools.ts → src/artifacts/builder.ts → src/runtime/server.ts
  → src/artifacts/registry.ts.

  http://127.0.0.1:<port>/genui/app/<task-app>

❯ Where does the path I selected stop?

  It reaches the permission check in src/runtime/server.ts, then stops before
  the connected tool runs because access has not been allowed.

How It Works

  1. The Agent keeps the explanation in the conversation and creates one focused interface when interaction adds value.
  2. It writes React + TypeScript and declares only the exact connected Harness/MCP/Skill tools or credential-free public HTTPS prefixes it needs; the plugin then builds and checks the interface.
  3. The interface saves semantic values—selections, form answers, drafts, and progress—to the task. When the user follows up, the Agent can read those values instead of asking them to repeat the result.
  4. Later edits update the same app without replacing a working version with a failed one.

Before the first use of each declared capability, Harness asks for task-scoped approval; undeclared calls are blocked. In Web, access can be reviewed or revoked from the app card. MCP credentials never enter generated code, while direct API requests are limited to credential-free public HTTPS.

Design MD

Visual direction lives in DESIGN.md. Four profiles are included:

ProfileBest fit
editorial-workbenchReading, planning, forms, and content-heavy work
ledger-gridComparisons, schedules, evidence, and shortlists
field-atlasScientific, causal, and spatial explanations
kinetic-signalChanging data, connected tools, and user-triggered actions

Open Settings → Plugins → Plugin configuration to use automatic selection, choose a profile, import a DESIGN.md, or export one as a starting point. The choice applies to new apps without adding design controls to them.

Install

Use Node.js ^22.19.0 || >=24. This release is tested with DeepSeek Harness 0.1.0-rc.6.

dsh plugin --profile web add dsh-plugin-genui
dsh plugin --profile web exec playwright install chromium
dsh --profile web

The Web profile supports Inline, Canvas, full screen, and localhost links. For a terminal profile, replace web with tui; TUI returns localhost links and does not embed Canvas. Connect MCP servers to the same profile as usual.

Safety

Generated code runs in a sandbox. Tool calls and public HTTPS routes must be declared, scoped, and approved. Temporary links and grants expire after 7 days; saved task state expires 7 days after its last update. Return to the app card in the task to review or remove access.

The plugin uses DeepSeek Harness + Cordis, React 18 + TypeScript, esbuild, Playwright, and Vitest.

Development

Building from source requires pnpm 11.

pnpm install
pnpm run typecheck
pnpm test
pnpm run package:plugin

Acceptance scenarios · Screenshot guide · Contributing · MIT