Session process control method and device, equipment and storage medium

By splitting the conversation process into global and domain components, using component identification to generate session output text, the computing resource occupation problem caused by frequent fine-tuning of the big model is solved, and the stability and flexibility of the conversation process are achieved.

CN120452438APending Publication Date: 2025-08-08BEIJING WATERDROP TECH GRP CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510361981.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-25
Publication Date
2025-08-08

AI Technical Summary

Technical Problem

In the prior art, frequent fine-tuning of large models will continue to occupy a large amount of computing resources, making it difficult to ensure the stability of session process control.

Method used

Split the session process into global components and domain components, determine the component identity by constructing session context information, and transferring it to the corresponding components to generate output text, avoiding frequent fine-tuning of the large model.

Benefits of technology

It realizes the stability and flexibility of the session process, reduces the use of computing resources, and speeds up the session process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120452438A_ABST
    Figure CN120452438A_ABST
Patent Text Reader

Abstract

The invention discloses a session process control method and device, equipment and a storage medium, relates to the technical field of intelligent sessions, and aims at realizing logic processing of different problems by calling different session process components, accelerating the session process and ensuring the stability of session process control. The method comprises the steps that a session process is split into session process components with different functions, the session process components comprise a global component and at least one field component, the global component is used for global control of the session process and logic processing of universal problems in the session process, and the field component is used for logic processing of field problems in the session process; in response to an interaction instruction of the session process, determining a component identifier called by the session process according to session context information constructed by the session input text; and transferring the session context information to a corresponding session process component according to the component identifier called by the session process, so that the corresponding session process component generates a session output text according to the session context information.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of intelligent conversation technology, and in particular to a conversation process control method, apparatus, device, and storage medium. Background Art

[0002] With the rapid development of artificial intelligence technology, conversational robots are becoming increasingly integrated into people's daily lives. For some everyday conversation scenarios, the control process of the conversation process can use a trained general large-scale model to understand the intention behind the user's words and generate corresponding responses.

[0003] In related technologies, general-purpose large models have powerful language capabilities, generation and knowledge reasoning capabilities, and perform well in various natural language processing tasks. Considering that different fields have their own unique language styles, terminology systems, and ways of thinking, general-purpose large models may find it difficult to fully adapt to the special requirements of specific fields. In specific fields, the control of conversation processes can use specific domain data to train large models or use general-purpose large models combined with specific scenario conversation data for fine-tuning to enhance the general-purpose large model's understanding of domain knowledge and build a large model for specific fields. However, private data in specific fields will continue to update and change over time, which requires frequent fine-tuning of large models. Frequent fine-tuning of large models will continue to occupy a large amount of computing resources, causing large fluctuations in the output of the large model, making it difficult to ensure the stability of conversation process control. Summary of the Invention

[0004] In view of this, the present application provides a method, device and equipment for controlling the conversation process, the main purpose of which is to solve the problem in the existing technology that frequent fine-tuning of large models will continue to occupy a large amount of computing resources, causing large fluctuations in the output of the large model, and it is difficult to ensure the stability of the conversation process control.

[0005] According to a first aspect of the present application, a method for controlling a session flow is provided, comprising:

[0006] Split the conversation process into conversation process components with different functions. The conversation process components include a global component and at least one domain component. The global component is used for global control of the conversation process and logical processing of common problems in the conversation process. The domain component is used for logical processing of domain problems in the conversation process.

[0007] In response to the interactive instruction of the conversation process, determining the component identifier of the conversation process call according to the conversation context information constructed from the conversation input text;

[0008] The session context information is transferred to a corresponding session process component according to the component identifier called by the session process, so that the corresponding session process component generates a session output text according to the session context information.

[0009] Furthermore, the splitting of the conversation process into conversation process components with different functions includes:

[0010] Collecting conversation process data of different business scenarios in advance, and extracting the interactive links of the conversation process based on the conversation process data;

[0011] Determining, based on the interaction links of the conversation process, process nodes that affect conversation decisions in the conversation process;

[0012] The conversation process is split into conversation process components with different functions according to the process nodes that affect the conversation decision.

[0013] Furthermore, after splitting the conversation process into conversation process components with different functions, the method further includes:

[0014] A routing prompting statement of a conversation process component is constructed, wherein the routing prompting statement is used to determine a component identifier of a conversation process call according to conversation context information.

[0015] Furthermore, determining the component identifier of the conversation process call according to the conversation context information constructed from the conversation input text includes:

[0016] Inputting the conversation context information constructed from the conversation input text and the routing prompt words of the conversation process component into the universal big model, so that the universal big model performs classification reasoning on the conversation context information and the routing prompt words to obtain classification reasoning features;

[0017] Mapping the classification reasoning features to the probability space of different process components to obtain the probability of calling different session process components;

[0018] The component identifiers called by the conversation process are determined according to the probabilities of calling different conversation process components.

[0019] Furthermore, after splitting the conversation process into conversation process components with different functions, the method further includes:

[0020] Constructing a function prompting script for a conversation process component, wherein the function prompting script is used to guide the conversation process component to perform logical processing;

[0021] Accordingly, a process prompting speech is constructed for the global component, so that the global component performs logical processing on common questions in the conversation context information through the process prompting speech;

[0022] A domain prompting script is constructed for the domain component, so that the domain component performs logical processing on the domain problem in the conversation context information through the domain prompting script.

[0023] Furthermore, the transferring of the session context information to a corresponding session process component according to the component identifier called by the session process, so that the corresponding session process component generates a session output text according to the session context information, includes:

[0024] Transferring the session context information to a corresponding session process component according to the component identifier, so as to call the universal large model through the corresponding session process component;

[0025] Inputting the conversation context information and the functional prompt words of the conversation process component into a universal macro model, so that the universal macro model fuses the conversation context information with the functional prompt words to obtain conversation fusion information;

[0026] Logical reasoning is performed based on the conversation fusion information to generate a conversation output text.

[0027] Furthermore, after constructing the function prompting words of the conversation process component, the method further includes:

[0028] By utilizing the dependency relationship between the domain component and the global component, associated prompts are added to the domain prompt dialogue and / or the process prompt dialogue to guide the conversation process from the domain conversation component to the global conversation component or from the global conversation component to the domain conversation component through the associated prompts.

[0029] According to a second aspect of the present application, a session flow control device is provided, comprising:

[0030] A splitting unit, configured to split a conversation process into conversation process components with different functions, wherein the conversation process components include a global component and at least one domain component. The global component is used for global control of the conversation process and logical processing of common problems in the conversation process, and the domain component is used for logical processing of domain problems in the conversation process.

[0031] a determining unit, configured to determine, in response to an interactive instruction of the conversation process, a component identifier called by the conversation process according to conversation context information constructed from conversation input text;

[0032] A generating unit is configured to transfer the session context information to a corresponding session process component according to a component identifier called by the session process, so that the corresponding session process component generates a session output text according to the session context information.

[0033] Furthermore, the splitting unit is specifically used to:

[0034] Collecting conversation process data of different business scenarios in advance, and extracting the interactive links of the conversation process based on the conversation process data;

[0035] Determining, based on the interaction links of the conversation process, process nodes that affect conversation decisions in the conversation process;

[0036] The conversation process is split into conversation process components with different functions according to the process nodes that affect the conversation decision.

[0037] Furthermore, the device further comprises:

[0038] The first construction unit is configured to construct a routing prompting statement for the conversation process component after splitting the conversation process into conversation process components with different functions, wherein the routing prompting statement is used to determine a component identifier called by the conversation process according to the conversation context information.

[0039] Furthermore, the determining unit is specifically configured to:

[0040] Inputting the conversation context information constructed from the conversation input text and the routing prompt words of the conversation process component into the universal big model, so that the universal big model performs classification reasoning on the conversation context information and the routing prompt words to obtain classification reasoning features;

[0041] Mapping the classification reasoning features to the probability space of different process components to obtain the probability of calling different session process components;

[0042] The component identifiers called by the conversation process are determined according to the probabilities of calling different conversation process components.

[0043] Furthermore, the device further comprises:

[0044] A second construction unit is configured to construct function prompting words for the conversation process components after splitting the conversation process into conversation process components with different functions, wherein the function prompting words are used to guide the conversation process components to perform logical processing;

[0045] Accordingly, the second construction unit is specifically used to:

[0046] Constructing a process prompting speech for the global component, so that the global component performs logical processing on common questions in the conversation context information through the process prompting speech;

[0047] A domain prompting script is constructed for the domain component, so that the domain component performs logical processing on the domain problem in the conversation context information through the domain prompting script.

[0048] Furthermore, the generating unit is specifically configured to:

[0049] Transferring the session context information to a corresponding session process component according to the component identifier, so as to call the universal large model through the corresponding session process component;

[0050] Inputting the conversation context information and the functional prompt words of the conversation process component into a universal macro model, so that the universal macro model fuses the conversation context information with the functional prompt words to obtain conversation fusion information;

[0051] Logical reasoning is performed based on the conversation fusion information to generate a conversation output text.

[0052] Furthermore, the device further comprises:

[0053] An adding unit is used to add associated prompts in the domain prompt dialogue and / or the process prompt dialogue after constructing the function prompt dialogue of the conversation process component, utilizing the dependency relationship between the domain component and the global component, so as to guide the conversation process from the domain conversation component to the global conversation component or from the global conversation component to the domain conversation component through the associated prompts.

[0054] According to a third aspect of the present application, a computer device is provided, comprising a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the steps of the method for controlling the session process described in the first aspect are implemented.

[0055] According to a fourth aspect of the present application, a readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps of the method for controlling the conversation process described in the first aspect are implemented.

[0056] By leveraging the above technical solution, the present application provides a method, apparatus, device, and storage medium for controlling a conversation process. Compared to the existing method of controlling a conversation process by frequently calling and fine-tuning a large model, the present application divides the conversation process into conversation process components with different functions. The conversation process components include a global component and at least one domain component. The global component is used for global control of the conversation process and logical processing of common problems in the conversation process, and the domain component is used for logical processing of domain problems in the conversation process. In response to an interactive instruction of the conversation process, the identifier of the component to be called by the conversation process is determined based on the conversation context information constructed from the conversation input text. The conversation context information is transferred to the corresponding conversation process component based on the component identifier of the conversation process, so that the corresponding conversation process component generates conversation output text based on the conversation context information. The entire process does not logically process the entire conversation process as a large conversation component. Instead, by dividing the conversation process into conversation process components with different functions, the conversation process can be refined without fine-tuning the general large model, making the connection range of the conversation process components flexible and controllable. In this way, during the conversation interaction process, different conversation process components can be called to connect to the logical processing of different problems, accelerating the conversation process and ensuring the stability of conversation process control.

[0057] The above description is only an overview of the technical solution of the present application. In order to more clearly understand the technical means of the present application, it can be implemented in accordance with the contents of the specification. In order to make the above and other purposes, features and advantages of the present application more obvious and easy to understand, the specific implementation methods of the present application are listed below. BRIEF DESCRIPTION OF THE DRAWINGS

[0058] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:

[0059] Figure 1 This is a flowchart of a method for controlling a session flow provided by an embodiment of the present application;

[0060] Figure 2 yes Figure 1 A schematic flow chart of a specific implementation of step 101;

[0061] Figure 3 This is a flowchart of a method for controlling a session flow provided by another embodiment of the present application;

[0062] Figure 4 This is a flowchart of a method for controlling a session flow provided by another embodiment of the present application;

[0063] Figure 5This is a structural diagram of a control device for a conversation process in an embodiment of the present application;

