Multi-role interaction method and device

By introducing multiple interactive characters to interact with virtual characters, the problem of single interactive scene of large language models is solved, the character interaction scenes and experience are enriched, and user participation is improved.

CN119476348BActive Publication Date: 2025-09-05BEIJING XIYU JIZHI TECH CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202411609872.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-11-12
Publication Date
2025-09-05
Estimated Expiration
2044-11-12

AI Technical Summary

Technical Problem

In the interactive scenarios of existing large language models, only a single user can interact with the model individually, resulting in single functions and applicable scenarios, lack of fun and competitiveness, and inability to meet the interactive needs of multiple people.

Method used

Introduce multiple interactive characters to interact with the same virtual character, enrich the character interaction scenarios and experience by generating interactive prompt words, determining the virtual character and calculating the interaction results based on the large language model.

Benefits of technology

It improves user participation enthusiasm and interactive experience, is suitable for interactive scenarios with multiple participants, and enhances the fun and competitiveness of the interaction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119476348B_ABST
    Figure CN119476348B_ABST
Patent Text Reader

Abstract

The present application provides a multi-role interaction method and device, wherein the multi-role interaction includes interaction between at least one virtual character and at least two interactive characters. The method comprises: determining an interaction prompt word in response to a user's request to create a multi-role interaction; generating a virtual character based on the interaction prompt word; determining the interactive characters in response to a user's request to start a multi-role interaction, and starting the multi-role interaction; and determining the interaction results between each interactive character and the virtual character based on the interaction information and interaction prompt word generated during the multi-role interaction. In this way, by introducing a method in which multiple interactive characters interact with the same virtual character and determining the interaction results between each interactive character and the virtual character, the method can enrich the character interaction scene and interactive experience, improve user participation enthusiasm, and is suitable for interactive scenes involving multiple people.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer application technology, and in particular to a multi-role interaction method and device. Background Art

[0002] In the existing interactive scenarios of large language models, only a single user can interact with the model on the same interactive page, which makes the functions and applicable scenarios of existing large language models single, the model capabilities cannot be fully utilized, and there is a lack of interesting and competitive interactive experience, which cannot meet current interactive needs. Summary of the Invention

[0003] In view of this, the purpose of this application is to provide a multi-role interaction method and device, which introduces a way for multiple interactive characters to interact with the same virtual character and determines the interaction results between each interactive character and the virtual character. In this way, it can enrich the character interaction scenes and interactive experience, improve user participation enthusiasm, and is suitable for interactive scenes involving multiple people.

[0004] The embodiment of the present application provides a multi-role interaction method, wherein the multi-role interaction includes interaction between at least one virtual character and at least two interactive characters; the method includes:

[0005] In response to a user's request to create the multi-role interaction, determining an interaction prompt word; wherein the interaction prompt word is used to determine the interaction content of the multi-role interaction;

[0006] Based on the interactive prompt word, the virtual character is generated; wherein the virtual character serves as the interactive object of the interactive character;

[0007] In response to a user's request to start the multi-role interaction, determining the interactive roles and starting the multi-role interaction; wherein the interactive roles include at least one user role operated by the user;

[0008] Based on the interaction information generated in the multi-role interaction and the interaction prompt words, the interaction result between each interactive role and the virtual role is determined.

[0009] Furthermore, in response to the user's request to create the multi-role interaction, determining the interaction prompt words includes:

[0010] Determining the interactive prompt word according to the interactive information input by the user in the creation request;

[0011] Alternatively, in response to the creation request, a preset prompt word template is displayed; and the interactive prompt word is generated according to the prompt word template;

[0012] Alternatively, a pre-trained large language model is used to generate a prompt word template according to the interactive keyword input by the user in the creation request; and the interactive prompt word is generated according to the prompt word template;

[0013] Alternatively, in response to the creation request, current network hot words are obtained; a prompt word template is generated based on the current network hot words using a large language model; and the interactive prompt word is generated according to the prompt word template.

[0014] Furthermore, generating the interactive prompt word according to the prompt word template includes:

[0015] In response to a user's confirmation operation on the prompt word template, determining the prompt word template as the interactive prompt word;

[0016] Alternatively, in response to a configuration operation of the prompt word template by the user, the prompt word template is modified, and the modified prompt word template is determined as the interactive prompt word.

[0017] Furthermore, in response to the user's request to start the multi-role interaction, determining the interactive role includes:

[0018] In response to a first user's interaction request to start the multi-role interaction, creating a first user role and interaction invitation information corresponding to the first user;

[0019] Sharing the interaction invitation information with other users according to the interaction participation method determined by the first user;

[0020] In response to confirmation operations of the second users on the received interaction invitation information, second user roles corresponding to the second users are created respectively.

[0021] Furthermore, the step of determining the interactive roles in response to the user's request to start the multi-role interaction further includes:

[0022] In response to a first user's interaction request to start the multi-role interaction, determining a target number of the interactive roles;

[0023] A corresponding number of virtual user roles is created according to the difference between the target number and the number of created user roles.

[0024] Furthermore, determining the interaction result between each interactive character and the virtual character based on the interaction information and the interaction prompt words generated in the multi-character interaction includes:

[0025] For each interactive character, extracting interactive information generated when the virtual character interacts with the interactive character;

[0026] According to the interactive information generated when interacting with the interactive character and the interactive rules included in the interactive prompt words, the interactive performance of the interactive character is determined and used as the interactive result between the interactive character and the virtual character.

[0027] Furthermore, determining the interactive performance between the interactive character and the virtual character according to the interactive information generated when interacting with the interactive character and the interactive rules included in the interactive prompt words includes:

[0028] Sending interactive information generated during the interaction with the interactive character and the interactive rules included in the interactive prompt words to the first language model in real time, and determining the interactive performance between the interactive character and the virtual character by the first language model;

[0029] And / or, in response to a request to end the interaction or the interaction meets a preset condition, all interaction information generated when interacting with the interactive character and the interaction rules included in the interaction prompt words are sent to the first language model, and the first language model determines the interaction performance between the interactive character and the virtual character.

[0030] Furthermore, the multi-role interaction includes at least one round of role interaction between the virtual character and each interactive character; the method further includes generating interaction information in the multi-role interaction by:

[0031] For any interactive role in any round of role interaction, obtain the current round of interactive dialogue sent by the interactive role to the virtual role;

[0032] The virtual character generates a feedback dialogue for the interactive character based on the current round of interactive dialogue and the historical interactive dialogue.

[0033] Furthermore, generating the virtual character based on the interactive prompt word includes:

[0034] The virtual character is generated based on the interaction prompt words using a pre-trained second language model; wherein the interaction prompt words are related to at least one of the following: an interaction scene, an interaction task, and an interaction rule.

[0035] The embodiment of the present application further provides a multi-role interaction device, wherein the multi-role interaction includes interaction between at least one virtual character and at least two interactive characters; the device includes:

[0036] A prompt word determination module is used to determine an interaction prompt word in response to a user's creation request for creating the multi-role interaction; wherein the interaction prompt word is used to determine the interactive content of the multi-role interaction;

[0037] A generating module, configured to generate the virtual character based on the interactive prompt word; wherein the virtual character serves as an interactive object of the interactive character;

[0038] a role determination module, configured to determine the interactive roles in response to a user's request to start the multi-role interaction, and start the multi-role interaction; wherein the interactive roles include at least one user role operated by the user;

[0039] The result determination module is used to determine the interaction result between each interactive character and the virtual character based on the interaction information generated in the multi-character interaction and the interaction prompt words.

[0040] An embodiment of the present application also provides an electronic device, comprising: a processor, a memory, and a bus, wherein the memory stores machine-readable instructions executable by the processor. When the electronic device is running, the processor and the memory communicate via the bus, and when the machine-readable instructions are executed by the processor, the steps of the multi-role interaction method described above are performed.

[0041] An embodiment of the present application further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the multi-role interaction method described above are executed.

[0042] The embodiments of the present application provide a multi-role interaction method and device that introduces a method for multiple interactive characters to interact with the same virtual character and determines the interaction results between each interactive character and the virtual character. This enriches the character interaction scenarios and interactive experience, increases user participation enthusiasm, and is suitable for multi-player interaction scenarios.

[0043] In order to make the above-mentioned objects, features and advantages of the present application more obvious and easy to understand, preferred embodiments are given below and described in detail with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0044] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following is a brief introduction to the drawings required for use in the embodiments. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other relevant drawings can be obtained based on these drawings without creative work.

[0045] Figure 1 A flowchart of a multi-role interaction method provided in an embodiment of the present application is shown;

[0046] Figure 2 A schematic diagram of the structure of a multi-role interaction device provided in an embodiment of the present application is shown;

[0047] Figure 3 A schematic structural diagram of an electronic device provided in an embodiment of the present application is shown. DETAILED DESCRIPTION

[0048] In order to make the purpose, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all of the embodiments. The components of the embodiments of the present application generally described and shown in the drawings here can be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present application provided in the drawings is not intended to limit the scope of the application for which protection is claimed, but merely represents the selected embodiments of the present application. Based on the embodiments of the present application, each other embodiment obtained by those skilled in the art without making creative work falls within the scope of protection of the present application.

[0049] Research has found that in the existing interactive scenarios of large language models, only a single user can interact with the model on the same interactive page, which makes the functions and applicable scenarios of the existing large language models single, the model capabilities cannot be fully utilized, and there is a lack of interesting and competitive interactive experience, which cannot meet current interactive needs.

[0050] Based on this, the embodiments of the present application provide a multi-role interaction method that introduces a method for multiple interactive characters to interact with the same virtual character and determines the interaction results between each interactive character and the virtual character. This can enrich the character interaction scenes and interactive experience, increase user participation enthusiasm, and is suitable for interactive scenarios involving multiple people.

[0051] See also Figure 1 , Figure 1 A flowchart of a multi-role interaction method provided in an embodiment of the present application. The multi-role interaction in the embodiment of the present application includes at least three roles, and the roles can be set according to different implementation environments. More specifically, the multi-role interaction includes interaction between at least one virtual character and at least two interactive characters. Here, a virtual character refers to an artificial intelligence-driven virtual robot, which plays a specific role to interact with an interactive character; the interactive character includes at least one real user character operated by a user, and may also include other virtual characters. Interaction can include a variety of methods, such as voice dialogue interaction, text dialogue interaction, and providing the image of a virtual character for action interaction.

[0052] Taking text dialogue interaction as an example, different characters take turns speaking to form a dialogue interaction; virtual characters can simulate human dialogue, provide information, entertainment, or assist users in completing various tasks. These virtual characters are usually based on natural language processing (NLP) technology, which can understand user language and generate human language, thereby interacting with users. In specific implementation, the multi-role interaction method provided in the embodiment of the present application can be executed based on terminal devices, cloud interaction systems, etc. Among them, the terminal device can be a local electronic device that has downloaded and can run an intelligent dialogue program, such as a smart phone, a personal computer, a tablet computer, etc. Taking the multi-role interaction system as an example, the local electronic device is equipped with a multi-role interaction system and is used to present a dialogue interface. The multi-role interaction system carried by the local electronic device is used to interact with the user through the dialogue interface, that is, the intelligent dialogue program is downloaded and installed by the electronic device and run, receives the dialogue utterances input by the user through the dialogue interface, generates reply utterances and feeds back to the user through the dialogue interface, thereby realizing multi-role interaction.

