METHOD AND SYSTEM FOR RECOMMENDATION OF SUITABLE ASSETS USING LARGE LANGUAGE MODEL (LLM)
The present disclosure provides a method for recommendation of suitable assets using Large Language Model (LLM), method comprising receiving descriptors for each asset from amongst plurality of assets; generating embeddings for each asset from amongst plurality of assets, by employing LLM; creating database of assets by storing generated embeddings for each asset from amongst plurality of assets in database; receiving user query pertaining to request for recommendation to solve enterprise problem; generating cosine similarity scores, wherein each cosine similarity score is generated between user query and corresponding generated embedding for given asset stored in database of assets; identifying predefined number of similar assets from amongst database of assets, based on highest cosine similarity scores; constructing optimal prompt based on identified predefined number of similar assets and user query; and prompting LLM, using constructed optimal prompt for generating response as recommendation of identified predefined number of similar assets as suitable assets for solving user query.
1 . A method for recommendation of suitable assets using a Large Language Model (LLM) ( 202 ), the method comprising:
receiving descriptors for each asset from amongst a plurality of assets;
generating embeddings for each asset from amongst the plurality of assets, by employing the LLM, based on the provided descriptors of each asset from amongst the plurality of assets;
creating a database ( 206 ) of assets by storing the generated embeddings for each asset from amongst the plurality of assets in the database;
receiving a user query pertaining to a request for recommendation to solve an enterprise problem;
generating cosine similarity scores, wherein each cosine similarity score is generated between the user query and a corresponding generated embedding for a given asset stored in the database of assets;
identifying a predefined number of similar assets from amongst the database of assets, based on highest cosine similarity scores;
constructing an optimal prompt based on the identified predefined number of similar assets and the user query; and
prompting the LLM, using the constructed optimal prompt for generating a response as a recommendation of the identified predefined number of similar assets as the suitable assets for solving the user query.
2 . The method according to claim 1 , wherein the plurality of assets comprises at least one of: a machine learning model, a login module, a software, an object detection model, and the like.
3 . The method according to claim 1 , wherein the descriptors of each asset from amongst the plurality of assets comprises: an asset title, an asset description, asset metadata.
4 . The method according to claim 1 , wherein the LLM ( 202 ) used for implementing the step of generating embeddings for each asset from amongst the plurality of assets, is a text_embedding_ada model.
5 . The method according to claim 1 , wherein the generated embeddings for each asset from amongst the plurality of assets are stored in the database ( 206 ) in an indexed form.
6 . The method according to claim 1 , wherein the user query is received from a user device associated with a user.
7 . The method according to claim 1 , wherein the step of prompting the LLM ( 202 ), using the constructed optimal prompt, for recommending suitable assets for solving the enterprise problem, is implemented by using a technique of few-shot prompting.
8 . A system ( 200 ) for recommendation of suitable assets using a Large Language Model (LLM) ( 202 ), the system comprising a processor ( 204 ) configured to:
receive descriptors for each asset from amongst a plurality of assets;
generate embeddings for each asset from amongst the plurality of assets, by employing the LLM, based on the provided descriptors of each asset from amongst the plurality of assets;
create a database ( 206 ) of assets by storing the generated embeddings for each asset from amongst the plurality of assets in the database;
receive a user query pertaining to a request for recommendation to solve an enterprise problem;
generate cosine similarity scores, wherein each cosine similarity score is generated between the user query and a corresponding generated embedding for a given asset stored in the database of assets;
identify a predefined number of similar assets from amongst the database of assets, based on highest cosine similarity scores;
construct an optimal prompt based on the identified predefined number of similar assets and the user query; and
prompt the LLM, using the constructed optimal prompt for generating a response as a recommendation of the identified predefined number of similar assets as the suitable assets for solving the user query.
9 . The system ( 200 ) according to claim 8 , wherein the plurality of assets comprises at least one of: a machine learning module, a login model, a software, an object detection model, and the like.
10 . The system ( 200 ) according to claim 8 , wherein the descriptors of each asset from amongst the plurality of assets comprises: an asset title, an asset description, an asset metadata.
11 . The system ( 200 ) according to claim 8 , wherein the LLM ( 202 ) used to generate embeddings for each asset from amongst the plurality of assets, is a text_embedding_ada model.
12 . The system ( 200 ) according to claim 8 , wherein the generated embeddings for each asset from amongst the plurality of assets are stored in the database ( 206 ) in an indexed form.
13 . The system ( 200 ) according to claim 8 , wherein the user query is received from a user device associated with a user.
14 . The system ( 200 ) according to claim 9 , wherein to prompt the LLM ( 202 ), using the constructed optimal prompt, to recommend the suitable assets for solving the enterprise problem, at least one processor ( 204 ) is configured to implement a technique of few-shot prompting.