[0064] Figure 6 The figure is a schematic diagram of the device structure of a computer device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0065] The present invention will now be discussed with reference to several exemplary embodiments. It should be understood that these embodiments are discussed only to enable those skilled in the art to better understand and implement the present invention, rather than to imply any limitation on the scope of the present invention.

[0066] As used herein, the term "including" and variations thereof are to be interpreted as open-ended terms meaning "including, but not limited to." The term "based on" is to be interpreted as "based, at least in part, on." The terms "one embodiment" and "an embodiment" are to be interpreted as meaning "at least one embodiment." The term "another embodiment" is to be interpreted as meaning "at least one other embodiment."

[0067] Related technologies: In specific domains, conversation flow control can be achieved by training a large model using domain-specific data, or by fine-tuning a general large model in combination with scenario-specific conversation data. This enhances the general large model's understanding of domain knowledge and builds a domain-specific large model. However, private data in a specific domain is constantly updated and changes over time, necessitating frequent fine-tuning of the large model. This frequent fine-tuning of the large model consumes significant computing resources, causing significant fluctuations in the large model's output and making it difficult to ensure the stability of conversation flow control.

[0068] In order to solve this problem, this embodiment provides a method for controlling a session flow, such as Figure 1 As shown, the method is applied to the server side of the session process control and includes the following steps:

[0069] 101. Split the conversation process into conversation process components with different functions.

[0070] In this embodiment, a conversation process is a communication process in which participants follow an orderly sequence of steps and patterns to transfer information in order to achieve a specific goal or bring the communication to a natural conclusion. It typically includes the initiation phase, the need confirmation node, the information exchange phase, the negotiation phase, and the strategy agreement phase.

[0071] In actual conversation flows, the basic conversation flow and FAQs are often combined. The basic conversation flow is a common conversation format that typically follows a certain logical sequence. For example, in a conversation between a customer service bot and a user, the bot first politely greets the user and asks about their needs. The user then explains their problem. The bot analyzes and answers the question, confirms with the user whether the problem has been resolved, and finally thanks the user for their inquiry and concludes the conversation. FAQs are a type of conversation format that organizes and summarizes common questions and their answers, typically presented as a list or knowledge base, allowing users to quickly find the answer to their question. For example, website help centers, product manuals, or customer service systems often feature FAQ sections covering frequently asked questions about product features, usage, after-sales service, and other areas. To combine the basic conversation flow and FAQs, you first need to build a basic conversation framework based on the basic conversation flow, clearly defining the various process nodes from start to finish. At each process node, analyze potential user questions and interactive content to extract FAQs. These extracted FAQs are then matched to various nodes in the basic conversation flow, allowing users to flexibly access FAQs based on user questions during the conversation. For example, in e-commerce business, when users inquire about product information, the answers to questions such as "product material" and "size specifications" in the FAQ can be applied here.

[0072] Furthermore, in order to verify the conversation process, multiple rounds of simulation can be performed from the perspective of at least one participant, simulating different types of user questions, including common questions and some special cases, to test whether the conversation process is smooth, whether the answers to common questions are accurate, and whether the conversation process is complete.

[0073] Among them, the session process component includes a global component and at least one domain component. The global component is used for global control of the session process and logical processing of common problems in the session process. The domain component is used for logical processing of domain problems in the session process. Common problems here refer to problems that will occur in multiple business scenarios or fields. For example, problems about system operation, such as "how to log in to the account", "what to do if you forget the password", etc. These problems are usually not dependent on specific business fields. Domain problems are problems closely related to specific business fields, such as "what are the pixels of this phone", "how to query order logistics information", etc. Different business fields will have different domain problems, and these problems need to be handled based on specific business knowledge and processes.

[0074] It's understandable that in order for global components and domain components to work together, clear interfaces and interaction methods need to be defined. On the one hand, the input and output parameters of each conversation process component need to be defined. For example, the input of a product inquiry component might be the product ID and the user's question, and the output is the answer to the user's question. On the other hand, the calling relationship and sequence between conversation process components need to be determined. In the conversation process, the user's question and business logic determine which component should be called first. For example, when a user asks a question about a product, the process component will be called first to perform the logical processing of the product resources. If the user subsequently asks how to purchase the product, the domain component will be called to perform the logical processing of the order purchase, guiding the user through the purchase process.

[0075] The execution subject of this embodiment can be a control device or equipment for the conversation process, which can be configured on the server side of the conversation process control. By splitting the conversation process into conversation process components with different functions, each conversation process component has specific functions and processing capabilities after the split, allowing the system to manage and control different functions and tasks separately, rather than treating the entire conversation process in a general way. In this way, the scope of responsibility of each conversation process component can be dynamically adjusted according to different conversation scenarios and user needs. For example, when a user asks a relatively simple question, the scope of responsibility of the conversation process component is narrowed, allowing it to focus on answering questions quickly and accurately. When handling complex business processes, the scope of responsibility of the conversation process component is expanded, allowing it to comprehensively handle multiple related tasks and improve the accuracy of the question and answer output results. Compared to the method of controlling the entire conversation process, the different conversation process components after the split are independent of each other. When it is necessary to iterate a certain conversation process component, only the corresponding conversation process component needs to be fine-tuned, improving the convenience of iteration.

[0076] 102. In response to the interactive instruction of the conversation process, determine the component identifier called by the conversation process according to the conversation context information constructed from the conversation input text.

[0077] In this embodiment, interactive instructions for the conversation process can be triggered by user input text, for example, a user entering a question description into the conversation engine. They can also be triggered by intent inference. For example, if a user mentions mobile phone-related features in the conversation engine, it can be inferred that the user's primary intent is to purchase a mobile phone, triggering a mobile phone recommendation process. Typically, to facilitate conversational contextual understanding, before the conversational text is entered, the conversational interaction text from each round is recorded sequentially to form a conversational history sequence. Based on the conversational text, the conversational interaction text is sequentially recorded to form the conversational context information for subsequent understanding. As new conversational text enters, the conversational context information is promptly updated based on the new conversational text. It is understood that to reduce conversational resource usage, key information extraction and intent understanding can be performed on the conversational interaction text before the conversational text is entered. The extracted key information and understood intent serve as the conversational context information for contextual understanding of the associated text. Accordingly, upon the arrival of new conversational text, the extracted widget information and understood intent are modified and / or supplemented based on the new conversational text.

