Image Generate logo

Image Generate

Community
sagirimo
image-generate

Generate scientific illustrations (graphical abstracts, mechanism schematics, cover art, poster art) from a text prompt through the image provider configured in the BioDSH app. Not for data plots.

Overview

Publishersagirimo
RepositoryBioDSH
Skill nameimage-generate
Stars
65
Forks
2
Bundled files
2
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 2 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by sagirimo on GitHub. Read the source before you install it.

Installation

Install the Image Generate AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/sagirimo/BioDSH/tree/main/biodsh-core/skills/image-generate
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/sagirimo/BioDSH.git /tmp/BioDSH
mkdir -p .claude/skills
cp -r /tmp/BioDSH/biodsh-core/skills/image-generate .claude/skills/image-generate
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Image Generate in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Image Generate on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Image Generate is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

AI scientific illustration (text-to-image)

Use this skill when the user wants a picture that is drawn, not computed: a graphical abstract, a mechanism or pathway schematic, a cell/tissue cartoon, journal cover art, a poster hero image, a conceptual figure for a talk.

Do not use it for data plots (UMAP, volcano, heatmap, bar/box plots, survival curves). Those must come from the data through matplotlib/seaborn/scanpy so that every point is real. An image model cannot plot data; it only paints something that looks like a plot.

Provider configuration

The provider is configured by the user in the BioDSH app under 更多 → 图像生成 (base URL, API key, model). The app passes it to this script as environment variables BIODSH_IMAGE_BASE_URL, BIODSH_IMAGE_API_KEY, BIODSH_IMAGE_MODEL. Any OpenAI-compatible Images API works (OpenAI gpt-image-1, 智谱 CogView cogview-4-250304, SiliconFlow Kwai-Kolors/Kolors, 通义万相 wan2.2-t2i-flash, ...).

If the script prints {"error": "...not configured..."}, tell the user to fill in 更多 → 图像生成 in the app. Never guess a base URL or key and never ask the user to paste a key into the chat.

Command

bash
python "<skill dir>/generate.py" --prompt "..." --out generated_images

Options: --name NAME (file stem, default: slug of the prompt + timestamp), --size 1024x1024 (normalized per provider, e.g. 智谱 accepts 1024x1024, 768x1344, 864x1152, 1344x768, 1152x864, 1440x720, 720x1440), --n 1 (number of variants), --style scientific|flat|photo|none (default scientific, prepends a style template to your prompt), --negative "..." (things to avoid), --reference path.png (OpenAI-style providers only; others return an error).

Output: generated_images/<name>-1.png (one file per variant) plus generation.json (prompt, final prompt, model, provider hostname, size, files, elapsed seconds). The script prints the same JSON to stdout. On failure it prints {"error": ...} and exits 1; report the error text to the user as-is (HTTP status and body excerpt are included) and do not retry in a loop.

Writing a good prompt for a scientific figure

State, in one or two sentences each:

  • Subject — the biological entities and the relationship between them: "a T cell contacting a tumor cell through PD-1/PD-L1, with a blocking antibody in between".
  • Style — the --style scientific template already asks for a clean vector-like illustration on a white background with flat colors; add only the deviations ("isometric", "watercolor", "dark background for a slide").
  • Layout — left-to-right flow, number of panels, where the arrows go, what is enlarged in an inset.
  • What to avoid — put it in --negative: "text, letters, watermark, photorealistic gore, extra limbs, cluttered background". Ask for no text whenever possible: models misspell gene names; add labels afterwards in PowerPoint/Illustrator.

Keep prompts concrete and short (under ~80 words). Generate 2–3 variants (--n 2) when the user is exploring, one when they know what they want. Iterate on wording rather than re-running the same prompt.

After generation

  • Report the absolute path of every PNG to the user and show the image if the interface supports it.
  • Remind the user to check the image for factual errors: image models invent labels, ligand/receptor pairs, organelle shapes and arrow directions. A generated schematic is a draft to be corrected, not a source of truth, and should be labelled as AI-generated in a manuscript where the journal requires it.
  • Record the prompt in the report (it is in generation.json) so the figure can be regenerated.

Examples

bash
# graphical abstract, two variants to choose from
python "<skill dir>/generate.py" --prompt "left: a tumor with infiltrating T cells; right: the same tumor after anti-PD-1 therapy with more T cells and shrinking tumor; arrow between them" --n 2 --out generated_images

# wide poster banner, 智谱 CogView accepts 1440x720
python "<skill dir>/generate.py" --prompt "cross-section of a lymph node with B-cell follicles and T-cell zones" --size 1440x720 --negative "text, letters" --out generated_images

# photo-like cover art
python "<skill dir>/generate.py" --prompt "close-up of a single neuron with glowing synapses on a dark background" --style photo --name cover --out generated_images

Chinese prompt tips

Most image models follow English prompts more reliably than Chinese ones (CogView and 万相 handle Chinese well; OpenAI and Kolors prefer English). When the user writes the request in Chinese, translate the subject/style/layout into a precise English prompt internally before calling the script, but keep all your replies, file descriptions and the summary in Chinese. Do not translate gene, protein or drug names — keep the standard symbols (PD-1, TP53, KRAS G12C). If the user wants Chinese characters inside the image, warn that most models render CJK text poorly and suggest adding the text afterwards.

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Image Generate AI skill do?

Generate scientific illustrations (graphical abstracts, mechanism schematics, cover art, poster art) from a text prompt through the image provider configured in the BioDSH app. Not for data plots.

Why use Image Generate on TypingMind?

Because you install it once and use it with any model. Image Generate is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Image Generate in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/sagirimo/BioDSH/tree/main/biodsh-core/skills/image-generate. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Image Generate?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Image Generate?

As many as you like. As long as a model supports skills, you can use Image Generate with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Image Generate AI skill free?

Yes. It is published on GitHub by sagirimo under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