dsh-image-studio: DSH Multi-Provider Image Generation Workbench

Preface

When building agents or having daily conversations in DeepSeek Harness (DSH), generating images is a frequent requirement: some teams use Agnes, others use OpenAI GPT Image or xAI Grok, and some utilize self-built or relayed OpenAI-compatible Images APIs. If keys and parameters are scattered across scripts, environment variables, and different clients, switching providers becomes costly, and it is difficult to maintain a stable flow of “Generate — Edit — Continue Chatting” within a conversation.

Here we introduce the community plugin dsh-image-studio (Image Generation Workbench): it provides a primary entry point in the DSH sidebar and stores keys and default parameters separately for four types of providers: Agnes, OpenAI GPT Image, Grok Image, and OpenAI-compatible services. It also supports triggering the image_studio_generate tool via /image syntax within conversations, keeping the results in the current session. Maintainer: david-zdw. Category: Model Inference. Current repository version: v0.8.3 (MIT License). Plugin Directory Page: skillhub.cn/plugins/david-zdw/dsh-image-studio, Source Code: github.com/david-zdw/dsh-image-studio.

What is this

dsh-image-studio is a multi-provider image generation plugin for DSH: open the full panel via the “Image Workbench” in the sidebar, or invoke it using the /image shorthand in messages. Each of the four providers uses independent keys with no fallback or overwriting between them; keys are saved locally in $DSH_HOME/image-studio/ by default and are not written into DSH model credentials or other plugin configurations.

Functionally, it covers text-to-image, as well as image-to-image with up to 5 reference images (PNG / JPEG / WebP). On the Agnes side, it reuses the Agnes request contract from open-storyboard-canvas and supplements the mappings for OpenAI Images and Grok Imagine.

Supported Providers

id Panel Name Default Base URL Default Model Image-to-Image
agnes Agnes https://apihub.agnes-ai.cn agnes-image-2.5-flash extra_body.image
openai OpenAI GPT Image https://api.openai.com gpt-image-1.5 multipart /v1/images/edits (DALL·E 3 does not support reference images)
grok Grok Image https://api.x.ai grok-imagine-image-2.0 JSON /v1/images/edits, images[]
openai-compatible OpenAI Compatible https://api.example.com gpt-image-1 multipart /v1/images/edits

The “OpenAI Compatible” option can connect to any relay service following the POST /images/generations style; model name, size, and endpoint path can be modified in the panel. For image-to-image, replace generations in the generation path with edits (default /v1/images/edits); the Base URL remains unchanged.

Core Functions

Located at the same level as “Plugins,” “Automation Tasks,” and “Context Insights,” clicking it opens the full workbench: provider tabs, model/size/ratio/quality settings, prompts, reference images, and generation via Ctrl/⌘+Enter. The generation process features a matrix dot animation in the center of the main canvas. Results support fullscreen viewing, deletion, downloading originals, copying paths, and retain up to 80 recent history entries.

For GPT Image, custom 2.5 model sizes are set in four tiers: 1K/2K/3K/4K. After selecting a ratio, pixels are calculated according to official rules (width and height are multiples of 16, ratio 1:3–3:1). Quality supports xhigh / max. Image and history URLs use the absolute origin of the main Web service to avoid 401 errors in multi-port previews. The default generation timeout is 300 seconds, with a separate 120 second budget for URL return; the panel displays the elapsed waiting time.

In-Chat /image

/image is not a built-in DSH slash command, but a calling syntax within a normal message; once sent, the model calls image_studio_generate, and the image is inlined in the chat via Markdown. The tool card can open the local file or the original image. The input box clears as it would for a normal message, allowing the conversation to continue.

In the same conversation: the first message is for text-to-image, and subsequent messages default to modifying the previous image; add --new to force a fresh text-to-image generation. Provider, size, and ratio can be written at the beginning in any order; the prompt starts from the first unrecognized word encountered.

Examples:

/image gpt 2k 16:9 an orange cat wearing a space helmet
/image change the background to a neon street on a rainy night, keep the orange cat and helmet
/image --new agnes 1k 1:1 a cat sunbathing by a window
/image --provider openai --size 1024x1024 --quality high an orange cat wearing a space helmet