[0053] When the multi-role interaction method provided in the embodiments of the present application is applied to a server, the dialogue strategy prediction method can also be implemented and executed based on a cloud interaction system, where the cloud interaction system may include a server and a client device. In the cloud intelligent dialogue system operating mode, the operating body of the intelligent dialogue program and the body presenting the dialogue interface are separate. The multi-role interaction method is stored and executed on the cloud intelligent dialogue system server, and the client device is used to receive and send dialogue utterances and present the dialogue interface. For example, the client device can be a display device with data transmission capabilities close to the user, such as a smartphone, personal computer, tablet computer, etc.

[0054] like Figure 1 As shown in , the multi-role interaction method provided by the embodiment of the present application includes:

[0055] S101: In response to a user's request to create the multi-role interaction, determine an interaction prompt word.

[0056] The interactive prompt is used to determine the interactive content of the multi-role interaction. More specifically, the interactive prompt may be related to at least one of the following: interactive scene, interactive task, and interactive rules. An interactive scene refers to the contextual setting for the interaction between characters, such as a debate on a certain point of view, a simulated multi-person interview, a bragging competition, a bickering competition, a humor competition, and a speech competition; an interactive task refers to the goal that the user hopes to achieve in the interaction; and an interactive rule refers to the behavioral guidance of the characters and the criteria for determining the results of the interaction.

[0057] In one example, an interaction scenario involves character A being constantly undermined by character B in their workplace. Character A then decides to strike back at character B in a specific situation and invites character C to join them. The interaction task involves tasks like: which character A or C can quickly anger character B? Or, which character's speech can provoke the most anger in character B? The interaction rules are: during interaction with character B, whoever increases character B's anger will receive points. The higher the anger, the more points are awarded, while the lower the anger, the less points are deducted. Interaction rules can also include limiting each character to one or a few words per conversation, or allowing an unlimited number of interactions.

[0058] In this step, the user can trigger a creation request for creating multi-role interaction through voice commands, text commands, etc., and then the system can respond to this creation request and determine the interaction prompt words based on the information contained in the creation request.

[0059] In a possible implementation, the method of determining the interactive prompt word in step S101 may include at least one of the following:

[0060] Method A: determining the interactive prompt word according to the interactive information input by the user in the creation request.

[0061] In this way, the user can trigger a creation request by manually entering interactive information. The system can extract the interactive information from the creation request and then determine the interactive prompt words by processing the interactive information (such as filtering, word segmentation, etc.).

[0062] Mode B: In response to the creation request, a preset prompt word template is displayed; and the interactive prompt word is generated according to the prompt word template.

[0063] In this way, a plurality of prompt word templates are pre-stored in the system. After receiving a creation request, the plurality of prompt word templates are displayed in a visual interface, and then an interactive prompt word can be generated according to the prompt word template selected by the user.

[0064] Method C: Generate a prompt word template using a pre-trained large language model according to the interactive keyword input by the user in the creation request; and generate the interactive prompt word according to the prompt word template.

[0065] In this approach, users can manually enter interactive keywords to trigger a creation request. The system then extracts the interactive keywords from the creation request and automatically generates an adaptive prompt word template based on the interactive keywords by invoking a large language model, using methods such as expansion. Subsequently, interactive prompt words can be generated based on the prompt word template. Large language models refer to natural language processing (NLP) models that are trained using large amounts of data and have a very high number of parameters. These models can understand and generate human language and perform a variety of tasks such as text generation, translation, summarization, question-answering, and conversation.

[0066] For example, if the user inputs the interactive keyword "speech contest, rich emotions, high score winner", the large language model can expand the interactive keyword and generate a prompt word template with a preset word count range (this preset word count range can be determined during the model training process, which can maximize the model training effect). Alternatively, for example, if the user inputs the interactive keyword "joke contest", the user input content is input into the large language model for automatic generation, and the large model is used to generate at least one prompt word template with a preset word count range.

[0067] Mode D: in response to the creation request, obtaining current network hot words; using a large language model to generate a prompt word template based on the current network hot words; and generating the interactive prompt word according to the prompt word template.

[0068] In this approach, users can create a request to indicate their desire for multi-role interaction related to a current event. The system can then retrieve current online hot words based on the request. For example, this could be done by reading hot words from the search rankings of social software. Users can also specify the scope and theme of the current event in the request, allowing the system to further filter out current online hot words that match the user's desired scope and theme.

[0069] For example, some key and hot events can be collected in real time or at regular intervals, such as at least one current Internet hot word such as "XX meeting" as a keyword, and a large language model can be used to automatically generate at least one prompt word template based on the current Internet hot words, such as "Should a debate competition for the XX meeting be held?", "N places and M places are applying to host it, who should we support?", etc.

[0070] In this way, the method provided by the embodiments of the present application combines multi-role interaction with real-life events, and can provide users with a more interesting and engaging interactive experience by regularly publishing interactive games related to specific moments or events. This is specifically reflected in the following aspects:

