Training LUIS to recognise a job ticket number - microsoft-cognitive

I'm trying to train LUIS to recognise a request for a status update on a job ticket (analogous to a JIRA/GitHub issue ID). The job ticket number will be of the format [Letter S or s][One or more digits]. E.g.:
"What is that status on S344?"
Intent: StatusUpdate
Entity: Ticket = S344
After labelling a number of utterances LUIS can recognise the intent with high confidence, but is never able to identify the Ticket entity, even when I use the exact ticket number I've labelled as the entity in a labelled utterance.
I've also tried adding a Regex feature [sS]{1}\d+, but that doesn't seem to make any difference.
Is there something special I need to do to make this work, or do I just need to persevere adding more training utterances?

I just tried this myself and after 7 utterances, LUIS is recognizing the ticket just fine. What I did was:
Send a couple of utterances
Train
Send a new bunch of utterances (different tickets number and phrases)
Train again
I exported my LUIS App for you (below and here)
{
"luis_schema_version": "1.3.0",
"name": "testticket",
"desc": "",
"culture": "en-us",
"intents": [
{
"name": "None"
},
{
"name": "StatusUpdate"
}
],
"entities": [
{
"name": "Ticket"
}
],
"composites": [],
"bing_entities": [],
"actions": [],
"model_features": [],
"regex_features": [],
"utterances": [
{
"text": "what is that status on s344?",
"intent": "StatusUpdate",
"entities": [
{
"entity": "Ticket",
"startPos": 5,
"endPos": 5
}
]
},
{
"text": "status of s124",
"intent": "StatusUpdate",
"entities": [
{
"entity": "Ticket",
"startPos": 2,
"endPos": 2
}
]
},
{
"text": "what's the status of s4",
"intent": "StatusUpdate",
"entities": []
},
{
"text": "please tell me the status of s4",
"intent": "StatusUpdate",
"entities": [
{
"entity": "Ticket",
"startPos": 6,
"endPos": 6
}
]
},
{
"text": "whats the status of s5",
"intent": "StatusUpdate",
"entities": [
{
"entity": "Ticket",
"startPos": 4,
"endPos": 4
}
]
},
{
"text": "whats the status of s9",
"intent": "StatusUpdate",
"entities": [
{
"entity": "Ticket",
"startPos": 4,
"endPos": 4
}
]
},
{
"text": "please tell me the status of s24",
"intent": "StatusUpdate",
"entities": [
{
"entity": "Ticket",
"startPos": 6,
"endPos": 6
}
]
}
]
}

Related

Here Tour Planning API, facing issue on multiple pickup and multiple delivery on same shift

