# A Novel Framework Leveraging Large Language Models to Enhance Cold-Start Advertising Systems
## 3 Materials and Methods--The Proposed Framework
### Stage 3: LLM-Povered Enhancement System  
The final stage employs the Gemini 2.5 LLM API to process the top five candidate advertisements \(A_{\text{top}}=a_{1},a_{2},a_{3},a_{4},a_{5}\) from the ensemble model (Section 3.2) through three operations: select the best-match advertisement, refine the advertisement message at runtime, and generate an explanation. These operations leverage the LLM's semantic understanding to improve recommendation quality, personalization, and transparency in cold-start scenarios. In detail:  
1. Semantic reranking and best-match advertisement. The LLM evaluates the top five advertisements to select the one best aligned with the user's profile, considering contextual relevance, category diversity, sentiment alignment, fairness, and available feedback. The LLM processes a prompt with the user profile (e.g., location, time, inferred preferences) and ad metadata (e.g., description, category). This process incorporates:  
* Contextual Relevance: The LLM matches user attributes to ad metadata more effectively by processing sparse user data alongside rich ad descriptions and categories [31]. We include in the prompt a directive to prioritize ads whose metadata aligns closely with user attributes. * Recommendation Diversification: Using techniques inspired by Maximal Marginal Relevance [32], the LLM ensures the top recommendations span varied categories rather than redundant offerings. We include a prompt instruction to favor ads from distinct categories, reducing redundancy among the top selections. * Sentiment-Aware Ranking: The LLM incorporates sentiment analysis on the content to prioritize ads that align with positive user preferences inferred from available data [33]. We include a directive to prioritize ads with positive sentiment that matches user preferences, based on the LLM's natural language-processing capabilities. * Bias Mitigation: The system implements fairness constraints to prevent overrepresentation of certain ad categories and ensure balanced recommendations [34]. An instruction is added to ensure balanced category representation among the selected ads, using metadata to identify categories. * Real-Time Adaptation: The LLM framework can dynamically update rankings based on user feedback signals [35]. The mathematical formulation of the process can be written as follows:  
Let \(U\) be the user profile, encoded as a feature vector. Each ad \(a_{j}\in A_{top}\) has metadata encoded as \(vj\). The LLM computes a semantic relevance score \(r(u,aj)=cosine\_similarity(LLMembed(U),LLMembed(vj))\), where \(LLMembed\) is the Gemini 2.5 embedding function [31]. The ad with the highest score is selected. 2. Message Refinement: For the top-ranked advertisement, the LLM generates refined messaging that better aligns with the user's profile characteristics while maintaining the core business proposition. This personalization process leverages: * Inferred user preferences based on location, time, and domain context [36]; * Semantic understanding of user attributes to tailor messaging tone and content; * Adaptation to potential user needs even with limited historical data [37]. 3. Explanation Generation: The system produces natural language explanations that articulate the reasoning behind the recommendation, increasing transparency and helping users understand why particular advertisements were selected or eliminated. These explanations: * Reveal the factors influencing the recommendation decision; * Build user trust by making the recommendation process transparent [38]; * Address the \"black box\" nature of traditional recommendation systems. Table 1 below demonstrates the prompt message and LLM communication through API calls. 4. Cold-Start Problem Mitigation: The LLM leverages its pre-trained knowledge to generate recommendations even in the absence of user interaction history.