[0071] 1. Integrate with current events: Flexibly integrate with current events, such as launching a game on the fifth day of the Lunar New Year to compete for the favorability of the AI ​​God of Wealth. This regularly updated interactive game enables users to better experience and participate in real-life activities through interaction.

[0072] 2. Increased user engagement: By integrating games with real-life events, users can be motivated to participate more actively in the game. Because the game is related to real-life events, users feel more connected and engaged, which increases their engagement and activity.

[0073] 3. Creator Creation: Users can not only select their own game prompt templates, but also batch create interactive game prompt templates related to current events, ensuring the timely release of interactive games related to current events. This allows creators to more flexibly respond to current events and create more engaging and innovative interactive games.

[0074] Furthermore, in the above-mentioned methods B, C and D, generating the interactive prompt word according to the prompt word template may include:

[0075] In response to a user confirming the prompt word template, the prompt word template is determined as the interactive prompt word. In this case, multiple prompt word templates may be provided to the user, and in response to the user confirming the prompt word template, the prompt word template selected by the user or the specific prompt word content in the prompt word template is determined as the interactive prompt word.

[0076] Alternatively, in response to a user's configuration operation on the prompt word template, the prompt word template is modified, and the modified prompt word template is determined as the interaction prompt word. In this case, multiple prompt word templates can be provided to the user. In response to the user's configuration operation on the prompt word template, the specific prompt word content in the prompt word template selected by the user is modified and configured, and the modified prompt word template is determined as the interaction prompt word. For example, the user can change the character's identity AB to EF, or change the location of the interactive background to a more familiar place.

[0077] Alternatively, the prompt word template may be directly determined as the interactive prompt word without any user operation. For example, if the user directly requests to start a preset interactive topic, the interactive prompt word collection is completed directly based on the preset prompt word template without user confirmation.

[0078] In this way, the multi-role interaction method in the embodiment of the present application provides a variety of ways to generate interactive prompt words, which helps to generate rich and diverse multi-role interaction scenarios and meet the interaction needs of different users.

[0079] S102: Generate the virtual character based on the interactive prompt word.

[0080] In this step, the pre-trained second language model can be used to train and generate the virtual character based on the interactive prompt words. The specific generation method can refer to the existing technology and is not limited in this application.

[0081] Among them, the virtual character, as the interactive object of the interactive character, can make corresponding feedback based on the interactive information sent by the interactive character to the virtual character; the virtual character can also serve as a referee in multi-role interaction, and determine the interaction result based on the interactive information sent by the interactive character to the virtual character and / or the interactive information between the interactive characters. Corresponding to the above example, the character B (the corresponding AI virtual character) generated by the second largest language model can be a referee who is familiar with all backgrounds and rules, and can also be an interactive object with character A / C. For example, character B is the object that often suppresses character A and character C in the workplace. In multi-role interaction, character B will still maintain the characteristics of workplace suppression and interact with character A / C, thereby mobilizing the participation enthusiasm and emotions of character A / C and improving the user experience; and then according to the interaction between character A and character C and character B, character B will show a corresponding anger value.

[0082] S103: In response to the user's interaction request to start the multi-role interaction, determine the interactive roles and start the multi-role interaction.

[0083] As previously mentioned, a multi-role interaction includes at least two interactive characters, wherein at least one of the interactive characters is a user-operated user character. In this step, in response to any user's request to initiate a multi-role interaction, all interactive characters participating in the multi-role interaction are first determined, and then a multi-role interaction can be initiated based on the interactive characters and the virtual characters.

[0084] Here, multi-role interaction must take place within a specific interactive space, such as a group chat within a chat application or a virtual interactive room created within a dedicated interactive application. The addition of at least three characters unlocks a corresponding multi-role interaction space, which can be configured to allow interaction between characters, providing greater flexibility and a better user experience. Alternatively, it can be configured to allow only interaction between user characters and virtual characters, with all participating characters visible, thus enhancing the excitement of competition and the user experience.

[0085] In the embodiments of the present application, the method for determining interactive roles may include at least one of the following: random matching, user invitation, and virtual role supplementation. Random matching refers to randomly matching a determined user with other users to enter the interactive space for multi-role interaction; user invitation refers to adding other users invited by the determined user to the interactive space for multi-role interaction; and virtual role supplementation refers to adding a virtual character as an interactive role to accompany the determined user to the interactive space for multi-role interaction.

[0086] In a possible implementation, step S103 may include:

[0087] S1031: In response to a first user's interaction request to start the multi-role interaction, create a first user role and interaction invitation information corresponding to the first user.

[0088] In this step, in response to the first user's request to initiate a multi-role interaction, a corresponding first user role is created for the first user and an interaction invitation message is generated. The number of first users can be one or more; the interaction invitation message is used to invite other users to join the multi-role interaction created by the first user. For example, the interaction invitation message may include the address link of the interaction space where the multi-role interaction is located, interaction prompt words, and a brief information about the first user.

[0089] S1032: Share the interaction invitation information with other users according to the interaction participation method determined by the first user.

[0090] In this step, interactive participation methods include random matching and user invitations. For random matching, the system can match users for the first user according to pre-set matching criteria and automatically send interactive invitations to other users who meet the matching criteria and / or are selected by the user. For user invitations, when sharing within the site, the system can first query the corresponding users based on the identity information entered by the first user, and then send interactive invitations to these users. Alternatively, the first user can also share the interactive invitation information externally, copying it and sending it to other users they want to invite via other communication programs.

[0091] S1033: In response to confirmation operations of the second users on the received interaction invitation information, create second user roles corresponding to the second users.

