@umituz/react-native-ai-generation-content 1.87.2 → 1.88.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@umituz/react-native-ai-generation-content",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.88.1",
|
|
4
4
|
"description": "Provider-agnostic AI generation orchestration for React Native with result preview components",
|
|
5
5
|
"main": "src/index.ts",
|
|
6
6
|
"types": "src/index.ts",
|
|
@@ -9,8 +9,18 @@ Preserve the EXACT facial appearance from reference photos with 100% accuracy.
|
|
|
9
9
|
Keep every detail identical: bone structure, eye shape, eye color, nose, lips, skin texture, freckles, moles.
|
|
10
10
|
The person must be instantly recognizable — do NOT alter, idealize, or beautify any facial feature.`;
|
|
11
11
|
|
|
12
|
+
export const IDENTITY_PRESERVATION_COUPLE = `IDENTITY PRESERVATION (HIGHEST PRIORITY):
|
|
13
|
+
Preserve the EXACT facial appearance of BOTH people from reference photos with 100% accuracy.
|
|
14
|
+
The resulting image MUST show BOTH individuals together as a couple.
|
|
15
|
+
Keep every detail identical for both individuals: bone structure, eye shape, eye color, nose, lips, skin texture, freckles, moles.
|
|
16
|
+
Both people must be instantly recognizable — do NOT alter, idealize, or beautify any facial features.`;
|
|
17
|
+
|
|
12
18
|
export const PHOTOREALISTIC_RENDERING = `STYLE: Photorealistic photograph, high quality, professional photography, natural lighting with realistic shadows.
|
|
13
19
|
PROHIBITED: No anime, cartoons, illustrations, sketches, 3D renders, paintings, or non-photorealistic styles.`;
|
|
14
20
|
|
|
15
21
|
export const NATURAL_POSE_GUIDELINES = `POSE: Natural, relaxed body language appropriate to the scenario context.
|
|
16
22
|
AVOID: No absurd poses, unnatural contortions, or physically impossible positions.`;
|
|
23
|
+
|
|
24
|
+
export const NATURAL_POSE_GUIDELINES_COUPLE = `POSE: Natural, relaxed body language and authentic interaction between the two people, appropriate to the scenario context.
|
|
25
|
+
AVOID: No absurd poses, unnatural contortions, or physically impossible positions.`;
|
|
26
|
+
|
|
@@ -4,8 +4,10 @@
|
|
|
4
4
|
|
|
5
5
|
import {
|
|
6
6
|
IDENTITY_PRESERVATION_CORE,
|
|
7
|
+
IDENTITY_PRESERVATION_COUPLE,
|
|
7
8
|
PHOTOREALISTIC_RENDERING,
|
|
8
9
|
NATURAL_POSE_GUIDELINES,
|
|
10
|
+
NATURAL_POSE_GUIDELINES_COUPLE,
|
|
9
11
|
} from "./constants";
|
|
10
12
|
import type { CreatePromptOptions } from "./types";
|
|
11
13
|
|
|
@@ -17,13 +19,14 @@ export const createPhotorealisticPrompt = (
|
|
|
17
19
|
includeIdentityPreservation = true,
|
|
18
20
|
includePhotoRealism = true,
|
|
19
21
|
includePoseGuidelines = true,
|
|
22
|
+
isCouple = false,
|
|
20
23
|
customInstructions,
|
|
21
24
|
} = options;
|
|
22
25
|
|
|
23
26
|
const parts: string[] = [];
|
|
24
27
|
|
|
25
28
|
if (includeIdentityPreservation) {
|
|
26
|
-
parts.push(IDENTITY_PRESERVATION_CORE);
|
|
29
|
+
parts.push(isCouple ? IDENTITY_PRESERVATION_COUPLE : IDENTITY_PRESERVATION_CORE);
|
|
27
30
|
}
|
|
28
31
|
|
|
29
32
|
if (includePhotoRealism) {
|
|
@@ -31,7 +34,7 @@ export const createPhotorealisticPrompt = (
|
|
|
31
34
|
}
|
|
32
35
|
|
|
33
36
|
if (includePoseGuidelines) {
|
|
34
|
-
parts.push(NATURAL_POSE_GUIDELINES);
|
|
37
|
+
parts.push(isCouple ? NATURAL_POSE_GUIDELINES_COUPLE : NATURAL_POSE_GUIDELINES);
|
|
35
38
|
}
|
|
36
39
|
|
|
37
40
|
if (customInstructions) {
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
* Scenario Data Utils
|
|
3
3
|
* Helper functions for scenario creation
|
|
4
4
|
*/
|
|
5
|
+
import { createPhotorealisticPrompt as createUnifiedPrompt } from "../../../prompts";
|
|
5
6
|
|
|
6
7
|
/**
|
|
7
8
|
* Photorealistic prompt constants for high-quality AI image generation
|
|
@@ -38,15 +39,17 @@ export const CREATIVE_BASE = {
|
|
|
38
39
|
* Creates a photorealistic AI prompt by combining scene description with quality modifiers
|
|
39
40
|
* Used for realistic image/video generation (future us, video apps)
|
|
40
41
|
* @param scene - The scene-specific description (what's happening, who, where)
|
|
41
|
-
* @param options - Optional configuration
|
|
42
|
+
* @param options - Optional configuration
|
|
42
43
|
* @returns Complete photorealistic prompt
|
|
43
44
|
*/
|
|
44
45
|
export const createPhotorealisticPrompt = (
|
|
45
46
|
scene: string,
|
|
46
|
-
options?: { customInstructions?: string },
|
|
47
|
+
options?: { customInstructions?: string; isCouple?: boolean },
|
|
47
48
|
): string => {
|
|
48
|
-
|
|
49
|
-
|
|
49
|
+
return createUnifiedPrompt(scene, {
|
|
50
|
+
customInstructions: options?.customInstructions,
|
|
51
|
+
isCouple: options?.isCouple,
|
|
52
|
+
});
|
|
50
53
|
};
|
|
51
54
|
|
|
52
55
|
/**
|