The invention relates to the technical field of
large model recommendation, and discloses a
large model recommendation
algorithm based on a KV cache lightweight optimization technology. The
algorithm comprises the steps of obtaining a user historical behavior data sequence, and performing cleaning and
standardization processing to obtain standardized user behavior data; the method comprises the steps that a user behavior vector is mapped to an embedding space to generate a user behavior vector, a lightweight key value cache model is trained in combination with an item
feature vector in an item
library, keys are embedded according to user requests, and values are embedded according to recommended items. When user recommendation requests are received, request features are extracted and mapped into request vectors, and the requests are classified according to the similarity of the vectors and keys in the key value cache; if the cache is hit, directly reading a corresponding value as a recommendation result; and if the cache is not hit,
processing the request vector by adopting a pre-training
large model to generate a recommendation result, and storing the result and a corresponding key into a key value cache. According to the
algorithm, through KV cache lightweight design, the recommendation effect is guaranteed, meanwhile, the large model calling frequency is reduced, and the recommendation response speed is increased.