--provider supports agnes, openai (alias gpt), grok, openai-compatible (aliases compatible / custom). If --provider is not written, the configured defaultProvider (default agnes) is used.

Model Sniffing & Theming

After saving a key in “Image Settings,” you can click “Sniff Models” to request /v1/models using the current provider’s key; checked image models will enter the main panel dropdown (marked with “Image”). The interface uses DSH tokens such as --dsw-alias-* and --dsh-frame-top-clearance to remain consistent with the host theme.

Clear prompts are provided for cases such as no key configured, 401/402/429 errors, timeouts, network errors, or missing image data.

Installation and Activation

The official README recommends local link installation: first obtain the repository directory, then link it to DSH under the corresponding profile.

git clone https://github.com/david-zdw/dsh-image-studio.git

# Install this local package in your DSH profile (replace path with your clone directory)
dsh plugin --profile desktop add link:D:/path/to/dsh-image-studio
# macOS / Linux:
# dsh plugin --profile desktop add link:/path/to/dsh-image-studio

Alternatively, select install_bundle in the DSH plugin manager, pointing the target directory to the repository directory mentioned above.

After installation, “Image Workbench” appears in the sidebar. If the window was open before installation, you need to reload the window or restart DSH. To uninstall:

dsh plugin --profile desktop remove dsh-image-studio

After updating, the top bar displays IMAGE WORKBENCH · v0.8.3 to confirm the version. For link installations, you need to git pull or git checkout v0.8.3 inside the repository and then restart DSH; dsh plugin --profile desktop update dsh-image-studio will not perform the git pull for you. Keys, configuration, and history are stored in $DSH_HOME/image-studio/, which will not be cleared when updating or reinstalling the plugin.

Configuration and Data Location

$DSH_HOME defaults to ~/.dsh (Windows: C:\Users\<you>\.dsh).

Path Contents
image-studio/credentials.json Keys for each provider: keys.agnes / openai / grok / openai-compatible
image-studio/config.json defaultProvider and baseUrl, endpointPath, model, size, ratio, quality for each provider
image-studio/history.json Metadata for the last 80 generations
image-studio/outputs/ Generated PNG/JPEG/WebP/GIF files

Key Priority: Key for that provider in credentials.json > Provider Environment Variable > None. Environment variables include DSH_IMAGE_STUDIO_AGNES_API_KEY (compatible with legacy DSH_IMAGE_STUDIO_API_KEY), DSH_IMAGE_STUDIO_OPENAI_API_KEY, DSH_IMAGE_STUDIO_GROK_API_KEY, DSH_IMAGE_STUDIO_OPENAI_COMPATIBLE_API_KEY.

Panel usage steps (summary):

  1. Open the “Image Workbench” in the sidebar and select the provider tab.
  2. Click “Configure” to fill in the Key, Base URL, model, and default parameters for the current provider; Agnes configuration includes a link to “Get Agnes Key”.
  3. Optionally “Sniff Models” and check the models you want to appear in the dropdown.
  4. If image-to-image is needed, “Add Reference Image” under the prompt (up to 5 images), enter the prompt, and click “Generate Image”.

Use Cases and Notes

Suitable for developers who need to manage multiple image generation APIs within DSH while wanting to quickly generate or continuously edit images within conversations. The OpenAI-compatible tier facilitates connection to self-built or aggregated relays; Grok prioritizes b64_json to reduce secondary download waiting, and includes the key when downloading images from xAI subdomains, automatically retrying without the key upon 401/403.

Please read the repository source code and the MIT License yourself before installing. The plugin runs with the permissions of the current DSH process, and keys and generated files reside locally in $DSH_HOME/image-studio/; do not commit configurations containing keys to version control. The community directory skillhub.cn is an independent site and has no official affiliation with DeepSeek / High-Flyer.

Conclusion

dsh-image-studio consolidates Agnes, GPT Image, Grok, and OpenAI-compatible image generation into a single workbench, using independent keys and the /image conversation link to reduce switching costs. Use the sidebar when you need fine-tuning parameters or browsing history; use /image when you need to edit images while chatting.

  • Directory Page: https://www.skillhub.cn/plugins/david-zdw/dsh-image-studio
  • GitHub: https://github.com/david-zdw/dsh-image-studio
羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye