Question recommendation method and device based on large language model, equipment and storage medium
By pre-presenting recommended queries in the large language model and allowing users to select a new query at the first character, the problem of waiting for a complete response in human-computer interaction is solved, improving efficiency and user experience.
Patent Information
- Application Number
- CN202510976400.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-15
- Publication Date
- 2025-10-28
AI Technical Summary
In the process of human-computer interaction, it is difficult to control the degree of matching between the output response of the large language model and the user's expectations, resulting in low efficiency and poor user experience, especially since it is only after waiting for a complete response that it can be determined whether the expected content is included.
During the process of generating query responses using a large language model, recommended queries are presented in advance, allowing users to view recommended queries at the first character and interrupt the existing response to generate a new query after selecting a recommended query, thus reducing unnecessary waiting and interaction.
By presenting recommended queries in advance, the time spent waiting for responses is reduced, improving the efficiency of human-computer interaction and user experience, and increasing the match between query responses and user needs.
Smart Images

Figure CN120849656A_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of data processing technology, specifically to the fields of artificial intelligence technology such as large language models, generative models, human-computer interaction, and query recommendation, and particularly to a query recommendation method, device, electronic device, computer-readable storage medium, and computer program product based on a large language model. Background Technology
[0002] With the gradual development of Large Language Model (LLM) technology, it has been widely used in various industries to help answer various questions raised by relevant users.
[0003] However, in actual human-computer interaction, it is difficult to control the degree of matching between the response output by the large language model and the expectation, and it is often necessary to wait for the large language model to output all the responses before we know whether it contains the part that the user actually expects. Therefore, the efficiency of human-computer interaction is relatively low and the user experience is poor. Summary of the Invention
[0004] This disclosure presents a query recommendation method, apparatus, electronic device, computer-readable storage medium, and computer program product based on a large language model.
[0005] In a first aspect, embodiments of this disclosure propose a query recommendation method based on a large language model, comprising: receiving a query request initiated by a user for a target video currently viewed in a video application; inputting the query request and relevant content of the target video together as prompt information into a preset large language model to obtain an output query response and recommended query in a pending presentation state; presenting each character constituting the query response character by character, and presenting the recommended query completely while presenting the first character constituting the query response; in response to any recommended query being selected by the user, terminating the presentation of the remaining characters constituting the query response, and inputting the selected recommended query as a new query request initiated for the target video and relevant content together as prompt information into the large language model to obtain an output new query response and new recommended query in a pending presentation state.
[0006] Secondly, embodiments of this disclosure propose an inquiry recommendation device based on a large language model, comprising: an inquiry request receiving unit configured to receive an inquiry request initiated by a user for a target video currently viewed in a video application; a request processing unit configured to input the inquiry request and relevant content of the target video as prompt information into a preset large language model, thereby obtaining an output inquiry response and recommended inquiry in a pending presentation state; a recommended inquiry presentation control unit configured to present each character constituting the inquiry response character by character, and to present the recommended inquiry completely while presenting the first character constituting the inquiry response; and a new inquiry request generation processing unit configured to, in response to any recommended inquiry being selected by the user, terminate the presentation of the remaining characters constituting the inquiry response, and input the selected recommended inquiry as a new inquiry request initiated for the target video and relevant content as prompt information into the large language model, thereby obtaining an output new inquiry response and new recommended inquiry in a pending presentation state.
[0007] Thirdly, embodiments of this disclosure provide an electronic device comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to implement the query recommendation method based on a large language model as described in the first aspect.
[0008] Fourthly, embodiments of this disclosure provide a non-transitory computer-readable storage medium storing computer instructions that enable a computer to implement the query recommendation method based on a large language model as described in the first aspect when executed.
[0009] Fifthly, embodiments of this disclosure provide a computer program product including a computer program that, when executed by a processor, can implement the steps of the query recommendation method based on a large language model as described in the first aspect.
[0010] The query recommendation solution based on a large language model provided in this disclosure offers a solution for video applications integrating a large language model, allowing recommended queries to be presented to users as early as possible. Specifically, when the large language model generates the query response and recommended query based on the user's query request, the recommended query is not presented after all the query responses have been presented, but rather simultaneously and completely with the first character of the query response. This allows users to see the recommended query earlier, eliminating the need to wait for all query responses that do not contain the user's expected content to be presented. Users can then change the query and have the large language model regenerate a new query response, thus minimizing unnecessary waiting time and reducing invalid interactions, thereby improving human-computer interaction efficiency and enhancing the user's experience. Furthermore, since the relevant content of the target video also contributes to the prompt information input to the large language model, the query response and recommended query are also generated based on the relevant video content, improving the matching degree with the user's needs in the current video viewing scenario.
[0011] It should be understood that the description in this section is not intended to identify key or essential features of the embodiments of this disclosure, nor is it intended to limit the scope of this disclosure. Other features of this disclosure will become readily apparent from the following description. Attached Figure Description
[0012] Other features, objects, and advantages of this disclosure will become more apparent from the following detailed description of non-limiting embodiments with reference to the accompanying drawings: Figure 1 This is an exemplary system architecture to which this disclosure can be applied; Figure 2 A flowchart illustrating a query recommendation method based on a large language model, provided for embodiments of this disclosure; Figure 3 A flowchart illustrating a method for presenting query responses and recommended queries, provided as an embodiment of this disclosure; Figure 4 This is a branch diagram illustrating different processing methods for determining a new query request based on different interfaces where the recommended query is selected, as provided in an embodiment of this disclosure. Figure 5-1 This is a schematic diagram illustrating the interface entry point for triggering interaction with a large language model in the currently playing video interface of a video application, as provided in this embodiment of the disclosure. Figure 5-2 A schematic diagram illustrating a response display area and a recommendation bar in an inquiry interaction interface, provided as an embodiment of this disclosure; Figure 5-3 A schematic diagram showing the distribution of a recommendation bar, an input bar, and a keyboard area displayed on top of an inquiry interaction interface when the input interface is invoked, provided in an embodiment of this disclosure. Figure 6 A structural block diagram of a query recommendation device based on a large language model provided in this disclosure embodiment; Figure 7 This is a schematic diagram of the structure of an electronic device suitable for executing a query recommendation method based on a large language model, as provided in an embodiment of this disclosure. Detailed Implementation
[0013] The exemplary embodiments of this disclosure are described below with reference to the accompanying drawings, including various details of the embodiments to aid understanding; these should be considered merely exemplary. Therefore, those skilled in the art will recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope and spirit of this disclosure. Similarly, for clarity and brevity, descriptions of well-known functions and structures are omitted in the following description. It should be noted that, unless otherwise specified, the embodiments and features described in this disclosure can be combined with each other.
[0014] The collection, storage, use, processing, transmission, provision, and disclosure of user personal information involved in the technical solution disclosed herein comply with the provisions of relevant laws and regulations and do not violate public order and good morals.
[0015] Figure 1 An exemplary system architecture 100 is shown, to which embodiments of the query recommendation method, apparatus, electronic device, and computer-readable storage medium based on the large language model of this disclosure can be applied.
[0016] like Figure 1 As shown, system architecture 100 may include terminal devices 101, 102, and 103, a network 104, and a server 105. Network 104 serves as the medium for providing communication links between terminal devices 101, 102, and 103 and server 105. Network 104 may include various connection types, such as wired or wireless communication links, or fiber optic cables, etc.
[0017] Users can use terminal devices 101, 102, and 103 to interact with server 105 via network 104 to receive or send messages, etc. Various applications for enabling information communication between the terminal devices 101, 102, and 103 and server 105 can be installed. These applications include video-on-demand applications, video sharing applications, video social applications, and instant messaging applications.
[0018] Terminal devices 101, 102, and 103 and server 105 can be either hardware or software. When terminal devices 101, 102, and 103 are hardware, they can be various electronic devices with displays, including but not limited to smartphones, tablets, laptops, and desktop computers. When terminal devices 101, 102, and 103 are software, they can be installed in the aforementioned electronic devices, and can be implemented as multiple software programs or software modules, or as a single software program or software module; no specific limitation is made here. When server 105 is hardware, it can be implemented as a distributed server cluster composed of multiple servers, or as a single server. When server 105 is software, it can be implemented as multiple software programs or software modules, or as a single software program or software module; no specific limitation is made here.
[0019] Server 105 can provide various services through its built-in applications. Taking a video social application that provides query-response services as an example, server 105 can achieve the following effects when running this video social application: First, it receives query requests initiated by users through terminal devices 101, 102, and 103 regarding the target video currently viewed in the video social application via network 104; then, it inputs the query request and the relevant content of the target video as prompt information into a preset large language model, resulting in the output query response and recommended query in a pending state; next, it presents each character constituting the query response character by character, and simultaneously presents the recommended query while presenting the first character constituting the query response; finally, in response to any recommended query being selected by the user, it stops presenting the remaining characters constituting the query response, and inputs the selected recommended query as a new query request initiated for the target video, along with the relevant content, as prompt information into the large language model, resulting in the output new query response and new recommended query in a pending state.
[0020] It should be noted that, in addition to being obtained from terminal devices 101, 102, and 103 via network 104, query requests can also be pre-stored locally on server 105 through various means. Therefore, when server 105 detects that this data is already stored locally (e.g., when starting to process previously reserved pending query tasks), it can choose to retrieve this data directly from locally. In this case, the exemplary system architecture 100 may also exclude terminal devices 101, 102, and 103 and network 104.
[0021] The query recommendation method based on a large language model provided in the subsequent embodiments of this disclosure is generally executed by a server 105 with strong computing power, abundant computing resources, and the ability to call the large language model to provide query response services. Correspondingly, the query recommendation device based on the large language model is also generally set in the server 105. However, it should also be noted that when terminal devices 101, 102, and 103 also have sufficient computing power and resources, they can also complete the various calculations performed by the server 105 through the video social networking applications installed on them, and thus output the same results as the server 105. Especially when multiple terminal devices with different computing capabilities exist simultaneously, but the video social networking application determines that the terminal device it is on has strong computing power and abundant remaining computing resources, it can let the terminal device perform the above calculations, thereby appropriately reducing the computing pressure on the server 105. Correspondingly, the query recommendation device based on the large language model can also be set in the terminal devices 101, 102, and 103. In this case, the exemplary system architecture 100 may also exclude the server 105 and the network 104.
[0022] The large language model can be deployed separately on a server other than server 105.
[0023] It should be understood that Figure 1 The number of terminal devices, networks, and servers shown is merely illustrative. Depending on implementation needs, any number of terminal devices, networks, and servers can be included.
[0024] Please refer to Figure 2 , Figure 2 A flowchart of a query recommendation method based on a large language model is provided for embodiments of this disclosure, wherein process 200 includes the following steps: Step 201: Receive a query request from the user regarding the target video currently being viewed in the video application; This step aims to be implemented by the entity executing the query recommendation method based on a large language model (e.g., Figure 1 The server 105 shown, or various video applications hosted on the server 105, receives a query request from the user regarding the target video currently being viewed in the video application. This video application (which may include video-on-demand applications, video sharing applications, video social applications, short video applications, or long video applications, etc.) may be pre-installed on the user's terminal device (e.g., [device name missing]). Figure 1 On the terminal devices 101, 102, and 103 shown, the target video currently being viewed is presented to the user when the user uses it on the terminal device.
[0025] Specifically, "user" refers to an individual who watches and interacts with a video application, potentially submitting custom questions through the application's built-in input interfaces (such as text input boxes, speech recognition modules, or preset query buttons); "video application" specifically refers to a software platform or mobile application that integrates a large language model, whose core function is to provide video playback services while supporting real-time question answering, such as embedding a query function panel in the user interface; "currently viewed target video" refers to the video object that the user is watching in real time, and its related content includes video metadata (such as title, author, tags, summary) and contextual information (such as subtitles, timestamps, and related content descriptions), which is transmitted through the application's backend API (Application Programming Interface). The interface (Application Programming Interface) or local cache is obtained in real time as the context basis for subsequent LLM prompts; the "inquiry request" should be a request further initiated by the user on the interface for viewing the target video. It may include request content expressing the actual inquiry purpose (such as the query content entered or selected by the user, which may exist in the form of a text string, such as "What is the explanation of this scene?") and user-related preference information, such as user profile, user group profile, etc. The aforementioned execution entity captures the request through an event listening mechanism (such as the user clicking the submit button or the voice input ending event) and performs preliminary standardization processing (such as removing redundant characters and language detection) to ensure the consistency of input.
[0026] It should be noted that all personal or sensitive information related to users has been authorized by the users before use, and this authorization was obtained on the premise that the users were clearly informed of what personal information they would be collected or recorded.
[0027] Step 202: Input the query request and the relevant content of the target video as prompt information into the preset large language model to obtain the output query response and recommended query in the pending state; Building upon step 201, this step aims to have the aforementioned executing entity input the inquiry request and the relevant content of the target video as prompt information into a preset large language model, so as to obtain the inquiry response and recommended inquiry in a pending presentation state output by the large language model. Here, the inquiry response and recommended inquiry in a pending presentation state refer to the state that has been analyzed by the large language model based on the input prompt information, but has not yet been presented to the user by the aforementioned executing entity.
[0028] In practical terms, a "query request" can refer to a combination of the user's original query text (such as "explain the protagonist's motivation") received and standardized through preliminary steps, and user preference information, usually transmitted in string format. "Relevant content of the target video" refers to structured information dynamically extracted from the video application's backend to achieve accurate contextual understanding. This includes, but is not limited to, video metadata (title, author, type, tags), content summary, number of video segments, number of viewed video segments, real-time subtitle clips, keyframe descriptions of the user's current playback timestamp, video comments, and extended information linked through a knowledge graph (such as director's biography, background information on film series, and other related videos). This content can be efficiently obtained through lightweight API interfaces or pre-loaded caches, and... Key-value pairs or JSON format organization; "Pre-set large language model" specifically refers to a pre-trained model optimized for the video domain (such as a fine-tuned model based on GPT or BERT architecture). Its prompting engineering needs to design specific templates, such as embedding the prompt text with the user's query request as the main instruction and video-related content as supplementary context, and adding implicit instructions to control the output format (such as requiring the model to strictly generate according to the two-part structure of "reply text + recommended query list"); "Common as prompt information input" operation involves dynamically constructing prompt strings, distinguishing different data sources by inserting separators (such as [video context]...[ / context]), and using token compression technology (such as key information extraction) to ensure that the prompt length meets the input constraints of the large language model; "Question Response" is a direct answer text to the user's request (such as "The protagonist's motivation stems from family responsibility..."), while "Recommended Questions" can be a list of 3-5 candidate questions predicted by the large language model based on semantic association (such as "What is the villain's motivation?" "What is the metaphor in the ending?" "What are the differences from the original work?"). Both are in a "pending presentation state"—that is, the large language model already knows what content should be output. However, Question Response is usually rendered sequentially in a generative manner, word by word or token by token, while Recommended Questions have the complete content cached but have not yet triggered interface rendering, thus providing a data foundation for the subsequent parallel presentation mechanism.
[0029] The video-related content involved in this step can also be intelligently filtered (e.g., prioritizing segments based on the current playback progress) to avoid information overload; the output of the large language model can also be deployed for real-time quality monitoring (e.g., filtering invalid recommendations through confidence thresholds) to ensure the diversity and guiding value of recommended queries; at the same time, the output can be received gradually through a streaming response mechanism, making it possible to coordinate the presentation of replies word by word with the complete rendering of recommended queries, ultimately supporting the core interactive goal of users making decisions in advance.
[0030] Step 203: Present each character that constitutes the query response, and present the recommended query completely while presenting the first character that constitutes the query response; Building upon step 202, this step aims to have the aforementioned executing entity present each character constituting the query response character by character, and to present the complete recommendation query while presenting the first character constituting the query response. Here, "character by character" does not strictly refer to a "single character" in the context of Chinese or other foreign languages, but rather corresponds to the segmentation unit (token) used in the large language model actually used in different contexts. A token can be a single character, a word, or a part of a word; no specific limitation is made here.
[0031] The "presenting each character that constitutes the query response word by word" means that the aforementioned execution entity uses streaming output technology to simulate the rhythm of natural dialogue, dynamically loading the query response text generated by the large language model (such as "This scene uses symbolic techniques...") into the user interface in the form of a character sequence. The rendering interval of each character is controlled by a configurable timing algorithm (such as fixed delay or dynamic speed adjustment) to form a progressive display effect to reduce the cognitive pressure on the user. The "first character that constitutes the query response" is the initial trigger point of this process. When the aforementioned execution entity detects that the first character (such as "this") has been successfully rendered to the interface, it immediately activates the parallel rendering channel. The "simultaneously presenting the recommended queries in their entirety" requires the system to display the pre-generated list of recommended queries (such as ["How does the director explain this scene?" "Where is the corresponding chapter in the original work?" "What other use cases are there for similar techniques?"]) in a non-streaming, one-time complete loading manner in the designated interactive area (such as a floating panel or a recommendation bar on the side or bottom), ensuring that the user can view all recommended query options without waiting.
[0032] In practical terms, this step can be implemented using a dual-channel rendering architecture: the main channel is responsible for the character-level streaming output of query responses, updating the text container frame by frame through an asynchronous event loop; the auxiliary channel, when the first character rendering event is triggered, directly injects the cached complete dataset of recommended queries, the content of which originates from the structured recommendation fields output by LLM and undergoes lightweight formatting (such as adding icons and category labels). To ensure timing accuracy, the above execution entities can also establish a cross-thread state synchronization mechanism: when the character rendering engine submits the first character to the graphics layer, it immediately sends an interrupt signal to the recommended query rendering module, which then takes priority to preempt interface resources for real-time rendering. Simultaneously, to prevent visual conflicts, the interface layout needs to pre-define dynamic area divisions: the query response area maintains adaptive expansion, while the recommended query area is fixed as a collapsible container, expanding to cover redundant blank areas when triggered. This design uses a strong synchronization mechanism of "first character - full recommendation" to move the user's decision point from the end of the traditional process to the beginning, laying the technical foundation for core interruption switching functions (such as terminating the current reply after the user clicks on the recommended inquiry), so as to ultimately achieve the core goal of reducing invalid waiting time and improving interaction efficiency.
[0033] Step 204: In response to any recommended query being selected by the user, terminate the presentation of the remaining characters constituting the query response, and input the selected recommended query as a new query request initiated against the target video and related content together as prompt information into the large language model to obtain the output of the new query response and new recommended query in the pending presentation state.
[0034] Based on step 203, this step aims to have the aforementioned executing entity stop presenting the remaining characters constituting the query response when any recommended query is selected by the user, and input the selected recommended query as a new query request initiated against the target video and related content together as prompt information into the large language model to obtain the output new query response and new recommended query in the pending presentation state, and repeat the above steps to perform the same processing.
[0035] This step efficiently responds to shifts in user intent through an interrupt-driven process reset. Specifically, it involves coordinating event listening, resource reclamation, and data reassembly. "Any recommended query selected by the user" means the user triggers a specific option from the fully presented recommendation list (e.g., "How much did it cost to shoot?", "Where are the filming locations?") through interactive actions such as clicking, touching, or voice confirmation. The aforementioned execution entity captures this operation and extracts the original text identifier of the selected option through an event delegation mechanism. "Terminate the presentation of the remaining characters constituting the query response" requires immediately terminating the ongoing streaming rendering thread. This can be achieved by injecting an interrupt signal into the character generator, clearing the output buffer, freezing the dynamic expansion of the current text container, and simultaneously applying visual feedback (e.g., a fade-out effect) at the interface layer to mark the invalidation state of undisplayed content, ensuring the user clearly perceives that the original response has been discarded. "Treat the selected recommended query as a new query request" means the aforementioned execution entity encapsulates the selected recommended query text (e.g., "Who is the behind-the-scenes special effects team?") into a structured request object, inheriting the context identifier of the current session (e.g., user ID, video ID) and reusing the existing standardized processing flow. In the process of "inputting relevant content as prompt information into the large language model," the "relevant content" can be the same as the target video content in the initial request, such as metadata (e.g., pre-loaded video tags, subtitle summaries, etc.) and others. Alternatively, it can be selectively filtered based on the selected recommended query content and directly reused through memory caching to avoid duplicate extraction. The aforementioned execution entity dynamically combines the new query request with it into prompt text, reusing the preset delimiter rules and length compression strategies to input into the same LLM instance. The process of "obtaining the output of the new query response and new recommended query in the pending presentation state" will trigger the generation logic isomorphic to the initial process: that is, the LLM output parsing module divides the main text answer (e.g., "Special effects are handled by MOREVFX Studio") and the recommendation list (e.g., "Other works by this studio?", "How long did the production take?", "What are the technical difficulties?") according to a predetermined format. Both are directly stored in the pending presentation cache area, providing a data source for the subsequent parallel rendering of "first character - full recommendation".
[0036] The key to the solution provided in this step lies in achieving seamless state switching: the aforementioned execution entities need to complete three-thread collaboration (i.e., terminating the original rendering, initiating a new request, and preparing for the new rendering) the instant the user selects a state, reducing latency through resource reuse (video metadata caching, LLM connection pool); simultaneously, maintaining session continuity ensures that the recommended paths for previous and subsequent queries are traceable, avoiding context breaks caused by frequent switching. Ultimately, through this ability to instantly interrupt and regenerate, the user's exploration cost is reduced to a single click, thereby improving the efficiency of human-computer interaction.
[0037] The query recommendation method based on a large language model provided in this disclosure offers a solution for video applications integrating a large language model. It presents recommended queries to the user as early as possible. Specifically, when the large language model generates the query response and recommended query based on the user's query request, the recommended query is not presented after all the query responses have been presented. Instead, it is presented simultaneously with the first character of the query response, and presented completely. This allows the user to see the recommended query earlier, eliminating the need to wait for all query responses that do not contain the user's desired content to be presented. The user can then change the query and allow the large language model to regenerate a new query response, thus minimizing unnecessary waiting time and reducing unnecessary interactions, thereby improving human-computer interaction efficiency and enhancing the user's experience. Furthermore, since the relevant content of the target video also contributes to the prompt information input to the large language model, the query response and recommended query are also generated based on the relevant video content, improving the matching degree with the user's needs in the current video viewing scenario.
[0038] To deepen your understanding of the operations involved in step 203, please refer to [the relevant documentation / reference]. Figure 3 , Figure 3 A flowchart of a method for presenting query responses and recommended queries is provided for embodiments of this disclosure, wherein process 300 includes the following steps: Step 301: Display each character constituting the query response in the response display area of the query interaction interface; Step 302: While displaying the first character constituting the query reply in the reply display area, the recommended query is displayed in its entirety in the recommendation bar.
[0039] The specific implementation scheme provided in this embodiment achieves the parallel presentation of inquiry responses and recommended inquiries through interface partitioning and time synchronization strategies. The inquiry interaction interface, serving as a unified carrier for user operations, can be designed using a responsive layout. The response presentation area can be a dynamic text container (such as a scrolling text box), responsible for streaming the inquiry response text content generated by the LLM. A character-level timing controller progressively renders the character sequence at a configurable rate (such as 50 milliseconds / character) to simulate the rhythm of human conversation and reduce information overload. The recommendation bar in the inquiry interaction interface can be an independent interactive component (such as a fixed-position panel), which can be preset to a collapsed / hidden state and is dedicated to the structured display of the recommended inquiry list. When the aforementioned execution entity detects that the first character in the response presentation area has been rendered (such as when a DOM rendering event is triggered), it immediately activates a dual-channel synchronization protocol: on the one hand, it continues to execute the word-by-word output task in the response area; on the other hand, it sends atomic operation instructions to the recommendation bar to perform real-time and complete rendering of the LLM-pre-generated recommended inquiry dataset (such as [“Scene symbolic meaning?”, “Director’s creative intention?”, “Historical background interpretation?”]).
[0040] Furthermore, in the complete presentation operation, the content of the recommendation bar can be injected all at once instead of being streamed, and data latency can be avoided by prefetching and caching. At the same time, the recommended questions can be displayed as interactive elements (such as card-style buttons) with visual priority markers (such as sorting by predicted weight), and the recommendation bar and the reply presentation area can adopt a non-overlapping layout (such as a floating vertical bar on the right or a drawer-style panel at the bottom), and content occlusion can be avoided by dynamic area calculation.
[0041] In practical terms, the solution provided in this embodiment can be implemented through cross-component state binding: the rendering event of the first character in the reply presentation area serves as a hard synchronization signal, triggering the switching of the display state of the recommendation bar (from hidden to expanded), and simultaneously initiating the data binding of the recommended query items. If the interface space is limited, the aforementioned execution entity can automatically enable a smart folding strategy, such as compressing the row height of the reply presentation area or enabling semi-transparent coverage of the recommendation bar, ensuring that the visibility of the core content is not compromised when both coexist.
[0042] The solution provided in this embodiment achieves "zero-wait exposure" for recommendation queries by using the presentation time of the first character as an anchor point, thereby creating a decision window for subsequent user interruption behavior and ultimately achieving the core goal of reducing redundant waiting time and enhancing the degree of freedom of interaction.
[0043] To further enhance your understanding of the presentation format of the recommendation section and the selection format of the recommendation questions, please refer to [link / reference]. Figure 4 , Figure 4 This embodiment of the present disclosure provides a branch diagram illustrating different processing methods for determining a new query request based on different interfaces where a recommended query is selected. The scheme of "determining a new query request based on the selected recommended query in response to any recommended query being selected by the user" can be further subdivided into three cases: Scenario 1: In response to any recommended question being selected by the user in the recommendation bar of the question interaction interface, the selected recommended question will be treated as a new question request; This scenario assumes the query interface includes a response display area and a recommendation bar, with the recommendation bar preferably located below the response display area—that is, in a clearly defined bottom bar within the query interface. In this case, if a user directly selects any of the presented recommended queries from the recommendation bar, the selected query can be directly presented as a new query request in the response display area of the query interface (see [reference]). Figure 5-1 and Figure 5-2 , Figure 5-1 This is a diagram illustrating the location of the entry point for triggering a query with the large language model, shown in the currently playing video interface of a video application. Figure 5-2 It shows in Figure 5-1The diagram illustrates a query interaction interface presented in a seven-screen format after triggering a query with the large language model. From top to bottom, this interface includes a response display area and a recommendation section. Figure 5-2 The current conversation asks "What are the must-see museums in Italy?" and the recommendations section shows two suggestions: "Must-see attractions in Italy" and "Recommended Italian food".
[0044] Unlike situations where selections only occur on the query interaction interface, an additional input interface activation control can be set on the far right of the recommendation bar on the query interaction interface. When the user activates the input interface by selecting (e.g., clicking) the input interface activation control, the recommendation bar can also be set at the top of the input interface, which is a secondary interaction interface displayed on top of the query interaction interface. In other words, the act of selecting a recommended query can also occur on this input interface.
[0045] Scenario 2: In response to any recommended query being selected by the user in the recommendation bar of the input interface, the selected recommended query will be treated as a new query request.
[0046] This scenario assumes that the user selects any recommended query from the recommendation bar on the input interface. That is, although the user invokes the input interface by selecting a control, they haven't entered a new query in the input bar; instead, they've selected any recommended query from the recommendation bar at the top of the input interface. In this case, the selected recommended query can be directly returned to the query interaction interface as a new query request (i.e., the input interface is collapsed), and the new query response will be displayed in the response area of the query interaction interface (see [reference]). Figure 5-3 , Figure 5-3 This diagram illustrates the distribution of the recommendation bar, input bar, and keyboard area when the input interface is invoked based on the query interaction interface. In this case, the recommendation bar, input bar, and keyboard area are arranged from top to bottom within the input interface. This input interface can be accessed by the user clicking... Figure 5-2 The input interface on the far right of the recommendation bar in the query interaction interface is activated by the control and displayed on the upper layer of the query interaction interface in a five-screen split.
[0047] Scenario 3: In response to any recommended query being selected by the user in the recommendation bar of the input interface, the selected recommended query is copied to the input bar of the input interface, and when the user selects the send control of the input interface, the information in the current input bar is used as the new query request.
[0048] Building upon scenario two, this solution involves copying the selected recommended query to the input field after the user selects it in the recommendation bar of the input interface. This allows the user to modify or adjust the information in the input field using the input tool, ensuring that the final query content better meets the user's expectations. Furthermore, when the system receives the user's selection information for the send control on the input interface (e.g., being clicked or selected), the information in the current input field is used as a new query request.
[0049] Furthermore, when the input interface is invoked, the remaining characters constituting the query response can be stopped from being displayed. That is, because the input interface obscures the query interaction interface, the remaining characters of the query response do not need to continue to be displayed in the response display area.
[0050] Based on any of the above embodiments, when there are multiple different recommended queries (the recall number can be preset in the large language model or adjusted in real time according to the requirements in the prompt information), multiple different recommended queries can be distributed in a horizontal order in the recommendation bar, and the recommendation bar can support the presentation of different recommended queries by horizontal swiping, so as to facilitate users to view different recommended queries and finally select the one that matches their needs.
[0051] Furthermore, multiple recommended queries can be sorted from left to right according to the return order of the large language model, or displayed in order according to the degree of matching with the current user's interests, or according to the depth and level of the query content.
[0052] Furthermore, when users scroll up and down through the history of the inquiry interaction interface, the reply display area can also show the question corresponding to the second inquiry reply (i.e., the recommended question selected or modified at that time) between the two inquiry replies.
[0053] Further references Figure 6 As an implementation of the methods shown in the above figures, this disclosure provides an embodiment of a query recommendation device based on a large language model. This device embodiment is similar to... Figure 2 Corresponding to the method embodiments shown, this device can be specifically applied to various electronic devices.
[0054] like Figure 6As shown, the query recommendation device 600 based on a large language model in this embodiment may include: a query request receiving unit 601, a request processing unit 602, a recommended query presentation control unit 603, and a new query request generation processing 604. The query request receiving unit 601 is configured to receive a query request initiated by a user for a target video currently viewed in a video application; the request processing unit 602 is configured to input the query request and relevant content of the target video as prompt information into a preset large language model, obtaining an output query response and recommended query in a pending presentation state; the recommended query presentation control unit 603 is configured to present each character constituting the query response character by character, and to present the recommended query completely while presenting the first character constituting the query response; the new query request generation processing 604 is configured to, in response to any recommended query being selected by the user, terminate the presentation of the remaining characters constituting the query response, and input the selected recommended query as a new query request initiated for the target video and relevant content as prompt information into the large language model, obtaining an output new query response and new recommended query in a pending presentation state.
[0055] In this embodiment, the specific processing of the query request receiving unit 601, the request processing unit 602, the recommended query presentation control unit 603, and the new query request generation processing 604 in the query recommendation device 600 based on a large language model, and the resulting technical effects, can be found in the following references: Figure 2 The relevant descriptions of steps 201-204 in the corresponding embodiments will not be repeated here.
[0056] In some other alternative implementations of this embodiment, it is recommended that the query presentation control unit 603 be further configured as follows: The reply display area in the inquiry interaction interface displays each character that constitutes the inquiry reply, character by character; The response display area shows the first character that constitutes the response to the inquiry, while the recommended inquiry is fully displayed in the recommendation bar; the inquiry interaction interface includes the response display area and the recommendation bar.
[0057] In some other optional implementations of this embodiment, the recommendation bar is located below the reply display area; In response to any recommended question being selected by a user in the recommendation bar of the question interaction interface, the selected recommended question will be treated as a new question request.
[0058] In some other optional implementations of this embodiment, an input interface call-up control is also provided on the far right of the recommendation bar; In response to the user activating the input interface by selecting the input interface control, the recommendation bar is also placed at the top of the input interface; the input interface is a secondary interactive interface displayed above the query interaction interface.
[0059] In some other optional implementations of this embodiment, the query recommendation device 600 based on a large language model may further include: The stop-presentation control unit is configured to stop displaying the remaining characters that constitute a query response in response to the input interface being invoked.
[0060] In some other optional implementations of this embodiment, the query recommendation device 600 based on a large language model may further include: The new query request confirmation unit is configured to respond to any recommended query being selected by the user in the recommendation bar of the input interface, and to treat the selected recommended query as a new query request.
[0061] In some other optional implementations of this embodiment, the query recommendation device 600 based on a large language model may further include: The modification and adjustment unit is configured to respond to any recommended query being selected by the user in the recommendation bar of the input interface, copy the selected recommended query to the input bar of the input interface, and, upon receiving the user's selection information for the send control of the input interface, use the information in the current input bar as a new query request.
[0062] In some other optional implementations of this embodiment, the relevant content of the target video includes at least one of the following: Video title, video author, video type, video synopsis, related videos, video plot highlights, number of video segments, number of viewed videos, and video comments.
[0063] In some other optional implementations of this embodiment, the query request includes the query content and the user's preference information.
[0064] In some other optional implementations of this embodiment, in response to the existence of multiple different recommendation queries, the multiple different recommendation queries are distributed in the recommendation bar in a horizontally arranged order; wherein, the recommendation bar supports presenting different recommendation queries by horizontal swiping.
[0065] This embodiment exists as a device embodiment corresponding to the above method embodiment. The query recommendation device based on a large language model provided in this embodiment offers a solution for video applications integrating a large language model, allowing recommended queries to be presented to the user as early as possible. Specifically, when the large language model generates the query response and recommended query based on the user's query request, the recommended query is not presented after all the query responses have been presented, but rather simultaneously and completely with the first character constituting the query response. This allows the user to see the recommended query earlier, eliminating the need to wait for all query responses that do not contain the user's expected content to be presented. The user can then change the query and allow the large language model to regenerate a new query response, thereby minimizing unnecessary waiting time and reducing unnecessary interactions, thus improving human-computer interaction efficiency and enhancing the user's human-computer interaction experience. Furthermore, since the relevant content of the target video also contributes to the prompt information input to the large language model, the query response and recommended query are also generated based on the relevant video content, improving the matching degree with the user's needs in the current video viewing scenario.
[0066] According to embodiments of this disclosure, this disclosure also provides an electronic device, the electronic device comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to implement the query recommendation method based on the large language model described in any of the above embodiments.
[0067] According to embodiments of this disclosure, this disclosure also provides a readable storage medium storing computer instructions that enable a computer to implement the query recommendation method based on a large language model as described in any of the above embodiments.
[0068] According to embodiments of this disclosure, this disclosure also provides a computer program product that, when executed by a processor, can implement the steps of the query recommendation method based on a large language model described in any of the above embodiments.
[0069] Figure 7A schematic block diagram of an example electronic device 700 that can be used to implement embodiments of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device may also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the present disclosure described and / or claimed herein.
[0070] like Figure 7 As shown, device 700 includes a computing unit 701, which can perform various appropriate actions and processes based on a computer program stored in read-only memory (ROM) 702 or a computer program loaded into random access memory (RAM) 703 from storage unit 708. The RAM 703 may also store various programs and data required for the operation of device 700. The computing unit 701, ROM 702, and RAM 703 are interconnected via bus 704. Input / output (I / O) interface 705 is also connected to bus 704.
[0071] Multiple components in device 700 are connected to I / O interface 705, including: input unit 706, such as keyboard, mouse, etc.; output unit 707, such as various types of monitors, speakers, etc.; storage unit 708, such as disk, optical disk, etc.; and communication unit 709, such as network card, modem, wireless transceiver, etc. Communication unit 709 allows device 700 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.
[0072] The computing unit 701 can be various general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the computing unit 701 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 701 performs the various methods and processes described above, such as a query recommendation method based on a large language model. For example, in some embodiments, the query recommendation method based on a large language model can be implemented as a computer software program tangibly contained in a machine-readable medium, such as storage unit 708. In some embodiments, part or all of the computer program can be loaded and / or installed on device 700 via ROM 702 and / or communication unit 709. When the computer program is loaded into RAM 703 and executed by the computing unit 701, one or more steps of the query recommendation method based on a large language model described above can be performed. Alternatively, in other embodiments, the computing unit 701 may be configured, by any other suitable means (e.g., by means of firmware), to perform a query recommendation method based on a large language model.
[0073] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SoCs), payload-programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.
[0074] The program code used to implement the methods of this disclosure may be written in any combination of one or more programming languages. This program code may be provided to a processor or controller of a general-purpose computer, special-purpose computer, or other programmable data processing apparatus, such that when executed by the processor or controller, the program code causes the functions / operations specified in the flowcharts and / or block diagrams to be implemented. The program code may be executed entirely on a machine, partially on a machine, as a standalone software package partially on a machine and partially on a remote machine, or entirely on a remote machine or server.
[0075] In the context of this disclosure, a machine-readable medium can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can be, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.
[0076] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device for displaying information to the user (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor); and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the computer. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).
[0077] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as a data server), or computing systems that include middleware components (e.g., an application server), or computing systems that include frontend components (e.g., a user computer with a graphical user interface or web browser through which a user can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., a communication network). Examples of communication networks include local area networks (LANs), wide area networks (WANs), and the Internet.
[0078] Computer systems can include clients and servers. Clients and servers are generally located far apart and typically interact through communication networks. The client-server relationship is created by computer programs running on the respective computers and having a client-server relationship with each other. The server can be a cloud server, also known as a cloud computing server or cloud host, which is a hosting product within the cloud computing service system to address the shortcomings of traditional physical hosts and Virtual Private Server (VPS) services, such as high management difficulty and weak business scalability.
[0079] According to the technical solution of this disclosure, for video applications integrating a large language model, a solution is provided to present recommended queries to the user as early as possible. Specifically, when the large language model generates the query response and recommended query based on the user's query request, the recommended query is not presented after all the query responses have been presented, but rather simultaneously and completely with the first character constituting the query response. This allows the user to see the recommended query earlier, eliminating the need to wait for all query responses that do not contain the user's expected content to be presented. The user can then change the query and allow the large language model to regenerate a new query response, thereby improving human-computer interaction efficiency by minimizing unnecessary waiting time and reducing unnecessary interactions, thus enhancing the user's human-computer interaction experience. Furthermore, since the relevant content of the target video also contributes to the prompt information input to the large language model, the query response and recommended query are also generated based on the relevant video content, improving the matching degree with the user's needs in the current video viewing scenario.
[0080] It should be understood that the various forms of processes shown above can be used to rearrange, add, or delete steps. For example, the steps described in this disclosure can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution disclosed in this disclosure can be achieved, and this is not limited herein.
[0081] The specific embodiments described above do not constitute a limitation on the scope of protection of this disclosure. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this disclosure should be included within the scope of protection of this disclosure.
Claims
1. A query recommendation method based on a large language model, comprising: Receive queries from users regarding the target video currently being viewed in the video application; The query request and the relevant content of the target video are input together as prompt information into a preset large language model to obtain the output query response and recommended query in the pending presentation state; The system presents each character that constitutes the query response, and presents the recommended query in its entirety while presenting the first character that constitutes the query response. In response to any of the recommended queries being selected by the user, the presentation of the remaining characters constituting the query response is terminated, and the selected recommended query, along with the relevant content, is input into the large language model as a prompt message to initiate a new query request for the target video, resulting in the output of a new query response and a new recommended query in a pending presentation state.
2. The method according to claim 1, wherein, The presentation of each character constituting the query response, and the complete presentation of the recommended query while presenting the first character constituting the query response, includes: The reply display area in the inquiry interaction interface displays each character that constitutes the inquiry reply, character by character; The first character constituting the query response is displayed in the response display area, while the recommended query is fully displayed in the recommendation bar; wherein, the query interaction interface includes the response display area and the recommendation bar.
3. The method according to claim 2, wherein, The recommendation section is located below the response display area; In response to any of the recommended queries being selected by the user in the recommendation bar of the query interaction interface, the selected recommended query is used as the new query request.
4. The method according to claim 2, wherein, The rightmost side of the recommendation bar also has an input interface activation control. In response to the user activating the input interface by selecting the input interface activation control, the recommendation bar is also set at the top of the input interface; wherein, the input interface is a secondary interactive interface displayed above the query interaction interface.
5. The method according to claim 4, further comprising: In response to the input interface being invoked, the display of the remaining characters constituting the query response is stopped.
6. The method according to claim 4, further comprising: In response to any of the recommended queries being selected by the user in the recommendation bar of the input interface, the selected recommended query is treated as the new query request.
7. The method according to claim 4, further comprising: In response to any of the recommended queries being selected by the user in the recommendation bar of the input interface, the selected recommended query is copied to the input bar of the input interface, and when the user selects the send control of the input interface, the information in the current input bar is used as the new query request.
8. The method according to claim 1, wherein, The relevant content of the target video includes at least one of the following: Video title, video author, video type, video synopsis, related videos, video plot highlights, number of video segments, number of viewed videos, and video comments.
9. The method according to claim 1, wherein, The query request includes the query content and the user's preference information.
10. The method according to any one of claims 2-9, wherein, In response to the existence of multiple different recommended queries, the multiple different recommended queries are distributed in the recommendation bar in a horizontally arranged order; wherein, the recommendation bar supports the presentation of different recommended queries by horizontal swiping.
11. A query recommendation device based on a large language model, comprising: The query request receiving unit is configured to receive query requests initiated by users for the target video currently being viewed in the video application; The request processing unit is configured to input the query request and the relevant content of the target video as prompt information into a preset large language model, and obtain the output query response and recommended query in the state of waiting to be presented; The recommended query presentation control unit is configured to present each character constituting the query response word by word, and to present the recommended query completely while presenting the first character constituting the query response; The new query request generation process is configured to, in response to any of the recommended queries being selected by the user, terminate the presentation of the remaining characters constituting the query response, and input the selected recommended query as a new query request initiated against the target video and the related content together as prompt information into the large language model, thereby obtaining the output new query response and new recommended query in a pending presentation state.
12. An electronic device, comprising: At least one processor; as well as A memory communicatively connected to the at least one processor; wherein, The memory stores instructions executable by the at least one processor, which, when executed by the at least one processor, enables the at least one processor to perform the query recommendation method based on a large language model as described in any one of claims 1-10.
13. A non-transitory computer-readable storage medium storing computer instructions for causing the computer to perform the query recommendation method based on a large language model according to any one of claims 1-10.
14. A computer program product comprising a computer program that, when executed by a processor, implements the steps of the query recommendation method based on a large language model according to any one of claims 1-10.