I am working with a fleet management system. I have a scenario that driver have to go multiple places to pickup and deliver the pickup product in multiple delivery location.
Here i have a scenario like that,
Order 1 - Pickup (P1 time range 10:00AM to 11:00 AM) 10 Product. it has 3 delivery point in different location in any time can be delivered with in shift (D1,D2,D3) all of the picked product will delivered in delivered location .
Order 2 - Pickup (P2 time range 11:00AM to 12:00 PM) 10 Product. it has 3 delivery point in different location in any time can be delivered with in shift (D4,D5,D6) all of the picked product will delivered in delivered location .
Order 3 - Pickup (P3 time range 10:30AM to 11:30 PM) 10 Product. it has 3 delivery point in different location in any time can be delivered with in shift (D7,D8,D9) all of the picked product will delivered in delivered location .
in above scenario we have a restriction that if pickup is not complete then we can't make the delivery of this order like if P1 is not complete then we can't complete D1,D2 or D3.
so our optimized list should be set priority wise. We are getting optimized stop but some time we are getting delivery stop is coming before pickup stop. so we want to prevent this things.
is there any instruction to do this using Here Tour Planning API.
VRP with Multi-Jobs
A multi-job as opposed to a simple job is a job that consists of multiple pickups and deliveries. The specific of such jobs is that they only can be considered as executed when all the tasks inside the job are done, otherwise, none of them will be executed. Also, the sum of demands for pickups and deliveries must be equal. A very common scenario for a multi-job problem could be executing multiple pickups at different locations followed by delivery to a single location.
We can imagine the multi-job VRP in real life as for example a daily routine of a school bus that has to pick up several children at different addresses and deliver them to school. As we can guess, taking the kids back to their homes from the school by the same school bus is a multi-job VRP as well.
Another example of multi-job VRP use in real life is the work of garbage collection companies when a vehicle has to execute several pickups and one delivery within the job (collect garbage from several locations in the city and deliver it to the dump location).
So let’s consider we have a multi-job with several pickups and one delivery in it. Let’s say we need to deliver 3 children to the local school from their specific address via the school bus. Regarding the vehicle, we need it to start and end the shift at one depo, that is at the same location. We specify the routine vehicle constraints like cost, distance, shift time, location, capacity and amount. Note that In the case of a school bus, for example, you may assume your capacity units as people/children.
{
"fleet": {
"types": [
{
"id": "b0130d2f754d",
"profile": "car_1",
"costs": {
"fixed": 5.0,
"distance": 0.007,
"time": 0.002
},
"shifts": [
{
"start": {
"time": "2021-08-27T08:03:00Z",
"location": {
"lat": 52.530971,
"lng": 13.384915
}
},
"end": {
"time": "2021-08-27T16:03:00Z",
"location": {
"lat": 52.48693181589403,
"lng": 13.308748991045801
}
}
}
],
"capacity": [
20
],
"amount": 1
}
],
"profiles": [
{
"type": "car",
"name": "car_1"
}
]
},
Regarding the jobs, in this very case, you can set them depending on your needs. One way is to add all of your pickups as separate jobs and then add a delivery job. The other way is to use a multi-job. In this way, you may add a multi-job with all the pickups and one delivery at the end. Let's build a problem where we would have one multi-job with 3 pickups and 1 delivery to deliver all those pickups in one location.
Problem
{
"fleet": {
"types": [
{
"id": "b0130d2f754d",
"profile": "car_1",
"costs": {
"fixed": 5.0,
"distance": 0.007,
"time": 0.002
},
"shifts": [
{
"start": {
"time": "2021-08-27T08:03:00Z",
"location": {
"lat": 52.530971,
"lng": 13.384915
}
},
"end": {
"time": "2021-08-27T16:03:00Z",
"location": {
"lat": 52.530971,
"lng": 13.384915
}
}
}
],
"capacity": [
30
],
"amount": 1
}
],
"profiles": [
{
"type": "car",
"name": "car_1"
}
]
},
"plan": {
"jobs": [
{
"id": "job_1",
"tasks": {
"pickups": [
{
"places": [
{
"location": {
"lat": 52.47706593757918,
"lng": 13.390815701172201
},
"duration": 660,
"tag": "Address_1"
}
],
"demand": [
1
]
},
{
"places": [
{
"location": {
"lat": 52.473571009931106,
"lng": 13.389035169086807
},
"duration": 1140,
"tag": "Address_2"
}
],
"demand": [
1
]
},
{
"places": [
{
"location": {
"lat": 52.53090538774364,
"lng": 13.384692097156309
},
"duration": 840,
"tag": "Address_3"
}
],
"demand": [
1
]
}
],
"deliveries": [
{
"places": [
{
"location": {
"lat": 52.58919138279804,
"lng": 13.462161100698735
},
"duration": 1020,
"tag": "Address_4"
}
],
"demand": [
3
]
}
]
}
}
]
}
}
Solution
The solution for this problem will look as follows:
{
"statistic": {
"cost": 273.77500000000003,
"distance": 36041,
"duration": 8244,
"times": {
"driving": 4584,
"serving": 3660,
"waiting": 0,
"break": 0
}
},
"tours": [
{
"vehicleId": "b0130d2f754d_1",
"typeId": "b0130d2f754d",
"stops": [
{
"location": {
"lat": 52.530971,
"lng": 13.384915
},
"time": {
"arrival": "2021-08-27T08:03:00Z",
"departure": "2021-08-27T08:03:00Z"
},
"load": [
0
],
"activities": [
{
"jobId": "departure",
"type": "departure"
}
]
},
{
"location": {
"lat": 52.53090538774364,
"lng": 13.384692097156307
},
"time": {
"arrival": "2021-08-27T08:03:02Z",
"departure": "2021-08-27T08:17:02Z"
},
"load": [
1
],
"activities": [
{
"jobId": "job_1",
"type": "pickup",
"jobTag": "Address_3"
}
]
},
{
"location": {
"lat": 52.473571009931106,
"lng": 13.389035169086808
},
"time": {
"arrival": "2021-08-27T08:34:57Z",
"departure": "2021-08-27T08:53:57Z"
},
"load": [
2
],
"activities": [
{
"jobId": "job_1",
"type": "pickup",
"jobTag": "Address_2"
}
]
},
{
"location": {
"lat": 52.47706593757918,
"lng": 13.3908157011722
},
"time": {
"arrival": "2021-08-27T08:54:51Z",
"departure": "2021-08-27T09:05:51Z"
},
"load": [
3
],
"activities": [
{
"jobId": "job_1",
"type": "pickup",
"jobTag": "Address_1"
}
]
},
{
"location": {
"lat": 52.58919138279804,
"lng": 13.462161100698737
},
"time": {
"arrival": "2021-08-27T09:40:21Z",
"departure": "2021-08-27T09:57:21Z"
},
"load": [
0
],
"activities": [
{
"jobId": "job_1",
"type": "delivery",
"jobTag": "Address_4"
}
]
},
{
"location": {
"lat": 52.530971,
"lng": 13.384915
},
"time": {
"arrival": "2021-08-27T10:20:24Z",
"departure": "2021-08-27T10:20:24Z"
},
"load": [
0
],
"activities": [
{
"jobId": "arrival",
"type": "arrival"
}
]
}
],
"statistic": {
"cost": 273.77500000000003,
"distance": 36041,
"duration": 8244,
"times": {
"driving": 4584,
"serving": 3660,
"waiting": 0,
"break": 0
}
}
}
]
}
From this solution we can see that the vehicle starts its way from a depot, after that it executes 3 pickup and 1 delivery multi-job, and arrives back to the depot.
See also the documentation here

Rest request api linkedin

I'm making a request in the api following this documentation and I'm getting the following error
https://learn.microsoft.com/en-us/linkedin/compliance/integrations/groups/group-posts-and-actions?context=linkedin%2Fcompliance%2Fcontext
Request
{
"author": "urn:li:person:123ABC",
"containerEntity": "urn:li:group:123",
"lifecycleState": "PUBLISHED",
"specificContent": {
"com.linkedin.ugc.ShareContent": {
"media": [
{
"description": {
"attributes": [],
"text": "Check out our awesome group!"
},
"status": "READY",
"thumbnails": [],
"title": {
"attributes": [],
"text": "Group Post!"
}
}
],
"shareCommentary": {
"attributes": [],
"text": "Some group text"
}
}
},
"visibility": {
"com.linkedin.ugc.MemberNetworkVisibility": "CONTAINER"
}
}
response
Unpermitted fields present in REQUEST_BODY: Data Processing Exception while processing fields [/containerEntity]

"The metric names were not found" when deploying microsoft.insights/metricAlerts

I'm trying to deploy a MetricAlert with my Traffic Manager Profile and I always get {
"Code": "BadRequest",
"Message": "The metric names were not found ."
}
I'm trying to use the Endpoint Status by Endpoint metric and having no luck. Any idea what the correct metric name would be or how I can find it?
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {},
"variables": {},
"resources": [
{
"type": "microsoft.insights/metricAlerts",
"apiVersion": "2018-03-01",
"name": "All-PPE-Endpoints-Down",
"location": "global",
"tags": {
"displayName": "Alert-AllEndpointsDown"
},
"properties": {
"actions": [
{
"actionGroupId": "[resourceId('microsoft.insights/actionGroups', 'TDFFCEmailActionGroup')]"
}
],
"criteria": {
"odata.type": "Microsoft.Azure.Monitor.MultipleResourceMultipleMetricCriteria",
"allOf": [
{
"criterionType": "DynamicThresholdCriterion",
"name": "1st criterion",
"metricName": "Endpoint Status by Endpoint(Platform)",
"dimensions": [],
"operator": "LessThan",
"alertSensitivity": "Medium",
"failingPeriods": {
"numberOfEvaluationPeriods": "4",
"minFailingPeriodsToAlert": "3"
},
"timeAggregation": "Maximum"
}
]
},
"description": "All endpoints are not responding to ping",
"enabled": true,
"evaluationFrequency": "PT5M",
"scopes": [
"/subscriptions/84eba200-00a9-41d3-9916-d63b2e25da02/resourceGroups/tdff5-rg-ppe/providers/Microsoft.Network/trafficManagerProfiles/tdfppegas"
],
"severity": 3,
"windowSize": "PT5M"
}
}
]
}
The metrics documentation webpage which describes all of the built-in metrics can be found here: https://learn.microsoft.com/en-us/azure/azure-monitor/platform/metrics-supported#microsoftnetworktrafficmanagerprofiles
In this case, the key I was looking for was ProbeAgentCurrentEndpointStateByProfileResourceId

