/install ai-lmage-for-file-repair
\r \r
AI Image for File Repair skill介绍\r
\r 🚀 Quick Overview \r Generate stunning AI images from simple text prompts for free. \r Powered by Gemini-level AI image generation technology. \r Create illustrations, product images, concept art, and social media visuals in seconds.\r \r 🧠 Skill Overview \r AI Image for File Repair is a free AI image generation skill that allows users to create high-quality visuals from text prompts. \r Powered by Gemini-level image generation capabilities, this tool understands natural language descriptions and transforms them into detailed images such as illustrations, concept art, marketing visuals, and product designs. \r Each user can generate up to 5 images for free, making it perfect for experimenting with AI art and creative ideas.\r \r ✨ Key Features \r 🎨 Text-to-Image Generation \r Generate detailed images from simple text prompts. \r ⚡Gemini-Level AI Quality \r Image generation capability comparable to Gemini 2.5. \r 🆓 Free AI Image Generation \r Generate up to 5 images for free. \r 🎭Multiple Styles \r Supports various styles including:\r
- Realistic photography\r
- Anime illustration\r
- Cyberpunk art\r
- Concept design\r
- Minimalist poster\r \r 🎨 Example Prompts \r Try prompts like:\r
- A futuristic cyberpunk city at night, neon lights, ultra detailed\r
- A cute shiba inu astronaut floating in space, cartoon style\r
- Luxury product photography, studio lighting, black background\r
- Fantasy castle on a floating island, epic concept art\r
- Minimalist poster design, pastel colors, modern style\r \r 🚀 Use Cases \r This skill is perfect for:\r
- AI art creation\r
- Social media images\r
- Marketing visuals\r
- Product mockups\r
- Game concept art\r
- Creative inspiration\r \r 💡 Why Use This Skill \r
- Gemini-level AI image generation\r
- Free image generation (5 images)\r
- Fast and easy to use\r
- High-quality visuals\r
- Perfect for creators and designers\r \r ⚡ Quick Start \r 1️⃣ Enter a detailed prompt \r 2️⃣ Generate your AI image \r 3️⃣ Download or use the generated image\r \r 🔥 Trending Prompts\r
- AI influencer portrait\r
- Cyberpunk city\r
- Anime character design\r
- Luxury product photo\r
- Minimalist poster\r \r 🏷 Tags\r
- AI image generator\r
- AI art\r
- text to image\r
- AI illustration\r
- AI design\r
- Gemini AI\r
- AI image creator\r \r
Overview\r
\r
ai-lmage-for-file-repair exposes an async, job-based image generation API:\r
\r
- Submit a generation request → receive a
task_id\r - Poll status → on success returns
result.file_url(OSS URL) for download/display\r - On failure returns a structured
errorpayload\r \r
Use cases\r
\r
- Text-to-image: generate images from a prompt\r
- Image-to-image: provide an input image (Base64) plus a prompt\r
- Serverless / multi-instance: task status + result are persisted in KV (not in-memory)\r \r
Access\r
\r
- Base URL: value of the
AI_IMAGE_HOSTenvironment variable, e.g.http://localhost:9000\r - Auth: every request must include header
x-api-keywith the value ofAI_IMAGE_API_KEY\r \r Header example:\r \r
-H "x-api-key: ${AI_IMAGE_API_KEY}"\r
```\r
\r
> Configuration example (local development): \r
> - `AI_IMAGE_HOST=https://file-repiar-wfaxciicwy.ap-southeast-1.fcapp.run` (this is the default when you run this repo's `index.js` locally) \r
> - `AI_IMAGE_API_KEY=s8cxRtUxNcNEL4um`\r
\r
## Quota & limits\r
\r
- **Daily limit**: **5 images per IP per day (free)**\r
- The service uses the first IP in `x-forwarded-for`; if absent it falls back to `req.ip`\r
- If you're behind a gateway/CDN, ensure `x-forwarded-for` is correctly forwarded, otherwise multiple users may share the same outbound IP quota\r
\r
## Endpoints\r
\r
- `GET /quota`: check today's usage and remaining quota\r
- `POST /generate`: submit a generation job (text-to-image / image-to-image)\r
- `GET /status/:taskId`: check job status and retrieve the download URL\r
\r
## Contracts (request/response)\r
\r
### 1) `GET /quota`\r
\r
Response:\r
\r
```json\r
{\r
"client_id": "ip:203.0.113.10",\r
"date": "2026-03-10",\r
"used": 1,\r
"limit": 3,\r
"remaining": 2\r
}\r
```\r
\r
### 2) `POST /generate`\r
\r
- **Content-Type**: `application/json`\r
\r
Request body (text-to-image):\r
\r
- **prompt** (required, string): the prompt\r
- **negative_prompt** (optional, string): negative prompt\r
- **aspect_ratio** (optional, string): e.g. `"1:1"`, `"16:9"`\r
- **width/height** (optional, number|string): size (may be ignored by the model)\r
- **seed** (optional, number|string): seed\r
\r
For image-to-image, add:\r
\r
- **input_image_base64** (optional, string): input image Base64 (**without** the `data:image/...;base64,` prefix)\r
- **input_image_mime_type** (required when `input_image_base64` is provided, string): e.g. `image/png`, `image/jpeg`\r
\r
Success response:\r
\r
```json\r
{ "task_id": "xxxxxxxxxxxxxxxx" }\r
```\r
\r
### 3) `GET /status/:taskId`\r
\r
Common fields:\r
\r
- **status**: `queued` / `running` / `succeeded` / `failed`\r
- **result**: present on success; `null` on failure\r
- **error**: present on failure; `null` on success\r
\r
Success example:\r
\r
```json\r
{\r
"task_id": "xxxxxxxxxxxxxxxx",\r
"status": "succeeded",\r
"created_at": 1760000000000,\r
"updated_at": 1760000005000,\r
"started_at": 1760000001000,\r
"finished_at": 1760000004500,\r
"error": null,\r
"result": {\r
"file_url": "https://ts-xxx.oss-cn-shenzhen.aliyuncs.com/ai-photo/20260117070932_user-card-bg.png",\r
"file_name": "user-card-bg.png",\r
"mime_type": "image/png"\r
}\r
}\r
```\r
\r
Failure example (shape):\r
\r
```json\r
{\r
"task_id": "xxxxxxxxxxxxxxxx",\r
"status": "failed",\r
"error": {\r
"message": "Upstream HTTP 401",\r
"code": "UPSTREAM_ERROR",\r
"statusCode": 401,\r
"upstream": {}\r
},\r
"result": null\r
}\r
```\r
\r
## Recommended flow\r
\r
1. Call `GET /quota` and ensure `remaining > 0`\r
2. Call `POST /generate` to get a `task_id`\r
3. Poll `GET /status/:taskId`\r
- `queued/running`: poll every 1–2 seconds (recommend polling up to 30–60 seconds; you can retry later)\r
- `succeeded`: download/display via `result.file_url`\r
- `failed`: show `error.message` and stop\r
\r
## Examples\r
\r
### Text-to-image (macOS/Linux: curl)\r
\r
```bash\r
curl -X POST "${AI_IMAGE_HOST}/generate" \\r
-H "Content-Type: application/json" \\r
-H "x-api-key: ${AI_IMAGE_API_KEY}" \\r
-d '{\r
"prompt": "一只戴墨镜的柯基,赛博朋克霓虹灯风格,高清",\r
"aspect_ratio": "1:1"\r
}'\r
```\r
\r
### Text-to-image (Windows: PowerShell)\r
\r
```powershell\r
$body = @{\r
prompt = "A corgi wearing sunglasses, cyberpunk neon, high detail"\r
aspect_ratio = "1:1"\r
} | ConvertTo-Json -Depth 10\r
\r
Invoke-RestMethod -Method Post "$env:AI_IMAGE_HOST/generate" `\r
-Headers @{ "x-api-key"=$env:AI_IMAGE_API_KEY } `\r
-ContentType "application/json" `\r
-Body $body\r
```\r
\r
### Image-to-image (Windows: PowerShell)\r
\r
```powershell\r
$b64 = [Convert]::ToBase64String([IO.File]::ReadAllBytes("input.png"))\r
\r
$body = @{\r
prompt = "Enhance and restore this image, keep the subject, photo-realistic"\r
input_image_base64 = $b64\r
input_image_mime_type = "image/png"\r
} | ConvertTo-Json -Depth 10\r
\r
Invoke-RestMethod -Method Post "$env:AI_IMAGE_HOST/generate" `\r
-Headers @{ "x-api-key"=$env:AI_IMAGE_API_KEY } `\r
-ContentType "application/json" `\r
-Body $body\r
```\r
\r
### Image-to-image (macOS/Linux: curl)\r
\r
> Tip: the `base64` flags differ across platforms. The PowerShell example above is the most portable for Windows.\r
\r
```bash\r
IMG_B64="$(base64 -i input.png | tr -d '\
')"\r
\r
curl -X POST "${AI_IMAGE_HOST}/generate" \\r
-H "Content-Type: application/json" \\r
-H "x-api-key: ${AI_IMAGE_API_KEY}" \\r
-d "{\r
\"prompt\": \"Enhance and restore this image, keep the subject, photo-realistic\",\r
\"input_image_base64\": \"${IMG_B64}\",\r
\"input_image_mime_type\": \"image/png\"\r
}"\r
```\r
\r
### Download result (any OS with curl)\r
\r
```bash\r
curl -L "\x3Cfile_url>" -o "output.png"\r
```\r
\r
## Errors & troubleshooting\r
\r
- **HTTP 400**: missing/invalid parameters (common: empty `prompt`; or missing `input_image_mime_type` for image-to-image)\r
- **HTTP 401**: missing/invalid `x-api-key`\r
- **HTTP 429**: quota exceeded (5 images per IP per day)\r
- **HTTP 500**: internal server error (inspect `error.upstream` and server logs)\r
\r
## Recommended (optional)\r
\r
If you require more extensive or advanced format repair support, or you need audio/image repair, please visit: https://bit.ly/4roS6Rv\r
\r
We offer the following services:\r
\r
●Effortlessly repair videos, photos and files that are blurry, overexposed and corrupted.\r
●AI enhance photo quality, sharpen detail, and colorize photos.\r
●Effectively improve video quality and boost resolution up to 8K.\r
●Extend, fill, and restyle your images with AI. No quality loss.\r
●Expertly repair corrupted files, including Word, Excel, PPTX, EPUB, PDF, PSD, PSB, and more.\r
●Seamlessly repair corrupted audio files in M4A, MP3, AAC, WAV and FLAC formats.\r
●Convert PNG, HEIC, CR2, BMP -> JPG for repair & enhance\r
\r
- Make sure OpenClaw is installed (local or Docker)
- Run the install command in chat:
/install ai-lmage-for-file-repair - After installation, invoke the skill by name or use
/ai-lmage-for-file-repair - Provide required inputs per the skill's parameter spec and get structured output
What is ai lmage?
Async AI image generation (text-to-image and image-to-image). Submit a job to get a task_id, then poll status to get an OSS download URL. It is an AI Agent Skill for Claude Code / OpenClaw, with 399 downloads so far.
How do I install ai lmage?
Run "/install ai-lmage-for-file-repair" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.
Is ai lmage free?
Yes, ai lmage is completely free, licensed under MIT-0. You can download, install and use it at no cost.
Which platforms does ai lmage support?
ai lmage is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).
Who created ai lmage?
It is built and maintained by ilpvc (@ilpvc); the current version is v1.0.3.