Supporting database queries using unsupervised vector embedding approaches over unseen data

A computer-implemented method of performing queries using Artificial Intelligence (AI) database embeddings includes the operations of generating a plurality of vector embeddings describing a training data from a database for training a machine learning model. A test vector embedding is generated from the plurality of vector embeddings based on training data for unseen data from one or more rows of the database. One or more vectors from the plurality of vector embeddings describing the training data that are a closest match to the test vector embedding are identified. A task is determined based upon the unseen data. The determined task is performed using the trained machine learning model.

BACKGROUND

Technical Field

The present disclosure generally relates to systems and methods for computer Artificial Intelligence Database (AIDB) queries, and more particularly, to providing AIDB queries using unsupervised vector embeddings.

Description of the Related Art

AI-powered databases use semantic vector representation of relational entities to generate additional types of Structured Query Language (SQL) analytical queries such as cognitive intelligence queries. Cognitive intelligence queries can improve a user's search query by using semantic matching and retrieving relevant information from a plurality of diverse data sets. The semantic vectors used in cognitive intelligence queries are generated from an unstructured representation of the structured relational data. However, in the case of unseen data, which is data that has not been used for training an AIDB model, can only undergo an exploratory analysis. Conventional systems lack an ability to execute any existing cognitive intelligence queries for unseen data.

As client interest grows in the use of AIDB queries, there is a growing need for wider applicability and usefulness of AIDB methodology. For example, there is a desire to support multiple SQL types for functions such as prediction.

SUMMARY

According to one embodiment, a computer-implemented method of performing queries using Artificial Intelligence (AI) database embeddings includes generating a plurality of vector embeddings describing a training data from a database for training a machine learning model. A test vector embedding is generated using the trained plurality of vector embeddings for unseen data including one or more rows of the database. A task is determined based upon the unseen data. The determined task is performed using the trained machine learning model. One or more vectors are identified from the plurality of vector embeddings describing the training data that are a closest match to the test vector embeddings or test vector attributes. This method enables an inference to be made about the unseen data using, for example, a prediction query. In addition, support is provided for a plurality of functions including classification and data imputation. This method can be used with other cognitive intelligence queries including but not limited to similarity, inductive reasoning, and semantic clustering.

According to an embodiment, the training of the machine learning model is unsupervised. The unsupervised training of the machine learning model provides for a way to generate an inference about the unseen data that is more efficient and more accurate than from supervised training. There is an improvement in the processing of unseen data.

According to an embodiment, the generated trained vector embeddings describe the training data for training a machine learning prediction model, the determined task is a prediction task on unseen data, and the method further includes performing the prediction task using the trained machine learning prediction model. The use of the generated trained vector embeddings provides for a more efficient and more accurate prediction model.

According to an embodiment, the determined task that is performed includes filling in missing values in the database. The imputation of missing/null values renders more accurate results.

According to an embodiment, the weighted averages are computed by performing a Modified Best Matching (BM) 25 operation using AIDB specific metrics and a modified average sentence length combined with an Inverse Document Frequency (IDF) to generate weights for token vectors. This embodiment provides an improvement in the operation of a Best Matching 25 operation (referred to as a “Modified Best Matching 25” operation herein) through at least the use of the AIDB specific metrics and modified average sentence length.

According to an embodiment, the weighted averages are computed by performing a Smoothing Inverse Frequency (SIF) operation including performing test row embedding by assigning a weight to one or more token vectors that are selected based on a high influence and discriminatory score, wherein the assigned weight for each token vector is its inverse frequency from training data, and averaging the token vectors to produce a representative test row vector. The SIF operation provides an alternative method to assigning weight than the Modified Best Matching 25 operation.

According to an embodiment, the determined task is a classification operation including generating vectors of the unseen data using weighted averages for combinations of tokens in a test row of the unseen data, and voting among the generated vectors is based on a highest cosine similarity. The ability to perform a classification operation including generating vectors of the unseen data using weighted averages is a novel additional functionality of computer operations.

According to an embodiment, the generated vectors are by using a pointwise mutual information (PMI) of the combination of tokens in the test row.

According to an embodiment, the determined task that is performed is a row-matching operation. The ability to perform a row matching operation with improved accuracy is enhanced.

According to an embodiment, the determined task that is performed is a Cognitive Intelligence Query for unseen data. Heretofore, only exploratory analysis of unseen data could be performed, and this embodiment provides an improvement in computer operations.