[0078] The constructed session context information is further stored in a structured manner to facilitate system retrieval and use. Here, the structured manner can adopt data structures such as tables and dictionaries to store different types of information in corresponding fields respectively. In this way, when processing new session input text, the corresponding session context information can be updated efficiently.

[0079] Considering the different processing logic for interfacing different session process components, as one implementation, different session process components can be pre-analyzed to determine their key features. A mapping rule set can then be developed based on these key features. Session context information can then be mapped to different component identifiers using the mapping rule set. The session context information is then subjected to grammatical, syntactic, and semantic analysis to extract key session information. This information is then matched against the mapping rule set to determine the component identifiers that meet the requirements, i.e., the component identifiers invoked by the session process. As another implementation, a pre-trained large language model can be used to extract features from the session context information. The component identifiers invoked by the session process can then be determined based on the pre-learned mapping relationship between the features and the component identifiers. Alternatively, a combination of these two implementations can be employed: first, the component identifiers invoked by the session process can be determined using the mapping rule set. If this method fails to determine the unique component identifiers invoked by the session process, the large language model can be used to perform more detailed analysis and prediction of the session context information to determine the unique component identifiers invoked by the session process, thereby improving the accuracy and efficiency of component identifier determination.

[0080] 103. Transfer the session context information to a corresponding session process component according to the component identifier called by the session process, so that the corresponding session process component generates a session output text according to the session context information.

[0081] In this embodiment, after the component identifier of the conversation process call, the constructed conversation context information is accurately delivered to the conversation process component with the corresponding component identifier. This information typically includes historical interaction text, key information extraction results, semantic understanding content, etc. For example, if a user mentions in a conversation, "I want to book an economy class flight from Shanghai to Beijing next Friday," the system will send this conversation context information to the flight booking component.

[0082] Accordingly, after receiving the conversation context information, the conversation process component further understands the user's intent. Using a pre-trained large language model, it further analyzes the conversation context information to determine the user's specific needs and expectations. For example, the flight booking component uses the conversation context information to determine the user's departure location (Shanghai), destination (Beijing), departure time (next Friday), and cabin class (economy class). Then, based on the conversation context information, it integrates data resources for answering questions. For example, the flight booking component queries the flight schedule database to obtain flight information that meets the user's requirements, including flight number, departure time, landing time, and fare. Finally, based on this integrated data resource to understand the user's intent, the conversation journey component organizes the response content according to a specific logic and format. For the flight booking component, the generated conversation output might be something like, "We've found economy class flights from Shanghai to Beijing next Friday: Flight XXX, departure time XX:XX, landing time XX:XX, fare XXX yuan."

[0083] Furthermore, in order to improve the interactivity between the conversation output text and the physical world, the conversation output text can be interactively identified during or after the generation of the conversation output text. If the conversation output text is found to contain interactive keywords, the corresponding interactive method and the conversation output text are sent to the user together according to the interactive keywords, or the corresponding interactive resources are called according to the interactive keywords, so that the conversation process is guided by the interactive resources for subsequent logical processing, for example, sending friend requests or sending text messages through the interactive resources.

[0084] The conversation flow control method provided in the embodiments of the present application, compared to the existing method of controlling the conversation flow by frequently calling and fine-tuning a large model, divides the conversation flow into conversation flow components with different functions. The conversation flow components include a global component and at least one domain component. The global component is used for global control of the conversation flow and logical processing of common problems in the conversation flow, while the domain component is used for logical processing of domain problems in the conversation flow. In response to the interaction instructions of the conversation flow, the identifier of the component to be called by the conversation flow is determined based on the conversation context information constructed from the conversation input text. The conversation context information is transferred to the corresponding conversation flow component based on the component identifier of the conversation flow call, so that the corresponding conversation flow component generates conversation output text based on the conversation context information. The entire process does not logically process the entire conversation flow as a large conversation component. Instead, by breaking the conversation flow into conversation flow components with different functions, the conversation flow can be refined without fine-tuning the general large model, making the connection range of the conversation flow components flexible and controllable. In this way, during the conversation interaction process, different conversation flow components can be called to connect to the logical processing of different problems, accelerating the conversation process and ensuring the stability of conversation flow control.

[0085] In actual application scenarios, different types of tasks have different resource requirements during a session. When tasks with different resource requirements run in the same environment, resource competition is likely to occur, causing data queries to require a large amount of memory resources for data operations. Session process components are required to perform reasonable resource allocation and isolation. Specifically, in the above embodiment, if Figure 2 As shown, step 101 includes the following steps:

[0086] 201. Collect conversation process data of different business scenarios in advance, and extract interaction links of the conversation process based on the conversation process data.

[0087] 202. Determine, in the conversation process, a process node that affects the conversation decision based on the interaction link of the conversation process.

[0088] 203. Split the conversation process into conversation process components with different functions according to the process nodes that affect the conversation decision.

[0089] In this embodiment, a unified data collection interface is pre-designed for different business systems to integrate conversation data across the systems. Specifically, the conversation types and key nodes to be collected can be defined based on business needs. For example, e-commerce scenarios require focusing on processes such as product inquiries and payment exceptions. The data collection interface then stores user interaction data from different systems in a data warehouse, enabling integration of conversation process data across different business scenarios. The interaction nodes of the conversation process are further identified within the integrated conversation process data. This can be determined through statistical analysis. One method involves performing word frequency analysis on the conversation process data to identify the interaction nodes of the conversation process based on the most frequently occurring words. For example, if words such as "software failure" and "error code" frequently appear in online consultations, this indicates that the user is reporting a software issue. Another method is co-occurrence analysis, which analyzes the co-occurrence relationships of words in conversation process data to infer the interaction nodes of the conversation process. For example, in e-commerce conversations, the frequent co-occurrence of words such as "product name," "size," and "color" may indicate that the user is engaging in product inquiry.

