Correlating request and response data using supervised learning
The example embodiments relate to matching response data to request data. in an embodiment, a method includes retrieving a request and a plurality of responses; generating packed candidates based on the request and the plurality of responses, a given packed candidate in the packed candidates including the request and a subset of the plurality of responses; generating feature vectors corresponding to the packed candidates, a given feature vector in the feature vectors including at least one aggregated feature computed based on the request and one or more corresponding responses in a respective packed candidate; inputting the feature vectors into a machine learning (ML) model, the ML model configured to output predictions corresponding to the feature vectors; selecting a feature vector from the feature vectors based on the predictions; and storing responses associated with the optimal feature vector and the request in a data storage device.
1 . A method comprising:
retrieving, by a processor, a request and a plurality of responses;
filtering, by the processor, the plurality of responses by removing responses having a field value that conflicts with a corresponding field value of the request;
generating, by the processor, packed candidates based on the request and the plurality of responses remaining after the filtering by iteratively computing permutations of responses from the plurality of responses until reaching a threshold number of permutations, a given packed candidate in the packed candidates comprising the request and a subset of the plurality of responses, wherein an aggregate value computed from a numerical field of the responses in the subset satisfies a condition of the request;
generating, by the processor, feature vectors corresponding to the packed candidates, a given feature vector in the feature vectors including at least one synthesized feature computed from fields of both the request and one or more corresponding responses in a respective packed candidate, the at least one synthesized feature comprising a computed temporal difference between a date associated with the request and dates associated with the one or more corresponding responses;
inputting, by the processor, the feature vectors into a machine learning (ML) model trained on previously labeled packed candidates, the ML model configured to output, for each of the feature vectors, a score representing a likelihood that the respective packed candidate accurately bundles the one or more corresponding responses with the request;
selecting, by the processor, a feature vector from the feature vectors having a highest score from the scores output by the ML model; and
storing, by the processor, responses associated with the feature vector and the request in a data storage device.
2 . The method of claim 1 , wherein generating the packed candidates comprises: matching a subset of responses to the request based on a matching rule; and excluding the request and the subset of responses when generating the packed candidates.
3 . The method of claim 1 , wherein computing permutations of responses from the plurality of responses comprises computing permutations less than a fixed permutation size.
4 . The method of claim 1 , wherein inputting the feature vectors into the ML model comprises inputting the feature vectors into a gradient-boosted decision tree.
5 . The method of claim 1 , further comprising: transmitting the responses associated with the feature vector and the request to a user; receiving a response from the user, the response comprising one of a confirmation or rejection of the responses associated with the feature vector and the request; and using the response as a label during training of the ML model.
6 . A non-transitory computer readable storage medium for tangibly storing computer program instructions capable of being executed by a computer processor, the computer program instructions defining steps of:
retrieving a request and a plurality of responses;
filtering the plurality of responses by removing responses having a field value that conflicts with a corresponding field value of the request;
generating packed candidates based on the request and the plurality of responses remaining after the filtering by iteratively computing permutations of responses from the plurality of responses until reaching a threshold number of permutations, a given packed candidate in the packed candidates comprising the request and a subset of the plurality of responses, wherein an aggregate value computed from a numerical field of the responses in the subset satisfies a condition of the request;
generating feature vectors corresponding to the packed candidates, a given feature vector in the feature vectors including at least one synthesized feature computed from fields of both the request and one or more corresponding responses in a respective packed candidate, the at least one synthesized feature comprising a computed temporal difference between a date associated with the request and dates associated with the one or more corresponding responses;
inputting the feature vectors into a machine learning (ML) model trained on previously labeled packed candidates, the ML model configured to output, for each of the feature vectors, a score representing a likelihood that the respective packed candidate accurately bundles the one or more corresponding responses with the request;
selecting a feature vector from the feature vectors having a highest score from the scores output by the ML model; and
storing responses associated with the feature vector and the request in a data storage device.
7 . The non-transitory computer readable storage medium of claim 6 , wherein generating the packed candidates comprises: matching a subset of responses to the request based on a matching rule; and excluding the request and the subset of responses when generating the packed candidates.
8 . The non-transitory computer readable storage medium of claim 6 , wherein computing permutations of responses from the plurality of responses comprises computing permutations less than a fixed permutation size.
9 . The non-transitory computer readable storage medium of claim 6 , wherein inputting the feature vectors into the ML model comprises inputting the feature vectors into a gradient-boosted decision tree.
10 . The non-transitory computer readable storage medium of claim 6 , the steps further comprising: transmitting the responses associated with the feature vector and the request to a user; receiving a response from the user, the response comprising one of a confirmation or rejection of the responses associated with the feature vector and the request; and using the response as a label during training of the ML model.
11 . A device comprising:
a processor configured to:
retrieve a request and a plurality of responses;
filter the plurality of responses by removing responses having a field value that conflicts with a corresponding field value of the request;
generate packed candidates based on the request and the plurality of responses remaining after the filtering by iteratively computing permutations of responses from the plurality of responses until reaching a threshold number of permutations, a given packed candidate in the packed candidates comprising the request and a subset of the plurality of responses, wherein an aggregate value computed from a numerical field of the responses in the subset satisfies a condition of the request;
generate feature vectors corresponding to the packed candidates, a given feature vector in the feature vectors including at least one synthesized feature computed from fields of both the request and one or more corresponding responses in a respective packed candidate, the at least one synthesized feature comprising a computed temporal difference between a date associated with the request and dates associated with the one or more corresponding responses;
input the feature vectors into a machine learning (ML) model trained on previously labeled packed candidates, the ML model configured to output, for each of the feature vectors, a score representing a likelihood that the respective packed candidate accurately bundles the one or more corresponding responses with the request;
select a feature vector from the feature vectors having a highest score from the scores output by the ML model; and
store responses associated with the feature vector and the request in a data storage device.
12 . The device of claim 11 , wherein generating the packed candidates comprises: matching a subset of responses to the request based on a matching rule; and excluding the request and the subset of responses when generating the packed candidates.
13 . The device of claim 11 , wherein computing permutations of responses from the plurality of responses comprises computing permutations less than a fixed permutation size.
14 . The device of claim 11 , wherein inputting the feature vectors into the ML model comprises inputting the feature vectors into a gradient-boosted decision tree.