Skip to content

Commit b3ca9c4

Browse files
Automatic commit: Move 'cp-aibus-ber-custom-data', 'cp-aibus-ber-swagger-ui' from QA to Production
1 parent ee15ca1 commit b3ca9c4

34 files changed

+168
-24
lines changed

tutorials/cp-aibus-ber-custom-data/cp-aibus-ber-custom-data.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ The core functionality of Business Entity Recognition is to automatically detect
1717

1818
In this tutorial, you will learn how to use the service APIs to create a dataset, upload training data, and submit a training job to finally create your own custom machine learning model to classify any given type of named entity, such as mobile number, first name, last name and address, in the texts you will submit to the service in the next tutorial: [Deploy Model and Get Prediction Results](cp-aibus-ber-custom-deploy).
1919

20+
Check out the tutorial group [Use Pre-Trained Machine Learning Models to Process Unstructured Text](group.cp-aibus-business-entity-detect) to try out the Business Entity Recognition pre-trained machine learning models.
21+
2022
---
2123

2224
[ACCORDION-BEGIN [Step 1: ](Authorize Swagger UI)]

tutorials/cp-aibus-ber-swagger-ui/cp-aibus-ber-swagger-ui.md

Lines changed: 166 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -19,12 +19,14 @@ The core functionality of Business Entity Recognition is to automatically detect
1919

2020
Business Entity Recognition is a customizable machine learning service, but you can also use the following pre-trained machine learning models:
2121

22+
- `sap_address_entity`
2223
- `sap_email_business_entity`
24+
- `sap_generic_entities`
2325
- `sap_invoice_header`
2426