[0090] Specifically, in the interactive links of the conversation process, we need to pay attention to the interactive links that guide the direction of the process and play a decisive role. For example, in a product sales conversation, aspects such as product core functions, after-sales service, and price consultation will affect the user's strategy of whether to purchase the product. By comparing the differences between the various interactive links in the conversation process and the relationship between the interactive links and the final decision, we can evaluate the impact of each interactive link on the conversation process and determine the interactive links with a high correlation with the conversation decision.

[0091] As a feasible implementation, a decision tree model can be built using the collected data and the analyzed interaction attributes. The target variable is the conversation decision, and the attributes of the interaction are the feature variables. This decision tree model allows you to intuitively identify which interactions significantly influence the conversation decision. The nodes corresponding to these interactions are the process nodes that influence the conversation decision. For example, a decision tree might show that the interaction of user feedback on course recommendations is a key node in determining whether to purchase a course. Therefore, course recommendations are a process node that influences conversation decisions. Another example is that the interaction of product display influences the user's willingness to buy or sell. Therefore, product display is a process node that influences conversation decisions.

[0092] The conversation process is further divided into different stages, using the process nodes that influence conversation decisions as boundaries. Each stage can be considered a conversation process component, with relatively independent functions and goals. For example, in an e-commerce shopping conversation, the conversation process can be divided into conversation process components such as product browsing, customer service consultation, and order processing, based on the process nodes that influence decision-making, such as "user selection of products," "user consultation with customer service," and "user order placement and payment." The function of each divided conversation process component is then summarized and described, clarifying each component's role in the overall conversation process and its relationship with other conversation process components.

[0093] It's understandable that, given the versatility of conversation flow components, during the specific division process, conversation flow components that are independent of specific business operations and perform common functions can be considered global components. These global components handle common tasks and functions throughout the entire conversation process, playing a key role in managing, controlling, and coordinating the entire conversation. They are not limited to a specific business domain or topic, but rather support all types of conversations. They primarily control the conversation flow, including starting, ending, transferring, and logically controlling multi-round conversations. Accordingly, conversation flow components responsible for domain-specific functions within the conversation process are considered domain components. Domain components focus on specific business domains or topics, providing specialized processing and solutions for different types of questions or tasks. For example, in an e-commerce customer service system, the product inquiry component handles user questions about product specifications, features, and usage; the order processing component handles order-related operations, including querying order status, modifying order information, and processing refunds. The functions of these components are confined to their respective business domains.

[0094] Furthermore, in the above embodiment, if Figure 3 As shown, after step 101, the method further includes the following steps:

[0095] 301. Construct the routing prompt words of the conversation process component.

[0096] Accordingly, step 102 includes the following steps:

[0097] 1021. Input the conversation context information constructed from the conversation input text and the routing prompt words of the conversation process component into the general big model, so that the general big model classifies and infers the conversation context information and the routing prompt words to obtain classification inference features.

[0098] 1022. Map the classification reasoning features to the probability space of different process components to obtain the probability of calling different session process components.

[0099] 1023. Determine a component identifier for the session process call according to the probability of calling different session process components.

[0100] In this embodiment, the routing prompt is used to determine the component identifiers of the session flow based on the session context. Here, the routing prompt guides the general model to focus on determining the component identifiers of the session flow. Key information extracted from the session context is incorporated into the routing prompt to expand the routing prompt. The expanded routing prompt then determines the component identifiers of the session flow based on the expanded routing prompt. For example, in the case of flight query, the expanded routing prompt might be "The user wants to query flight information from Shanghai to Beijing tomorrow." Based on this session context, the system determines which session flow component should be invoked to handle the user's request.

[0101] For example, in a financial scenario, the conversation process is divided into a main process component and a repayment component. The routing prompt script may include the following:

[0102] #

Character Settings

[0103] Who are you...

[0104] Based on the conversation record, determine which conversation process component you need to call to answer the parent's question. The conversation process components you can call are:

[0105] Main process component: mainly responsible for...

[0106] Repayment component: mainly responsible for...

[0107] #

Notes

[0109] #[Dialogue Record] ...

[0111] After inputting conversation context and routing prompts into the general large model, it converts the information into a vector form that the model can understand. Using mechanisms such as self-attention, the model then deeply analyzes the text's semantics, syntax, and contextual relationships to understand the conversation's intent and key information. Based on its understanding of the input, the model then performs classification reasoning based on learned knowledge and patterns, generating classification reasoning features. These features serve as an abstract representation of the degree of association between conversation process components. Finally, the classification reasoning features are mapped to the probability space of different process components. For example, the probability of a conversation process invoking the product inquiry component is calculated to be 0.2, while the probability of invoking the after-sales complaint component is calculated to be 0.7. The component identifier of the after-sales complaint component is then used as the component representation of the conversation process call.

[0112] In actual application scenarios, the conversation process is divided into global component A, domain component B, and domain component C. After the conversation context information and the routing prompts of the conversation process components are input into the general large model, the corresponding output can be the label A of the global component, and then the label A of the global component is used as the component identifier of the conversation process call, and jumps to the global component A. The corresponding output can also be in the form of probability space A: 0.2, B: 0.7, C: 0.1, and then the label B of the domain component with the highest probability is used as the component identifier of the conversation process call, and jumps to the global component B.

[0113] Furthermore, in the above embodiment, if Figure 4 As shown, after step 101, the method further includes the following steps:

[0114] 401. Construct the functional prompt words of the conversation process component.

[0115] Accordingly, step 103 includes the following steps:

[0116] 1031. Transfer the session context information to a corresponding session process component according to the component identifier, so as to call a universal large model through the corresponding session process component.