According to one embodiment, a computer-implemented method of performing queries using Artificial Intelligence database (AIDB) embeddings includes textifying training data from a database including generating data specific statistics. A model is trained using the AIDB with the textified training data. An unseen data row is analyzed, and a prediction task is determined based upon the unseen data. The determined prediction task is performed. Textifying the training data permits a more accurate way to train a machine learning model that can perform tasks on unseen data.

According to an embodiment, the computer-implemented method includes performing the prediction task. At least an interpretability score is provided. The interpretability score proves an improvement in determining the accuracy of the performed prediction task.

According to one embodiment, a computing device for performing queries using Artificial Intelligence database (AIDB) embeddings includes a processor, and a memory coupled to the processor, the memory storing instructions to cause the processor to perform acts including generating a plurality of vector embeddings describing a training data from a database resulting from unsupervised training of a machine learning model. A test vector embedding is generated for unseen data including one or more rows of the database. One or more vectors are identified from the plurality of vector embeddings describing the training data that are a closest match to the test vector embedding. A task is determined based upon the unseen data, and the determined task is performed using the trained machine learning model. The computing device enables an inference to be made about the unseen data using, for example, a prediction query. In addition, support is provided for a plurality of functions including classification and data imputation. The computing device can perform other cognitive intelligence queries including but not limited to similarity, inductive reasoning, and semantic clustering. The unsupervised training of the machine learning model provides for a way to generate an inference about the unseen data that is more efficient and more accurate than from supervised training.

According to an embodiment, the determined task is a prediction task. The prediction task is performed using the trained machine learning prediction model. An improvement in the processing of unseen data is provided through the use of training the machine learning model with unsupervised training.

According to an embodiment, the prediction task is a classification operation. The processor is configured with instructions to generate vectors representing the unseen data using weighted averages for combinations of vectors representing tokens in a test row of the unseen data and a voting operation is performed to rank the generated vectors based on a highest cosine similarity. The processing of unseen data that includes voting, vector generation, or an ensemble of voting and a vector generation, is an improvement in the processing of unseen data.

According to an embodiment, the prediction task is a row matching operation. The ability to perform a row-matching operation on unseen data is an improvement over any conventional operations.

According to an embodiment, the prediction task is a semantic analysis using Cognitive Intelligence Queries. Prediction tasks could not be previously performed on unseen data using Cognitive Intelligence Queries.

DETAILED DESCRIPTION

Overview

The term “Artificial Intelligence power database” (AIDB) as used herein generally refers to a database which employs an unsupervised neural network model to generate database embeddings to enable semantic matching through cognitive intelligence queries

The term “test data” is unseen data that has not been analyzed by a trained data model.

In conventional AI-powered databases, the semantic vectors are generated from an unstructured representation of the structured relational data. Currently, a relational row is viewed as a “sentence” in the unstructured text. In addition, the unstructured representation should be able to support multiple SQL data types. Cognitive Intelligence Queries were previously used to provide only an exploratory analysis of the data.

In the case of a prediction query, the prerequisites may include a trained AIDB model (vector embeddings) exists for similar data, and an inference regarding an incoming row which was unseen to the model is to be found, and there is familiarity with a task (e.g., row matching, classification, semantic analysis using cognitive intelligence queries).

According to the present disclosure, a prediction query enables an AI-Powered Database (AIDB) support prediction in which an AIDB model is trained and used for unseen data. There are multiple methodologies depending on the task, including row-matching (e.g., entity resolution, pattern identification), classification (class label prediction), similarity-based Cognitive Intelligence Queries (e.g., inductive reasoning). The unseen data is converted into an AIDB recognizable format through textification. Depending on the task, the converted unseen data is provided to a prediction processing module and results are obtained. The particular prediction processing module is available through User-Defined Functions (UDFs) which can be invoked on unseen data through SQL.

The computer-implemented method and computing device of the present disclosure provides a number of improvements in the processing of unseen data for a multitude of tasks using an AIDB. For example, an unsupervised approach in the present disclosure is enabled rather than a traditionally supervised learning task in AIDB to increase the predictability and classification of unstructured data. In addition, a data agnostic operation for a general model building having a specific inference can be used. The improvements further include the ability to predict any column from the structured data, and interpretable and transparent operations are performed as compared with other deep learning approaches for structured data. The Artificial intelligence-powered database operations of the present disclosure can handle null values and provide imputation. Another improvement is the ability to execute any existing cognitive intelligence queries for unseen data.

The computer-implemented method and computing device of the present disclosure also improves the efficiency of computer operations by reducing unnecessary computer processing due to more accurate data predictions and classification. A reduction in processing overhead and storage can be realized, with a reduction in power consumed.

Additional advantages of the computer-implemented method and device of the present disclosure are disclosed herein.

