File tree Expand file tree Collapse file tree 2 files changed +24
-31
lines changed Expand file tree Collapse file tree 2 files changed +24
-31
lines changed Original file line number Diff line number Diff line change @@ -19,6 +19,15 @@ abstract class ImageOptions implements Arrayable
19
19
20
20
public ?int $ priority = null ;
21
21
22
+ /**
23
+ * This is only needed on model: bodies-xl-00001.safetensors, when we switch to the new model that Boris is training (expected to
24
+ * arrive on October 2nd), we can clear this. This model doesn't need a negative prompt. It also doesn't need Lora's probably
25
+ * (contact Boris for more information on this)
26
+ *
27
+ * @var string|null
28
+ */
29
+ public ?string $ negativePrompt = null ;
30
+
22
31
/**
23
32
* Return the array representation of the character options.
24
33
*
@@ -32,6 +41,7 @@ public function toArray(): array
32
41
'guidance_scale ' => $ this ->guidanceScale ,
33
42
'webhook_urls ' => $ this ->webhookUrls ,
34
43
'priority ' => $ this ->priority ,
44
+ 'negative_prompt ' => $ this ->negativePrompt ,
35
45
];
36
46
}
37
47
@@ -103,4 +113,17 @@ public function setPriority(?int $priority): self
103
113
104
114
return $ this ;
105
115
}
116
+
117
+ /**
118
+ * Set the negative prompt for the image.
119
+ *
120
+ * @param string|null $negativePrompt
121
+ * @return $this
122
+ */
123
+ public function setNegativePrompt (?string $ negativePrompt ): self
124
+ {
125
+ $ this ->negativePrompt = $ negativePrompt ;
126
+
127
+ return $ this ;
128
+ }
106
129
}
Original file line number Diff line number Diff line change 2
2
3
3
namespace IntelligentsDev \AiaConnector \Requests \Images \Data ;
4
4
5
- class TextToImageOptions extends ImageOptions
6
- {
7
- /**
8
- * This is only needed on model: bodies-xl-00001.safetensors, when we switch to the new model that Boris is training (expected to
9
- * arrive on October 2nd), we can clear this. This model doesn't need a negative prompt. It also doesn't need Lora's probably
10
- * (contact Boris for more information on this)
11
- *
12
- * @var string|null
13
- */
14
- public ?string $ negativePrompt = null ;
15
-
16
- public function toArray (): array
17
- {
18
- return [
19
- 'negative_prompt ' => $ this ->negativePrompt ,
20
- ];
21
- }
22
-
23
- /**
24
- * Set the negative prompt for the image.
25
- *
26
- * @param string|null $negativePrompt
27
- * @return $this
28
- */
29
- public function setNegativePrompt (?string $ negativePrompt ): self
30
- {
31
- $ this ->negativePrompt = $ negativePrompt ;
32
-
33
- return $ this ;
34
- }
35
- }
5
+ class TextToImageOptions extends ImageOptions {}
You can’t perform that action at this time.
0 commit comments