[0092] In this step, the second user can learn about the multi-role interaction from the received interaction invitation information and can select to join the multi-role interaction by triggering a confirmation operation, or can select to decline the multi-role interaction by triggering a decline operation. In response to each second character's confirmation operation on the interaction invitation information, a second user character corresponding to each second character who has confirmed to join the multi-role interaction can be created, and each second user character can be added to the interaction space.

[0093] In another possible implementation, step S103 may further include:

[0094] In response to the first user's interaction request to start the multi-role interaction, a target number of the interactive roles is determined; and a corresponding number of virtual user roles is created according to the difference between the target number and the number of user roles that have been created.

[0095] Here, in addition to the two real-user participation methods mentioned above, random matching and user invitation, virtual characters can also be used to supplement. The first user can specify the target number of interactive characters, that is, the total number, in the interaction request that triggers the start of multi-character interaction. Afterwards, the first user can invite a portion of second users to join through random matching and / or user invitation. After the first user requests additional virtual characters, the system determines the difference between the target number and the number of user characters already created; alternatively, the first user can directly request additional virtual characters, and the system determines the difference between the target number and the number of user characters already created.

[0096] Based on the difference between the target number and the number of already created user roles, a corresponding number of virtual user roles are created and added to the interactive space. The virtual roles can be generated by a large language model based on user needs, or they can be pre-generated virtual roles with different characteristics.

[0097] At this point, the virtual characters, interactive characters, and interactive prompt words required for multi-character interaction are all prepared, and the system can start multi-character interaction.

[0098] S104: Determine an interaction result between each interactive character and the virtual character based on the interaction information and the interaction prompt words generated in the multi-character interaction.

[0099] In multi-role interaction, depending on the different interaction settings, dialogue interactions can occur between different interactive characters, between virtual characters and interactive characters, or even between multiple virtual characters. Multi-role interaction includes at least one round of role interaction between the virtual character and each interactive character. Specifically, the method provided in the embodiment of the present application further includes generating interaction information in the multi-role interaction by:

[0100] For any interactive role in any round of role interaction, a current round of interactive dialogue sent by the interactive role to the virtual role is obtained; and the virtual role generates a feedback dialogue to the interactive role based on the current round of interactive dialogue and historical interactive dialogues.

[0101] Here, during any round of character interaction, the virtual character can perform semantic analysis on the interactive dialogue sent by the interactive character in the current round. Combined with the historical interactive dialogues before the current round, the large language model uses the corresponding dialogue strategy to generate a response to the interactive character. This allows the large model to capture all conversation information at each feedback output, helping to overcome the problem of context recognition barriers and output more accurate and humane feedback dialogues.

[0102] In this step, the interaction result can be expressed as a score value and / or a comment (such as good, very good, excellent, etc.) and / or a win or loss result, etc.

[0103] In a possible implementation, step S104 may include:

[0104] For each interactive character, the interactive information generated when the virtual character interacts with the interactive character is extracted; according to the interactive information generated when interacting with the interactive character and the interactive rules included in the interactive prompt words, the interactive performance of the interactive character is determined and used as the interactive result between the virtual character and the interactive character.

[0105] Specifically, the interactive information generated when the virtual character interacts with the interactive character, such as the conversation between the two, is extracted from all interaction information. Based on the interaction information and the interaction rules, the interactive character's interactive performance is determined and used as the interaction result between the interactive character and the virtual character. Furthermore, after determining the interaction result between the interactive character and the virtual character, the multi-character interaction can be continued based on the previous interaction in response to a request from at least one user character to continue the multi-activity.

[0106] The interactive performance between the interactive character and the virtual character can be determined by:

[0107] Method 1: sending the interactive information generated when interacting with the interactive character and the interactive rules included in the interactive prompt words to the first language model in real time, and using the first language model to determine the interactive performance between the interactive character and the virtual character.

[0108] In this method, the interactive information and interactive rules generated during the interaction with the interactive character can be sent to the first language model in real time to determine the real-time interactive performance between the interactive character and the virtual character. For example, after each round of speech by the interactive character ends, the speech of that round is sent to the first language model.

[0109] In this way, through real-time feedback and timely response to the interactive characters, we can better simulate the instantaneous reaction of the virtual characters in specific scenarios, help the interactive characters to adjust their strategies in time in the next interaction, and ultimately achieve the ideal interactive effect.

[0110] And / or, method two, in response to a request to end the interaction or the interaction meets a preset condition, all interaction information generated when interacting with the interactive character and the interaction rules included in the interaction prompt words are sent to the first language model, and the first language model determines the interaction performance between the interactive character and the virtual character.

[0111] In this approach, a user character can trigger an end-of-interaction request at any time to end a multi-character interaction, or the multi-character interaction can be automatically terminated when it is determined that the multi-character interaction meets preset conditions. Preset conditions can be set based on the interaction rules of different interaction scenarios. For example, they can include the interaction duration reaching a preset duration, the number of interaction rounds reaching a preset round, or the virtual character's emotion value reaching a preset threshold.

[0112] At this time, in response to the end interaction request or the interaction meeting the preset conditions, all interaction information and interaction rules generated when interacting with the interactive character can be sent to the first language model to determine the overall interaction performance between the interactive character and the virtual character.

[0113] In this way, a comprehensive overall interactive performance can be given to the interactive role, which can better simulate the final judgment result of the virtual role on the user role in a specific scenario and achieve an ideal interactive effect.

[0114] It should be noted that the above two methods can be used in combination, that is, both the real-time interaction performance between the interactive character and the virtual character and the overall interaction performance between the interactive character and the virtual character are given.

