CPC G06F 16/24549 (2019.01) [G06F 16/2455 (2019.01); G06F 16/2462 (2019.01); G06F 16/248 (2019.01); G06F 16/903 (2019.01); G06F 16/90335 (2019.01); G06N 3/044 (2023.01); G06N 3/045 (2023.01); G06N 3/06 (2013.01); G06N 3/08 (2013.01); G06N 3/084 (2013.01)] | 7 Claims |
1. A method for providing local approximations of results to database queries, comprising:
providing a primary neural network with at least one test database query, wherein the at least one test database query includes at least one training query and a real test result derived from executing the at least one training query on a data set, wherein the primary neural network is trained on a plurality of database queries and respective results;
receiving from the primary neural network a predicted test result in response to the at least one test database query;
sending, a leaner model of the primary neural network to a local machine, wherein the leaner model of the primary neural network is trained on the plurality of database queries and respective results; and
storing the leaner model of the primary neural network on the local machine as an entirety of a local neural network that is adapted to produce an overall result to a database query, wherein the leaner model of the primary neural network on the local machine is configured to generate a prediction in response to a database query received by the local machine;
receiving a user query at the local machine;
when the local machine has sufficient resources to execute the leaner model of the primary neural network, execute the query on the leaner model of the primary neural network and provide an initial estimated result for the query to the user at the local machine;
when at least one condition of the local machine having insufficient resources to execute the leaner model of the primary neural network and a confidence level for a predicted test result produced by the leaner model of the primary neural network at the
user device is below a prescribed threshold, the confidence level being based on a loss function, is met, transmitting the query for execution to the primary neural network;
when the local machine has sufficient resources to execute the leaner model of the primary neural network, also transmit the query for execution to the primary neural network;
receiving an estimated result for the query from the primary neural network; and
providing the estimated result for the query from the primary neural network to the user at the local machine, wherein when the leaner model of the primary neural network on the local machine provided an initial estimated result for the query to the user at the local machine, replacing the initial estimated result for the query that had been provided to the user with the estimated result for the query from the primary neural network.
|