← Back to Skills Marketplace
windandliberty

modelscope_img_generator

by ruifeng · GitHub ↗ · v1.2.0 · MIT-0
cross-platform ✓ Security Clean
124
Downloads
1
Stars
0
Active Installs
3
Versions
Install in OpenClaw
/install modelscope-img-generator
Description
Generate images with ModelScope API. Use for image generation requests. Supports text-to-image + image-to-image; configurable models; use --input-image.
Usage Guidance
This skill appears to do what it says: it will upload your prompt and any input image to ModelScope's official API and save the returned image in your current working directory. Before installing, confirm you trust ModelScope with any image content or prompts you send (sensitive images may be retained by the service). Provide an API key scoped to your account, and be prepared to revoke it if misused. Note the script will download whatever image URL the API returns (typically ModelScope storage/CDN); if you need stricter guarantees about where assets are hosted, review ModelScope's service docs. Also verify you are comfortable installing/using the 'uv' runner and the Python dependencies (requests, pillow).
Capability Analysis
Type: OpenClaw Skill Name: modelscope-img-generator Version: 1.2.0 The ModelScope-Img skill is a legitimate tool for generating and editing images using the ModelScope API. The implementation in `scripts/generate_img.py` follows security best practices by hardcoding the official API endpoint (https://api-inference.modelscope.cn/) to prevent API key redirection or data exfiltration to untrusted servers. The skill handles image-to-image tasks by converting local files to base64 data URLs for the official API and includes clear instructions in `SKILL.md` for the AI agent to manage filenames and prompts without any signs of malicious intent or prompt injection attacks.
Capability Assessment
Purpose & Capability
Name/description, manifest, SKILL.md, and the Python script all align: the tool needs a MODELSCOPE_API_KEY, accepts prompts and optional input images, supports model selection and LoRA, and saves generated images locally. No unrelated credentials, binaries, or capabilities are requested.
Instruction Scope
Instructions and code stay within the stated purpose (send prompts and optional input images to ModelScope and save the returned image). Important privacy note: any provided input image and the prompt are uploaded (the script encodes input images as base64 and posts them). The script downloads the result from the URL returned by the API — SKILL.md and manifest assert the API endpoint is fixed, but the final image URL returned by the API could point to a storage/CDN host (the script will fetch whatever URL ModelScope returns). This is expected for the task but is worth the user's awareness.
Install Mechanism
There is no install spec (instruction-only with a single script). Dependencies are standard Python packages (requests, pillow) and running via 'uv' is documented. Nothing is downloaded from arbitrary or untrusted URLs and no extracted archives or install scripts are present.
Credentials
Only MODELSCOPE_API_KEY is required and it is declared as the primaryEnv in manifest. The code only reads the provided API key and does not request unrelated secrets or system credentials.
Persistence & Privilege
The skill does not request permanent/always-on inclusion and does not modify other skills or system-wide settings. It writes only the generated image file to the user's working directory (expected behavior).
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install modelscope-img-generator
  3. After installation, invoke the skill by name or use /modelscope-img-generator
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.2.0
**Security hardening: Endpoint is now fixed to the official ModelScope API** - The API endpoint is now locked to `https://api-inference.modelscope.cn/` and cannot be customized. - All ability to set a custom base URL has been removed, eliminating risks of sending your API key or images to untrusted servers. - Documentation updated to clarify endpoint restrictions and reinforce user security. - All other usage, prerequisites, and prompt/filename conventions remain unchanged.
v1.1.0
- Adds manifest.yaml for improved skill metadata and distribution. - SKILL.md updated with clearer prerequisites and detailed security warnings, especially regarding the --base-url parameter and image input. - Explicit instructions for required Python version, package manager (uv), and package dependencies. - Existing features and usage remain unchanged.
v1.0.0
- Initial release of ModelScope-Img skill for image generation and editing using ModelScope community models. - Supports both text-to-image and image-to-image tasks, with flexible model selection via the `--model` flag. - Implements LoRA adapter support, including multiple LoRAs and weighting. - API key can be provided via command line or environment variable. - Guides on filename generation, typical error handling, and secure use from any working directory. - Provides usage examples for generating and editing images, as well as prompt templates for better results.
Metadata
Slug modelscope-img-generator
Version 1.2.0
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 3
Frequently Asked Questions

What is modelscope_img_generator?

Generate images with ModelScope API. Use for image generation requests. Supports text-to-image + image-to-image; configurable models; use --input-image. It is an AI Agent Skill for Claude Code / OpenClaw, with 124 downloads so far.

How do I install modelscope_img_generator?

Run "/install modelscope-img-generator" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is modelscope_img_generator free?

Yes, modelscope_img_generator is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does modelscope_img_generator support?

modelscope_img_generator is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created modelscope_img_generator?

It is built and maintained by ruifeng (@windandliberty); the current version is v1.2.0.

💬 Comments