[0115] In a possible implementation, determining the interactive performance between the interactive character and the virtual character according to the interactive information generated when interacting with the interactive character and the interactive rules included in the interactive prompt words may further include:

[0116] Keywords are extracted from the interactive information generated when interacting with the interactive character; the keywords are matched with a preset emotional change vocabulary to determine the emotional change value of the virtual character caused by the interactive character; and a scoring value for the interactive performance between the interactive character and the virtual character is determined based on the emotional change value.

[0117] In the example above, where characters A and C counterattack character B, the virtual characters have preset emotion change lexicons based on their characteristics. These lexicons contain values ​​for different emotional changes triggered by different emotional keywords. Therefore, by extracting keywords from the interaction information and matching them with the preset emotion change lexicon, the emotional change value of the virtual character triggered by the interaction can be determined, and then converted into a score.

[0118] In this way, by determining the interaction results and feeding them back to the user, the user can intuitively understand the performance of each role in the multi-role interaction and solve the problems in it in a targeted manner, thereby further improving the user's enthusiasm for participation and interactive experience.

[0119] An embodiment of the present application provides a multi-role interaction method, wherein the multi-role interaction includes interaction between at least one virtual character and at least two interactive characters; the method includes: determining an interaction prompt word in response to a user's creation request for creating the multi-role interaction; wherein the interaction prompt word is used to determine the interactive content of the multi-role interaction; generating the virtual character based on the interaction prompt word; wherein the virtual character serves as the interactive object of the interactive character; determining the interactive role and starting the multi-role interaction in response to a user's interaction request to start the multi-role interaction; wherein the interactive role includes at least one user role operated by the user; and determining the interaction result between each interactive role and the virtual character based on the interactive information generated in the multi-role interaction and the interaction prompt word.

[0120] In this way, by introducing a method in which multiple interactive characters interact with the same virtual character and determining the interaction results between each interactive character and the virtual character, the character interaction scenes and interactive experience can be enriched, the enthusiasm of user participation can be improved, and it is suitable for interactive scenes involving multiple people.

[0121] See also Figure 2 , Figure 2 This is a schematic diagram of the structure of a multi-role interaction device provided in an embodiment of the present application. The multi-role interaction includes interaction between at least one virtual character and at least two interactive characters; Figure 2 As shown in , the multi-role interaction device 200 includes:

[0122] The prompt word determination module 210 is configured to determine an interaction prompt word in response to a user's request to create the multi-role interaction; wherein the interaction prompt word is used to determine the interactive content of the multi-role interaction;

[0123] A generating module 220 is configured to generate the virtual character based on the interactive prompt word; wherein the virtual character serves as an interactive object of the interactive character;

[0124] The role determination module 230 is configured to determine the interactive roles in response to a user's request to start the multi-role interaction, and start the multi-role interaction; wherein the interactive roles include at least one user role operated by the user;

[0125] The result determination module 240 is configured to determine the result of the interaction between each interactive character and the virtual character based on the interaction information and the interaction prompt words generated in the multi-character interaction.

[0126] Furthermore, when the prompt word determination module 210 is used to determine the interaction prompt word in response to the user's creation request for creating the multi-role interaction, the prompt word determination module 210 is specifically used to:

[0127] Determining the interactive prompt word according to the interactive information input by the user in the creation request;

[0128] Alternatively, in response to the creation request, a preset prompt word template is displayed; and the interactive prompt word is generated according to the prompt word template;

[0129] Alternatively, a pre-trained large language model is used to generate a prompt word template according to the interactive keyword input by the user in the creation request; and the interactive prompt word is generated according to the prompt word template;

[0130] Alternatively, in response to the creation request, current network hot words are obtained; a prompt word template is generated based on the current network hot words using a large language model; and the interactive prompt word is generated according to the prompt word template.

[0131] Furthermore, when the prompt word determination module 210 is used to generate the interactive prompt word according to the prompt word template, the prompt word determination module 210 is specifically used to:

[0132] In response to a user's confirmation operation on the prompt word template, determining the prompt word template as the interactive prompt word;

[0133] Alternatively, in response to a configuration operation of the prompt word template by the user, the prompt word template is modified, and the modified prompt word template is determined as the interactive prompt word.

[0134] Furthermore, when the role determination module 230 is used to determine the interactive role in response to the user's interaction request to start the multi-role interaction, the role determination module 230 is specifically used to:

[0135] In response to a first user's interaction request to start the multi-role interaction, creating a first user role and interaction invitation information corresponding to the first user;

[0136] Sharing the interaction invitation information with other users according to the interaction participation method determined by the first user;

[0137] In response to confirmation operations of the second users on the received interaction invitation information, second user roles corresponding to the second users are created respectively.

[0138] Furthermore, when the role determination module 230 is used to determine the interactive role in response to the user's interaction request to start the multi-role interaction, the role determination module 230 is further used to:

[0139] In response to a first user's interaction request to start the multi-role interaction, determining a target number of the interactive roles;

[0140] A corresponding number of virtual user roles is created according to the difference between the target number and the number of created user roles.

[0141] Furthermore, when the result determination module 240 is used to determine the interaction result between each interactive character and the virtual character based on the interaction information and the interaction prompt words generated in the multi-character interaction, the result determination module 240 is also used to:

[0142] For each interactive character, extracting interactive information generated when the virtual character interacts with the interactive character;

[0143] According to the interactive information generated when interacting with the interactive character and the interactive rules included in the interactive prompt words, the interactive performance of the interactive character is determined and used as the interactive result between the interactive character and the virtual character.