Example of Training a Machine Learning Model

FIG.1provides an example of a workflow100configured for training a machine learning model using an Artificial Intelligence-powered database (AIDB) to perform a task, consistent with an illustrative embodiment. At an input data stage105, data may be acquired from an AIDB. The data is textified and data specific statistics can be generated. In the textification process, hidden information may be extracted and represented by text tokens projected into a semantic vector. At training stage110, a machine language model is trained using AIDB with the input data. The training of the model is unsupervised because of the vector embeddings of the database.

At test data stage115, the unseen data is textified. In this illustrative embodiment, a prediction task is determined based on the unseen data. However, virtually any task can be performed, including but not limited to, classification, row-matching, entity resolution, or semantic analysis using cognitive intelligence queries, etc.

At prediction stage120, a method of operation is automatically selected based on the task, and an interpretability or other score may be provided. New kinds of SQL analytics queries are enabled to provide more accurate information about unseen data.

FIG.2illustrates a classification operation200, consistent with an illustrative embodiment. The class prediction201can be performed through either voting203, or vector generation205, or an ensemble207, which is an amalgamation of both the voting203and the vector generation205. The predicting method for this task includes suggesting a present value in the domain of a column that is to be predicted.

FIG.3illustrates an AIDB prediction300using raw card data as an example, consistent with an illustrative embodiment. A test query305and a training set315are shown. The test query is used to predict whether the credit card purchases are fraudulent. For example, the test query can be used to predict whether an unauthorized user has accessed the system and entered a transaction that is fraudulent (e.g., fake). The machine learning model has been trained by the training set315, and as shown by the merchant names, all of the merchants are fake. In comparing the test query305with the training set315, there is a transaction id320and a fraud prompt325shown in the training set315. However, the test query305is lacking the transaction id320and the fraud prompt325, as indicated in annotation330. Thus, if a prediction task is performed on the unseen data in test query305, the result is the unseen data is predicted to be fraudulent.

FIG.4illustrates an example of textified training data400in an AIDB, consistent with an illustrative embodiment. The test query405and the training set415are shown. The textified form of unseen data indicates a no fraud field420, and the annotation425provides information about no fraud field and no primary key PK_ID.

FIG.5illustrates a database embedding model500of a relational table that has been textified, consistent with an illustrative embodiment. The relational table520is embedded with the textification data such as customer id, merchant, state, category, items purchased, and amount. A relation row525is shown and the textification530of the data.

FIG.6illustrates an example of a row-wise prediction operation600, consistent with an illustrative embodiment. Row-wise prediction can be used in many tasks, including but not limited to entity resolution or pattern identification. At605it is shown that certain statistics are calculated based on the training data. For example, an Influence and Discriminator score per column can be calculated. Additional calculations may be performed for a corpus, a column based relative frequency, and/or an inverse frequency.

Still referring toFIG.6, upon receiving a test row, a number of operations610are performed. For example, there is a textification of the test row to convert the information into an AIDB readable format. A vector is generated for the test row (T). The nearest neighbors of T are found depending on the type (e.g., a Primary key). A result is chosen as either the top n neighbors or neighbors having a cosine similarity over a threshold (threshold “th”). The unseen data is compared with the training data to identify the training rows most similar to the test row.

FIG.7illustrates an example of a vector generation operation700, consistent with an illustrative embodiment. In vector generation there can be created a weight average705of the vector of tokens in the test row. The weighted average of the vectors can represent the test row. An illustration of vector generation procedure710is shown that includes a modified version of best match (BM) 25. The modified version of BM25 is discussed with reference toFIGS.8A and8B.

FIGS.8A and8Bare illustrations800A,800B of a modified Best Matching (BM25) operation, consistent with an illustrative embodiment.FIG.8Ashows an equation810given a query Q of a document D. BM25 is a ranking function that can estimate the relevance of documents to a given search query. BM25 is often used by search engines to determine relevance of documents to provide in response to a search request.

InFIG.8B, according to this illustrative embodiment, the bm25 algorithm is modified to use AIDB specific metrics such as an Influence & Discriminator score as well as a modified average sentence length combined with Inverse Document Frequency (IDF) to generate weights for token vectors. The average sentence length860is calculated by averaging the row length for the rows in the textified training data. The sentence length for a row of textified training data is calculated as the number of non-null values in that row. For a test row tr with tokens t, every token's vector is assigned a weight as mentioned above and then averaged to produce a single vector for tr. In addition, unlike IDF shown inFIG.8A, a discriminatory score that is a sum of proportions of unique values in a column is assigned.