25-
See [Extracted Entities by Pre-trained Model](https://help.sap.com/viewer/b43f8f61368d455793a241d2b10baeb2/SHIP/en-US/7eb1408001564d679adcd3bc4796800f.html)
27+
See [Extracted Entities by Pre-trained Model](https://help.sap.com/docs/Business_Entity_Recognition/b43f8f61368d455793a241d2b10baeb2/7eb1408001564d679adcd3bc4796800f.html) and [Free Service Plan and Trial Account Technical Constraints](https://help.sap.com/docs/Business_Entity_Recognition/b43f8f61368d455793a241d2b10baeb2/c80a45cc7416409eb9bf64667487c375.html).
2628

27-
This tutorial gives you an introduction to the service using a trial account and the available pre-trained machine learning models. If you want to try out the Business Entity Recognition training endpoints to create your own model, go to the next tutorial [Detect and Highlight Entities from Unstructured Text with Custom Models](cp-aibus-ber-swagger-ui-custom).
29+
This tutorial gives you an introduction to the service using a trial account and the available pre-trained machine learning models. If you want to try out the Business Entity Recognition training endpoints to create your own model, check out the tutorial group [Use Custom Machine Learning Models to Process Unstructured Text](group.cp-aibus-business-entity-custom).
2830

2931
---
3032

@@ -40,73 +42,143 @@ In the service key you created for Business Entity Recognition in the previous t
4042

4143
2. To be able to use the Swagger UI endpoints, you need to authorize yourself. In the top right corner, click **Authorize**.
4244

43-
!![BER](png-files/swagger0.png)
45+
!![BER](png-files/swagger.png)
4446

4547
3. Get the `access_token` value created in the previous tutorial: [Get OAuth Access Token for Business Entity Recognition Using Any Web Browser](cp-aibus-ber-web-oauth-token), then add **bearer** in front of it, and enter in the **Value** field.
4648

4749
```
4850
bearer <access_token>
4951
```
5052
51-
!![BER](png-files/Authorize.png)
53+
!![BER](png-files/authorize.png)
5254
5355
4. Click **Authorize** and then click **Close**.
5456
55-
!![BER](png-files/Authorize2.png)
57+
!![BER](png-files/close.png)
5658
5759
[VALIDATE_1]
5860
[ACCORDION-END]
5961
6062
61-
[ACCORDION-BEGIN [Step 2: ](Post inference result with sap_email_business_entity)]
63+
[ACCORDION-BEGIN [Step 2: ](Enter inference text for sap_address_entity)]
6264
6365
Use the **POST /inference/jobs** endpoint to submit the text to be extracted and choose the pre-trained machine learning model you want to use to extract entities from the text.
6466
6567
1. Click the endpoint name to expand it.
6668
6769
2. Click **Try it out**.
6870
69-
!![BER](png-files/post-1.png)
71+
!![BER](png-files/post-try.png)
72+
73+
3. In **payload**, enter the `text` you want to extract named entities from, `modelName`, and `modelVersion`. In this `sap_address_entity` pre-trained model example, you can use the following:
74+
75+
```JSON
76+
{
77+
"text":"Warehouse 02 (UK) Ltd c/o Excel Logistics Waindyke Way WF6 1TF. West Yorkshire United Kingdom.",
78+
"modelName":"sap_address_entity",
79+
"modelVersion":2
80+
}
81+
```
82+
83+
4. Click **Execute**.
84+
85+
!![BER](png-files/post-address-payload.png)
86+
87+
5. Copy the **`id`** from the **Response body** to see the result of the extraction in the next step.
88+
89+
!![BER](png-files/post-address-id.png)
90+
91+
[DONE]
92+
[ACCORDION-END]
93+
94+
95+
[ACCORDION-BEGIN [Step 3: ](Get inference response from sap_address_entity)]
96+
97+
Use the **GET /inference/jobs/{`jobId`}** endpoint to see the text extraction results and the confidence level of the `sap_address_entity` model.
98+
99+
1. Click the endpoint name to expand it.
100+
101+
2. Click **Try it out**.
102+
103+
!![BER](png-files/get-try.png)
104+
105+
3. Enter the `jobId` obtained in the previous step and click **Execute**.
106+
107+
!![BER](png-files/get-address-id.png)
108+
109+
You should receive a response like the following:
110+
111+
!![BER](png-files/get-address-response.png)
112+
113+
In the response, you will find the prediction for the extracted entities. The prediction is made with a probability indicated by the **confidence** field which represents how certain the model is about the value provided. A confidence of 1 means that the model is 100% sure about its prediction.
114+
115+
You have now successfully used the `sap_address_entity` model to get text entity predictions for the unstructured text you submitted to Business Entity Recognition.
116+
117+
You can also use the following **payload** example with the `sap_address_entity` model:
118+
119+
```JSON
120+
{
121+
"text":"STAG GmbH Beriiner Chaussee 29, 39307 Genthin Logistik / Einkauf Tel.: 039 33/821 - 223 Fax: 039 33/ 821 - 259.",
122+
"modelName":"sap_address_entity",
123+
"modelVersion":2
124+
}
125+
```
126+
127+
To try out the `sap_address_entity` model with your own unstructured text, keep in mind the model scope and supported languages, as detailed in [`sap_address_entity`](https://help.sap.com/docs/Business_Entity_Recognition/b43f8f61368d455793a241d2b10baeb2/55ab2ca0f9064aefbc1425246a1b3d1f.html) and [Supported Languages](https://help.sap.com/docs/Business_Entity_Recognition/b43f8f61368d455793a241d2b10baeb2/e710add9d4d743958a3d21b82b3f220d.html).
128+
129+
[DONE]
130+
[ACCORDION-END]
131+
132+
133+
[ACCORDION-BEGIN [Step 4: ](Enter inference text for sap_email_business_entity)]
134+
135+
Use the **POST /inference/jobs** endpoint to submit the text to be extracted and choose the pre-trained machine learning model you want to use to extract entities from the text.
136+
137+
1. Click the endpoint name to expand it.
138+
139+
2. Click **Try it out**.
140+
141+
!![BER](png-files/post-try.png)
70142

71143
3. In **payload**, enter the `text` you want to extract named entities from, `modelName`, and `modelVersion`. In this `sap_email_business_entity` pre-trained model example, you can use the following:
72144

73145
```JSON
74146
{
75147
"text":"11577210 - FAGOR EDERLAN MEXICO § Dear colleagues, there any way to identify which procurement division has transmitted 1339846 this payment to ABC Ltd. as there is no identification number. Are you able to help? Thank you: Doe, Jane <[email protected]>: 15 May 2019 15:25 To: Doe, John <[email protected]>Cc: Smith, John <[email protected]>: /432216153 328,439.24 Thanks and best Jane. Doe, Jane. Accountant, Procurement Department, Doe Company, S. L. P.Phone+52 444 880 2300. 1114 Doe Company<doe-company.com>",
76148
"modelName":"sap_email_business_entity",
77-
"modelVersion":1
149+
"modelVersion":2
78150
}
79151
```
80152

81153
4. Click **Execute**.
82154

83-
!![BER](png-files/post-2.png)
155+
!![BER](png-files/post-email-payload.png)
84156

85157
5. Copy the **`id`** from the **Response body** to see the result of the extraction in the next step.
86158

87-
!![BER](png-files/post-3.png)
159+
!![BER](png-files/post-email-id.png)
88160

89161
[DONE]
90162
[ACCORDION-END]
91163

92164

93-
[ACCORDION-BEGIN [Step 3: ](Get inference result with sap_email_business_entity)]
165+
[ACCORDION-BEGIN [Step 5: ](Get inference response from sap_email_business_entity)]
94166

95167
Use the **GET /inference/jobs/{`jobId`}** endpoint to see the text extraction results and the confidence level of the `sap_email_business_entity` model.
96168

97169
1. Click the endpoint name to expand it.
98170

99171
2. Click **Try it out**.
100172

101-
!![BER](png-files/get-1.png)
173+
!![BER](png-files/get-try.png)
102174

103175
3. Enter the `jobId` obtained in the previous step and click **Execute**.
104176

105-
!![BER](png-files/get-2.png)
177+
!![BER](png-files/get-email-id.png)
106178

107179
You should receive a response like the following:
108180

109-
!![BER](png-files/get-3.png)
181+
!![BER](png-files/get-email-response.png)
110182

111183
In the response, you will find the prediction for the extracted entities. The prediction is made with a probability indicated by the **confidence** field which represents how certain the model is about the value provided. A confidence of 1 means that the model is 100% sure about its prediction.
112184

@@ -118,25 +190,95 @@ You can also use the following **payload** example with the `sap_email_business_
118190
{
119191
"text":"Von: lena nova <[email protected]> Gesendet: Montag, 21. Januar 2019, 19:13 Uhr An: canu, ana <[email protected]>; [email protected] Betreff: RE: M & B EOOD 2639710315 Sehr geehrter Kunde, ich sende Ihnen Informationen für unsere Zahlung. Proforma 198305906 ist ein Teil der Rechnung 4830476570 / 11.01.2019. Rechnungsdatum Betrag in EUR 4830473772 14.12.2018 9,28 € 4830474632 21.12.2018 29,16 € 4830475244 28.12.2018 46,19 € 4830475919 4.1.2019 9,28 € 198305906 10.1.2019 9,29 € 103,20 € 4830476570 11.1.2019 37,13 198305906 10.1.2019 -9,29 € 27,84 Einen schönen Tag noch! Mit freundlichen Grüßen, lena lena nova Verkaufsleiterin M & B EOOD-Computer Center 11, Angel Kanchev Str; 1000, Sofia, Bulgarien Tel.: + 359 2 981 58 57; Mobil: + 359 889 61 13 21 E-Mail: [email protected] Besuchen Sie uns unter: www.computercenter.bg",
120192
"modelName":"sap_email_business_entity",
193+
"modelVersion":2
194+
}
195+
```
196+
197+
To try out the `sap_email_business_entity` model with your own unstructured text, keep in mind the model scope and supported languages, as detailed in [`sap_email_business_entity`](https://help.sap.com/docs/Business_Entity_Recognition/b43f8f61368d455793a241d2b10baeb2/8f940cca185144b8baff1fdf31ce2c82.html) and [Supported Languages](https://help.sap.com/docs/Business_Entity_Recognition/b43f8f61368d455793a241d2b10baeb2/e710add9d4d743958a3d21b82b3f220d.html).
198+
199+
[DONE]
200+
[ACCORDION-END]
201+
202+
203+
[ACCORDION-BEGIN [Step 6: ](Enter inference text for sap_generic_entities)]
204+
205+
Use the **POST /inference/jobs** endpoint to submit the text to be extracted and choose the pre-trained machine learning model you want to use to extract entities from the text.
206+
207+
1. Click the endpoint name to expand it.
208+
209+
2. Click **Try it out**.
210+
211+
!![BER](png-files/post-try.png)
212+
213+
3. In **payload**, enter the `text` you want to extract named entities from, `modelName`, and `modelVersion`. In this `sap_generic_entities` pre-trained model example, you can use the following:
214+
215+
```JSON
216+
{
217+
"text":"In 1988, 31.6% of blacks lived in poverty, compared with 10.1% for whites and 26.8% for Hispanics.",
218+
"modelName":"sap_generic_entities",
219+
"modelVersion":1
220+
}
221+
```
222+
223+
4. Click **Execute**.
224+
225+
!![BER](png-files/post-generic-payload.png)
226+
227+
5. Copy the **`id`** from the **Response body** to see the result of the extraction in the next step.
228+
229+
!![BER](png-files/post-generic-id.png)
230+
231+
[DONE]
232+
[ACCORDION-END]
233+
234+
235+
[ACCORDION-BEGIN [Step 7: ](Get inference response from sap_generic_entities)]
236+
237+
Use the **GET /inference/jobs/{`jobId`}** endpoint to see the text extraction results and the confidence level of the `sap_generic_entities` model.
238+
239+
1. Click the endpoint name to expand it.
240+
241+
2. Click **Try it out**.
242+
243+
!![BER](png-files/get-try.png)
244+
245+
3. Enter the `jobId` obtained in the previous step and click **Execute**.
246+
247+
!![BER](png-files/get-generic-id.png)
248+
249+
You should receive a response like the following:
250+
251+
!![BER](png-files/get-generic-response.png)
252+
253+
In the response, you will find the prediction for the extracted entities. The prediction is made with a probability indicated by the **confidence** field which represents how certain the model is about the value provided. A confidence of 1 means that the model is 100% sure about its prediction.
254+
255+
You have now successfully used the `sap_generic_entities` model to get text entity predictions for the unstructured text you submitted to Business Entity Recognition.
256+
257+
You can also use the following **payload** example with the `sap_generic_entities` model:
258+
259+
```JSON
260+
{
261+
"text":"Sie liegt sechs Kilometer nordöstlich des Stadtzentrums von Pardubice und gehört zum Okres Pardubice.",
262+
"modelName":"sap_generic_entities",
121263
"modelVersion":1
122264
}
123265
```
124266

125-
To try out the `sap_email_business_entity` model with your own unstructured text, keep in mind the model scope and supported languages, as detailed in [Extracted Entities by Pre-trained Model](https://help.sap.com/viewer/b43f8f61368d455793a241d2b10baeb2/SHIP/en-US/7eb1408001564d679adcd3bc4796800f.html).
267+
To try out the `sap_generic_entities` model with your own unstructured text, keep in mind the model scope and supported languages, as detailed in [`sap_generic_entities`](https://help.sap.com/docs/Business_Entity_Recognition/b43f8f61368d455793a241d2b10baeb2/d1cc656813fa4737a5df3aa131bed338.html) and [Supported Languages](https://help.sap.com/docs/Business_Entity_Recognition/b43f8f61368d455793a241d2b10baeb2/e710add9d4d743958a3d21b82b3f220d.html).
126268

127269
[DONE]
128270
[ACCORDION-END]
129271

130272

131-
[ACCORDION-BEGIN [Step 4: ](Post inference result with sap_invoice_header)]
273+
[ACCORDION-BEGIN [Step 8: ](Enter inference text for sap_invoice_header)]
132274

133275
Use the **POST /inference/jobs** endpoint to submit the text to be extracted and choose the pre-trained machine learning model you want to use to extract entities from the text.
134276

135277
1. Click the endpoint name to expand it.
136278

137279
2. Click **Try it out**.
138280

139-
!![BER](png-files/post-1.png)
281+
!![BER](png-files/post-try.png)
140282

141283
3. In **payload**, enter the `text` you want to extract named entities from, `modelName`, and `modelVersion`. In this `sap_invoice_header` pre-trained model example, you can use the following:
142284

@@ -150,33 +292,33 @@ Use the **POST /inference/jobs** endpoint to submit the text to be extracted and
150292

151293
4. Click **Execute**.
152294

153-
!![BER](png-files/post-22.png)
295+
!![BER](png-files/post-invoice-payload.png)
154296

155297
5. Copy the **`id`** from the **Response body** to see the result of the extraction in the next step.
156298

157-
!![BER](png-files/post-33.png)
299+
!![BER](png-files/post-invoice-id.png)
158300

159301
[DONE]
160302
[ACCORDION-END]
161303

162304

163-
[ACCORDION-BEGIN [Step 5: ](Get inference result with sap_invoice_header)]
305+
[ACCORDION-BEGIN [Step 9: ](Get inference response from sap_invoice_header)]
164306

165307
Use the **GET /inference/jobs/{`jobId`}** endpoint to see the text extraction results and the confidence level of the `sap_invoice_header` model.
166308

167309
1. Click the endpoint name to expand it.
168310

169311
2. Click **Try it out**.
170312

171-
!![BER](png-files/get-1.png)
313+
!![BER](png-files/get-try.png)
172314

173315
3. Enter the `jobId` obtained in the previous step and click **Execute**.
174316

175-
!![BER](png-files/get-22.png)
317+
!![BER](png-files/get-invoice-id.png)
176318

177319
You should receive a response like the following:
178320

179-
!![BER](png-files/get-33.png)
321+
!![BER](png-files/get-invoice-response.png)
180322

181323
You have now successfully used the `sap_invoice_header` model to get text entity predictions for the unstructured text you submitted to Business Entity Recognition.
182324

@@ -190,7 +332,7 @@ You can also use the following **payload** example with the `sap_invoice_header`
190332
}
191333
```
192334

193-
To try out the `sap_invoice_header` model with your own unstructured text, keep in mind the model scope and supported languages, as detailed in [Extracted Entities by Pre-trained Model](https://help.sap.com/viewer/b43f8f61368d455793a241d2b10baeb2/SHIP/en-US/7eb1408001564d679adcd3bc4796800f.html).
335+
To try out the `sap_invoice_header` model with your own unstructured text, keep in mind the model scope and supported languages, as detailed in [`sap_invoice_header`](https://help.sap.com/docs/Business_Entity_Recognition/b43f8f61368d455793a241d2b10baeb2/cb6a6a5b1ad94096a6e1060460d9fcd8.html) and [Supported Languages](https://help.sap.com/docs/Business_Entity_Recognition/b43f8f61368d455793a241d2b10baeb2/e710add9d4d743958a3d21b82b3f220d.html).
194336

195337
Congratulations, you have completed this tutorial.
196338

Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Binary file not shown.

0 commit comments

Comments
 (0)