[0117] 1032. Input the conversation context information and the function prompt words of the conversation process component into the universal big model, so that the universal big model fuses the conversation context information with the function prompt words to obtain conversation fusion information.

[0118] 1033. Perform logical reasoning based on the conversation fusion information to generate a conversation output text.

[0119] In this embodiment, the function prompting language is used to guide the conversation process component to perform logical processing. Here, the function prompting language needs to break down the complex functions of the conversation process component into specific sub-functions and operations, and integrate the key information extracted from the conversation context information into the function prompting language, so as to convert the function prompting language into a fusion prompting language that protects the context information, and generate the conversation output text based on the fusion prompting language. For example, if a user asks "I want a mobile phone with good camera, and the budget is 3000-4000 yuan", the function prompting language is converted to "The user needs a mobile phone with good camera, and the budget is 3000-4000 yuan. Please use the function of the product recommendation component to generate the reply content based on this demand and context". The corresponding product recommendation component will filter and recommend the most suitable products from the product database based on the user's product preferences (such as style, color, function, etc.), budget constraints and past purchasing behavior, and then introduce in detail the unique selling points of the recommended products, their advantages compared with other similar products, and provide purchase links.

[0120] After inputting conversation context and function prompts into the general model, it fuses the information into a model-understandable feature vector. Based on this fused feature vector, the general model performs logical reasoning to determine the path for generating the output conversation text. This logical reasoning process determines how to organize the output text based on its understanding of the user's question and the information provided by the function prompt. Following the determined path, the general model generates word or subword units of the output conversation text one by one. For each unit, the general model predicts the next most likely word or subword based on the previous input and the generated text. This process is based on the language patterns and semantic relationships learned by the general model from massive amounts of text data. For example, in a hotel reservation scenario, if a user asks, "I'd like to book a hotel in Paris. Any recommendations?" the general model, based on the function prompt accelerator in the "Hotel Booking Component," determines that it needs to retrieve Paris hotel information from the hotel database. It then filters and recommends hotels based on specific criteria (such as ratings and prices), generating the appropriate response logic.

[0121] Considering the diverse functions of conversational process components, the general model for global components takes a broader perspective to understand the relationship between their functionality and the conversational context. For example, for a global search component, regardless of the domain scenario, as long as the user has a search-related need, the model can associate it with the global search component's functionality. For domain components, the general model integrates domain-specific knowledge and context to understand their functionality. For example, in the medical field, for a component that queries diseases based on symptoms, the model needs to understand medical terminology and the correspondence between symptoms and diseases, accurately matching the user's symptoms with the component's functionality. Furthermore, based on the fused feature representation, the model determines the path to generate the output conversation text based on its understanding of the user's question and the functional prompts. For global components, a relatively general process is typically used. For example, the global search component searches the entire knowledge system based on the user's input keywords and generates a description of the search results according to certain sorting rules. For domain components, the path generation requires domain-specific logic and rules. For example, in the legal field, the model analyzes the user's question based on specific legal provisions and cases and determines how to apply relevant components to provide accurate legal advice.

[0122] Accordingly, a process prompting speech is constructed for the global component, so that the global component performs logical processing on common questions in the conversation context information through the process prompting speech;

[0123] A domain prompting script is constructed for the domain component, so that the domain component performs logical processing on the domain problem in the conversation context information through the domain prompting script.

[0124] For example, in a financial scenario, the function prompts for global components may include the following:

[0125] #

Task Settings

[0126] You are..., mainly responsible for...

[0127] #[Dialogue Flow]

[0128] Here's the overall flow of the conversation...

[0129] ##1. Opening stage

[0130] -Confirmation time: Ask if it is convenient

[0131] -Introduction: Briefly explain your purpose

[0132] - Explain your purpose:...

[0133] ##2. Conversion stage (reminder for repayment) ... ...

[0136] ##3. Objection Handling ... ...

[0139] 4. End the conversation

[0140] #

Standard Script Library

[0141] ##Opening stage speech

[0142] You: "Hello, may I ask... ... ...

[0145] ## Objection handling techniques ... ...

[0148] #

Output requirements

[0150] #[Complete example] ...

[0152] It is understandable that, considering the association between the global component and the domain component during the conversation, after constructing the function prompt words of the conversation process component, the dependency relationship between the domain component and the global component can be used to add association prompts in the domain prompt words and / or process prompt words, so as to guide the conversation process from the domain conversation component to the global conversation component or from the global conversation component to the domain conversation component through the association prompt. Here, the dependency relationship between the domain component and the global component can be determined according to the business process and data flow to clarify the function call familiarity between the global component and the domain component. The functions of some components need to be executed before other components. For example, before performing any business operation, it is usually necessary to authenticate the identity through the user authentication global component. The functions of some components depend on the output results of other components. For example, in an e-commerce system, only after the user successfully logs in (completed by the global user authentication component) can the product purchase operation (completed by field components such as order processing) be performed.

[0153] Specifically, if the operation of a certain domain component depends on the function of a global component, add an associated prompt to the global component in the domain prompt language. For example, in the order processing domain component of an e-commerce company, when the user is about to submit an order, the domain prompt language can be "To ensure that your order is submitted safely and the payment is completed smoothly, please complete the account login authentication first (direct the conversation process from the domain component of order payment to the global component of user authentication)." Conversely, if the output of the global component needs to be passed to a specific domain component for subsequent processing, add an associated prompt to the global component in the process prompt language. For example, in the global component of problem classification, determine that the calling component of the conversation process is "the domain component of product technical issues." The corresponding process prompt language can be "Your problem has been classified as a product technical problem. Next, the product technical support domain component (which directs the conversation process from the global component of problem classification to the domain component of product technical issues) will give you a detailed answer."

[0154] Further, as Figure 1-4 The specific implementation of the method, the embodiment of the present application provides a control device for a session process, such as Figure 5 As shown, the device includes: a splitting unit 51, a determining unit 52, and a generating unit 53.

