wipo-gbd-transformation 1.1.47__py3-none-any.whl → 1.1.59__py3-none-any.whl
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.
Potentially problematic release.
This version of wipo-gbd-transformation might be problematic. Click here for more details.
- gbdtransformation/brands/attm/template.yml +1 -2
- gbdtransformation/brands/bgtm/template.yml +1 -1
- gbdtransformation/brands/catm/filters.py +2 -1
- gbdtransformation/brands/catm/template.yml +10 -6
- gbdtransformation/brands/chtm/filters.py +159 -181
- gbdtransformation/brands/chtm/schema +79 -91
- gbdtransformation/brands/chtm/template.yml +97 -106
- gbdtransformation/brands/eetm/template.yml +1 -1
- gbdtransformation/brands/emtm/template.yml +1 -1
- gbdtransformation/brands/estm/template.yml +1 -1
- gbdtransformation/brands/frtm/template.yml +1 -1
- gbdtransformation/brands/gdtm/__init__.py +5 -0
- gbdtransformation/brands/gdtm/filters.py +61 -0
- gbdtransformation/brands/gdtm/schema +87 -0
- gbdtransformation/brands/gdtm/template.yml +1 -0
- gbdtransformation/brands/gdtm/tests/__init__.py +0 -0
- gbdtransformation/brands/istm/filters.py +21 -14
- gbdtransformation/brands/istm/template.yml +1 -1
- gbdtransformation/brands/krtm/template.yml +1 -1
- gbdtransformation/brands/lktm/__init__.py +5 -0
- gbdtransformation/brands/lktm/filters.py +83 -0
- gbdtransformation/brands/lktm/schema +87 -0
- gbdtransformation/brands/lktm/template.yml +1 -0
- gbdtransformation/brands/lktm/tests/__init__.py +0 -0
- gbdtransformation/brands/natm/__init__.py +2 -3
- gbdtransformation/brands/natm/filters.py +8 -2
- gbdtransformation/brands/notm/__init__.py +5 -0
- gbdtransformation/brands/notm/filters.py +113 -0
- gbdtransformation/brands/notm/template.yml +152 -0
- gbdtransformation/brands/nztm/template.yml +1 -1
- gbdtransformation/brands/phtm/schema +79 -50
- gbdtransformation/brands/phtm/schema.classic +50 -0
- gbdtransformation/brands/phtm/template.classic.yml +102 -0
- gbdtransformation/brands/phtm/template.yml +1 -102
- gbdtransformation/brands/qatm/__init__.py +5 -0
- gbdtransformation/brands/qatm/filters.py +81 -0
- gbdtransformation/brands/qatm/schema +87 -0
- gbdtransformation/brands/qatm/template.yml +1 -0
- gbdtransformation/brands/qatm/tests/__init__.py +0 -0
- gbdtransformation/brands/sgtm/filters.py +1 -1
- gbdtransformation/brands/sgtm/template.trademark.yml +2 -2
- gbdtransformation/brands/ustm/template.yml +1 -1
- gbdtransformation/brands/vctm/__init__.py +5 -0
- gbdtransformation/brands/vctm/filters.py +75 -0
- gbdtransformation/brands/vctm/schema +87 -0
- gbdtransformation/brands/vctm/template.yml +1 -0
- gbdtransformation/brands/vctm/tests/__init__.py +0 -0
- gbdtransformation/brands/vntm/filters.py +1 -3
- gbdtransformation/brands/xxxx/template.yml +1 -1
- gbdtransformation/designs/__init__.py +8 -0
- gbdtransformation/designs/alid/__init__.py +1 -1
- gbdtransformation/designs/alid/filters.py +14 -1
- gbdtransformation/designs/bnid/__init__.py +5 -0
- gbdtransformation/designs/bnid/filters.py +61 -0
- gbdtransformation/designs/bnid/schema +80 -0
- gbdtransformation/designs/bnid/template.yml +1 -0
- gbdtransformation/designs/bwid/__init__.py +6 -0
- gbdtransformation/designs/bwid/filters.py +64 -0
- gbdtransformation/designs/bwid/schema +101 -0
- gbdtransformation/designs/bwid/template.yml +1 -0
- gbdtransformation/designs/crid/__init__.py +5 -0
- gbdtransformation/designs/crid/filters.py +63 -0
- gbdtransformation/designs/crid/schema +94 -0
- gbdtransformation/designs/crid/template.yml +1 -0
- gbdtransformation/designs/cuid/__init__.py +5 -0
- gbdtransformation/designs/cuid/filters.py +60 -0
- gbdtransformation/designs/cuid/schema +98 -0
- gbdtransformation/designs/cuid/template.yml +1 -0
- gbdtransformation/designs/egid/__init__.py +5 -0
- gbdtransformation/designs/egid/filters.py +62 -0
- gbdtransformation/designs/egid/schema +82 -0
- gbdtransformation/designs/egid/template.yml +1 -0
- gbdtransformation/designs/filters.py +73 -0
- gbdtransformation/designs/idid/__init__.py +5 -0
- gbdtransformation/designs/idid/filters.py +67 -0
- gbdtransformation/designs/idid/schema +102 -0
- gbdtransformation/designs/idid/template.yml +1 -0
- gbdtransformation/designs/ipas/filters.py +84 -2
- gbdtransformation/designs/ipas/template.yml +90 -79
- gbdtransformation/designs/joid/__init__.py +6 -0
- gbdtransformation/designs/joid/filters.py +62 -0
- gbdtransformation/designs/joid/schema +97 -0
- gbdtransformation/designs/joid/template.yml +1 -0
- gbdtransformation/designs/keid/__init__.py +5 -0
- gbdtransformation/designs/keid/filters.py +62 -0
- gbdtransformation/designs/keid/schema +99 -0
- gbdtransformation/designs/keid/template.yml +1 -0
- gbdtransformation/designs/khid/__init__.py +5 -0
- gbdtransformation/designs/khid/filters.py +63 -0
- gbdtransformation/designs/khid/schema +100 -0
- gbdtransformation/designs/khid/template.yml +1 -0
- gbdtransformation/designs/laid/__init__.py +5 -0
- gbdtransformation/designs/laid/filters.py +61 -0
- gbdtransformation/designs/laid/schema +94 -0
- gbdtransformation/designs/laid/template.yml +1 -0
- gbdtransformation/designs/mnid/__init__.py +6 -0
- gbdtransformation/designs/mnid/filters.py +62 -0
- gbdtransformation/designs/mnid/schema +98 -0
- gbdtransformation/designs/mnid/template.yml +1 -0
- gbdtransformation/designs/myid/__init__.py +5 -0
- gbdtransformation/designs/myid/filters.py +60 -0
- gbdtransformation/designs/myid/schema +95 -0
- gbdtransformation/designs/myid/template.yml +1 -0
- gbdtransformation/designs/phid/__init__.py +5 -0
- gbdtransformation/designs/phid/filters.py +70 -0
- gbdtransformation/designs/phid/schema +95 -0
- gbdtransformation/designs/phid/template.yml +1 -0
- gbdtransformation/designs/sgid/__init__.py +6 -0
- gbdtransformation/designs/sgid/filters.py +66 -0
- gbdtransformation/designs/sgid/schema +115 -0
- gbdtransformation/designs/sgid/template.yml +1 -0
- gbdtransformation/designs/thid/__init__.py +4 -0
- gbdtransformation/designs/thid/filters.py +64 -0
- gbdtransformation/designs/thid/schema +98 -0
- gbdtransformation/designs/thid/template.yml +1 -0
- gbdtransformation/designs/tnid/__init__.py +5 -0
- gbdtransformation/designs/tnid/filters.py +66 -0
- gbdtransformation/designs/tnid/schema +96 -0
- gbdtransformation/designs/tnid/template.yml +1 -0
- gbdtransformation/designs/vnid/__init__.py +5 -0
- gbdtransformation/designs/vnid/filters.py +62 -0
- gbdtransformation/designs/vnid/schema +97 -0
- gbdtransformation/designs/vnid/template.yml +1 -0
- gbdtransformation/designs/woid/__init__.py +2 -0
- gbdtransformation/designs/woid/filters.py +372 -0
- gbdtransformation/designs/woid/schema +592 -0
- gbdtransformation/designs/woid/template.yml +516 -0
- gbdtransformation/designs/xxid/template.yml +331 -119
- gbdtransformation/execs-nico.py +709 -0
- gbdtransformation/execs.py +55 -4
- gbdtransformation/gbd-transform.exec.tgz +0 -0
- {wipo_gbd_transformation-1.1.47.dist-info → wipo_gbd_transformation-1.1.59.dist-info}/METADATA +4 -1
- {wipo_gbd_transformation-1.1.47.dist-info → wipo_gbd_transformation-1.1.59.dist-info}/RECORD +138 -38
- wipo_gbd_transformation-1.1.59.dist-info/SOURCES_Stefans-Mac-Studio.local_Sep-18-063455-2024_Conflict.txt +690 -0
- {wipo_gbd_transformation-1.1.47.dist-info → wipo_gbd_transformation-1.1.59.dist-info}/entry_points.txt +1 -0
- {wipo_gbd_transformation-1.1.47.dist-info → wipo_gbd_transformation-1.1.59.dist-info}/LICENSE.md +0 -0
- {wipo_gbd_transformation-1.1.47.dist-info → wipo_gbd_transformation-1.1.59.dist-info}/WHEEL +0 -0
- {wipo_gbd_transformation-1.1.47.dist-info → wipo_gbd_transformation-1.1.59.dist-info}/top_level.txt +0 -0
|
@@ -8,12 +8,11 @@
|
|
|
8
8
|
|
|
9
9
|
st13: {{ mark.Anmeldenummer | st13("AT", appdate=appyear) }}
|
|
10
10
|
registrationOfficeCode: AT
|
|
11
|
-
|
|
11
|
+
type: TRADEMARK
|
|
12
12
|
gbdStatus: {{ gstatus }}
|
|
13
13
|
|
|
14
14
|
{% if not gstatus == 'Delete' %}
|
|
15
15
|
|
|
16
|
-
type: TRADEMARK
|
|
17
16
|
kind:
|
|
18
17
|
- Individual
|
|
19
18
|
markFeature: {{ feature }}
|
|
@@ -7,9 +7,9 @@
|
|
|
7
7
|
st13: {{ TradeMark.ApplicationNumber | st13('BG') }}
|
|
8
8
|
gbdStatus: {{ status }}
|
|
9
9
|
registrationOfficeCode: BG
|
|
10
|
+
type: TRADEMARK
|
|
10
11
|
|
|
11
12
|
{% if not status == 'Delete' %}
|
|
12
|
-
type: TRADEMARK
|
|
13
13
|
kind: {{ TradeMark.KindMark | translate_kind }}
|
|
14
14
|
markFeature: {{ TradeMark.MarkFeature | translate_feature }}
|
|
15
15
|
designatedCountries:
|
|
@@ -193,8 +193,9 @@ def translate_feature(feature):
|
|
|
193
193
|
if feature == 'Olfactory': return 'Olfactory'
|
|
194
194
|
if feature == 'Hologram': return 'Hologram'
|
|
195
195
|
if feature == 'Other': return 'Other'
|
|
196
|
+
if feature == 'Design': return 'Combined'
|
|
196
197
|
|
|
197
|
-
|
|
198
|
+
return 'Unknown'
|
|
198
199
|
|
|
199
200
|
def get_mark_names(word_mark_spec):
|
|
200
201
|
verbal = word_mark_spec.MarkVerbalElementText
|
|
@@ -9,9 +9,9 @@
|
|
|
9
9
|
st13: {{ appnum | st13('CA', appdate=trademark.ApplicationDate, type=type) }}
|
|
10
10
|
gbdStatus: {{ status }}
|
|
11
11
|
registrationOfficeCode: {{ trademark.RegistrationOfficeCode }}
|
|
12
|
+
type: {{ type }}
|
|
12
13
|
|
|
13
14
|
{% if not status == 'Delete' %}
|
|
14
|
-
type: {{ type }}
|
|
15
15
|
kind:
|
|
16
16
|
- {{ kind }}
|
|
17
17
|
|
|
@@ -52,17 +52,21 @@ markDescriptionDetails:
|
|
|
52
52
|
text: {{ description.__value }}
|
|
53
53
|
{% endcall %}
|
|
54
54
|
|
|
55
|
-
|
|
55
|
+
|
|
56
56
|
wordMarkSpecification:
|
|
57
|
-
{%
|
|
57
|
+
{% call(wspec) match('IndexHeadingBag.IndexHeading', trademark) %}
|
|
58
58
|
markVerbalElement:
|
|
59
|
-
- languageCode: {{
|
|
60
|
-
text: {{
|
|
59
|
+
- languageCode: {{ wspec.IndexHeadingText | guess_language(trademark.ApplicationLanguageCode) }}
|
|
60
|
+
text: {{ wspec.IndexHeadingText }}
|
|
61
|
+
{% endcall %}
|
|
62
|
+
{% call(wspec) match('MarkRepresentation.MarkReproduction.WordMarkSpecification', trademark) %}
|
|
63
|
+
{% set (verbal, signif) = wspec | get_mark_names %}
|
|
61
64
|
markSignificantVerbalElement:
|
|
62
65
|
- languageCode: {{ signif | guess_language(trademark.ApplicationLanguageCode) }}
|
|
63
66
|
text: {{ signif }}
|
|
64
67
|
markTransliteration: {{ wspec.MarkTransliteration }}
|
|
65
|
-
{% endcall %}
|
|
68
|
+
{% endcall %}
|
|
69
|
+
|
|
66
70
|
|
|
67
71
|
markImageDetails:
|
|
68
72
|
{% call(img) match('MarkRepresentation.MarkReproduction.MarkImageBag.MarkImage', trademark) %}
|
|
@@ -1,183 +1,161 @@
|
|
|
1
1
|
import re
|
|
2
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
|
-
|
|
86
|
-
'
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
if
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
raise Exception('Status "%s" unmapped' % status)
|
|
164
|
-
|
|
165
|
-
def translate_feature(feature, marart):
|
|
166
|
-
if feature == '1': return 'Word'
|
|
167
|
-
if feature == '2': return 'Figurative'
|
|
168
|
-
if feature == '3': return 'Combined'
|
|
169
|
-
if feature == '4':
|
|
170
|
-
if not marart: return 'Undefined'
|
|
171
|
-
# we do not support multi-value
|
|
172
|
-
# for features. take the first one
|
|
173
|
-
if isinstance(marart.marartn, list):
|
|
174
|
-
marart.marartn = marart.marartn.pop()
|
|
175
|
-
if marart.marartn == '10': return 'Sound'
|
|
176
|
-
if marart.marartn == '11': return 'Three dimensional'
|
|
177
|
-
if marart.marartn == '12': return 'Colour'
|
|
178
|
-
if marart.marartn == '14': return 'Motion'
|
|
179
|
-
if marart.marartn == '15': return 'Position'
|
|
180
|
-
if marart.marartn == '16': return 'Hologram'
|
|
181
|
-
|
|
182
|
-
raise Exception('Feature "%s" unmapped' % feature)
|
|
183
|
-
|
|
3
|
+
# namespaces defined in XML and to be ignored in procecssing
|
|
4
|
+
ignore_namespace = [
|
|
5
|
+
'http://www.wipo.int/standards/XMLSchema/ST96/Common',
|
|
6
|
+
'http://www.oasis-open.org/tables/exchange/1.0',
|
|
7
|
+
'http://www.wipo.int/standards/XMLSchema/ST96/Trademark',
|
|
8
|
+
'http://www.w3.org/2001/XMLSchema-instance',
|
|
9
|
+
'urn:ige:schema:xsd:st96trademarksuperset-1.0.0'
|
|
10
|
+
]
|
|
11
|
+
|
|
12
|
+
def translate_kind(kind):
|
|
13
|
+
if not kind: return ['Individual']
|
|
14
|
+
|
|
15
|
+
if kind == 'Individual mark': return ['Individual']
|
|
16
|
+
if kind == 'Collective mark': return ['Collective']
|
|
17
|
+
|
|
18
|
+
return 'Unknown'
|
|
19
|
+
#raise Exception('kind "%s" is not mapped.' % kind)
|
|
20
|
+
|
|
21
|
+
def translate_status(status):
|
|
22
|
+
if not status: return 'Ended'
|
|
23
|
+
|
|
24
|
+
if status in ['Registered',
|
|
25
|
+
'Registration published']:
|
|
26
|
+
return 'Registered'
|
|
27
|
+
|
|
28
|
+
if status in ['Application published',
|
|
29
|
+
'Application filed',
|
|
30
|
+
'Application opposed',
|
|
31
|
+
'Application accepted']:
|
|
32
|
+
return 'Pending'
|
|
33
|
+
|
|
34
|
+
if status in ['Application refused',
|
|
35
|
+
'Registration cancelled',
|
|
36
|
+
'Application cancelled']:
|
|
37
|
+
return 'Ended'
|
|
38
|
+
|
|
39
|
+
return 'Unknown'
|
|
40
|
+
#raise Exception('Status "%s" unmapped' % status)
|
|
41
|
+
|
|
42
|
+
def translate_feature(feature):
|
|
43
|
+
"""translation of mark feature"""
|
|
44
|
+
if not feature: return 'Undefined'
|
|
45
|
+
feature = feature.upper()
|
|
46
|
+
if feature == 'COMBINED': return 'Combined'
|
|
47
|
+
if feature == 'WORD': return 'Word'
|
|
48
|
+
if feature == 'STYLIZED CHARACTERS': return 'Stylized characters'
|
|
49
|
+
if feature == 'FIGURATIVE': return 'Figurative'
|
|
50
|
+
if feature == 'SOUND': return 'Sound'
|
|
51
|
+
if feature == '_3_D': return 'Three dimensional'
|
|
52
|
+
if feature == '3-D': return 'Three dimensional'
|
|
53
|
+
if feature == 'THREE DIMENSIONAL': return 'Three dimensional'
|
|
54
|
+
if feature == 'POSITION': return 'Position'
|
|
55
|
+
if feature == 'HOLOGRAM': return 'Hologram'
|
|
56
|
+
if feature == 'TRACER': return 'Tracer'
|
|
57
|
+
if feature == 'PATTERN': return 'Pattern'
|
|
58
|
+
if feature == 'OLFACTORY': return 'Olfactory'
|
|
59
|
+
if feature == 'MULTIMEDIA': return 'Multimedia'
|
|
60
|
+
if feature == 'MOTION': return 'Motion'
|
|
61
|
+
return 'Unknown'
|
|
62
|
+
|
|
63
|
+
#return feature.lower().capitalize()
|
|
64
|
+
# raise Exception to recognize unmapped values
|
|
65
|
+
#raise Exception('Feature "%s" unmapped' % feature)
|
|
66
|
+
|
|
67
|
+
def get_registration_nb(trademark, tmstatus):
|
|
68
|
+
if trademark.RegistrationNumber:
|
|
69
|
+
return trademark.RegistrationNumber
|
|
70
|
+
|
|
71
|
+
# default registration number to application number
|
|
72
|
+
# in case none is provided
|
|
73
|
+
if tmstatus in ['Registered', 'Expired']:
|
|
74
|
+
return trademark.ApplicationNumber.ApplicationNumberText
|
|
75
|
+
|
|
76
|
+
def get_goods_services(goods_services):
|
|
77
|
+
nc_gs = {} # classified
|
|
78
|
+
if not goods_services:
|
|
79
|
+
goods_services = []
|
|
80
|
+
|
|
81
|
+
if not isinstance(goods_services, list):
|
|
82
|
+
goods_services = [goods_services]
|
|
83
|
+
|
|
84
|
+
for goods_service in goods_services:
|
|
85
|
+
code = goods_service.ClassNumber
|
|
86
|
+
if code and not code == '0':
|
|
87
|
+
nc_gs[code] = {}
|
|
88
|
+
desc = goods_service.GoodsServicesDescription
|
|
89
|
+
|
|
90
|
+
if hasattr(desc, '__value'):
|
|
91
|
+
terms = desc.__value
|
|
92
|
+
else:
|
|
93
|
+
terms = desc
|
|
94
|
+
|
|
95
|
+
if terms:
|
|
96
|
+
nc_gs[code]['terms'] = terms
|
|
97
|
+
else:
|
|
98
|
+
continue
|
|
99
|
+
|
|
100
|
+
if hasattr(desc, '_languageCode'):
|
|
101
|
+
lang = desc._languageCode
|
|
102
|
+
nc_gs[code]['lang'] = lang.lower()
|
|
103
|
+
|
|
104
|
+
return nc_gs
|
|
105
|
+
|
|
106
|
+
def get_entity_addr(addr):
|
|
107
|
+
if not addr: return None
|
|
108
|
+
return "%s %s %s" % (addr.AddressStreet, addr.AddressCity, addr.AddressPostcode)
|
|
109
|
+
def get_entity_name(name):
|
|
110
|
+
if not name: return
|
|
111
|
+
if name.OrganizationName: return name.OrganizationName
|
|
112
|
+
return "%s %s" % (name.FirstName, name.LastName )
|
|
113
|
+
def get_entity_kind(name):
|
|
114
|
+
if not name: return
|
|
115
|
+
if name.OrganizationName: return 'Legal entity'
|
|
116
|
+
return 'Natural person'
|
|
117
|
+
|
|
118
|
+
def get_full_address(postalStructuredAddress):
|
|
119
|
+
if "AddressLineText" not in postalStructuredAddress:
|
|
120
|
+
return
|
|
121
|
+
result = ""
|
|
122
|
+
first = True
|
|
123
|
+
for addressLineText in postalStructuredAddress["AddressLineText"]:
|
|
124
|
+
if hasattr(addressLineText, '__value'):
|
|
125
|
+
if first:
|
|
126
|
+
first = False
|
|
127
|
+
else:
|
|
128
|
+
result += ", "
|
|
129
|
+
result += addressLineText.__value
|
|
130
|
+
if len(result) == 0:
|
|
131
|
+
return
|
|
132
|
+
else:
|
|
133
|
+
return result.strip()
|
|
134
|
+
|
|
135
|
+
def select_priority_date(priority):
|
|
136
|
+
if priority == None:
|
|
137
|
+
return None
|
|
138
|
+
if "PriorityApplicationFilingDate" in priority:
|
|
139
|
+
return priority["PriorityApplicationFilingDate"]
|
|
140
|
+
elif "PriorityRegistrationDate" in priority:
|
|
141
|
+
return priority["PriorityRegistrationDate"]
|
|
142
|
+
else:
|
|
143
|
+
return None
|
|
144
|
+
|
|
145
|
+
def clean_verbal_element(element_text):
|
|
146
|
+
if element_text == None:
|
|
147
|
+
return None
|
|
148
|
+
element_text = element_text.replace("((fig.))", "")
|
|
149
|
+
return element_text.strip()
|
|
150
|
+
|
|
151
|
+
def local_guess_language(content):
|
|
152
|
+
if content == None:
|
|
153
|
+
return None
|
|
154
|
+
from lingua import Language, LanguageDetectorBuilder
|
|
155
|
+
languages = [Language.ENGLISH, Language.FRENCH, Language.GERMAN, Language.ITALIAN]
|
|
156
|
+
detector = LanguageDetectorBuilder.from_languages(*languages).build()
|
|
157
|
+
language = detector.detect_language_of(content)
|
|
158
|
+
if language:
|
|
159
|
+
return language.iso_code_639_1.name.lower()
|
|
160
|
+
else:
|
|
161
|
+
return "en"
|
|
@@ -1,91 +1,79 @@
|
|
|
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
|
-
______/prirem
|
|
81
|
-
____/regadr
|
|
82
|
-
______/addrrole
|
|
83
|
-
______/nameadd
|
|
84
|
-
________/addrl
|
|
85
|
-
__________/addrll
|
|
86
|
-
________/namel
|
|
87
|
-
__________/namell
|
|
88
|
-
________/nat
|
|
89
|
-
________/plainco
|
|
90
|
-
____/renewalgr
|
|
91
|
-
______/renewalt
|
|
1
|
+
/Trademark
|
|
2
|
+
__/ApplicantBag
|
|
3
|
+
____/Applicant
|
|
4
|
+
______/Contact
|
|
5
|
+
________/Name
|
|
6
|
+
__________/PersonName
|
|
7
|
+
____________/PersonFullName
|
|
8
|
+
________/PostalAddressBag
|
|
9
|
+
__________/PostalAddress
|
|
10
|
+
____________/PostalStructuredAddress
|
|
11
|
+
______________/AddressLineText
|
|
12
|
+
______________/AddressLineText[@sequenceNumber=1]
|
|
13
|
+
______________/CountryCode
|
|
14
|
+
______/LegalEntityName
|
|
15
|
+
__/ApplicationDate
|
|
16
|
+
__/ApplicationNumber
|
|
17
|
+
____/ApplicationNumberText
|
|
18
|
+
__/CHMarkCategory
|
|
19
|
+
__/ExpiryDate
|
|
20
|
+
__/GoodsServicesBag
|
|
21
|
+
____/GoodsServices
|
|
22
|
+
______/ClassDescriptionBag
|
|
23
|
+
________/ClassDescription
|
|
24
|
+
__________/ClassNumber
|
|
25
|
+
__________/GoodsServicesDescriptionText
|
|
26
|
+
______/GoodsServicesClassificationBag
|
|
27
|
+
________/GoodsServicesClassification
|
|
28
|
+
__________/ClassNumber
|
|
29
|
+
__________/ClassificationKindCode
|
|
30
|
+
__/MarkCategory
|
|
31
|
+
__/MarkCurrentStatusCode
|
|
32
|
+
__/MarkRepresentation
|
|
33
|
+
____/MarkFeatureCategory
|
|
34
|
+
____/MarkReproduction
|
|
35
|
+
______/MarkImageBag
|
|
36
|
+
________/MarkImage
|
|
37
|
+
__________/FileName
|
|
38
|
+
__________/MarkImageColourClaimedText
|
|
39
|
+
______/WordMarkSpecification
|
|
40
|
+
________/MarkSignificantVerbalElementText
|
|
41
|
+
__/PriorityBag
|
|
42
|
+
____/Priority
|
|
43
|
+
______/PriorityApplicationFilingDate
|
|
44
|
+
______/PriorityCountryCode
|
|
45
|
+
______/PriorityRegistrationDate
|
|
46
|
+
______/PriorityRegistrationNumber
|
|
47
|
+
__/PublicationBag
|
|
48
|
+
____/Publication
|
|
49
|
+
______/NationalPublication
|
|
50
|
+
________/PublicationCategoryText
|
|
51
|
+
________/PublicationStatusCategory
|
|
52
|
+
________/RegistrationChangeBag
|
|
53
|
+
__________/RegistrationChange
|
|
54
|
+
____________/ChangeDescriptionText
|
|
55
|
+
____________/ChangeText
|
|
56
|
+
______/PublicationDate
|
|
57
|
+
______/PublicationIdentifier
|
|
58
|
+
______/PublicationIdentifier[@officeCode=CH]
|
|
59
|
+
______/PublicationPage
|
|
60
|
+
__/RegistrationDate
|
|
61
|
+
__/RegistrationNumber
|
|
62
|
+
__/RegistrationOfficeCode
|
|
63
|
+
__/RepresentativeBag
|
|
64
|
+
____/Representative
|
|
65
|
+
______/Contact
|
|
66
|
+
________/Name
|
|
67
|
+
__________/PersonName
|
|
68
|
+
____________/PersonFullName
|
|
69
|
+
________/PostalAddressBag
|
|
70
|
+
__________/PostalAddress
|
|
71
|
+
____________/PostalStructuredAddress
|
|
72
|
+
______________/AddressLineText
|
|
73
|
+
______________/AddressLineText[@sequenceNumber=1]
|
|
74
|
+
______________/CountryCode
|
|
75
|
+
______/LegalEntityName
|
|
76
|
+
__/TradeDistinctivenessIndicator
|
|
77
|
+
__/Version
|
|
78
|
+
____/VersionDateTime
|
|
79
|
+
______________________________/TrademarkApplicationType_V7_1.xsd]
|