Spaces:
Running on Zero
Running on Zero
Enforce single-subject neural assets
Browse filesStrengthen direct text-to-image prompts and negative prompts to reject contact sheets, turnarounds, duplicates, lineups, and alternate views.
app.py
CHANGED
|
@@ -324,9 +324,10 @@ def build_asset_prompt(role: str, prompt: str, style_hint: str) -> str:
|
|
| 324 |
)
|
| 325 |
else:
|
| 326 |
asset_instruction = (
|
| 327 |
-
"Create one complete standalone 2D
|
| 328 |
-
"
|
| 329 |
-
"
|
|
|
|
| 330 |
)
|
| 331 |
return (
|
| 332 |
f"{role} asset: {prompt}. Creative brief: {style_hint}. "
|
|
@@ -1541,7 +1542,9 @@ def diffusion_negative_prompt(spec: AssetSpec) -> str:
|
|
| 1541 |
common = (
|
| 1542 |
"texture map, material texture, seamless texture, tiled pattern, uv map, uv unwrap, "
|
| 1543 |
"3d model texture, normal map, roughness map, diffuse map, sprite sheet, atlas, "
|
| 1544 |
-
"
|
|
|
|
|
|
|
| 1545 |
)
|
| 1546 |
if is_background_spec(spec):
|
| 1547 |
camera_negative = {
|
|
@@ -1657,8 +1660,10 @@ def primary_diffusion_prompt(spec: AssetSpec) -> str:
|
|
| 1657 |
"Use connected environmental forms and clean terrain structure. No characters and no decorative overlay."
|
| 1658 |
)
|
| 1659 |
return (
|
| 1660 |
-
f"{spec.prompt}
|
| 1661 |
-
"
|
|
|
|
|
|
|
| 1662 |
"Use a plain uniform white studio background for clean extraction. "
|
| 1663 |
"Add recognizable costume, equipment, materials, and character details. "
|
| 1664 |
"No scenery, floor, trees, foliage, frame, or environmental props."
|
|
|
|
| 324 |
)
|
| 325 |
else:
|
| 326 |
asset_instruction = (
|
| 327 |
+
"Create exactly one complete standalone 2D game character or object, centered and fully visible. "
|
| 328 |
+
"Show one subject in one pose from one view only; do not create a character sheet, turnaround, lineup, "
|
| 329 |
+
"or alternate views. Use a transparent or plain background and a readable silhouette. Not a texture map, "
|
| 330 |
+
"not a tiled pattern, not a material swatch, not a UV unwrap, not a 3D model skin."
|
| 331 |
)
|
| 332 |
return (
|
| 333 |
f"{role} asset: {prompt}. Creative brief: {style_hint}. "
|
|
|
|
| 1542 |
common = (
|
| 1543 |
"texture map, material texture, seamless texture, tiled pattern, uv map, uv unwrap, "
|
| 1544 |
"3d model texture, normal map, roughness map, diffuse map, sprite sheet, atlas, "
|
| 1545 |
+
"character sheet, model sheet, turnaround, lineup, comparison, alternate views, multiple views, "
|
| 1546 |
+
"duplicate subject, repeated subject, pair, group, multiple objects, cropped subject, close-up surface, "
|
| 1547 |
+
"fabric swatch, text, watermark"
|
| 1548 |
)
|
| 1549 |
if is_background_spec(spec):
|
| 1550 |
camera_negative = {
|
|
|
|
| 1660 |
"Use connected environmental forms and clean terrain structure. No characters and no decorative overlay."
|
| 1661 |
)
|
| 1662 |
return (
|
| 1663 |
+
f"{spec.prompt} Exactly one isolated subject only, centered, fully visible, with one pose and one view. "
|
| 1664 |
+
"Do not repeat the subject and do not create a character sheet, turnaround, lineup, or alternate views. "
|
| 1665 |
+
"Use a readable silhouette and derive its anatomy, body shape, camera angle, and pose directly from "
|
| 1666 |
+
"the written description. "
|
| 1667 |
"Use a plain uniform white studio background for clean extraction. "
|
| 1668 |
"Add recognizable costume, equipment, materials, and character details. "
|
| 1669 |
"No scenery, floor, trees, foliage, frame, or environmental props."
|