[0155] A splitting unit 51 is configured to split a conversation process into conversation process components with different functions, wherein the conversation process components include a global component and at least one domain component. The global component is used for global control of the conversation process and logical processing of common problems in the conversation process. The domain component is used for logical processing of domain problems in the conversation process.

[0156] a determining unit 52 for determining, in response to an interactive instruction of the conversation process, a component identifier to be called by the conversation process according to conversation context information constructed from the conversation input text;

[0157] The generating unit 53 is configured to transfer the session context information to a corresponding session process component according to the component identifier called by the session process, so that the corresponding session process component generates a session output text according to the session context information.

[0158] The conversation flow control device provided in an embodiment of the present invention, compared to the existing art method of controlling the conversation flow by frequently calling and fine-tuning a large model, divides the conversation flow into conversation flow components with different functions. The conversation flow components include a global component and at least one domain component. The global component is used for global control of the conversation flow and logical processing of common problems in the conversation flow, while the domain component is used for logical processing of domain problems in the conversation flow. In response to interaction instructions in the conversation flow, the identifier of the component to be called by the conversation flow is determined based on the conversation context information constructed from the conversation input text. The conversation context information is transferred to the corresponding conversation flow component based on the component identifier of the conversation flow call, so that the corresponding conversation flow component generates conversation output text based on the conversation context information. The entire process does not logically process the entire conversation flow as a large conversation component. Instead, by breaking the conversation flow into conversation flow components with different functions, the conversation flow can be refined without fine-tuning the general large model, making the scope of connection of conversation flow components flexible and controllable. In this way, during the conversation interaction process, different conversation flow components can be called to connect to the logical processing of different problems, accelerating the conversation process and ensuring the stability of conversation flow control.

[0159] In a specific application scenario, the splitting unit is specifically used to:

[0160] Collecting conversation process data of different business scenarios in advance, and extracting the interactive links of the conversation process based on the conversation process data;

[0161] Determining, based on the interaction links of the conversation process, process nodes that affect conversation decisions in the conversation process;

[0162] The conversation process is split into conversation process components with different functions according to the process nodes that affect the conversation decision.

[0163] In a specific application scenario, the device further includes:

[0164] The first construction unit is configured to construct a routing prompting statement for the conversation process component after splitting the conversation process into conversation process components with different functions, wherein the routing prompting statement is used to determine a component identifier called by the conversation process according to the conversation context information.

[0165] In a specific application scenario, the determining unit is specifically configured to:

[0166] Inputting the conversation context information constructed from the conversation input text and the routing prompt words of the conversation process component into the universal big model, so that the universal big model performs classification reasoning on the conversation context information and the routing prompt words to obtain classification reasoning features;

[0167] Mapping the classification reasoning features to the probability space of different process components to obtain the probability of calling different session process components;

[0168] The component identifiers called by the conversation process are determined according to the probabilities of calling different conversation process components.

[0169] In a specific application scenario, the device further includes:

[0170] A second construction unit is configured to construct function prompting words for the conversation process components after splitting the conversation process into conversation process components with different functions, wherein the function prompting words are used to guide the conversation process components to perform logical processing;

[0171] Accordingly, the second construction unit is specifically used to:

[0172] Constructing a process prompting speech for the global component, so that the global component performs logical processing on common questions in the conversation context information through the process prompting speech;

[0173] A domain prompting script is constructed for the domain component, so that the domain component performs logical processing on the domain problem in the conversation context information through the domain prompting script.

[0174] In a specific application scenario, the generating unit is specifically used to:

[0175] Transferring the session context information to a corresponding session process component according to the component identifier, so as to call the universal large model through the corresponding session process component;

[0176] Inputting the conversation context information and the functional prompt words of the conversation process component into a universal macro model, so that the universal macro model fuses the conversation context information with the functional prompt words to obtain conversation fusion information;

[0177] Logical reasoning is performed based on the conversation fusion information to generate a conversation output text.

[0178] In a specific application scenario, the device further includes:

[0179] An adding unit is used to add associated prompts in the domain prompt dialogue and / or the process prompt dialogue after constructing the function prompt dialogue of the conversation process component, utilizing the dependency relationship between the domain component and the global component, so as to guide the conversation process from the domain conversation component to the global conversation component or from the global conversation component to the domain conversation component through the associated prompts.

[0180] It should be noted that for other corresponding descriptions of the functional units involved in the control device for a session flow provided in this embodiment, please refer to Figures 1-4 The corresponding description in will not be repeated here.

[0181] Based on the above Figures 1-4 The method shown in FIG. 1 is a method for performing the above-mentioned operation. Accordingly, the embodiment of the present application further provides a storage medium on which a computer program is stored. When the program is executed by a processor, the above-mentioned operation is performed. Figures 1-4 The control method of the session flow shown.

[0182] Based on this understanding, the technical solution of the present application can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, USB flash drive, mobile hard disk, etc.), including a number of instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) to execute the methods described in each implementation scenario of the present application.

[0183] Based on the above Figures 1-4 The method shown, and Figure 5 In order to achieve the above-mentioned purpose, the embodiment of the present application further provides a physical device for controlling the session flow, which can be a computer, a smart phone, a tablet computer, a smart watch, a server, or a network device, etc. The physical device includes a storage medium and a processor; the storage medium is used to store a computer program; the processor is used to execute the computer program to achieve the above-mentioned Figures 1-4 The control method of the session flow shown.

[0184] Optionally, the physical device may further include a user interface, a network interface, a camera, a radio frequency (RF) circuit, a sensor, an audio circuit, a Wi-Fi module, etc. The user interface may include a display, an input unit such as a keyboard, etc., and the optional user interface may also include a USB interface, a card reader interface, etc. The network interface may optionally include a standard wired interface, a wireless interface (such as a Wi-Fi interface), etc.