LUIS batch testing

I want to batch train my Luis app. My JSON file for batch testing.
[
{
"text": "Wo ist die CMS?",
"intent": "standort",
"entities":
[
{
"entity": "place",
"startPos": 9,
"endPos": 11
}
]
}
]
When I click run, the running icon is there, but nothing happens, even after 5 Minutes. What am I doing wrong? When i run the example file from the LUIS page everything is fine. Example from MS:
[
{
"text": "hey dad, are you hungry?",
"intent": "None",
"entities":
[
{
"entity": "FamilyMember",
"startPos": 4,
"endPos": 6
}
]
},
{
...
}
]

OpenRefine reconciliation service not working - mutliple vs single queries

I have been using OpenRefine 2.6 Beta 1 w/o problems since its release, and later, with the reconciliation service at:
http://reconcile.freebaseapps.com/reconcile
However, in the past fee days, I have not been able to use it all. If I go to the URL:
http://reconcile.freebaseapps.com/
and type the multiple query:
{
"query": "Ford",
"type": "/people/person",
"properties": [
{
"pid": "/people/person/place_of_birth",
"v": "Detroit"
}
]
}
I obtain:
{
"result": [
{
"id": "/m/0j8pb6y",
"name": "Ford",
"type": [
{
"id": "/people/person",
"name": "Person"
},
{
"id": "/common/topic",
"name": "Topic"
},
{
"id": "/geography/mountaineer",
"name": "Mountaineer"
}
],
"notable": [],
"score": 1.1546246,
"match": false
},
{
"id": "/m/01vd3gv",
"name": "Ford",
"type": [
{
"id": "/common/topic",
"name": "Topic"
},
{
"id": "/music/artist",
"name": "Musical Artist"
}
],
"notable": [],
"score": 1.0330245999999998,
"match": false
},
{
"id": "/m/0cmdhzt",
"name": "James Meredith",
"type": [
{
"id": "/common/topic",
"name": "Topic"
},
{
"id": "/people/person",
"name": "Person"
},
{
"id": "/military/military_person",
"name": "Military Person"
},
{
"id": "/people/deceased_person",
"name": "Deceased Person"
}
],
"notable": [],
"score": 0.0681692,
"match": false
}
],
"duration": 369
}
But if I try a simple query:
{
"query": "Ford"
}
I get:
Status: error Error:undefined
Any insights into what's happening with the reconciliation service? Is there any other service I could use to replace freebaseapps.com?
Thanks
Try this in Queries Parameter at http://reconcile.freebaseapps.com/
{
"q0": {
"query": "Ford"
}
}
For some reason, single queries are not accepted in Query Parameter but in Queries Parameter in the format above. I have not tested this in OpenRefine, so you might have to modify it.
I don't know for certain about the date, but Freebase was announced earlier this year as being shutdown by Jun 30, 2015, for some services. Maybe service is intermittent until full shutdown? Sorry, this answer probably doesn't help much.

Resources