[0144] Furthermore, when the result determination module 240 is used to determine the interaction performance between the interactive character and the virtual character according to the interaction information generated when interacting with the interactive character and the interaction rules included in the interaction prompt words, the result determination module 240 is specifically used to:

[0145] Sending interactive information generated during the interaction with the interactive character and the interactive rules included in the interactive prompt words to the first language model in real time, and determining the interactive performance between the interactive character and the virtual character by the first language model;

[0146] And / or, in response to a request to end the interaction or the interaction meets a preset condition, all interaction information generated when interacting with the interactive character and the interaction rules included in the interaction prompt words are sent to the first language model, and the first language model determines the interaction performance between the interactive character and the virtual character.

[0147] Furthermore, the multi-role interaction includes at least one round of role interaction between the virtual character and each interactive character; the multi-role interaction device 200 further includes an interaction module; the interaction module is configured to generate interaction information in the multi-role interaction by:

[0148] For any interactive role in any round of role interaction, obtain the current round of interactive dialogue sent by the interactive role to the virtual role;

[0149] The virtual character generates a feedback dialogue for the interactive character based on the current round of interactive dialogue and the historical interactive dialogue.

[0150] Furthermore, when the generating module 220 is used to generate the virtual character based on the interactive prompt word, the generating module 220 is used to:

[0151] The virtual character is generated based on the interaction prompt words using a pre-trained second language model; wherein the interaction prompt words are related to at least one of the following: an interaction scene, an interaction task, and an interaction rule.

[0152] See also Figure 3 , Figure 3 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application. Figure 3 As shown in FIG, the electronic device 300 includes a processor 310 , a memory 320 and a bus 330 .

[0153] The memory 320 stores machine-readable instructions executable by the processor 310. When the electronic device 300 is running, the processor 310 communicates with the memory 320 via the bus 330. When the machine-readable instructions are executed by the processor 310, the above-mentioned Figure 1 The steps of the multi-role interaction method in the illustrated method embodiment and the specific implementation thereof can be found in the method embodiment, which will not be described in detail here.

[0154] The embodiment of the present application also provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the computer program can execute the above-mentioned Figure 1 The steps of the multi-role interaction method in the illustrated method embodiment and the specific implementation thereof can be found in the method embodiment, which will not be described in detail here.

[0155] Those skilled in the art will clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0156] In the several embodiments provided in this application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. The device embodiments described above are merely schematic. For example, the division of the units is merely a logical function division. There may be other division methods in actual implementation. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed may be through some communication interface, indirect coupling or communication connection of devices or units, which may be electrical, mechanical or other forms.

[0157] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.

[0158] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.

[0159] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a non-volatile computer-readable storage medium that is executable by a processor. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0160] Finally, it should be noted that the above-described embodiments are only specific implementation methods of the present application, which are used to illustrate the technical solutions of the present application, rather than to limit them. The scope of protection of the present application is not limited thereto. Although the present application has been described in detail with reference to the above-mentioned embodiments, those skilled in the art should understand that any person skilled in the art can modify or easily conceive of changes to the technical solutions described in the above-mentioned embodiments within the technical scope disclosed in the present application, or perform equivalent replacements for some of the technical features thereof. These modifications, changes, or replacements do not deviate from the spirit and scope of the technical solutions of the embodiments of the present application, and should be included in the scope of protection of the present application. Therefore, the scope of protection of the present application should be based on the scope of protection of the claims.

Claims

1. A multi-role interaction method, characterized in that: The multi-role interaction includes interaction between at least one virtual character and at least two interactive characters; the method includes: In response to a user's request to create the multi-role interaction, determining an interaction prompt word; wherein the interaction prompt word is used to determine the interaction content of the multi-role interaction; Based on the interactive prompt word, the virtual character is generated; wherein the virtual character serves as the interactive object of the interactive character; In response to a user's request to start the multi-role interaction, determining the interactive roles and starting the multi-role interaction; wherein the interactive roles include at least one user role operated by the user; Determining an interaction result between each interactive character and the virtual character based on the interaction information generated in the multi-character interaction and the interaction prompt words; The step of determining the interaction prompt word in response to the user's request to create the multi-role interaction includes: Based on the interactive keyword input by the user in the creation request, the interactive keyword is expanded using a pre-trained large language model to generate a prompt word template with a preset word count range; based on the prompt word template, the interactive prompt word is generated; the preset word count range is determined based on the model training effect during the training process to achieve the best model training effect; Alternatively, in response to the creation request, current network hot words are collected in real time or periodically; a prompt word template is generated based on the current network hot words using a large language model; and the interactive prompt word is generated according to the prompt word template; The virtual character also serves as a referee in the multi-role interaction, and determines the interaction result between each interactive character and the virtual character based on the interaction information generated in the multi-role interaction and the interaction prompt words, including: For each interactive character, extracting interactive information generated when the virtual character interacts with the interactive character; Determining the interactive performance of the interactive character according to the interactive information generated when interacting with the interactive character and the interactive rules included in the interactive prompt words, and feeding back the interactive results to the user as the interactive results with the virtual character; Determining the interactive performance of the interactive character according to the interactive information generated when interacting with the interactive character and the interactive rules included in the interactive prompt words, including: Extracting keywords from interactive information generated when interacting with the interactive character; Matching the keyword with a preset emotion change vocabulary to determine the emotion change value of the virtual character caused by the interactive character; wherein the virtual character has a preset corresponding emotion change vocabulary according to the characteristics of different characters; A rating value for the interaction performance between the interactive character and the virtual character is determined based on the emotion change value.