[0185] In an exemplary embodiment, see Figure 6The physical device includes a communication bus, a processor, a memory, and a communication interface. It may also include an input / output interface and a display device. The various functional units can communicate with each other via the bus. The memory stores a computer program, and the processor is configured to execute the program stored in the memory and perform the method for controlling the session flow in the above embodiment.

[0186] Those skilled in the art will understand that the physical device structure for controlling a session flow provided in this embodiment does not constitute a limitation on the physical device, and may include more or fewer components, or a combination of certain components, or different component arrangements.

[0187] The storage medium may also include an operating system and a network communication module. The operating system is a program that manages the hardware and software resources of the physical device that controls the aforementioned session flow and supports the execution of the information processing program and other software and / or programs. The network communication module is used to enable communication between components within the storage medium and with other hardware and software in the physical information processing device.

[0188] Through the description of the above implementation methods, those skilled in the art can clearly understand that this application can be implemented by means of software plus the necessary general hardware platform, or by hardware. By applying the technical solution of this application, compared with the current existing methods, this application can refine the conversation process by splitting the conversation process into conversation process components with different functions without fine-tuning the general large model, making the connection range of the conversation process components flexible and controllable. In this way, during the conversation interaction process, different conversation process components can be called to connect to the logical processing of different problems, thereby accelerating the conversation process and ensuring the stability of the conversation process control.

[0189] Those skilled in the art will understand that the accompanying drawings are only schematic diagrams of a preferred implementation scenario, and the modules or processes in the accompanying drawings are not necessarily required to implement the present application. Those skilled in the art will understand that the modules in the devices in the implementation scenario can be distributed in the devices of the implementation scenario according to the implementation scenario description, or can be changed accordingly and located in one or more devices different from the implementation scenario. The modules of the above-mentioned implementation scenario can be combined into one module, or can be further split into multiple sub-modules.

[0190] The serial numbers of the above application are for descriptive purposes only and do not represent the advantages or disadvantages of the implementation scenarios. The above disclosure only discloses several specific implementation scenarios of the present application, but the present application is not limited thereto. Any changes that can be conceived by those skilled in the art should fall within the scope of protection of the present application.

Claims

1. A method for controlling a conversation process, characterized in that: include: Split the conversation process into conversation process components with different functions. The conversation process components include a global component and at least one domain component. The global component is used for global control of the conversation process and logical processing of common problems in the conversation process. The domain component is used for logical processing of domain problems in the conversation process. In response to the interactive instruction of the conversation process, determining the component identifier of the conversation process call according to the conversation context information constructed from the conversation input text; The session context information is transferred to a corresponding session process component according to the component identifier called by the session process, so that the corresponding session process component generates a session output text according to the session context information.

2. The method according to claim 1, characterized in that The process of splitting the conversation process into conversation process components with different functions includes: Collecting conversation process data of different business scenarios in advance, and extracting the interactive links of the conversation process based on the conversation process data; Determining, based on the interaction links of the conversation process, process nodes that affect conversation decisions in the conversation process; The conversation process is split into conversation process components with different functions according to the process nodes that affect the conversation decision.

3. The method according to claim 1, characterized in that After splitting the conversation flow into conversation flow components with different functions, the method further includes: A routing prompting statement of a conversation process component is constructed, wherein the routing prompting statement is used to determine a component identifier of a conversation process call according to conversation context information.

4. The method according to claim 3, characterized in that The determining of the component identifier of the conversation process call based on the conversation context information constructed according to the conversation input text includes: Inputting the conversation context information constructed from the conversation input text and the routing prompt words of the conversation process component into the universal big model, so that the universal big model performs classification reasoning on the conversation context information and the routing prompt words to obtain classification reasoning features; Mapping the classification reasoning features to the probability space of different process components to obtain the probability of calling different session process components; The component identifiers called by the conversation process are determined according to the probabilities of calling different conversation process components.

5. The method according to claim 1, wherein After splitting the conversation flow into conversation flow components with different functions, the method further includes: Constructing a function prompting script for a conversation process component, wherein the function prompting script is used to guide the conversation process component to perform logical processing; Accordingly, a process prompting speech is constructed for the global component, so that the global component performs logical processing on common questions in the conversation context information through the process prompting speech; A domain prompting script is constructed for the domain component, so that the domain component performs logical processing on the domain problem in the conversation context information through the domain prompting script.

6. The method according to claim 5, characterized in that The component identifier called according to the conversation process transfers the conversation context information to a corresponding conversation process component, so that the corresponding conversation process component generates a conversation output text according to the conversation context information, including: Transferring the session context information to a corresponding session process component according to the component identifier, so as to call the universal large model through the corresponding session process component; Inputting the conversation context information and the functional prompt words of the conversation process component into a universal macro model, so that the universal macro model fuses the conversation context information with the functional prompt words to obtain conversation fusion information; Logical reasoning is performed based on the conversation fusion information to generate a conversation output text.

7. The method according to claim 5, characterized in that After constructing the function prompting words of the conversation process component, the method further includes: By utilizing the dependency relationship between the domain component and the global component, associated prompts are added to the domain prompt dialogue and / or the process prompt dialogue to guide the conversation process from the domain conversation component to the global conversation component or from the global conversation component to the domain conversation component through the associated prompts.

8. A conversation process control device, characterized in that: include: A splitting unit, configured to split a conversation process into conversation process components with different functions, wherein the conversation process components include a global component and at least one domain component. The global component is used for global control of the conversation process and logical processing of common problems in the conversation process, and the domain component is used for logical processing of domain problems in the conversation process. a determining unit, configured to determine, in response to an interactive instruction of the conversation process, a component identifier called by the conversation process according to conversation context information constructed from conversation input text; A generating unit is configured to transfer the session context information to a corresponding session process component according to a component identifier called by the session process, so that the corresponding session process component generates a session output text according to the session context information.

9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method for controlling the conversation process according to any one of claims 1 to 7 are implemented.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method for controlling a conversation process according to any one of claims 1 to 7 are implemented.