Kling AI Image Generation
Turn a creative brief into one well-specified Kling image request. Use only the live tools and schemas from the configured MCP at https://kling.ai/mcp.
Contract
- Use host-managed OAuth. Never request or expose API keys, tokens, cookies, authorization headers, or signed URLs.
- A user request to generate authorizes one submission after materially missing inputs are resolved. Do not add a credit-cost warning or a separate confirmation step.
- Submit once per approved intent. Never blind-retry an ambiguous or failed submission.
- Discover the live schema before choosing tools, models, input names, or enumerated values. Live provider fields override examples here.
- Upload attached reference media with the remote upload tool when required, then reuse the returned provider reference exactly.
Before submission, read the complete MCP input/output and current model parameter snapshot, then let the current tools/list and who_am_i override dynamic snapshot values.
Workflow
- Classify the request using the mode table below.
- Read scene patterns for product, advertising, thumbnail, portrait, editorial, or conceptual work.
- Read prompt construction when the brief is vague, has references, contains exact copy, or needs multiple controlled variants.
- Ask only for missing facts that materially change the result: subject/product, intended use, ratio, required copy, or mandatory reference identity.
- Among live models compatible with the mode and references, prefer a full-quality model. Prefer a low-cost or fast model only when the user explicitly asks for a draft, speed, or credit savings.
- Build one prompt that separates subject, action, environment, composition, lighting, palette, material detail, camera language, and exclusions. Translate abstract requests such as “premium,” “cinematic,” or “high quality” into visible lighting, materials, depth of field, color, and composition instead of stacking adjectives.
- Call the live image generation tool once when the request has enough information. Preserve the exact
generationId and any taskTraceId.
- If the submission is not terminal, poll its status at provider-allowed intervals until success or failure. On user cancellation or current-turn timeout, return the current state and task number.
- Provide the primary image or result link returned by Kling. Show
generationId as the task number and keep taskTraceId internal unless troubleshooting requires it.
Generation modes
| User intent |
Mode |
Required interpretation |
| Text-to-image |
New image |
No source image controls identity or composition. Build the scene from the text brief. |
| Image-to-image |
Edit or reference-guided image |
At least one image controls content, identity, product geometry, composition, or style. Assign every input an explicit role. |
| Element subject reference |
Image-to-image |
Read the Element first, confirm it is an image subject, and use only an image-to-image model whose live schema explicitly supports elements. Text-to-image never uses Elements. |
| Restyle |
Focused image-to-image change |
Lock all unspecified source facts and name the one allowed change. |
| Status check |
Read-only |
Do not call a generation tool; query the existing task. |
Do not silently switch modes. An attached image is not automatically an image-to-image instruction: if the user asks for an unrelated new image, ignore it only after confirming it is irrelevant. Conversely, never reduce an explicit image-to-image request to text-to-image after an upload or schema failure.
Before calling the tool, check the selected mode, ratio, reference roles, and
allowed changes internally. Do not show a pre-submission process message unless
you need the user to clarify a missing creative requirement.
Defaults
- Use a supported
2k setting for a normal deliverable, 4k for high-quality, commercial, advertising, fine-material, or crop-heavy work, and 1k only for drafts or speed-first work. Do not lower a higher live model default.
- When the live model exposes a
quality argument, use its middle tier for a normal deliverable, its high tier for high-quality or commercial work, and its low tier only for drafts. Obtain the exact value from the live enumeration.
- Choose ratio from the destination:
1:1 square social/product, 4:5 feed portrait, 9:16 story/vertical cover, 16:9 landscape banner or thumbnail.
- Generate
1 image unless the user requests multiple results; do not substitute a batch of near-duplicates for a clear creative decision.
- Prefer a clean image without text unless the user explicitly requires text in the generated artwork.
- For variants, change one named dimension per approved generation: concept, composition, palette, camera distance, or expression. Do not use near-duplicate prompts.
- Preserve supplied brand names, labels, logos, faces, and product geometry as locked constraints. Never invent claims, prices, certifications, ingredients, results, or statistics.
Quality gate
Before submission, check that the brief has one clear focal subject, a readable hierarchy, destination-appropriate safe space, coherent lighting, and no conflicting camera/composition instructions. When the host can inspect outputs, verify reference fidelity, text accuracy, subject count, and obvious artifacts. Do not claim visual QA when inspection is unavailable.
Failure behavior
- Authorization failure: direct the user to WorkBuddy's native MCP connection flow.
- Unsupported argument: refresh the live schema and revise only the rejected field.
- Insufficient credits: tell the user to recharge and stop. Do not retry automatically.
- Lost response: treat task creation as unknown and query existing tasks before any new generation.
- Provider failure: report the provider message and preserve IDs; do not resubmit automatically.
1---2name: kling-ai-generate-image-23description: Generate cinematic-quality images via Kling AI in WorkBuddy. Supports T2I & I2I. Ideal for posters, product photography, ads, and high-visual-quality creative work.4---5
6# Kling AI Image Generation
7
8Turn a creative brief into one well-specified Kling image request. Use only the live tools and schemas from the configured MCP at `https://kling.ai/mcp`.
9
10## Contract
11
12- Use host-managed OAuth. Never request or expose API keys, tokens, cookies, authorization headers, or signed URLs.
13- A user request to generate authorizes one submission after materially missing inputs are resolved. Do not add a credit-cost warning or a separate confirmation step.
14- Submit once per approved intent. Never blind-retry an ambiguous or failed submission.
15- Discover the live schema before choosing tools, models, input names, or enumerated values. Live provider fields override examples here.
16- Upload attached reference media with the remote upload tool when required, then reuse the returned provider reference exactly.
17
18Before submission, read the [complete MCP input/output and current model parameter snapshot](../kling-ai-plugin/references/mcp-contract.md), then let the current `tools/list` and `who_am_i` override dynamic snapshot values.
19
20## Workflow
21
221. Classify the request using the mode table below.
232. Read [scene patterns](references/scene-patterns.md) for product, advertising, thumbnail, portrait, editorial, or conceptual work.
243. Read [prompt construction](references/prompt-construction.md) when the brief is vague, has references, contains exact copy, or needs multiple controlled variants.
254. Ask only for missing facts that materially change the result: subject/product, intended use, ratio, required copy, or mandatory reference identity.
265. Among live models compatible with the mode and references, prefer a full-quality model. Prefer a low-cost or fast model only when the user explicitly asks for a draft, speed, or credit savings.
276. Build one prompt that separates subject, action, environment, composition, lighting, palette, material detail, camera language, and exclusions. Translate abstract requests such as “premium,” “cinematic,” or “high quality” into visible lighting, materials, depth of field, color, and composition instead of stacking adjectives.
287. Call the live image generation tool once when the request has enough information. Preserve the exact `generationId` and any `taskTraceId`.
298. If the submission is not terminal, poll its status at provider-allowed intervals until success or failure. On user cancellation or current-turn timeout, return the current state and task number.
309. Provide the primary image or result link returned by Kling. Show `generationId` as the **task number** and keep `taskTraceId` internal unless troubleshooting requires it.
31
32## Generation modes
33
34| User intent | Mode | Required interpretation |
35| --- | --- | --- |
36| Text-to-image | New image | No source image controls identity or composition. Build the scene from the text brief. |
37| Image-to-image | Edit or reference-guided image | At least one image controls content, identity, product geometry, composition, or style. Assign every input an explicit role. |
38| Element subject reference | Image-to-image | Read the Element first, confirm it is an image subject, and use only an image-to-image model whose live schema explicitly supports `elements`. Text-to-image never uses Elements. |
39| Restyle | Focused image-to-image change | Lock all unspecified source facts and name the one allowed change. |
40| Status check | Read-only | Do not call a generation tool; query the existing task. |
41
42Do not silently switch modes. An attached image is not automatically an image-to-image instruction: if the user asks for an unrelated new image, ignore it only after confirming it is irrelevant. Conversely, never reduce an explicit image-to-image request to text-to-image after an upload or schema failure.
43
44Before calling the tool, check the selected mode, ratio, reference roles, and
45allowed changes internally. Do not show a pre-submission process message unless
46you need the user to clarify a missing creative requirement.
47
48## Defaults
49
50- Use a supported `2k` setting for a normal deliverable, `4k` for high-quality, commercial, advertising, fine-material, or crop-heavy work, and `1k` only for drafts or speed-first work. Do not lower a higher live model default.
51- When the live model exposes a `quality` argument, use its middle tier for a normal deliverable, its high tier for high-quality or commercial work, and its low tier only for drafts. Obtain the exact value from the live enumeration.
52- Choose ratio from the destination: `1:1` square social/product, `4:5` feed portrait, `9:16` story/vertical cover, `16:9` landscape banner or thumbnail.
53- Generate `1` image unless the user requests multiple results; do not substitute a batch of near-duplicates for a clear creative decision.
54- Prefer a clean image without text unless the user explicitly requires text in the generated artwork.
55- For variants, change one named dimension per approved generation: concept, composition, palette, camera distance, or expression. Do not use near-duplicate prompts.
56- Preserve supplied brand names, labels, logos, faces, and product geometry as locked constraints. Never invent claims, prices, certifications, ingredients, results, or statistics.
57
58## Quality gate
59
60Before submission, check that the brief has one clear focal subject, a readable hierarchy, destination-appropriate safe space, coherent lighting, and no conflicting camera/composition instructions. When the host can inspect outputs, verify reference fidelity, text accuracy, subject count, and obvious artifacts. Do not claim visual QA when inspection is unavailable.
61
62## Failure behavior
63
64- Authorization failure: direct the user to WorkBuddy's native MCP connection flow.
65- Unsupported argument: refresh the live schema and revise only the rejected field.
66- Insufficient credits: tell the user to recharge and stop. Do not retry automatically.
67- Lost response: treat task creation as unknown and query existing tasks before any new generation.
68- Provider failure: report the provider message and preserve IDs; do not resubmit automatically.