Skip to content

Commit ed4f4dd

Browse files
techpro-aimlapigitbook-bot
authored andcommitted
GITBOOK-737: docs: add wan-2-6-image
1 parent 6a59cb5 commit ed4f4dd

10 files changed

Lines changed: 116 additions & 4 deletions

File tree

970 KB
Loading
87.6 KB
Loading
87.6 KB
Loading
1.12 MB
Loading

docs/.gitbook/assets/t rex (3).png

1.12 MB
Loading

docs/SUMMARY.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,7 @@
154154
* [qwen-image-edit](api-references/image-models/alibaba-cloud/qwen-image-edit.md)
155155
* [z-image-turbo](api-references/image-models/alibaba-cloud/z-image-turbo.md)
156156
* [z-image-turbo-lora](api-references/image-models/alibaba-cloud/z-image-turbo-lora.md)
157+
* [wan-2-6-image](api-references/image-models/alibaba-cloud/wan-2-6-image.md)
157158
* [ByteDance](api-references/image-models/bytedance/README.md)
158159
* [Seedream 3.0](api-references/image-models/bytedance/seedream-3.0.md)
159160
* [Seededit 3.0 (Image-to-Image)](api-references/image-models/bytedance/seededit-3.0-image-to-image.md)

docs/api-references/image-models/README.md

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.
Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
# wan-2-6-image
2+
3+
{% columns %}
4+
{% column width="66.66666666666666%" %}
5+
{% hint style="info" %}
6+
This documentation is valid for the following list of our models:
7+
8+
* `alibaba/wan-2-6-image`
9+
{% endhint %}
10+
{% endcolumn %}
11+
12+
{% column width="33.33333333333334%" %}
13+
<a href="https://aimlapi.com/app/alibaba/wan-2-6-image" class="button primary">Try in Playground</a>
14+
{% endcolumn %}
15+
{% endcolumns %}
16+
17+
## Model Overview
18+
19+
Text-to-Image and Image-to-Image generator in a single model, providing artists and creators with complete creative freedom.
20+
21+
## Setup your API Key
22+
23+
If you don’t have an API key for the AI/ML API yet, feel free to use our [Quickstart guide](https://docs.aimlapi.com/quickstart/setting-up).
24+
25+
## API Schema
26+
27+
{% openapi-operation spec="wan-2-6-image" path="/v1/images/generations" method="post" %}
28+
[OpenAPI wan-2-6-image](https://raw.githubusercontent.com/aimlapi/api-docs/refs/heads/main/docs/api-references/image-models/Alibaba-Cloud/wan-2-6-image.json)
29+
{% endopenapi-operation %}
30+
31+
## Quick Example
32+
33+
Let's generate an image using two input images and a prompt that defines how they should be edited.
34+
35+
{% tabs %}
36+
{% tab title="Python" %}
37+
{% code overflow="wrap" %}
38+
```python
39+
import requests
40+
import json # for getting a structured output with indentation
41+
42+
def main():
43+
response = requests.post(
44+
"https://api.aimlapi.com/v1/images/generations",
45+
headers={
46+
# Insert your AIML API Key instead of <YOUR_AIMLAPI_KEY>:
47+
"Authorization": "Bearer <YOUR_AIMLAPI_KEY>",
48+
"Content-Type": "application/json",
49+
},
50+
json={
51+
"model": "alibaba/wan-2-6-image",
52+
"prompt": "Combine the images so the T-Rex is wearing a business suit, sitting in a cozy small café, drinking from the mug. Blur the background slightly to create a bokeh effect.",
53+
"image_urls": [
54+
"https://raw.githubusercontent.com/aimlapi/api-docs/main/reference-files/t-rex.png",
55+
"https://raw.githubusercontent.com/aimlapi/api-docs/main/reference-files/blue-mug.jpg"
56+
]
57+
}
58+
)
59+
60+
data = response.json()
61+
print(json.dumps(data, indent=2, ensure_ascii=False))
62+
63+
if __name__ == "__main__":
64+
main()
65+
```
66+
{% endcode %}
67+
{% endtab %}
68+
69+
{% tab title="JS" %}
70+
{% code overflow="wrap" %}
71+
```javascript
72+
async function main() {
73+
const response = await fetch('https://api.aimlapi.com/v1/images/generations', {
74+
method: 'POST',
75+
headers: {
76+
// Insert your AIML API Key instead of <YOUR_AIMLAPI_KEY>:
77+
'Authorization': 'Bearer <YOUR_AIMLAPI_KEY>',
78+
'Content-Type': 'application/json',
79+
},
80+
body: JSON.stringify({
81+
model: 'alibaba/wan-2-6-image',
82+
prompt: 'Combine the images so the T-Rex is wearing a business suit, sitting in a cozy small café, drinking from the mug. Blur the background slightly to create a bokeh effect.',
83+
image_urls: [
84+
"https://raw.githubusercontent.com/aimlapi/api-docs/main/reference-files/t-rex.png",
85+
"https://raw.githubusercontent.com/aimlapi/api-docs/main/reference-files/blue-mug.jpg"
86+
]
87+
}),
88+
});
89+
90+
const data = await response.json();
91+
console.log(data);
92+
}
93+
94+
main();
95+
```
96+
{% endcode %}
97+
{% endtab %}
98+
{% endtabs %}
99+
100+
<details>
101+
102+
<summary>Response</summary>
103+
104+
{% code overflow="wrap" %}
105+
```json5
106+
```
107+
{% endcode %}
108+
109+
</details>
110+
111+
<table data-full-width="true"><thead><tr><th width="442.0667724609375" valign="top">Reference Images</th><th valign="top">Generated Image</th></tr></thead><tbody><tr><td valign="top"><div><figure><img src="../../../.gitbook/assets/t rex (3).png" alt=""><figcaption><p>Image #1</p></figcaption></figure></div></td><td valign="top"><div><figure><img src="../../../.gitbook/assets/alibaba-wan-2-6-image_output.png" alt=""><figcaption><p><kbd><code>"Combine the images so the T-Rex is wearing a business suit, sitting in a cozy small café, drinking from the mug. Blur the background slightly to create a bokeh effect."</code></kbd></p></figcaption></figure></div></td></tr><tr><td valign="top"><div><figure><img src="../../../.gitbook/assets/blue mug (2).jpg" alt=""><figcaption><p>Image #2</p></figcaption></figure></div></td><td valign="top"></td></tr></tbody></table>

docs/api-references/image-models/bytedance/seedream-4-5.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ If you don’t have an API key for the AI/ML API yet, feel free to use our [Quic
2525
## API Schema
2626

2727
{% openapi-operation spec="seedream-4-5" path="/v1/images/generations" method="post" %}
28-
[OpenAPI seedream-4-5](https://raw.githubusercontent.com/aimlapi/api-docs/refs/heads/main/docs/api-references/image-models/ByteDance/seedream-4-5.json)
28+
[OpenAPI seedream-4-5](https://raw.githubusercontent.com/aimlapi/api-docs/main/docs/api-references/image-models/ByteDance/seedream-4-5.json)
2929
{% endopenapi-operation %}
3030

3131
## Quick Example
@@ -121,4 +121,4 @@ main();
121121

122122
</details>
123123

124-
<table data-full-width="true"><thead><tr><th width="442.0667724609375" valign="top">Reference Images</th><th valign="top">Generated Image</th></tr></thead><tbody><tr><td valign="top"><div><figure><img src="../../../.gitbook/assets/t rex (1).png" alt=""><figcaption><p>Image #1</p></figcaption></figure></div></td><td valign="top"><div><figure><img src="../../../.gitbook/assets/bytedance-seedream-4-5_output.jpeg" alt=""><figcaption><p><kbd><code>"Combine the images so the T-Rex is wearing a business suit, sitting in a cozy small café, drinking from the mug. Blur the background slightly to create a bokeh effect."</code></kbd></p></figcaption></figure></div></td></tr><tr><td valign="top"><div><figure><img src="../../../.gitbook/assets/blue mug.jpg" alt=""><figcaption><p>Image #2</p></figcaption></figure></div></td><td valign="top"></td></tr></tbody></table>
124+
<table data-full-width="true"><thead><tr><th width="442.0667724609375" valign="top">Reference Images</th><th valign="top">Generated Image</th></tr></thead><tbody><tr><td valign="top"><div><figure><img src="../../../.gitbook/assets/t rex (1) (1).png" alt=""><figcaption><p>Image #1</p></figcaption></figure></div></td><td valign="top"><div><figure><img src="../../../.gitbook/assets/bytedance-seedream-4-5_output.jpeg" alt=""><figcaption><p><kbd><code>"Combine the images so the T-Rex is wearing a business suit, sitting in a cozy small café, drinking from the mug. Blur the background slightly to create a bokeh effect."</code></kbd></p></figcaption></figure></div></td></tr><tr><td valign="top"><div><figure><img src="../../../.gitbook/assets/blue mug (1).jpg" alt=""><figcaption><p>Image #2</p></figcaption></figure></div></td><td valign="top"></td></tr></tbody></table>

docs/api-references/model-database.md

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)