FIG.8Cis an overview of a Smoothing Inverse Function (SIF), consistent with an illustrative embodiment. In vector generation, where a vector is generated for an unseen row, a weighted average of vectors (generated using training data) that represent tokens in the unseen row is computed. SIF is one of the ways that the weights can be assigned (modified BM25 as described above is another way to assign the weights). For example, the use of an SIF can determine a representative test row vector.FIG.8Cshows at880a test row embedding is constructed by assigning weights to token vectors which are chosen based on a high Influence and Discriminator score. At890, it is expressed that the assigned weight is the inverse frequency from training data. At895, the vectors are then averaged to produce the representative test row vector.

FIG.9is an illustration of the use of row similarity900in an AIDB Query, consistent with an illustrative embodiment. InFIG.9, a test row905is compared with training data from a training set to create a new row vector.

FIGS.10A and10Bshow results operations100A,100B using a prediction technique, consistent with an illustrative embodiment. The figures represent the entity matching task for prediction queries. A vector is created for the seed id row, t, using the appropriate row matching algorithm mentioned in the presentation. All primary key vectors are found from the trained model which have cosine similarity with t which is above the threshold 0.85 and report that as the result. For example,FIG.10Ashows that given an unknown test row, existing instances are found from the training data that are similar to it over a threshold. In this illustrative embodiment, the threshold is 0.85, the disclosure is not limited to this value. The result1005and the seed ID1015are shown.FIG.10Bshows a holistic matching with accuracy, precision, and recall showing results1050returned by the prediction query.

Example Process

With the foregoing overview of the example architecture, it may be helpful now to consider a high-level discussion of example processes. To that end, in conjunction withFIGS.1-10B,FIGS.11and12depict respective flowcharts1100,1200illustrating various aspects of a computer-implemented method, consistent with an illustrative embodiment.FIGS.11and12are shown as a collection of blocks, in a logical order, which represents a sequence of operations that can be implemented in hardware, software, or a combination thereof. In the context of software, the blocks represent computer-executable instructions that, when executed by one or more processors, perform the recited operations. Generally, computer-executable instructions may include routines, programs, objects, components, data structures, and the like that perform functions or implement abstract data types. In each process, the order in which the operations are described is not intended to be construed as a limitation, and any number of the described blocks can be combined in any order and/or performed in parallel to implement the process.

FIG.11is a flowchart illustrating a computer-implemented method of performing a task based on an AIDB training model, consistent with an illustrated embodiment.

Referring now toFIG.11, at operation1105, vector embeddings are generated describing a training data input from a database for unsupervised training of a machine learning model. The database is an AI-powered database. Although the training of a machine learning model by an AI-powered database is traditionally supervised, in this embodiment, the training of the machine learning model is unsupervised. The machine learning model is trained so that, for example, a transaction vector can be built for an incoming unseen row using vectors from the training data. For example, each row receives a unique vector capturing the behavior of an entire transaction (e.g., in a fraud prediction operation).

At operation1115, the test vector embeddings are generated with regard to an unseen data of one or more rows of the database by using the generated plurality of vector embeddings.

At operation1125, there is an identification of one or more vector embeddings describing the training data that are a closest match to the test vector embedding.

At operation1135, a task is automatically determined based on the unseen data. The task is included but not limited in any way to a prediction task, such as row matching, or an entity resolution task, a classification task, a cognitive intelligence query, etc. In the case of a prediction task, the values of any column can be predicted from the structured data. In addition, this approach is interpretable and transparent when compared to other complex deep learning approaches for structured data.

At operation1145, the task is performed using the trained machine learning model. The prediction task can handle null values in the database and provide imputation.

FIG.12is a flowchart illustrating a computer-implemented method of performing a voting operation based on an AIDB training model, consistent with an illustrated embodiment. At operation1205, tokens from a test row are selected based on their type/column. For example, the tokens belong to a particular column. Moreover, in a row, choose the values which are all numeric types/belonging to certain columns like Merchant, Amount, etc.

At operation1215, specific type columns are chosen based on influence and discriminator scores of the column.

At operation1225, the cosine similarity is calculated between all unique values in the domain of the column to be predicted for every chosen token.

At operation1235, a vote is assigned to the value that has the highest cosine similarity. That vote is weighted by the PMI between the token and the value.

At operation1245, the value that has the highest weighted votes is predicted as the result. For example, there may be a plurality of values present that have been weighted by the vote assigned in operation1235. The value with the highest weight votes is predicted to be the result.

Example Particularly Configured Computer Hardware Platform

FIG.13provides a functional block diagram illustration1300of a computer hardware platform. In particular,FIG.13illustrates a particularly configured network or host computer platform1300, as may be used to implement the methods shown inFIGS.11and12.

