-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathplugin.json
85 lines (85 loc) · 3.64 KB
/
plugin.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
{
"id": "image_generation_via_stable_diffusion_3",
"uuid": "f582e880-16d8-4a02-b247-86b4cbe9b390",
"userSettings": [
{
"name": "stabilityAPIKey",
"required": true,
"type": "password",
"label": "StabilityAI API Key",
"description": "Get your free API Key from StabilityAI: https://platform.stability.ai/account/keys"
},
{
"name": "output_format",
"label": "Format of the generated image",
"description": "Optional, default: \"png\"",
"type": "enum",
"values": ["png", "jpeg"],
"defaultValue": "png"
},
{
"name": "aspect_ratio",
"label": "Aspect ratio of the generated image",
"description": "Optional, default: \"1:1\"",
"type": "enum",
"values": [
"16:9",
"1:1",
"21:9",
"2:3",
"3:2",
"4:5",
"5:4",
"9:16",
"9:21"
],
"defaultValue": "1:1"
},
{
"name": "model",
"label": "Model to use for generation",
"description": "Optional, default: \"sd3-large\"",
"type": "enum",
"values": ["sd3-medium", "sd3-large", "sd3-large-turbo"],
"defaultValue": "sd3-large"
}
],
"iconURL": "https://www.typingmind.com/stable-diffusion.png",
"title": "Stable Diffusion v3 Image",
"openaiSpec": {
"name": "image_generation_via_stable_diffusion_3",
"parameters": {
"type": "object",
"required": ["prompt"],
"properties": {
"prompt": {
"type": "string",
"description": "The text description of the desired image."
},
"negative_prompt": {
"type": "string",
"description": "A blurb of text describing what you do not wish to see in the output image. Include only if the user asks for it."
}
}
},
"description": "Generate images using Stable Diffusion v3 based on a text description. Adhere to guidelines such as English translation, not depicting politicians or recent artists, and ensuring artist references are over 100 years old.\n\nWhen creating prompt: substitute artist names with style-describing adjectives, include artistic era, mention primary medium. Image type, descent, gender are to be explicitly stated. Avoid offense and bias, conceal identities except gender and physique, retain text references, replace profession titles with universal terms.\n\nPrompt changes aren't allowed unless they anonymise individuals. Replace creative professional/studio names with style descriptions. All prompts should detail every image part in objective terms within a detailed paragraph of over three sentences.\n\nImportant: after calling this function, the output images will be shown to the user automatically. You don't need to include the output image to the users again in your response to avoid duplicate images."
},
"httpAction": {
"id": "4105dcae-c4c5-432f-91cd-af69188adda4",
"method": "POST",
"name": "",
"url": "https://api.stability.ai/v2beta/stable-image/generate/sd3",
"requestBody": "{\"prompt\":\"{prompt}\",\"model\":\"{model}\",\"aspect_ratio\":\"{aspect_ratio}\",\"negative_prompt\":\"{negative_prompt}\",\"output_format\":\"{output_format}\"}",
"requestBodyFormat": "form-data",
"requestHeaders": "{\"Accept\":\"application/json; type=image/*\",\"Authorization\":\"Bearer {stabilityAPIKey}\"}",
"resultTransform": {
"engine": "handlebars",
"templateString": "![{{__VARIABLES.prompt}}](data:image/{{__VARIABLES.output_format}};base64,{{image}})"
},
"hasResultTransform": true,
"hasBody": true,
"hasHeaders": true
},
"implementationType": "javascript",
"outputType": "render_markdown"
}