System and method for dynamically updating front-end interface based on LLM (Language Language Model)
By designing a front-end interface dynamic update system based on large language model LLM, and using event-driven mechanism and state synchronization service mechanism, the active control and dynamic update of front-end interface components by large language model LLM is realized, solving the problem of inability to effectively control front-end interface updates in the existing technology, and improving human-computer interaction efficiency and system adaptability.
Patent Information
- Application Number
- CN202510253867.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-05
- Publication Date
- 2025-04-04
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The application of the existing large language model LLM in the web front-end interface is mainly passive content generators, and it is unable to effectively control the front-end interface for accurate and efficient dynamic updates.
A front-end interface dynamic update system based on large language model LLM is designed, including front-end, API server, large language model LLM, event instruction generation module and intelligent learning module. Through the event-driven mechanism and the state synchronization service mechanism, the active manipulation and dynamic update of front-end interface components by the large language model LLM is realized.
The large language model LLM has been transformed from a passive responder to an active interface controller, which has significantly improved the human-computer interaction efficiency, solved the problems of data misalignment and operational illusion in traditional solutions, and optimized the interaction logic through adaptive intelligent learning to adapt to the operating habits of different users.
Smart Images

Figure CN119759459A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to front-end interface updating, and in particular to a front-end interface dynamic updating system and method based on a large language model (LLM). Background Art
[0002] With the continuous development of artificial intelligence technology, large language models (LLMs) have made significant progress in the field of natural language processing and have been widely used in various software systems. However, in practical applications, the interaction and state synchronization between large language models (LLMs) and Web front-end interfaces still face challenges, especially how to use large language models (LLMs) to control Web front-end interfaces for accurate and efficient dynamic updates.
[0003] At present, the large language models (LLMs) of existing access systems usually interact with users in the form of text, pictures, etc. For example, the customer service system mainly interacts through text dialogue: For traditional AI dialogue systems: User asks “How do I change my address?” → LLM replies with text instructions “Please go to the Personal Center—Information Modification Page…” → User operates manually.
[0004] If users want to switch the style of the Web front-end interface, modify the layout, etc., they need to perform manual operations: modify the interface style - click settings - select the style; layout - select the font, etc. - apply. It can be seen that the existing large language model LLM in the system mainly plays the role of "passive content generator" (i.e. passive responder). How to upgrade the large language model LLM from a "passive content generator" to an "active interface manipulator" (i.e. active controller) to use the large language model LLM to control the Web front-end interface for accurate and efficient dynamic updates has become a technical problem that needs to be solved urgently. Summary of the invention
[0005] In view of the above-mentioned shortcomings of the prior art, the present invention provides a front-end interface dynamic update system and method based on a large language model LLM, which can effectively overcome the defect of the prior art that it is impossible to use the large language model LLM to control the Web front-end interface for accurate and efficient dynamic update.
[0006] To achieve the above objectives, the present invention is implemented through the following technical solutions: A front-end interface dynamic update system based on the large language model LLM, including the front-end, API server, large language model LLM, event instruction generation module and intelligent learning module; The front end sends a request to the API server to create a new session or obtain historical data based on the user's selection, and performs the corresponding UI update operation based on the returned event instructions; The API server receives requests from users during a user session and calls the Large Language Model (LLM). Large Language Model (LLM) intelligently analyzes user input, determines whether new interaction events need to be triggered, and generates trigger events corresponding to user input; The event instruction generation module converts the trigger events generated by the large language model LLM into structured event instructions based on the event-driven mechanism, and pushes the event instructions to the front end; The intelligent learning module intelligently analyzes user behavior trajectories during the dynamic update of the front-end interface. By comparing the execution effect of current event instructions with historical data, it dynamically optimizes the event generation strategy and front-end response logic of the large language model LLM, forming a closed-loop optimization system of "intention recognition-event execution-feedback learning".
[0007] Preferably, the front end sends a request to the API server to create a new session or obtain historical data according to the user's selection, including: When the user selects the "new session" related service, the front end requests the API server to create a new session space through the RESTful API interface, and obtains event instructions related to the session in the returned response; When the user selects the "historical data" related service, the front end requests historical data including historical session data and historical event instructions according to the ID to reproduce the state of the user calling the front end interface component; Among them, the front-end interface is implemented through Vue or other front-end frameworks, and functional components are built in.
[0008] Preferably, the API server receives a request initiated by a user during a user session and calls a large language model LLM, including: During a user session, the user sends a request through a conversation or by operating front-end interface elements, and the API server calls the large language model (LLM) for processing.
[0009] Preferably, the large language model LLM intelligently analyzes the user input, determines whether a new interaction event needs to be triggered, and generates a trigger event corresponding to the user input, including: The pre-intention recognition model of the Large Language Model (LLM) presets roles through prompt words, judges the prompt words in the user input, intelligently recognizes the user's intention, and confirms to answer ordinary content / call external tools / perform form operations; The large language model (LLM) intelligently analyzes user input, determines whether a new interaction event needs to be triggered, and generates a trigger event corresponding to the user input; Among them, in the process of dynamic update of the front-end interface, the large language model LLM plays the role of the front-end interface update decision maker, transforming from a passive responder to an active controller, and promoting the update of the front-end interface.
[0010] Preferably, the event instruction generation module converts the trigger event generated by the large language model LLM into a structured event instruction based on an event-driven mechanism, and pushes the event instruction to the front end, including: Verify the triggering events and structures to ensure the accuracy of the triggering events; After verification, based on the user intent recognition results, combined with function calls and prompt word engineering, the trigger event is converted into a structured event instruction, and the event instruction is pushed to the front end through the SSE protocol; The event instruction includes event type, description, data and parameters.
[0011] Preferably, the front end performs corresponding UI update operations according to the returned event instructions, including: The front-end code parses the event instructions and dynamically renders and updates the front-end interface components based on the event instruction parsing results.
[0012] Preferably, the intelligent learning module intelligently analyzes the user behavior trajectory during the dynamic update of the front-end interface, dynamically optimizes the event generation strategy and front-end response logic of the large language model LLM by comparing the current event instruction execution effect with historical data, and forms a closed-loop optimization system of "intention recognition-event execution-feedback learning", including: During the user session, the front-end interface and data processing methods are optimized by recording the user's operating habits, including front-end interface adjustments, data modification frequency, and common operation paths. The front-end framework adjusts the front-end interface layout according to the user's operating habits, making it easier for users to access frequently accessed content, reducing unnecessary interaction processes, and improving usage efficiency. In terms of trigger event generation, the content generated by trigger events is optimized in combination with the user's historical behavior and preference data. By analyzing the user's adjustment of the content generated by trigger events, the content generated by trigger events is optimized in the subsequent trigger event generation process. For content that is frequently modified or input by users, the content generated by trigger events is adjusted in the subsequent trigger event generation process to make it more in line with the user's actual needs and reduce unnecessary modifications. In terms of event command generation, we optimize the front-end response logic by combining the user's historical behavior and preference data. For event commands that are frequently modified or revoked by users, we reduce the execution frequency of the event commands and optimize the execution conditions to avoid unnecessary interactive interference and improve the accuracy and fluency of operations. In terms of system adaptability, when a significant deviation is detected between actual operations and the user's historical behavior and preference data, the interaction mode is automatically adjusted, and the content of fields frequently modified by users is automatically filled in, the default fill value is automatically adjusted, or a manual input option is provided to ensure that the data better meets the user's actual needs; Among them, during the user session, in order to reduce unnecessary data updates, the RESTful API interface is used for data updates. When the user modifies the data multiple times in a short period of time, the front end will perform the final data update after the user operation stabilizes, so as to reduce the system burden and improve data transmission efficiency.
[0013] Preferably, it also includes a state synchronization service module, which stores the execution content through the HTTP interface each time the front end updates or creates the front end interface component, so as to avoid the front end directly sending a one-way notification of the front end interface component status to the large language model LLM or sending a form of the front end interface component each time an event instruction is executed, thereby generating an illusion; When the large language model LLM needs to obtain the status of the front-end interface components or form content, it ensures accurate status information of the front-end interface components by querying in the status synchronization service module. An independent session ID is generated for each query to avoid confusion in operations. When the user modifies the form content, the front end updates the data and synchronizes it to the status synchronization service module through the RESTful API interface to ensure the consistency and real-time nature of the data obtained by the front end and the large language model LLM; Among them, the basis of the state synchronization service module is a relational database, which is used to store form content, current session data, historical session data, historical event instructions, and historical behavior and preference data.
[0014] The front-end interface dynamic update method based on the large language model LLM includes the following steps: S1. The front end sends a request to the API server to create a new session or obtain historical data based on the user's selection: When the user selects the "new session" related service, the front end requests the API server to create a new session space through the RESTful API interface, and obtains event instructions related to the session in the returned response; When the user selects the "historical data" related service, the front end requests historical data including historical session data and historical event instructions according to the ID to reproduce the state of the user calling the front end interface component; Among them, during the user session, by recording the user's operating habits, including front-end interface adjustments, data modification frequency and common operation paths, the front-end interface and data processing methods are optimized. The front-end framework adjusts the front-end interface layout according to the user's operating habits, making it easier for users to access frequently visited content, reducing unnecessary interaction processes and improving usage efficiency; S2, the front end and the large language model LLM obtain historical behavior and preference data related to the current session from the database through API service requests, and temporarily act on the session space; S3, the front end sends the user's operation event to the large language model LLM through the network interface for processing; S4, Large Language Model LLM intelligently analyzes user input, determines whether a new interaction event needs to be triggered, and generates a trigger event corresponding to the user input. For trigger event generation, the trigger event generation content is optimized in combination with the user's historical behavior and preference data. By analyzing the user's adjustment of the trigger event generation content, the trigger event generation content is optimized in the subsequent trigger event generation process; S5. The event instruction generation module converts the trigger events generated by the large language model LLM into structured event instructions based on the event-driven mechanism, and pushes the event instructions to the front end. For event instruction generation, the front end response logic is optimized in combination with the user's historical behavior and preference data; S6. The front end executes the corresponding UI update operation according to the returned event instruction. For system adaptability, when it detects that there is a significant deviation between the actual operation and the user's historical behavior and preference data, it automatically adjusts the interaction mode; S7, record the user's behavior trajectory and synchronize it to the database, and the database updates the historical behavior and preference data; S8. After the user sees the updated front-end interface displayed on the front-end, the user continues to perform interactive operations, repeats S1 to S7, and continuously executes event instructions in a loop to achieve dynamic update of the front-end interface.
[0015] Preferably, the large language model LLM in S4 performs intelligent analysis on the user input, determines whether a new interaction event needs to be triggered, and generates a trigger event corresponding to the user input, including: S41, the pre-intention recognition model of the large language model LLM presets roles through prompt words, judges the prompt words in the user input, intelligently recognizes the user's intention, and confirms to answer ordinary content / call external tools / perform form operations; S42, the large language model LLM intelligently analyzes the user input, determines whether a new interaction event needs to be triggered, and generates a trigger event corresponding to the user input; Among them, in the process of dynamic update of the front-end interface, the large language model LLM plays the role of the front-end interface update decision maker, transforming from a passive responder to an active controller, and promoting the update of the front-end interface.
[0016] Compared with the prior art, the front-end interface dynamic update system and method based on the large language model LLM provided by the present invention has the following beneficial effects: 1) The first event-driven mechanism enables the large language model (LLM) to actively control the front-end interface components through a structured protocol, realizing intelligent operations such as automatic form filling and dynamic layout adjustment, significantly improving the efficiency of human-computer interaction; 2) Build a state synchronization service mechanism based on the intermediate API service, ensure the consistency of event instructions and the state of front-end interface components through real-time verification, and effectively solve the problems of data dislocation and operation illusion in traditional solutions; 3) Introduce adaptive intelligent learning, continuously optimize the interaction logic through intelligent analysis of user behavior trajectories, enable the system to automatically adapt to the operating habits of different users, reduce repetitive operation steps, and promote the evolution of human-computer interaction towards autonomy and personalization. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the prior art descriptions are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention, and for ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0018] Figure 1 It is a system schematic diagram of the present invention; Figure 2 It is a schematic diagram of the process of the present invention. DETAILED DESCRIPTION
[0019] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0020] The front-end interface dynamic update system based on the large language model LLM, such as Figure 1 As shown, it includes the front end, API server, large language model LLM, event instruction generation module and intelligent learning module; The front end sends a request to the API server to create a new session or obtain historical data based on the user's selection, and performs the corresponding UI update operation based on the returned event instructions; The API server receives requests from users during a user session and calls the Large Language Model (LLM). Large Language Model (LLM) intelligently analyzes user input, determines whether new interaction events need to be triggered, and generates trigger events corresponding to user input; The event instruction generation module converts the trigger events generated by the large language model LLM into structured event instructions based on the event-driven mechanism, and pushes the event instructions to the front end; The intelligent learning module intelligently analyzes user behavior trajectories during the dynamic update of the front-end interface. By comparing the execution effect of current event instructions with historical data, it dynamically optimizes the event generation strategy and front-end response logic of the large language model LLM, forming a closed-loop optimization system of "intention recognition-event execution-feedback learning".
[0021] ① The front end sends a request to the API server based on the user's selection to create a new session or obtain historical data, including: When the user selects the "new session" related service, the front end requests the API server to create a new session space through the RESTful API interface, and obtains event instructions related to the session in the returned response; When the user selects the "historical data" related service, the front end requests historical data including historical session data and historical event instructions according to the ID to reproduce the state of the user calling the front end interface component; Among them, the front-end interface is implemented through Vue or other front-end frameworks (such as React, etc.), and functional components are built in.
[0022] ②The API server receives the request initiated by the user during the user session and calls the large language model LLM, including: During a user session, the user sends a request through a conversation or by operating front-end interface elements, and the API server calls the large language model (LLM) for processing.
[0023] ③ The large language model LLM intelligently analyzes the user input, determines whether a new interaction event needs to be triggered, and generates a trigger event corresponding to the user input, including: The pre-intention recognition model of the Large Language Model (LLM) presets roles through prompt words, judges the prompt words in the user input, intelligently recognizes the user's intention, and confirms to answer ordinary content / call external tools / perform form operations; The Large Language Model (LLM) intelligently analyzes user input to determine whether new interaction events need to be triggered (such as displaying forms, updating content, performing data operations, etc.), and generates trigger events corresponding to user input; Among them, in the process of dynamic update of the front-end interface, the large language model LLM plays the role of the front-end interface update decision maker, transforming from a passive responder to an active controller, and promoting the update of the front-end interface.
[0024] ④ The event instruction generation module converts the trigger events generated by the large language model LLM into structured event instructions based on the event-driven mechanism, and pushes the event instructions to the front end, including: Verify the triggering events and structures to ensure the accuracy of the triggering events; After verification, based on the user intent recognition results, combined with function calls and prompt word engineering, the trigger event is converted into a structured event instruction, and the event instruction is pushed to the front end through the SSE protocol; The event instruction includes event type, description, data and parameters, as shown in Table 1: Table 1 Event command content information table
[0025] ⑤The front end performs corresponding UI update operations according to the returned event instructions, including: The front-end code parses the event instructions and dynamically renders and updates the front-end interface components (such as form items, text display, image loading, collection files, etc.) according to the event instruction parsing results.
[0026] When the front end receives the form_action.new event command, it will be judged as starting a new form operation task, and a new form will be displayed for the user to fill in. After saving, the large language model LLM will synchronously obtain the form content. When the large language model LLM is required to update a certain content, it will return the display_action event command and the updated content, and the front end will render and update the content.
[0027] ⑥ The intelligent learning module intelligently analyzes the user behavior trajectory during the dynamic update of the front-end interface. By comparing the execution effect of the current event instruction with historical data, it dynamically optimizes the event generation strategy and front-end response logic of the large language model LLM, forming a closed-loop optimization system of "intention recognition-event execution-feedback learning", including: During the user session, the front-end interface and data processing methods are optimized by recording the user's operating habits, including front-end interface adjustments, data modification frequency, and common operation paths. The front-end framework adjusts the front-end interface layout according to the user's operating habits, making it easier for users to access frequently accessed content, reducing unnecessary interaction processes, and improving usage efficiency. In terms of trigger event generation, the content generated by trigger events is optimized in combination with the user's historical behavior and preference data. By analyzing the user's adjustment of the content generated by trigger events, the content generated by trigger events is optimized in the subsequent trigger event generation process. For content that is frequently modified or input by users, the content generated by trigger events is adjusted in the subsequent trigger event generation process to make it more in line with the user's actual needs and reduce unnecessary modifications. In terms of event command generation, we optimize the front-end response logic by combining the user's historical behavior and preference data. For event commands that are frequently modified or revoked by users, we reduce the execution frequency of the event commands and optimize the execution conditions to avoid unnecessary interactive interference and improve the accuracy and fluency of operations. In terms of system adaptability, when a significant deviation is detected between actual operations and the user's historical behavior and preference data, the interaction mode is automatically adjusted, and the content of fields frequently modified by users is automatically filled in, the default fill value is automatically adjusted, or a manual input option is provided to ensure that the data better meets the user's actual needs; Among them, during the user session, in order to reduce unnecessary data updates, the RESTful API interface is used for data updates. When the user modifies the data multiple times in a short period of time, the front end will perform the final data update after the user operation stabilizes, so as to reduce the system burden and improve data transmission efficiency.
[0028] ⑦ The technical solution of the present application also includes a state synchronization service module. The state synchronization service module stores the execution content through the HTTP interface each time the front-end updates or creates the front-end interface component, so as to avoid the front-end directly sending a one-way notification of the state of the front-end interface component to the large language model LLM or sending a form of the front-end interface component each time an event instruction is executed, which causes hallucinations; When the large language model LLM needs to obtain the status of the front-end interface components or form content, it ensures accurate status information of the front-end interface components by querying in the status synchronization service module. An independent session ID is generated for each query to avoid confusion in operations. When the user modifies the form content, the front end updates the data and synchronizes it to the status synchronization service module through the RESTful API interface to ensure the consistency and real-time nature of the data obtained by the front end and the large language model LLM; Among them, the basis of the state synchronization service module is a relational database, which is used to store form content, current session data, historical session data, historical event instructions, and historical behavior and preference data.
[0029] In the technical solution of this application, on the basis of the above-mentioned front-end interface dynamic update system based on the large language model LLM, a front-end interface dynamic update method based on the large language model LLM is also disclosed, such as Figure 2 As shown, the following steps are included: S1. The front end sends a request to the API server to create a new session or obtain historical data based on the user's selection: When the user selects the "new session" related service, the front end requests the API server to create a new session space through the RESTful API interface, and obtains event instructions related to the session in the returned response; When the user selects the "historical data" related service, the front end requests historical data including historical session data and historical event instructions according to the ID to reproduce the state of the user calling the front end interface component; Among them, during the user session, by recording the user's operating habits, including front-end interface adjustments, data modification frequency and common operation paths, the front-end interface and data processing methods are optimized. The front-end framework adjusts the front-end interface layout according to the user's operating habits, making it easier for users to access frequently visited content, reducing unnecessary interaction processes and improving usage efficiency; S2, the front end and the large language model LLM obtain historical behavior and preference data related to the current session from the database through API service requests, and temporarily act on the session space; S3, the front end sends the user's operation event to the large language model LLM through the network interface for processing; S4, Large Language Model LLM intelligently analyzes user input, determines whether a new interaction event needs to be triggered, and generates a trigger event corresponding to the user input. For trigger event generation, the trigger event generation content is optimized in combination with the user's historical behavior and preference data. By analyzing the user's adjustment of the trigger event generation content, the trigger event generation content is optimized in the subsequent trigger event generation process; S5. The event instruction generation module converts the trigger events generated by the large language model LLM into structured event instructions based on the event-driven mechanism, and pushes the event instructions to the front end. For event instruction generation, the front end response logic is optimized in combination with the user's historical behavior and preference data; S6. The front end executes the corresponding UI update operation according to the returned event instruction. For system adaptability, when it detects that there is a significant deviation between the actual operation and the user's historical behavior and preference data, it automatically adjusts the interaction mode; S7, record the user's behavior trajectory and synchronize it to the database, and the database updates the historical behavior and preference data; S8. After the user sees the updated front-end interface displayed on the front-end, the user continues to perform interactive operations, repeats S1 to S7, and continuously executes event instructions in a loop to achieve dynamic update of the front-end interface.
[0030] Specifically, the large language model LLM in S4 intelligently analyzes the user input, determines whether a new interaction event needs to be triggered, and generates a trigger event corresponding to the user input, including: S41, the pre-intention recognition model of the large language model LLM presets roles through prompt words, judges the prompt words in the user input, intelligently recognizes the user's intention, and confirms to answer ordinary content / call external tools / perform form operations; S42, the large language model LLM intelligently analyzes the user input, determines whether a new interaction event needs to be triggered, and generates a trigger event corresponding to the user input; Among them, in the process of dynamic update of the front-end interface, the large language model LLM plays the role of the front-end interface update decision maker, transforming from a passive responder to an active controller, and promoting the update of the front-end interface.
[0031] It is worth noting that the technical solution of the present application can be applied not only to Web front-end interfaces, but also to front-end interfaces such as desktops, applets, mobile terminals, and embedded devices.
[0032] The above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements will not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A front-end interface dynamic update system based on a large language model (LLM), characterized by: Including front-end, API server, large language model LLM, event instruction generation module and intelligent learning module; The front end sends a request to the API server to create a new session or obtain historical data based on the user's selection, and performs the corresponding UI update operation based on the returned event instructions; The API server receives requests from users during a user session and calls the Large Language Model (LLM). Large Language Model (LLM) intelligently analyzes user input, determines whether new interaction events need to be triggered, and generates trigger events corresponding to user input; The event instruction generation module converts the trigger events generated by the large language model LLM into structured event instructions based on the event-driven mechanism, and pushes the event instructions to the front end; The intelligent learning module intelligently analyzes user behavior trajectories during the dynamic update of the front-end interface. By comparing the execution effect of current event instructions with historical data, it dynamically optimizes the event generation strategy and front-end response logic of the large language model LLM, forming a closed-loop optimization system of "intention recognition-event execution-feedback learning".
2. The front-end interface dynamic update system based on the large language model LLM according to claim 1, characterized in that: The front end sends a request to the API server based on the user's selection to create a new session or obtain historical data, including: When the user selects the "new session" related service, the front end requests the API server to create a new session space through the RESTful API interface, and obtains event instructions related to the session in the returned response; When the user selects the "historical data" related service, the front-end requests historical data including historical session data and historical event instructions based on the ID to reproduce the state of the user calling the front-end interface component; Among them, the front-end interface is implemented through Vue or other front-end frameworks, and functional components are built in.
3. The front-end interface dynamic update system based on the large language model LLM according to claim 2 is characterized in that: The API server receives a request initiated by a user during a user session and calls the large language model LLM, including: During a user session, the user sends a request through a conversation or by operating front-end interface elements, and the API server calls the large language model (LLM) for processing.
4. The front-end interface dynamic update system based on the large language model LLM according to claim 3 is characterized in that: The large language model LLM intelligently analyzes the user input, determines whether a new interaction event needs to be triggered, and generates a trigger event corresponding to the user input, including: The LLM pre-intention recognition model uses prompt words to preset roles, judge the prompt words in the user input, intelligently identify the user's intention, and confirm to answer ordinary content / call external tools / perform form operations; The large language model (LLM) intelligently analyzes user input, determines whether a new interaction event needs to be triggered, and generates a trigger event corresponding to the user input; Among them, in the process of dynamic update of the front-end interface, the large language model LLM plays the role of the front-end interface update decision maker, transforming from a passive responder to an active controller, and promoting the update of the front-end interface.
5. The front-end interface dynamic update system based on the large language model LLM according to claim 4 is characterized in that: The event instruction generation module converts the trigger event generated by the large language model LLM into a structured event instruction based on the event-driven mechanism, and pushes the event instruction to the front end, including: Verify the triggering events and structures to ensure the accuracy of the triggering events; After verification, based on the user intent recognition results, combined with function calls and prompt word engineering, the trigger event is converted into a structured event instruction, and the event instruction is pushed to the front end through the SSE protocol; The event instruction includes event type, description, data and parameters.
6. The front-end interface dynamic update system based on the large language model LLM according to claim 5, characterized in that: The front end performs corresponding UI update operations according to the returned event instructions, including: The front-end code parses the event instructions and dynamically renders and updates the front-end interface components based on the event instruction parsing results.
7. The front-end interface dynamic update system based on the large language model LLM according to any one of claims 1 to 6, characterized in that: The intelligent learning module intelligently analyzes the user behavior trajectory during the dynamic update of the front-end interface, dynamically optimizes the event generation strategy and front-end response logic of the large language model LLM by comparing the current event instruction execution effect with historical data, and forms a closed-loop optimization system of "intention recognition-event execution-feedback learning", including: During the user session, the front-end interface and data processing methods are optimized by recording the user's operating habits, including front-end interface adjustments, data modification frequency, and common operation paths. The front-end framework adjusts the front-end interface layout according to the user's operating habits, making it easier for users to access frequently visited content. In terms of trigger event generation, the content generated by trigger events is optimized in combination with the user's historical behavior and preference data. By analyzing the user's adjustment of the content generated by trigger events, the content generated by trigger events is optimized in the subsequent trigger event generation process. For content that is frequently modified or input by users, the content generated by trigger events is adjusted in the subsequent trigger event generation process to make it more in line with the user's actual needs and reduce unnecessary modifications. In terms of event command generation, we optimize the front-end response logic by combining the user's historical behavior and preference data. For event commands that are frequently modified or revoked by users, we reduce the execution frequency of the event commands and optimize the execution conditions to avoid unnecessary interaction interference. In terms of system adaptability, when a significant deviation is detected between actual operations and the user's historical behavior and preference data, the interaction mode is automatically adjusted, and the content of fields frequently modified by users is automatically filled in, the default fill value is automatically adjusted, or a manual input option is provided to ensure that the data better meets the user's actual needs; Among them, during the user session, in order to reduce unnecessary data updates, the RESTful API interface is used for data updates. When the user modifies the data multiple times in a short period of time, the front end will perform the final data update after the user operation stabilizes, so as to reduce the system burden and improve data transmission efficiency.
8. The front-end interface dynamic update system based on the large language model LLM according to claim 7, characterized in that: It also includes a state synchronization service module, which stores the execution content through the HTTP interface each time the front end updates or creates the front end interface component, so as to avoid the front end directly sending a one-way notification of the front end interface component status to the large language model LLM or sending a form of the front end interface component each time an event instruction is executed, thereby generating an illusion; When the large language model LLM needs to obtain the status of the front-end interface components or form content, it ensures accurate status information of the front-end interface components by querying in the status synchronization service module. An independent session ID is generated for each query to avoid confusion in operations. When the user modifies the form content, the front end updates the data and synchronizes it to the status synchronization service module through the RESTful API interface to ensure the consistency and real-time nature of the data obtained by the front end and the large language model LLM; Among them, the basis of the state synchronization service module is a relational database, which is used to store form content, current session data, historical session data, historical event instructions, and historical behavior and preference data.
9. A front-end interface dynamic update method based on a large language model LLM, applied to a front-end interface dynamic update system based on a large language model LLM as claimed in claim 1, characterized in that: The following steps are involved: S1. The front end sends a request to the API server to create a new session or obtain historical data based on the user's selection: When the user selects the "new session" related service, the front end requests the API server to create a new session space through the RESTful API interface, and obtains event instructions related to the session in the returned response; When the user selects the "historical data" related service, the front-end requests historical data including historical session data and historical event instructions based on the ID to reproduce the state of the user calling the front-end interface component; Among them, during the user session, by recording the user's operating habits, including front-end interface adjustments, data modification frequency and common operation paths, the front-end interface and data processing methods are optimized. The front-end framework adjusts the front-end interface layout according to the user's operating habits, making it easier for users to access frequently visited content; S2, the front end and the large language model LLM obtain historical behavior and preference data related to the current session from the database through API service requests, and temporarily act on the session space; S3, the front end sends the user's operation event to the large language model LLM through the network interface for processing; S4, Large Language Model LLM intelligently analyzes user input, determines whether a new interaction event needs to be triggered, and generates a trigger event corresponding to the user input. For trigger event generation, the trigger event generation content is optimized in combination with the user's historical behavior and preference data. By analyzing the user's adjustment of the trigger event generation content, the trigger event generation content is optimized in the subsequent trigger event generation process; S5. The event instruction generation module converts the trigger events generated by the large language model LLM into structured event instructions based on the event-driven mechanism, and pushes the event instructions to the front end. For event instruction generation, the front end response logic is optimized in combination with the user's historical behavior and preference data; S6. The front end executes the corresponding UI update operation according to the returned event instruction. For system adaptability, when it detects that there is a significant deviation between the actual operation and the user's historical behavior and preference data, it automatically adjusts the interaction mode; S7, record the user's behavior trajectory and synchronize it to the database, and the database updates the historical behavior and preference data; S8. After the user sees the updated front-end interface displayed on the front-end, the user continues to perform interactive operations, repeats S1 to S7, and continuously executes event instructions in a loop to achieve dynamic update of the front-end interface.
10. The front-end interface dynamic update method based on the large language model LLM according to claim 9, characterized in that: The large language model (LLM) in S4 intelligently analyzes user input, determines whether a new interaction event needs to be triggered, and generates a trigger event corresponding to the user input, including: S41, the pre-intention recognition model of the large language model LLM presets roles through prompt words, judges the prompt words in the user input, intelligently recognizes the user's intention, and confirms to answer ordinary content / call external tools / perform form operations; S42, the large language model LLM intelligently analyzes the user input, determines whether a new interaction event needs to be triggered, and generates a trigger event corresponding to the user input; Among them, in the process of dynamic update of the front-end interface, the large language model LLM plays the role of the front-end interface update decision maker, transforming from a passive responder to an active controller, and promoting the update of the front-end interface.
Citation Information
Patent Citations
Application development method, electronic equipment, storage medium and program product
CN118092890A
Task execution method, electronic equipment, computer storage medium and program product
CN118964518A
Task processing method and device, electronic equipment and storage medium
CN119537541A
SYSTEM AND METHOD FOR ADAPTIVELY TRAVERSING CONVERSATION STATES USING CONVERSATIONAL Al TO EXTRACT CONTEXTUAL INFORMATION
US20240096312A1
Cited By
Processing method and device for text request
CN122133817A