The computer platform1300may include a central processing unit (CPU)1304, a hard disk drive (HDD)1306, random access memory (RAM) and/or read-only memory (ROM)1308, a keyboard1310, a mouse1312, a display1314, and a communication interface1316, which are connected to a system bus102. The HDD1306can include data stores.

In one embodiment, the HDD1306, has capabilities that include storing a program that can execute various processes, such as machine learning, predictive modeling, classification, updating model parameters. The AI database Query Module1340includes a processor configured to control AI database query operations including generating vector embeddings. While the modules1342through1356are shown as individual modules for illustrative purposes, multiple functionalities may be combined in to fewer modules than shown.

A prediction module1342is configured to perform a prediction query to make an inference about unseen data. The prediction module can be used to control performing tasks on unseen data such as row matching (generally used for entity resolution and pattern identification), classification, and/or semantic analysis using other Cognitive Intelligence Queries on unseen data in conjunction with a row matching module1344, a classification module1346, and a semantic analysis module1348, respectively. The vector generation module1349can be configured to generate a vector for an unseen row of data. A weighted average of vectors (generated during training) representing tokens in the unseen row is computed. The weights can be assigned by at least two methods including a modified BM25 (as discussed above) by the modified BM25 module, and by a smoothing inverse function (SIF) module1354. The textification module1350is configured, for example, to convert a test row of unseen data into an AIDB readable format. The training data1356is used to train a model as discussed above, such as a machine learning prediction model.

Example Cloud Platform

As discussed above, functions relating to the low bandwidth transmission of high definition video data may include a cloud. It is to be understood that although this disclosure includes a detailed description of cloud computing as discussed herein below, implementation of the teachings recited herein is not limited to a cloud computing environment. Rather, embodiments of the present disclosure are capable of being implemented in conjunction with any other type of computing environment now known or later developed.

Characteristics are as follows:

Service Models are as follows:

Deployment Models are as follows:

A cloud computing environment is service-oriented with a focus on statelessness, low coupling, modularity, and semantic interoperability. At the heart of cloud computing is an infrastructure that includes a network of interconnected nodes.

Referring now toFIG.14, an illustrative cloud computing environment1400utilizing cloud computing is depicted. As shown, cloud computing environment1400includes cloud1450having one or more cloud computing nodes1410with which local computing devices used by cloud consumers, such as, for example, personal digital assistant (PDA) or cellular telephone1454A, desktop computer1454B, laptop computer1454C, and/or automobile computer system1454N may communicate. Nodes1410may communicate with one another. They may be grouped (not shown) physically or virtually, in one or more networks, such as Private, Community, Public, or Hybrid clouds as described hereinabove, or a combination thereof. This allows cloud computing environment1400to offer infrastructure, platforms, and/or software as services for which a cloud consumer does not need to maintain resources on a local computing device. It is understood that the types of computing devices1454A-N shown inFIG.14are intended to be illustrative only and that computing nodes1410and cloud computing environment1400can communicate with any type of computerized device over any type of network and/or network addressable connection (e.g., using a web browser).

Referring now toFIG.15, a set of functional abstraction layers1500provided by cloud computing environment1400(FIG.14) is shown. It should be understood in advance that the components, layers, and functions shown inFIG.15are intended to be illustrative only and embodiments of the disclosure are not limited thereto. As depicted, the following layers and corresponding functions are provided:

Hardware and software layer1560include hardware and software components. Examples of hardware components include: mainframes1561; RISC (Reduced Instruction Set Computer) architecture based servers1562; servers1563; blade servers1564; storage devices1565; and networks and networking components1566. In some embodiments, software components include network application server software1567and database software1568.

Virtualization layer1570provides an abstraction layer from which the following examples of virtual entities may be provided: virtual servers1571; virtual storage1572; virtual networks1373, including virtual private networks; virtual applications and operating systems1574; and virtual clients1575.

Workloads layer1590provides examples of functionality for which the cloud computing environment may be utilized. Examples of workloads and functions which may be provided from this layer include: mapping and navigation1591; software development and lifecycle management1592; virtual classroom education delivery1593; data analytics processing1594; transaction processing1595; and an AI-Powered Database Query module1596configured to perform queries of an AI-powered database based on unsupervised training of a machine learning model producing database embeddings to perform tasks including but not limited in any way to prediction, classification, entity resolution, and fraud detection, as discussed herein above.

Conclusion

The flowchart, and diagrams in the figures herein illustrate the architecture, functionality, and operation of possible implementations according to various embodiments of the present disclosure.