@aglyn/plugins-ai 1.0.0-beta.268 → 1.0.0-beta.269
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 +17 -17
- package/src/lib/jobs/ai-job-page-language.d.ts +7 -1
- package/src/lib/jobs/ai-job-page-language.js +16 -3
- package/src/lib/jobs/ai-job-page-language.js.map +1 -1
- package/src/lib/jobs/ai-job-site-look.d.ts +2 -1
- package/src/lib/jobs/ai-job-site-look.js +6 -2
- package/src/lib/jobs/ai-job-site-look.js.map +1 -1
- package/src/lib/jobs/ai-job-site-step.js +11 -6
- package/src/lib/jobs/ai-job-site-step.js.map +1 -1
- package/src/lib/jobs/ai-layout-stock-photos.d.ts +16 -8
- package/src/lib/jobs/ai-layout-stock-photos.js +478 -67
- package/src/lib/jobs/ai-layout-stock-photos.js.map +1 -1
- package/src/lib/jobs/fixtures/ai-stock-photo-brightvale-recordings.d.ts +4 -0
- package/src/lib/jobs/fixtures/ai-stock-photo-brightvale-recordings.js +87 -1
- package/src/lib/jobs/fixtures/ai-stock-photo-brightvale-recordings.js.map +1 -1
- package/src/lib/jobs/fixtures/ai-stock-photo-mexicano-recordings.d.ts +31 -0
- package/src/lib/jobs/fixtures/ai-stock-photo-mexicano-recordings.js +325 -0
- package/src/lib/jobs/fixtures/ai-stock-photo-mexicano-recordings.js.map +1 -0
- package/src/lib/layout-language/ai-layout-motion.d.ts +60 -7
- package/src/lib/layout-language/ai-layout-motion.js +231 -4
- package/src/lib/layout-language/ai-layout-motion.js.map +1 -1
- package/src/lib/layout-language/ai-layout-pictures.d.ts +8 -0
- package/src/lib/layout-language/ai-layout-pictures.js +68 -4
- package/src/lib/layout-language/ai-layout-pictures.js.map +1 -1
- package/src/lib/model/ai-site-look.d.ts +10 -1
- package/src/lib/model/ai-site-look.js +14 -3
- package/src/lib/model/ai-site-look.js.map +1 -1
|
@@ -1541,8 +1541,14 @@ const words = (list)=>new Set(list.trim().split(/\s+/));
|
|
|
1541
1541
|
]
|
|
1542
1542
|
});
|
|
1543
1543
|
}
|
|
1544
|
+
/**
|
|
1545
|
+
* Words that say a picture is one of a set, never what it shows (AGL-3923):
|
|
1546
|
+
* the beta.266 Mexicano portfolio's gallery was "Project one" to "Project
|
|
1547
|
+
* four", and searched "project" (students at a whiteboard), "project four"
|
|
1548
|
+
* (lavender) and "four" (a running track's lane numbers).
|
|
1549
|
+
*/ const PLACEHOLDER_SUBJECTS = words('project projects piece pieces item items example examples sample samples entry entries untitled work works ' + 'selected recent latest ' + 'four five six seven eight nine ten first second third fourth fifth sixth seventh eighth ninth tenth');
|
|
1544
1550
|
/** A phrase's content words without its filler; all filler, and nothing is left. */ function subjectOf(list) {
|
|
1545
|
-
return list.filter((word)=>!FILLER.has(word));
|
|
1551
|
+
return list.filter((word)=>!FILLER.has(word) && !PLACEHOLDER_SUBJECTS.has(word));
|
|
1546
1552
|
}
|
|
1547
1553
|
/**
|
|
1548
1554
|
* A picture's subject in a few words (AGL-3660): the noun phrase its alt
|
|
@@ -3438,6 +3444,16 @@ const EXTENSIONS = {
|
|
|
3438
3444
|
broad: [
|
|
3439
3445
|
'artist studio',
|
|
3440
3446
|
'creative workspace'
|
|
3447
|
+
],
|
|
3448
|
+
// "Artist" names a bee and a tattooist as often as a painter (AGL-3923):
|
|
3449
|
+
// the beta.266 Mexicano hero's first pick was "artist bee, giant artist bee".
|
|
3450
|
+
shunLead: [
|
|
3451
|
+
'bee',
|
|
3452
|
+
'insect',
|
|
3453
|
+
'insects',
|
|
3454
|
+
'tattoo',
|
|
3455
|
+
'makeup',
|
|
3456
|
+
'cosmetics'
|
|
3441
3457
|
]
|
|
3442
3458
|
},
|
|
3443
3459
|
studio: {
|
|
@@ -3789,7 +3805,7 @@ const EXTENSIONS = {
|
|
|
3789
3805
|
}
|
|
3790
3806
|
/** What a kind of site's pictures are searched and judged by ({@link KIND_SUBJECTS}); `null` for a kind not listed. */ export function aiStockKindTerms(kind) {
|
|
3791
3807
|
var _entry_broad;
|
|
3792
|
-
var _entry_kin;
|
|
3808
|
+
var _entry_kin, _entry_shunLead;
|
|
3793
3809
|
const entry = KIND_SUBJECTS[kind];
|
|
3794
3810
|
if (!entry) return null;
|
|
3795
3811
|
const base = aiStockSiteTerms(entry.subject);
|
|
@@ -3812,7 +3828,14 @@ const EXTENSIONS = {
|
|
|
3812
3828
|
...kin
|
|
3813
3829
|
])
|
|
3814
3830
|
]
|
|
3815
|
-
})
|
|
3831
|
+
}, ((_entry_shunLead = entry.shunLead) == null ? void 0 : _entry_shunLead.length) ? {
|
|
3832
|
+
shunLead: [
|
|
3833
|
+
...new Set([
|
|
3834
|
+
...base.shunLead,
|
|
3835
|
+
...entry.shunLead.map(aiStockStem)
|
|
3836
|
+
])
|
|
3837
|
+
]
|
|
3838
|
+
} : {});
|
|
3816
3839
|
}
|
|
3817
3840
|
/**
|
|
3818
3841
|
* The kind of site each starter is the shape of (`AiSiteKind.starter`): what
|
|
@@ -3824,38 +3847,142 @@ const EXTENSIONS = {
|
|
|
3824
3847
|
portfolio: 'portfolio',
|
|
3825
3848
|
landing: 'landing'
|
|
3826
3849
|
};
|
|
3850
|
+
const OFFICE = {
|
|
3851
|
+
kin: [
|
|
3852
|
+
'office',
|
|
3853
|
+
'workspace',
|
|
3854
|
+
'desk',
|
|
3855
|
+
'laptop',
|
|
3856
|
+
'computer',
|
|
3857
|
+
'meeting',
|
|
3858
|
+
'business',
|
|
3859
|
+
'work',
|
|
3860
|
+
'workplace',
|
|
3861
|
+
'team',
|
|
3862
|
+
'notebook',
|
|
3863
|
+
'coffee',
|
|
3864
|
+
'teamwork',
|
|
3865
|
+
'conference'
|
|
3866
|
+
],
|
|
3867
|
+
broad: [
|
|
3868
|
+
'office workspace',
|
|
3869
|
+
'business meeting',
|
|
3870
|
+
'workspace desk laptop'
|
|
3871
|
+
]
|
|
3872
|
+
};
|
|
3873
|
+
const WORKSPACE = {
|
|
3874
|
+
kin: [
|
|
3875
|
+
'workspace',
|
|
3876
|
+
'desk',
|
|
3877
|
+
'laptop',
|
|
3878
|
+
'notebook',
|
|
3879
|
+
'coffee',
|
|
3880
|
+
'office',
|
|
3881
|
+
'book',
|
|
3882
|
+
'books',
|
|
3883
|
+
'workplace'
|
|
3884
|
+
],
|
|
3885
|
+
broad: [
|
|
3886
|
+
'workspace desk laptop',
|
|
3887
|
+
'notebook coffee desk'
|
|
3888
|
+
]
|
|
3889
|
+
};
|
|
3827
3890
|
/**
|
|
3828
|
-
* The last searches a picture tries, for each
|
|
3829
|
-
* common photos of where
|
|
3830
|
-
* holds many of, held
|
|
3831
|
-
* child, a product
|
|
3832
|
-
|
|
3833
|
-
|
|
3834
|
-
|
|
3891
|
+
* The last searches a picture tries, for each kind of site the guided start
|
|
3892
|
+
* offers (AGL-3923): plain, common photos of where that kind's work happens,
|
|
3893
|
+
* which every library holds many of, held to their own words. Never a face
|
|
3894
|
+
* as the lead, never a child, never a product nor a rival business: a
|
|
3895
|
+
* restaurant's are its tables and plates, never an office. A kind with no set
|
|
3896
|
+
* keeps a slot nothing fits without a photo (AGL-3831).
|
|
3897
|
+
*/ const KIND_GENERIC = {
|
|
3898
|
+
business: OFFICE,
|
|
3899
|
+
trades: {
|
|
3900
|
+
kin: [
|
|
3901
|
+
'tools',
|
|
3902
|
+
'tool',
|
|
3903
|
+
'toolbox',
|
|
3904
|
+
'workbench',
|
|
3905
|
+
'workshop',
|
|
3906
|
+
'construction',
|
|
3907
|
+
'repair',
|
|
3908
|
+
'renovation',
|
|
3909
|
+
'drill',
|
|
3910
|
+
'hammer',
|
|
3911
|
+
'wrench',
|
|
3912
|
+
'roof',
|
|
3913
|
+
'house',
|
|
3914
|
+
'carpentry'
|
|
3915
|
+
],
|
|
3916
|
+
broad: [
|
|
3917
|
+
'tools workbench',
|
|
3918
|
+
'home renovation',
|
|
3919
|
+
'construction tools'
|
|
3920
|
+
]
|
|
3921
|
+
},
|
|
3922
|
+
professional: {
|
|
3835
3923
|
kin: [
|
|
3836
3924
|
'office',
|
|
3837
|
-
'workspace',
|
|
3838
3925
|
'desk',
|
|
3839
|
-
'
|
|
3840
|
-
'
|
|
3926
|
+
'documents',
|
|
3927
|
+
'document',
|
|
3841
3928
|
'meeting',
|
|
3842
|
-
'
|
|
3843
|
-
'
|
|
3929
|
+
'conference',
|
|
3930
|
+
'laptop',
|
|
3844
3931
|
'workplace',
|
|
3845
|
-
'
|
|
3932
|
+
'business',
|
|
3846
3933
|
'notebook',
|
|
3847
|
-
'
|
|
3848
|
-
'
|
|
3849
|
-
'conference'
|
|
3934
|
+
'paperwork',
|
|
3935
|
+
'consulting'
|
|
3850
3936
|
],
|
|
3851
3937
|
broad: [
|
|
3852
|
-
'office
|
|
3938
|
+
'office desk documents',
|
|
3853
3939
|
'business meeting',
|
|
3854
|
-
'
|
|
3940
|
+
'conference room'
|
|
3941
|
+
]
|
|
3942
|
+
},
|
|
3943
|
+
wellness: {
|
|
3944
|
+
kin: [
|
|
3945
|
+
'spa',
|
|
3946
|
+
'massage',
|
|
3947
|
+
'wellness',
|
|
3948
|
+
'relaxation',
|
|
3949
|
+
'relax',
|
|
3950
|
+
'towel',
|
|
3951
|
+
'towels',
|
|
3952
|
+
'candle',
|
|
3953
|
+
'stones',
|
|
3954
|
+
'therapy',
|
|
3955
|
+
'treatment',
|
|
3956
|
+
'aromatherapy'
|
|
3957
|
+
],
|
|
3958
|
+
broad: [
|
|
3959
|
+
'spa stones towel',
|
|
3960
|
+
'massage room',
|
|
3961
|
+
'wellness spa'
|
|
3855
3962
|
]
|
|
3856
3963
|
},
|
|
3857
|
-
|
|
3858
|
-
|
|
3964
|
+
restaurant: {
|
|
3965
|
+
kin: [
|
|
3966
|
+
'restaurant',
|
|
3967
|
+
'table',
|
|
3968
|
+
'dining',
|
|
3969
|
+
'food',
|
|
3970
|
+
'plate',
|
|
3971
|
+
'dish',
|
|
3972
|
+
'meal',
|
|
3973
|
+
'kitchen',
|
|
3974
|
+
'cafe',
|
|
3975
|
+
'dinner',
|
|
3976
|
+
'lunch',
|
|
3977
|
+
'cuisine'
|
|
3978
|
+
],
|
|
3979
|
+
broad: [
|
|
3980
|
+
'restaurant interior',
|
|
3981
|
+
'restaurant table food',
|
|
3982
|
+
'food plate'
|
|
3983
|
+
]
|
|
3984
|
+
},
|
|
3985
|
+
store: {
|
|
3859
3986
|
kin: [
|
|
3860
3987
|
'shop',
|
|
3861
3988
|
'store',
|
|
@@ -3874,7 +4001,6 @@ const EXTENSIONS = {
|
|
|
3874
4001
|
]
|
|
3875
4002
|
},
|
|
3876
4003
|
portfolio: {
|
|
3877
|
-
subject: 'studio',
|
|
3878
4004
|
kin: [
|
|
3879
4005
|
'studio',
|
|
3880
4006
|
'workspace',
|
|
@@ -3884,17 +4010,235 @@ const EXTENSIONS = {
|
|
|
3884
4010
|
'creative',
|
|
3885
4011
|
'sketch',
|
|
3886
4012
|
'drawing',
|
|
3887
|
-
'
|
|
4013
|
+
'paint',
|
|
4014
|
+
'painting',
|
|
4015
|
+
'brush',
|
|
4016
|
+
'brushes',
|
|
4017
|
+
'canvas',
|
|
4018
|
+
'pencil',
|
|
4019
|
+
'pencils',
|
|
3888
4020
|
'paper'
|
|
3889
4021
|
],
|
|
3890
4022
|
broad: [
|
|
4023
|
+
'art supplies',
|
|
4024
|
+
'creative workspace',
|
|
4025
|
+
'art studio'
|
|
4026
|
+
]
|
|
4027
|
+
},
|
|
4028
|
+
studio: {
|
|
4029
|
+
kin: [
|
|
4030
|
+
'design',
|
|
4031
|
+
'studio',
|
|
4032
|
+
'workspace',
|
|
4033
|
+
'desk',
|
|
4034
|
+
'laptop',
|
|
4035
|
+
'sketch',
|
|
4036
|
+
'creative',
|
|
4037
|
+
'office',
|
|
4038
|
+
'drawing',
|
|
4039
|
+
'pencil'
|
|
4040
|
+
],
|
|
4041
|
+
broad: [
|
|
4042
|
+
'design studio workspace',
|
|
3891
4043
|
'creative workspace',
|
|
3892
|
-
'art studio',
|
|
3893
4044
|
'workspace desk laptop'
|
|
3894
4045
|
]
|
|
3895
4046
|
},
|
|
4047
|
+
photography: {
|
|
4048
|
+
kin: [
|
|
4049
|
+
'camera',
|
|
4050
|
+
'cameras',
|
|
4051
|
+
'photography',
|
|
4052
|
+
'lens',
|
|
4053
|
+
'photographer',
|
|
4054
|
+
'studio',
|
|
4055
|
+
'film',
|
|
4056
|
+
'tripod'
|
|
4057
|
+
],
|
|
4058
|
+
broad: [
|
|
4059
|
+
'camera lens',
|
|
4060
|
+
'photography studio',
|
|
4061
|
+
'vintage camera'
|
|
4062
|
+
]
|
|
4063
|
+
},
|
|
4064
|
+
blog: {
|
|
4065
|
+
kin: [
|
|
4066
|
+
'notebook',
|
|
4067
|
+
'desk',
|
|
4068
|
+
'writing',
|
|
4069
|
+
'laptop',
|
|
4070
|
+
'coffee',
|
|
4071
|
+
'journal',
|
|
4072
|
+
'book',
|
|
4073
|
+
'books',
|
|
4074
|
+
'workspace',
|
|
4075
|
+
'pen',
|
|
4076
|
+
'typewriter'
|
|
4077
|
+
],
|
|
4078
|
+
broad: [
|
|
4079
|
+
'writing desk notebook',
|
|
4080
|
+
'laptop coffee desk'
|
|
4081
|
+
]
|
|
4082
|
+
},
|
|
4083
|
+
events: {
|
|
4084
|
+
kin: [
|
|
4085
|
+
'event',
|
|
4086
|
+
'venue',
|
|
4087
|
+
'wedding',
|
|
4088
|
+
'reception',
|
|
4089
|
+
'party',
|
|
4090
|
+
'celebration',
|
|
4091
|
+
'table',
|
|
4092
|
+
'decoration',
|
|
4093
|
+
'banquet',
|
|
4094
|
+
'hall',
|
|
4095
|
+
'flowers'
|
|
4096
|
+
],
|
|
4097
|
+
broad: [
|
|
4098
|
+
'event venue decoration',
|
|
4099
|
+
'banquet table',
|
|
4100
|
+
'party decoration'
|
|
4101
|
+
]
|
|
4102
|
+
},
|
|
4103
|
+
fitness: {
|
|
4104
|
+
kin: [
|
|
4105
|
+
'gym',
|
|
4106
|
+
'fitness',
|
|
4107
|
+
'weights',
|
|
4108
|
+
'dumbbell',
|
|
4109
|
+
'dumbbells',
|
|
4110
|
+
'barbell',
|
|
4111
|
+
'kettlebell',
|
|
4112
|
+
'workout',
|
|
4113
|
+
'exercise',
|
|
4114
|
+
'training'
|
|
4115
|
+
],
|
|
4116
|
+
broad: [
|
|
4117
|
+
'gym equipment',
|
|
4118
|
+
'dumbbells gym',
|
|
4119
|
+
'fitness gym'
|
|
4120
|
+
]
|
|
4121
|
+
},
|
|
4122
|
+
yoga: {
|
|
4123
|
+
kin: [
|
|
4124
|
+
'yoga',
|
|
4125
|
+
'mat',
|
|
4126
|
+
'meditation',
|
|
4127
|
+
'studio',
|
|
4128
|
+
'relaxation',
|
|
4129
|
+
'candle',
|
|
4130
|
+
'zen',
|
|
4131
|
+
'mindfulness'
|
|
4132
|
+
],
|
|
4133
|
+
broad: [
|
|
4134
|
+
'yoga mat',
|
|
4135
|
+
'yoga studio',
|
|
4136
|
+
'meditation candle'
|
|
4137
|
+
]
|
|
4138
|
+
},
|
|
4139
|
+
beauty: {
|
|
4140
|
+
kin: [
|
|
4141
|
+
'salon',
|
|
4142
|
+
'beauty',
|
|
4143
|
+
'hair',
|
|
4144
|
+
'makeup',
|
|
4145
|
+
'cosmetics',
|
|
4146
|
+
'nails',
|
|
4147
|
+
'manicure',
|
|
4148
|
+
'spa',
|
|
4149
|
+
'mirror',
|
|
4150
|
+
'brush',
|
|
4151
|
+
'brushes'
|
|
4152
|
+
],
|
|
4153
|
+
broad: [
|
|
4154
|
+
'beauty salon interior',
|
|
4155
|
+
'makeup brushes cosmetics',
|
|
4156
|
+
'hair salon chair'
|
|
4157
|
+
]
|
|
4158
|
+
},
|
|
4159
|
+
realestate: {
|
|
4160
|
+
kin: [
|
|
4161
|
+
'house',
|
|
4162
|
+
'home',
|
|
4163
|
+
'interior',
|
|
4164
|
+
'living',
|
|
4165
|
+
'room',
|
|
4166
|
+
'property',
|
|
4167
|
+
'architecture',
|
|
4168
|
+
'apartment',
|
|
4169
|
+
'kitchen',
|
|
4170
|
+
'estate'
|
|
4171
|
+
],
|
|
4172
|
+
broad: [
|
|
4173
|
+
'house exterior',
|
|
4174
|
+
'home interior living room',
|
|
4175
|
+
'modern kitchen interior'
|
|
4176
|
+
]
|
|
4177
|
+
},
|
|
4178
|
+
education: {
|
|
4179
|
+
kin: [
|
|
4180
|
+
'classroom',
|
|
4181
|
+
'books',
|
|
4182
|
+
'book',
|
|
4183
|
+
'library',
|
|
4184
|
+
'school',
|
|
4185
|
+
'desk',
|
|
4186
|
+
'education',
|
|
4187
|
+
'learning',
|
|
4188
|
+
'study',
|
|
4189
|
+
'studying',
|
|
4190
|
+
'notebook',
|
|
4191
|
+
'chalkboard',
|
|
4192
|
+
'blackboard',
|
|
4193
|
+
'lecture'
|
|
4194
|
+
],
|
|
4195
|
+
broad: [
|
|
4196
|
+
'library books',
|
|
4197
|
+
'classroom',
|
|
4198
|
+
'study desk books'
|
|
4199
|
+
]
|
|
4200
|
+
},
|
|
4201
|
+
nonprofit: {
|
|
4202
|
+
kin: [
|
|
4203
|
+
'volunteer',
|
|
4204
|
+
'volunteers',
|
|
4205
|
+
'volunteering',
|
|
4206
|
+
'charity',
|
|
4207
|
+
'donation',
|
|
4208
|
+
'donations',
|
|
4209
|
+
'community',
|
|
4210
|
+
'helping',
|
|
4211
|
+
'help',
|
|
4212
|
+
'hands'
|
|
4213
|
+
],
|
|
4214
|
+
broad: [
|
|
4215
|
+
'volunteers charity',
|
|
4216
|
+
'donation box',
|
|
4217
|
+
'community volunteering'
|
|
4218
|
+
]
|
|
4219
|
+
},
|
|
4220
|
+
music: {
|
|
4221
|
+
kin: [
|
|
4222
|
+
'music',
|
|
4223
|
+
'guitar',
|
|
4224
|
+
'piano',
|
|
4225
|
+
'instrument',
|
|
4226
|
+
'instruments',
|
|
4227
|
+
'concert',
|
|
4228
|
+
'stage',
|
|
4229
|
+
'microphone',
|
|
4230
|
+
'drums',
|
|
4231
|
+
'studio',
|
|
4232
|
+
'vinyl'
|
|
4233
|
+
],
|
|
4234
|
+
broad: [
|
|
4235
|
+
'guitar instrument',
|
|
4236
|
+
'concert stage lights',
|
|
4237
|
+
'music studio microphone'
|
|
4238
|
+
]
|
|
4239
|
+
},
|
|
4240
|
+
personal: WORKSPACE,
|
|
3896
4241
|
landing: {
|
|
3897
|
-
subject: 'office',
|
|
3898
4242
|
kin: [
|
|
3899
4243
|
'office',
|
|
3900
4244
|
'workspace',
|
|
@@ -3914,13 +4258,47 @@ const EXTENSIONS = {
|
|
|
3914
4258
|
'workspace desk laptop',
|
|
3915
4259
|
'business meeting'
|
|
3916
4260
|
]
|
|
3917
|
-
}
|
|
4261
|
+
},
|
|
4262
|
+
'coming-soon': WORKSPACE
|
|
4263
|
+
};
|
|
4264
|
+
/** The kind of site whose common photos each starter falls back to. */ const STARTER_GENERIC_KIND = {
|
|
4265
|
+
business: 'business',
|
|
4266
|
+
'physical-shop': 'store',
|
|
4267
|
+
portfolio: 'portfolio',
|
|
4268
|
+
landing: 'landing'
|
|
3918
4269
|
};
|
|
4270
|
+
/** Stems no common photo leads with: a face, a portrait (AGL-3923). */ const FACE_STEMS = [
|
|
4271
|
+
'face',
|
|
4272
|
+
'portrait',
|
|
4273
|
+
'selfie',
|
|
4274
|
+
'headshot'
|
|
4275
|
+
].map(aiStockStem);
|
|
3919
4276
|
/** The starter a kind of site follows ({@link STARTER_KINDS}); a kind not listed follows the business starter. */ function starterOfKind(kind) {
|
|
3920
4277
|
var _ref;
|
|
3921
4278
|
var _aiSiteKind;
|
|
3922
4279
|
const starter = (_ref = (_aiSiteKind = aiSiteKind(kind)) == null ? void 0 : _aiSiteKind.starter) != null ? _ref : 'business';
|
|
3923
|
-
return
|
|
4280
|
+
return STARTER_KINDS[starter] ? starter : 'business';
|
|
4281
|
+
}
|
|
4282
|
+
/** A kind of site's common photos as a world to search and judge by ({@link KIND_GENERIC}); `null` for a kind with no set. */ export function aiStockKindGenericTerms(kind) {
|
|
4283
|
+
const set = KIND_GENERIC[kind];
|
|
4284
|
+
if (!set) return null;
|
|
4285
|
+
const kin = [
|
|
4286
|
+
...new Set(set.kin.map(aiStockStem))
|
|
4287
|
+
];
|
|
4288
|
+
return {
|
|
4289
|
+
business: '',
|
|
4290
|
+
craft: '',
|
|
4291
|
+
domain: kin,
|
|
4292
|
+
broad: [
|
|
4293
|
+
...set.broad
|
|
4294
|
+
],
|
|
4295
|
+
making: [],
|
|
4296
|
+
named: [],
|
|
4297
|
+
rivals: [],
|
|
4298
|
+
core: kin,
|
|
4299
|
+
shun: [],
|
|
4300
|
+
shunLead: []
|
|
4301
|
+
};
|
|
3924
4302
|
}
|
|
3925
4303
|
/**
|
|
3926
4304
|
* Whether a site's world is only its own words (AGL-3923): no craft this
|
|
@@ -3936,24 +4314,46 @@ const EXTENSIONS = {
|
|
|
3936
4314
|
];
|
|
3937
4315
|
return terms.broad.length > 0 && terms.broad.length === own.length && terms.broad.every((query, index)=>query === own[index]);
|
|
3938
4316
|
}
|
|
4317
|
+
/**
|
|
4318
|
+
* Whether a site's world agrees with the kind of site the person picked
|
|
4319
|
+
* (AGL-3923): it was read from the kind, or names one of the kind's own
|
|
4320
|
+
* words. A gym whose owner picked Business & services does not, and is never
|
|
4321
|
+
* given an office.
|
|
4322
|
+
*/ function worldOfKind(terms, kind) {
|
|
4323
|
+
var _ref;
|
|
4324
|
+
var _aiStockKindGenericTerms;
|
|
4325
|
+
const own = aiStockKindTerms(kind);
|
|
4326
|
+
if (!own) return false;
|
|
4327
|
+
if (own.craft === terms.craft && own.broad.join('|') === terms.broad.join('|')) return true;
|
|
4328
|
+
const words = new Set([
|
|
4329
|
+
...own.domain,
|
|
4330
|
+
...(_ref = (_aiStockKindGenericTerms = aiStockKindGenericTerms(kind)) == null ? void 0 : _aiStockKindGenericTerms.domain) != null ? _ref : []
|
|
4331
|
+
]);
|
|
4332
|
+
return terms.domain.some((stem)=>words.has(stem));
|
|
4333
|
+
}
|
|
3939
4334
|
/**
|
|
3940
4335
|
* What a picture is searched by once nothing narrower found it a photo
|
|
3941
|
-
* (AGL-3923), widest last
|
|
3942
|
-
*
|
|
3943
|
-
*
|
|
3944
|
-
*
|
|
3945
|
-
*
|
|
3946
|
-
*
|
|
3947
|
-
*
|
|
4336
|
+
* (AGL-3923), widest last.
|
|
4337
|
+
*
|
|
4338
|
+
* - A site whose world is its own words alone ({@link aiStockWorldIsUnlisted})
|
|
4339
|
+
* widens to the kind of site the person picked, the kind its starter is the
|
|
4340
|
+
* shape of, and last the kind's own common photos ({@link KIND_GENERIC}),
|
|
4341
|
+
* else its starter's.
|
|
4342
|
+
* - Any other site widens only to its kind's own common photos, and only
|
|
4343
|
+
* where its world agrees with that kind ({@link worldOfKind}): a portfolio
|
|
4344
|
+
* read from its kind takes art supplies before no photo at all, and a
|
|
4345
|
+
* barbecue caterer whose kind says nothing of food never takes an office
|
|
4346
|
+
* (AGL-3831). A kind with no set keeps a slot nothing fits without a photo.
|
|
4347
|
+
*
|
|
4348
|
+
* A rung that would search what an earlier one did is left out.
|
|
3948
4349
|
*
|
|
3949
4350
|
* The beta.265 Kasvora Marketing Solutions start (job BK3r4I8bF1) typed its
|
|
3950
4351
|
* business as "Freelencing site offer services": its world was the one word
|
|
3951
4352
|
* "freelencing", which no library tags, so its cover hero searched it, found
|
|
3952
4353
|
* nothing, and shipped a flat dark band with no photo.
|
|
3953
4354
|
*/ export function aiStockWiderTerms(terms, kind) {
|
|
3954
|
-
var _STARTER_KINDS_starter;
|
|
4355
|
+
var _STARTER_KINDS_starter, _aiStockKindGenericTerms, _STARTER_GENERIC_KIND_starter;
|
|
3955
4356
|
const rungs = [];
|
|
3956
|
-
if (!aiStockWorldIsUnlisted(terms)) return rungs;
|
|
3957
4357
|
const seen = new Set([
|
|
3958
4358
|
JSON.stringify([
|
|
3959
4359
|
terms.craft,
|
|
@@ -3975,25 +4375,14 @@ const EXTENSIONS = {
|
|
|
3975
4375
|
terms: found
|
|
3976
4376
|
});
|
|
3977
4377
|
};
|
|
4378
|
+
if (!aiStockWorldIsUnlisted(terms)) {
|
|
4379
|
+
if (kind && worldOfKind(terms, kind)) add('generic', aiStockKindGenericTerms(kind));
|
|
4380
|
+
return rungs;
|
|
4381
|
+
}
|
|
3978
4382
|
const starter = starterOfKind(kind);
|
|
3979
4383
|
if (kind) add('kind', aiStockKindTerms(kind));
|
|
3980
4384
|
add('starter', aiStockKindTerms((_STARTER_KINDS_starter = STARTER_KINDS[starter]) != null ? _STARTER_KINDS_starter : 'business'));
|
|
3981
|
-
|
|
3982
|
-
const kin = generic.kin.map(aiStockStem);
|
|
3983
|
-
add('generic', {
|
|
3984
|
-
business: '',
|
|
3985
|
-
craft: '',
|
|
3986
|
-
domain: kin,
|
|
3987
|
-
broad: [
|
|
3988
|
-
...generic.broad
|
|
3989
|
-
],
|
|
3990
|
-
making: [],
|
|
3991
|
-
named: [],
|
|
3992
|
-
rivals: [],
|
|
3993
|
-
core: kin,
|
|
3994
|
-
shun: [],
|
|
3995
|
-
shunLead: []
|
|
3996
|
-
});
|
|
4385
|
+
add('generic', (_aiStockKindGenericTerms = aiStockKindGenericTerms(kind)) != null ? _aiStockKindGenericTerms : aiStockKindGenericTerms((_STARTER_GENERIC_KIND_starter = STARTER_GENERIC_KIND[starter]) != null ? _STARTER_GENERIC_KIND_starter : 'business'));
|
|
3997
4386
|
return rungs;
|
|
3998
4387
|
}
|
|
3999
4388
|
/**
|
|
@@ -4050,6 +4439,7 @@ const EXTENSIONS = {
|
|
|
4050
4439
|
const terms = aiStockSourceTerms(input);
|
|
4051
4440
|
// Where a picture's own world finds nothing, the wider worlds it tries (AGL-3923).
|
|
4052
4441
|
const wider = aiStockWiderTerms(terms, (_input_kind = input.kind) != null ? _input_kind : '');
|
|
4442
|
+
const unlisted = aiStockWorldIsUnlisted(terms);
|
|
4053
4443
|
const proper = aiStockProperWords(input.business);
|
|
4054
4444
|
return async (slots)=>{
|
|
4055
4445
|
var _deps_budgetMs, _input_avoid;
|
|
@@ -4348,6 +4738,7 @@ const EXTENSIONS = {
|
|
|
4348
4738
|
* judged by the world it was asked for. A product, a portrait of the
|
|
4349
4739
|
* business's people and a record's cover keep their own fallbacks.
|
|
4350
4740
|
*/ const widerSearches = (slot, subject, sectionName)=>{
|
|
4741
|
+
var _wider_find;
|
|
4351
4742
|
if (!wider.length || slot.product || slot.people || slot.record) return [];
|
|
4352
4743
|
const part = aiStockSlotPart(slot, sectionName);
|
|
4353
4744
|
const asked = [];
|
|
@@ -4364,15 +4755,21 @@ const EXTENSIONS = {
|
|
|
4364
4755
|
...craftSearches(slot, world)
|
|
4365
4756
|
]);
|
|
4366
4757
|
}
|
|
4367
|
-
|
|
4368
|
-
|
|
4369
|
-
|
|
4370
|
-
|
|
4371
|
-
|
|
4372
|
-
|
|
4373
|
-
|
|
4374
|
-
|
|
4375
|
-
|
|
4758
|
+
const orientation = aiStockOrientation(slot.aspect);
|
|
4759
|
+
const size = slot.role === 'hero' ? {
|
|
4760
|
+
minWidth: 1600
|
|
4761
|
+
} : orientation === 'vertical' ? {
|
|
4762
|
+
minHeight: 900
|
|
4763
|
+
} : {
|
|
4764
|
+
minWidth: 900
|
|
4765
|
+
};
|
|
4766
|
+
// The slot's own words, only where the site's world is its own words
|
|
4767
|
+
// alone, held to the kind's common world (AGL-3923), never to no world:
|
|
4768
|
+
// the beta.267 Brightvale closing band's "ready talk marketing" was
|
|
4769
|
+
// answered with a tin-can telephone, and its pets-and-owners answers
|
|
4770
|
+
// name no office either.
|
|
4771
|
+
const common = (_wider_find = wider.find((rung)=>rung.rung === 'generic')) == null ? void 0 : _wider_find.terms;
|
|
4772
|
+
if (subject && unlisted && common) {
|
|
4376
4773
|
const object = aiStockObjectWord(subject);
|
|
4377
4774
|
const own = [
|
|
4378
4775
|
...new Set([
|
|
@@ -4380,16 +4777,30 @@ const EXTENSIONS = {
|
|
|
4380
4777
|
object
|
|
4381
4778
|
].map(clip).filter(Boolean))
|
|
4382
4779
|
];
|
|
4383
|
-
ask(
|
|
4780
|
+
ask(common, own.map((query)=>_extends({
|
|
4384
4781
|
query,
|
|
4385
4782
|
orientation
|
|
4386
4783
|
}, size, {
|
|
4387
4784
|
subject,
|
|
4388
|
-
strict: true
|
|
4389
|
-
worldless: true
|
|
4785
|
+
strict: true
|
|
4390
4786
|
})));
|
|
4391
4787
|
}
|
|
4392
|
-
|
|
4788
|
+
// The kind's common photos: OF its world among their first tags, never
|
|
4789
|
+
// led by a face, never of a child (AGL-3923).
|
|
4790
|
+
for (const { rung, terms: world } of wider)if (rung === 'generic') ask(world, world.broad.map((query)=>_extends({
|
|
4791
|
+
query: clip(query),
|
|
4792
|
+
orientation
|
|
4793
|
+
}, size, {
|
|
4794
|
+
broad: true,
|
|
4795
|
+
category: world.core
|
|
4796
|
+
}, slot.role === 'hero' ? {
|
|
4797
|
+
first: true
|
|
4798
|
+
} : {
|
|
4799
|
+
leadWorld: true
|
|
4800
|
+
}, {
|
|
4801
|
+
refuse: CHILD_STEMS,
|
|
4802
|
+
refuseLead: FACE_STEMS
|
|
4803
|
+
})));
|
|
4393
4804
|
return asked;
|
|
4394
4805
|
};
|
|
4395
4806
|
// 1. Choose, slot by slot, so the page's choices never collide: each
|