2. The method according to claim 1, characterized in that The step of determining the interaction prompt word in response to the user's request to create the multi-role interaction further includes: Processing the interactive information input by the user in the creation request to determine the interactive prompt words; the processing includes filtering and word segmentation; Alternatively, in response to the creation request, a preset prompt word template is displayed; and the interactive prompt word is generated according to the prompt word template.

3. The method according to claim 2, characterized in that Generating the interactive prompt word according to the prompt word template includes: In response to a user's confirmation operation on the prompt word template, determining the prompt word template as the interactive prompt word; Alternatively, in response to a configuration operation of the prompt word template by the user, the prompt word template is modified, and the modified prompt word template is determined as the interactive prompt word.

4. The method according to claim 1, wherein The step of determining the interactive roles in response to the user's request to start the multi-role interaction comprises: In response to a first user's interaction request to start the multi-role interaction, creating a first user role and interaction invitation information corresponding to the first user; Sharing the interaction invitation information with other users according to the interaction participation method determined by the first user; In response to confirmation operations of the second users on the received interaction invitation information, second user roles corresponding to the second users are created respectively.

5. The method according to claim 1 or 4, characterized in that The step of determining the interactive roles in response to the user's request to start the multi-role interaction further includes: In response to a first user's interaction request to start the multi-role interaction, determining a target number of the interactive roles; A corresponding number of virtual user roles is created according to the difference between the target number and the number of created user roles.

6. The method according to claim 1, wherein The step of determining the interactive performance between the interactive character and the virtual character according to the interactive information generated when interacting with the interactive character and the interactive rules included in the interactive prompt words further includes: Sending interactive information generated during the interaction with the interactive character and the interactive rules included in the interactive prompt words to the first language model in real time, and determining the interactive performance between the interactive character and the virtual character by the first language model; And / or, in response to a request to end the interaction or the interaction meets a preset condition, all interaction information generated when interacting with the interactive character and the interaction rules included in the interaction prompt words are sent to the first language model, and the first language model determines the interaction performance between the interactive character and the virtual character.

7. The method according to claim 1, characterized in that The multi-role interaction includes at least one round of role interaction between the virtual character and each interactive character; the method further includes generating interaction information in the multi-role interaction by: For any interactive role in any round of role interaction, obtain the current round of interactive dialogue sent by the interactive role to the virtual role; The virtual character generates a feedback dialogue for the interactive character based on the current round of interactive dialogue and the historical interactive dialogue.

8. The method according to claim 1, characterized in that Generating the virtual character based on the interactive prompt word includes: The virtual character is generated based on the interaction prompt words using a pre-trained second language model; wherein the interaction prompt words are related to at least one of the following: an interaction scene, an interaction task, and an interaction rule.

9. A multi-role interactive device, characterized in that: The multi-role interaction includes interaction between at least one virtual character and at least two interactive characters; the device includes: A prompt word determination module is used to determine an interaction prompt word in response to a user's creation request for creating the multi-role interaction; wherein the interaction prompt word is used to determine the interactive content of the multi-role interaction; A generating module, configured to generate the virtual character based on the interactive prompt word; wherein the virtual character serves as an interactive object of the interactive character; a role determination module, configured to determine the interactive roles in response to a user's request to start the multi-role interaction, and start the multi-role interaction; wherein the interactive roles include at least one user role operated by the user; A result determination module, configured to determine the result of the interaction between each interactive character and the virtual character based on the interaction information and the interaction prompt words generated in the multi-character interaction; The prompt word determination module is used to respond to the user's request to create the multi-role interaction and, when determining the interaction prompt word, the prompt word determination module is used to: Based on the interactive keyword input by the user in the creation request, the interactive keyword is expanded using a pre-trained large language model to generate a prompt word template with a preset word count range; based on the prompt word template, the interactive prompt word is generated; the preset word count range is determined based on the model training effect during the training process to achieve the best model training effect; Alternatively, in response to the creation request, current network hot words are collected in real time or periodically; a prompt word template is generated based on the current network hot words using a large language model; and the interactive prompt word is generated according to the prompt word template; The virtual character also serves as a referee in the multi-character interaction. When the result determination module is used to determine the interaction result between each interactive character and the virtual character based on the interaction information generated in the multi-character interaction and the interaction prompt words, the result determination module is used to: For each interactive character, extracting interactive information generated when the virtual character interacts with the interactive character; Determining the interactive performance of the interactive character according to the interactive information generated when interacting with the interactive character and the interactive rules included in the interactive prompt words, and feeding back the interactive results to the user as the interactive results with the virtual character; The result determination module is configured to determine the interactive performance of the interactive character according to the interactive information generated when interacting with the interactive character and the interactive rules included in the interactive prompt words, and the result determination module is configured to: Extracting keywords from interactive information generated when interacting with the interactive character; Matching the keyword with a preset emotion change vocabulary to determine the emotion change value of the virtual character caused by the interactive character; wherein the virtual character has a preset corresponding emotion change vocabulary according to the characteristics of different characters; A rating value for the interaction performance between the interactive character and the virtual character is determined based on the emotion change value.

Citation Information

Patent Citations

  • Interaction method and electronic equipment

    CN116938865A

  • Interaction method and device, medium and electronic equipment

    CN117959715A

  • Prompt word template generation method and device, computer equipment and readable storage medium

    CN118194838A

  • Virtual character control method and device, medium, equipment and program product

    CN118491100A