A method for training a text prediction model, a method for commentating a game, and related devices

CN122778031APending Publication Date: 2026-09-18TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510323808.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-18
Publication Date
2026-09-18

AI Technical Summary

Technical Problem

[0006]本申请实施例提供了一种文本预测模型的训练方法、对局解说方法及相关设备,用于解决采用目标预测模型进行对局解说时的解说局限性较大的问题

Benefits of technology

[0071] In this embodiment, a text prediction model is trained based on multiple game videos, enabling the text prediction model to acquire rich visual information. This helps the trained target prediction model learn visual information description capabilities during the training process, thereby describing multi-layered content such as game scenes and reducing the limitations of commentary when using the target prediction model for game commentary.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122778031A_ABST
    Figure CN122778031A_ABST
Patent Text Reader

Abstract

The application provides a text prediction model training method, a game session explanation method and related equipment, which are used to solve the problem of large explanation limitation of a target prediction model. The method comprises the following steps: obtaining a plurality of game session videos and corresponding session running data; for each session running data, the following operations are performed: extracting at least one game character corresponding behavior feature data set, event feature data set and state feature data set from the session running data; based on the plurality of game session videos, combining the obtained behavior feature data set, event feature data set and state feature data set, performing multi-round iterative training on the text prediction model to obtain the target prediction model. Training in combination with game session videos and various feature data reduces the explanation limitation of the target prediction model.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular to a training method for a text prediction model, a game commentary method, and related equipment. Background Technology

[0002] With the continuous development of technology, more and more client or server devices can run video games, such as first-person shooter (FPS) games. In some competitive sports, FPS video games have become official competition events. Therefore, online and offline competitive video games are often broadcast live with commentary to provide a comprehensive viewing experience.

[0003] Besides human commentary, there is also an intelligent commentary method based on a trained text prediction model. Specifically, firstly, based on the game's configuration data, corresponding event descriptions are pre-edited for various preset match events. Next, during the game's execution, when a preset match event is triggered, the associated event description is input into the trained text prediction model for text expansion, resulting in the event description text output by the model. Finally, this event description text is read aloud, thus providing commentary for the game.

[0004] In related technologies, text prediction models are large language models trained on a large number of short texts to expand text descriptions.

[0005] However, commentary based on pre-defined game events can only reflect the operation of the video game from a single event perspective. Furthermore, text expansion based on a trained text prediction model can only fully describe the pre-defined game events, but cannot vividly describe the game scenes and game strategies, etc., which makes the commentary based on the trained text prediction model quite limited. Summary of the Invention

[0006] This application provides a method for training a text prediction model, a method for game commentary, and related equipment to address the problem of significant limitations in commentary when using a target prediction model for game commentary.

[0007] Firstly, a training method for a text prediction model is provided, including:

[0008] Acquire multiple game match videos and corresponding match execution data;

[0009] For each of the aforementioned game operation data, the following operations are performed: extract at least one behavioral feature dataset, event feature dataset, and state feature dataset corresponding to each game character from the game operation data; wherein, each behavioral feature dataset represents a character behavior triggered by the corresponding game character; each event feature dataset represents a game event participated in by the corresponding game character; and each state feature dataset represents the character state of the corresponding game character within a time interval.

[0010] Based on the multiple game match videos, and combined with the obtained behavioral feature datasets, event feature datasets, and state feature datasets, the text prediction model is trained in multiple rounds of iterations to obtain the target prediction model; the target prediction model is used to: output match commentary text based on the received match video stream.

[0011] Secondly, a method for game commentary is provided, including:

[0012] Receive the game video stream and corresponding runtime data stream of the target game;

[0013] When a trained target prediction model is deployed, the target prediction model is used to generate game commentary text based on the game video stream and the running data stream; wherein, the target prediction model is trained based on the method described in the first aspect;

[0014] Based on the game video stream, the game process of the target game is presented in video form, and the game commentary text is broadcast in audio form using a preset tone.

[0015] Thirdly, a training device for a text prediction model is provided, comprising:

[0016] Acquisition module: Used to acquire multiple game match videos and corresponding match execution data respectively;

[0017] Processing module: For each of the game operation data, perform the following operations: extract at least one behavioral feature dataset, event feature dataset, and state feature dataset corresponding to each game character from the game operation data; wherein, each behavioral feature dataset represents a character behavior triggered by the corresponding game character; each event feature dataset represents a game event participated in by the corresponding game character; and each state feature dataset represents the character state of the corresponding game character within a time interval.

[0018] The processing module is further configured to: perform multiple rounds of iterative training on the text prediction model based on the multiple game video streams, combined with the obtained behavioral feature datasets, event feature datasets and state feature datasets, to obtain a target prediction model; the target prediction model is configured to: output game commentary text based on the received game video streams.

[0019] Optionally, each game video contains multiple video clips, and each video clip belongs to the perspective of a game character;

[0020] The processing module is specifically used for:

[0021] For each game video containing multiple video segments, the following steps are performed: using a trained question-answering model, based on the obtained behavioral feature datasets, event feature datasets, and state feature datasets, to perform textual descriptions of at least one of the character behaviors and game events presented in the video segment, as well as the changes in the game state presented in the video segment, to obtain a segment summary text.

[0022] Based on the multiple video segments contained in each of the multiple game match videos, and the obtained summary text of each segment, combined with the behavioral feature datasets and the event feature datasets, the text prediction model is trained in multiple rounds of iterations to obtain the target prediction model.

[0023] Optionally, the processing module is specifically used for:

[0024] Using a trained question-answering model, based on the obtained datasets of behavioral features and event features, and with a preset duration as the period, textual descriptions are performed on at least one of the character behaviors and game events presented in the video segment in each period, to obtain the periodic description text in each period;

[0025] Using the question-answering model, based on the obtained dataset of state features, the game state changes presented in the video segment are described in text, and state description text is obtained.

[0026] Using the question-and-answer model, the obtained period description text and state description text are summarized to obtain the segment summary text of the video segment.

[0027] Optionally, the processing module is specifically used for:

[0028] Based on the multiple video segments contained in each of the multiple game videos, and combined with the behavioral feature datasets and the event feature datasets, the text prediction model is trained in multiple rounds of iterations to obtain an intermediate prediction model.

[0029] Based on the multiple video segments contained in each of the multiple game match videos, and the obtained summary text of each segment, the intermediate prediction model is trained in multiple rounds of iterations to obtain the target prediction model.

[0030] Optionally, each of the behavioral feature datasets contains at least one subset of behavioral data; each behavioral feature data in each subset of behavioral data represents the various character behaviors triggered by the corresponding game character during a game presented in a video clip;

[0031] The processing module is specifically used for:

[0032] Using the text prediction model, based on the selected video clips and the behavioral feature datasets, the game character corresponding to the character's perspective presented in the video clip is predicted, and at least one predicted character behavior is triggered in the video clip.

[0033] Based on the at least one predicted character behavior, and the behavior of each character represented by the subset of behavior data corresponding to the video segment obtained from the behavior feature dataset corresponding to the game character, the behavior recognition loss of the text prediction model is determined.

[0034] Based on the behavior recognition loss, the model parameters of the text prediction model are adjusted.

[0035] Optionally, each of the event feature datasets contains at least one subset of event data; each event feature data in each subset of event data represents the various game events that the corresponding game character participates in during a game in a video clip.

[0036] The processing module is specifically used for:

[0037] Using the text prediction model, based on the selected video clips and the event feature datasets, the game character corresponding to the character's perspective presented in the video clip is predicted to participate in at least one predicted game event in the video clip.

[0038] Based on the at least one predicted game event, and each game event represented by the subset of event data corresponding to the video segment obtained from the event feature dataset corresponding to the game character, the event recognition loss of the text prediction model is determined.

[0039] Based on the event recognition loss, the model parameters of the text prediction model are adjusted.

[0040] Optionally, for each iteration of training of the intermediate prediction model, the processing module is specifically used for:

[0041] The intermediate prediction model is used to extract content features from the selected video segments to obtain content visual features;

[0042] Using the intermediate prediction model, based on the visual features of the content, predict the game description text of the video segment;

[0043] The model parameters of the intermediate prediction model are adjusted based on the textual differences between the game description text and the video clip summary text.

[0044] Optionally, the processing module is specifically used for:

[0045] Based on preset segmentation conditions, the game video corresponding to the game operation data is segmented to obtain multiple video segments; wherein, each video segment belongs to the perspective of a game character.

[0046] Select the segment execution data corresponding to each of the multiple video segments from the game execution data;

[0047] For each of the multiple video segments, the following steps are performed: extracting a subset of the behavior data, a subset of the event data, and a subset of the state data of the corresponding game character from the segment execution data corresponding to the video segment;

[0048] Based on the obtained subsets of behavioral data, event data, and state data, establish at least one behavioral feature dataset, event feature dataset, and state feature dataset corresponding to each game character.

[0049] Optionally, the segmentation conditions include at least one of the following:

[0050] The duration of the segments formed by the multiple video frames is within a preset range;

[0051] The segment formed by the multiple video frames is presented with at least one set game event from the set game event set;

[0052] The video segments formed by the split video frames present the game process as a preset game type.

[0053] Optionally, the processing module is further configured to:

[0054] After obtaining the target prediction model, the target prediction model is used to output the game commentary text corresponding to each of the multiple game videos and the corresponding game operation data.

[0055] A sample dataset is established using each game operation data as sample data and the game commentary text output based on each game operation data as the sample label of the corresponding sample data.

[0056] Based on the sample dataset, the preset initial prediction model is trained through multiple rounds of iteration to obtain a trained alternative prediction model; wherein, the alternative prediction model is used to: output game commentary text based on the received target game's running data stream; the parameter size of the alternative prediction model is smaller than the parameter size of the target prediction model.

[0057] Fourthly, a game commentary device is provided, comprising:

[0058] Transceiver module: Used to receive the game's video stream and corresponding runtime data stream;

[0059] Processing module: When a trained target prediction model is deployed, it uses the target prediction model to generate game commentary text based on the game video stream and the running data stream; wherein the target prediction model is trained based on the method described in the first aspect;

[0060] The transceiver module is also used to: present the game process of the target game in video form based on the game video stream, and broadcast the game commentary text in audio form using a preset tone.

[0061] Optionally, the processing module is further configured to:

[0062] When a trained alternative prediction model is deployed, the alternative prediction model is used to generate game commentary text based on the running data stream; wherein, the alternative prediction model is trained using the game running data input to the target prediction model as sample data and the game commentary text output by the target prediction model as sample labels, and the parameter size of the alternative prediction model is smaller than the parameter size of the target prediction model.

[0063] Fifthly, a computer program product is provided, comprising a computer program that, when executed by a processor, implements the method as described in the first or second aspect.

[0064] Sixthly, a computer device is provided, comprising:

[0065] Memory, used to store computer programs;

[0066] A processor is configured to invoke a computer program stored in the memory and execute the method as described in the first or second aspect according to the obtained computer program, including:

[0067] Acquire multiple game match videos and corresponding match execution data;

[0068] For each of the aforementioned game operation data, the following operations are performed: extract at least one behavioral feature dataset, event feature dataset, and state feature dataset corresponding to each game character from the game operation data; wherein, each behavioral feature dataset represents a character behavior triggered by the corresponding game character; each event feature dataset represents a game event participated in by the corresponding game character; and each state feature dataset represents the character state of the corresponding game character within a time interval.

[0069] Based on the multiple game match videos, and combined with the obtained behavioral feature datasets, event feature datasets, and state feature datasets, the text prediction model is trained in multiple rounds of iterations to obtain the target prediction model; the target prediction model is used to: output match commentary text based on the received match video stream.

[0070] A seventh aspect provides a computer-readable storage medium storing a computer program for causing a computer to perform the method as described in the first or second aspect.

[0071] In this embodiment, a text prediction model is trained based on multiple game videos, enabling the text prediction model to acquire rich visual information. This helps the trained target prediction model learn visual information description capabilities during the training process, thereby describing multi-layered content such as game scenes and reducing the limitations of commentary when using the target prediction model for game commentary.

[0072] Furthermore, feature data is extracted from game operation data from multiple perspectives, such as character behaviors triggered by game characters, game events participated in by game characters, and character states of game characters. This data is then used to train the text prediction model, enabling the text prediction model to acquire rich game background knowledge. This helps the trained target prediction model learn multi-angle detailed description capabilities during the training process, reducing the limitations of commentary when using the target prediction model for game commentary.

[0073] Furthermore, by combining game videos and extracted feature data, the text prediction model is trained, enabling it to correlate feature data with visual information. This helps the trained target prediction model learn to summarize and describe integrated feature data and visual information during the training process, thus describing multi-layered content such as game strategies and reducing the limitations of commentary when using the target prediction model for game commentary. Attached Figure Description

[0074] Figure 1A A domain illustration of a training method for a text prediction model provided in an embodiment of this application;

[0075] Figure 1B This is a schematic diagram illustrating the principle of a training method for a text prediction model based on related technologies.

[0076] Figure 1C This is one application scenario of the training method for the text prediction model provided in the embodiments of this application;

[0077] Figure 2 A flowchart illustrating a training method for a text prediction model provided in an embodiment of this application;

[0078] Figure 3A A schematic diagram illustrating the principle of a training method for a text prediction model provided in this application embodiment;

[0079] Figure 3B A schematic diagram of the principle of the training method for the text prediction model provided in the embodiments of this application. Figure 2 ;

[0080] Figure 4A A schematic diagram three illustrating the principle of a training method for a text prediction model provided in an embodiment of this application;

[0081] Figure 4B A schematic diagram four illustrating the principle of a training method for a text prediction model provided in an embodiment of this application;

[0082] Figure 4C A schematic diagram five illustrating the principle of a training method for a text prediction model provided in an embodiment of this application;

[0083] Figure 5A A schematic diagram six illustrating the principle of a training method for a text prediction model provided in an embodiment of this application;

[0084] Figure 5B A schematic diagram seven illustrating the principle of a training method for a text prediction model provided in an embodiment of this application;

[0085] Figure 5C Eight is a schematic diagram illustrating the principle of a training method for a text prediction model provided in an embodiment of this application.

[0086] Figure 6A A schematic diagram of the principle of the training method for the text prediction model provided in the embodiments of this application. Figure 9 ;

[0087] Figure 6B A schematic diagram illustrating the principle of a training method for a text prediction model provided in this application embodiment;

[0088] Figure 7A 11. A schematic diagram illustrating the principle of a training method for a text prediction model provided in this application embodiment;

[0089] Figure 7B A schematic diagram twelve illustrating the principle of a training method for a text prediction model provided in an embodiment of this application;

[0090] Figure 8A A schematic diagram of a training device for a text prediction model provided in an embodiment of this application;

[0091] Figure 8B A schematic diagram of the structure of the game commentary device provided in the embodiments of this application;

[0092] Figure 9 A schematic diagram of the structure of a training device or game commentary device for a text prediction model provided in the embodiments of this application. Figure 2 . Detailed Implementation

[0093] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings.

[0094] The following explanations of some terms used in the embodiments of this application are provided to facilitate understanding by those skilled in the art.

[0095] (1) First-person shooter (FPS) games:

[0096] FPS is a general term for shooting video games played from the first-person perspective of a single character. Typically, game characters need to use virtual tools to engage in virtual battles.

[0097] (2) Multimodal Large Language Models (MLLMs):

[0098] MLLMs are large-scale artificial intelligence models that fuse and understand data from multiple modalities (such as text, images, and speech). MLLMs have a massive number of model parameters, typically containing hundreds of millions or even more.

[0099] (3) Supervised fine-tuning (SFT):

[0100] Supervised fine-tuning is an important model optimization technique in the field of deep learning. It is often used to further train a pre-trained model using a labeled task-specific dataset. By adjusting some or all of the model's parameters, the model can learn the features and patterns of a specific task, thereby improving its performance on that specific task.

[0101] (4) Visual Question Answering (VQA):

[0102] Visual question answering is a multimodal task in the field of artificial intelligence that integrates computer vision and natural language processing. It enables computer systems to process image and natural language information simultaneously, establish the relationship between the two, and enable computers to understand the content of an image and answer questions related to the image in natural language.

[0103] (5) The InternVL Model:

[0104] The InternVL model supports multiple modalities including image, video, text, speech, 3D, and medical data. It integrates a pre-trained InternViT-6B network, uses a randomly initialized MLP projector network, and a pre-trained InternLM2-20B network. Based on the aspect ratio and resolution of the input image, it divides the image into 448×448 pixel blocks, with sizes ranging from 1 to 12. To enhance scalability at high resolutions, pixel shuffling is used, reducing the number of visual tokens to one-quarter of the original; a 448×448 image can be represented by 256 visual tokens.

[0105] It should be noted that the embodiments of this application involve operations such as obtaining game match videos and corresponding match operation data. When the above embodiments of this application are applied to specific products or technologies, user permission or consent is required, and the collection, use and processing of related data must comply with the relevant laws, regulations and standards of the relevant countries and regions.

[0106] In this application embodiment, the terms "module" or "unit" refer to a computer program or part of a computer program that has a predetermined function and works with other related parts to achieve a predetermined goal, and can be implemented wholly or partially using software, hardware (such as processing circuitry or memory), or a combination thereof. Similarly, a processor (or multiple processors or memory) can be used to implement one or more modules or units. Furthermore, each module or unit can be part of an overall module or unit that includes the functionality of that module or unit.

[0107] The following is a brief introduction to the application areas of the training method of the text prediction model and the game commentary method provided in the embodiments of this application.

[0108] With the continuous development of technology, more and more client or server devices can run video games, such as first-person shooter (FPS) games. Please refer to [link / reference]. Figure 1AThis is a schematic diagram of the game interface of an FPS video game, which includes the game scene (including buildings, terrain, vegetation, etc.) from the first-person perspective of a game character, the game character's health, movement speed, the remaining number of virtual combat tools possessed by the game character, the approximate location of other characters (including teammates and opponents) near the game character, and their positions on the minimap.

[0109] In some competitive sports, First-Person Shooter (FPS) video games have become official competition events. Therefore, both online and offline competitive video games are often streamed with commentary to provide a comprehensive viewing experience.

[0110] Besides human commentary, there is also an intelligent commentary method based on a trained text prediction model. Specifically, firstly, based on the game configuration data of the video game, corresponding event descriptions are pre-edited for various preset game events.

[0111] Please refer to Figure 1B Preset match events can include knocking down an opponent's character, depleting an opponent's health, replenishing the health of other teammates, throwing virtual tools, and teammates forming a positional relationship that surrounds the opponent's character. The pre-edited event descriptions could include phrases like "Character 1 quickly knocked down opponent's character 2," "Character 1 eliminated opponent's character 2," "Character 1 used a resurrection item to revive teammate character 2," "Character 1 threw out tool A," and "Character 1 skillfully completed a flanking maneuver."

[0112] Next, during the operation of the video game, when a preset match event is triggered, the event summary associated with the preset match event is input into the trained text prediction model for text expansion, obtaining the event description text output by the text prediction model. For example, inputting "Character 1 skillfully completed the flanking maneuver" into the trained text prediction model for text expansion can yield "Character 1 and his teammate coordinated their movements, skillfully completing the flanking maneuver without the opponent's notice."

[0113] Finally, the event description text is read aloud via voice, thus providing commentary on the video game.

[0114] In related technologies, text prediction models are large language models trained on a large number of short texts to expand text descriptions.

[0115] However, commentary based on pre-defined game events can only reflect the operation of the video game from a single event perspective. Furthermore, text expansion based on a trained text prediction model can only fully describe the pre-defined game events, but cannot vividly describe the game scenes and game strategies, etc., which makes the commentary based on the trained text prediction model quite limited.

[0116] To address the limitations of using target prediction models for game commentary, this application proposes a training method for a text prediction model. This method involves acquiring multiple game video clips and corresponding game execution data, and then performing the following operations for each game execution data set: extracting at least one behavioral feature dataset, event feature dataset, and state feature dataset for each game character from the game execution data. Each behavioral feature dataset represents a character action triggered by the corresponding game character; each event feature dataset represents a game event participated in by the corresponding game character; and each state feature dataset represents the character's state within a time interval.

[0117] Based on multiple game match videos, and combining the obtained datasets of behavioral features, event features, and state features, the text prediction model is trained iteratively through multiple rounds to obtain the target prediction model. The target prediction model is used to output match commentary text based on the received game video stream.

[0118] In this embodiment, a text prediction model is trained based on multiple game videos, enabling the text prediction model to acquire rich visual information. This helps the trained target prediction model learn visual information description capabilities during the training process, thereby describing multi-layered content such as game scenes and reducing the limitations of commentary when using the target prediction model for game commentary.

[0119] Furthermore, feature data is extracted from game operation data from multiple perspectives, such as character behaviors triggered by game characters, game events participated in by game characters, and character states of game characters. This data is then used to train the text prediction model, enabling the text prediction model to acquire rich game background knowledge. This helps the trained target prediction model learn multi-angle detailed description capabilities during the training process, reducing the limitations of commentary when using the target prediction model for game commentary.

[0120] Furthermore, by combining game videos and extracted feature data, the text prediction model is trained, enabling it to correlate feature data with visual information. This helps the trained target prediction model learn to summarize and describe integrated feature data and visual information during the training process, thus describing multi-layered content such as game strategies and reducing the limitations of commentary when using the target prediction model for game commentary.

[0121] Building upon this foundation, this application proposes a game commentary method. In this method, after receiving the game video stream and corresponding runtime data stream of the target game, and when a trained target prediction model is deployed, the target prediction model is used to generate game commentary text based on the game video stream and runtime data stream. The target prediction model is trained using the aforementioned text prediction model training method. Based on the game video stream, the game process of the target game is presented in video format, and the game commentary text is broadcast in audio format using a preset timbre.

[0122] In this embodiment, a target prediction model with multi-layered and multi-angle text description capabilities for game match videos is used to perform text prediction on the received target game match video stream to obtain the match commentary text of the target game. This allows the match commentary text to describe visual information such as game scenes, as well as rich game background knowledge, describe multi-angle details in the match process, and describe multi-layered content such as match strategies. This achieves a comprehensive and rich match commentary process, greatly reducing the limitations of commentary based on target prediction models.

[0123] The following describes the training method of the text prediction model and the application scenarios of the game commentary method provided in this application.

[0124] Please refer to Figure 1C This diagram illustrates an application scenario of the training method and game commentary method for the text prediction model provided in this application. The application scenario includes a server 101 and a client 102, which can communicate with each other. The communication method can be wired, such as through a network cable or serial cable; or wireless, such as through Bluetooth or Wi-Fi. No specific limitation is imposed.

[0125] Client 102 generally refers to devices that can perform downstream tasks based on text prediction models, such as terminal devices, third-party applications accessible by terminal devices, or web pages accessible by terminal devices. Server 101 generally refers to devices that can use or train text prediction models, such as terminal devices or servers.

[0126] Terminal devices include, but are not limited to, mobile phones, computers, smart medical devices, smart home appliances, vehicle terminals, or aircraft. Servers include, but are not limited to, cloud servers, local servers, or associated third-party servers. Both client 101 and server 102 can use cloud computing to reduce the use of local computing resources; similarly, they can also use cloud storage to reduce the use of local storage resources.

[0127] As one embodiment, the server 101 and the client 102 can be the same device, or they can be different devices, or they can be different devices with some modules shared, etc., and there are no specific restrictions.

[0128] Client 102 responds to live streaming or rebroadcasting operations for a game of the target game by obtaining the game video stream and runtime data stream. Client 102 sends the game video stream and runtime data stream to server 101. Server 101 continuously receives the game video stream and runtime data stream sent by client 102. At regular intervals, it uses the game video stream received during this period as the game video and the runtime data stream received during this period as the game runtime data. Using a trained target prediction model based on the game video and game runtime data, it generates game commentary text. Server 101 returns the generated game commentary text to client 102. After receiving the game commentary text sent by server 101, client 102, based on the game video stream during this period, presents the game of the target game in video format while simultaneously broadcasting the obtained game commentary text in audio format using a preset tone, thereby achieving an intelligent game commentary process.

[0129] The following is based on Figure 1C This document provides a detailed description of the training method for the text prediction model provided in the embodiments of this application. Please refer to [link / reference]. Figure 2 This is a flowchart illustrating a training method for a text prediction model provided in an embodiment of this application.

[0130] S201, acquires multiple game match videos and corresponding match operation data respectively.

[0131] Game match videos can be videos of clearing a level in the game, videos of battles between at least two groups of game characters, or videos of competitive matches between at least two game characters, etc. There are no specific restrictions.

[0132] Obtaining game match videos can be achieved by triggering the recording function at the start of the match and triggering the recording function to stop at the end of the match; or by triggering the video stream data acquisition function at the start of the match and triggering the video stream data acquisition function to stop at the end of the match, etc. There are no specific restrictions.

[0133] Match execution data refers to the execution data related to the match process corresponding to the match video, among the various execution data generated during game operation (such as the various execution data generated by the game core). By using at least one of the video information such as the content of each screen presented in the game match video, frame rate, match number, or timestamp, a correspondence between the game match video and the match execution data can be established. This allows the match execution data corresponding to the game match video to be obtained from the various execution data generated during game operation.

[0134] Multiple game match videos can be from the same game, such as all matches from game A; or they can be from multiple games of the same type, such as games A and B both being FPS games, in which case at least one match video can be from game A and at least one match video can be from game B; multiple game match videos can also be from multiple types of games, such as game C being a simulation game and game D being a shooting game, in which case at least one match video can be from game C and at least one match video can be from game D, etc., without specific limitations. This embodiment uses the example of multiple game match videos from at least one game of the same type for illustration.

[0135] Game match videos can be viewed from the perspective of a game character. The game character can be the player's virtual character, or a virtual character chosen by the player from a variety of virtual avatars provided by the target game, etc. There are no specific restrictions.

[0136] Game match videos can also consist of videos showcasing the gameplay from the perspectives of multiple game characters. For example, please refer to... Figure 3A Between the first and second moments, the game process is presented from the perspective of game character A; between the second and third moments, the game process is presented from the perspective of game character B; between the third and fourth moments, the game process is presented from the perspective of game character C; and between the fourth and fifth moments, the game process is switched back to the perspective of game character A, and so on.

[0137] A game match video presents the gameplay from the perspective of a single character. This can include only that character's actions, such as picking up virtual items, healing teammates, or driving virtual vehicles; or it can include combat between that character and other opposing characters, such as using attack skills on other opponents or surrounding them with teammates. Please refer to [link / reference]. Figure 3B This is a frame from a game video, showing the battle between a game character and other characters on the same team, and other characters on the opposing team, from the perspective of that character.

[0138] S202, for each game run data, perform the following operations: extract at least one behavioral feature dataset, event feature dataset, and state feature dataset corresponding to each game character from the game run data.

[0139] After obtaining multiple game match videos and corresponding match operation data, feature data that can characterize the game's features can be extracted from each match operation data, such as behavioral feature data, event feature data, or state feature data.

[0140] Each behavioral feature data represents a character behavior triggered by a corresponding game character. Taking FPS video games as an example, character behaviors may include: sprinting, standing, crawling, crawling, being in a vehicle, driving, jumping, vaulting over walls, crouching, swimming, aiming down sights, being inside a building, firing a gun, injuring an enemy, being attacked, throwing projectiles, seeing a person, seeing a vehicle, and using medicine, etc.

[0141] Each event feature data represents a game event in which the corresponding game character participated. For example, in an FPS video game, please refer to [reference needed]. Figure 4A Match events can include: {{Character Name A}} defeating {{Character Name B}}, {{Character Name A}} being eliminated, {{Character Name A}} knocking down {{Character Name B}}, {{Character Name A}} knocking down and defeating {{Character Name B}}, {{Character Name A}} aiming down sights and defeating {{Character Name B}}, {{Character Name A}} recovering health at the fastest speed, {{Character Name A}} being in the automatic health loss zone, {{Character Name A}} hitting {{Character Name B}} in the head, {{Character Name A}} driving towards {{Building Name 1}} at the second fastest speed, {{Character Name A}} landing near {{Building Name 1}}, etc.

[0142] The event feature data can also include a preset event description (e.g., denoted as caption), for example, please refer to [reference needed]. Figure 4BFor the match event {{character name A}} knocking down and defeating {{character name B}}, the default event description could be "{{character name A}} hit and finished off {{character name B}}, securing a kill"; for the match event {{character name A}} aiming down sights and defeating {{character name B}}, the default event description could be "{{character name A}} aiming down sights and knocking down {{character name B}} in one hit", etc.

[0143] Each state feature data represents the state of the corresponding game character within a time interval. Taking an FPS video game as an example, the character state can include: the game character's remaining health, position coordinates on the scene map, relative position to other enemy characters, and position coordinates of other enemy characters, etc. Please refer to [reference needed]. Figure 4C The status of the same game character in multiple adjacent time intervals can be recorded in the form of a list. In the first second, the remaining health of game character A is 100 and the position coordinates are (50, 26, 44). The position coordinates of the other opposing character B who is closest to game character A in a straight line are (62, 36, 24). In the second second, the remaining health of game character A is 100 and the position coordinates are (54, 21, 45). The position coordinates of the other opposing character B who is closest to game character A in a straight line are (58, 52, 20). In the third second, the remaining health of game character A is 80 and the position coordinates are (76, 35, 28). The position coordinates of the other opposing character C who is closest to game character A in a straight line are (78, 57, 20), and so on. These are not listed one by one here.

[0144] As one embodiment, when extracting the behavioral feature dataset, event feature dataset, and state feature dataset corresponding to each game character, the game execution data can be treated as a whole, and the behavioral feature dataset, event feature dataset, and state feature dataset corresponding to each game character can be extracted sequentially. Alternatively, the game execution data can be divided into multiple segments of execution data according to the character's perspective presented in the game game video. From each segment of execution data, a subset of behavioral data, a subset of event data, and a subset of state data for the corresponding game character can be extracted. Then, the obtained subsets of behavioral data, event data, and state data are integrated to obtain the behavioral feature dataset, event feature dataset, and state feature dataset corresponding to each game character. Each segment of execution data corresponds to a video segment in the game game video presented from the same character's perspective, while different segments of execution data correspond to video segments presented from different character perspectives in the game game video. In this embodiment, the method of extracting game execution data by dividing it into multiple segments of execution data is described as an example.

[0145] After obtaining multiple game match videos, each video can be segmented based on preset segmentation conditions to obtain multiple video clips. Each video clip belongs to the perspective of a game character, and different video clips belong to the perspectives of different game characters.

[0146] During a game, different players control different game characters, resulting in different character perspectives presented to each player. Each frame of the game video only shows the game from the perspective of one character. By switching between different character perspectives, the game can be shown from the individual combat angles of multiple game characters. For example, after character A is eliminated, the perspective can be switched to that of another character B on the same team; or, if character A is not participating in a team fight, the perspective can be switched to that of another character B on the same team who is participating in a team fight, and so on. There are no specific limitations. Therefore, by video segmentation, multiple adjacent video frames presenting the same character's perspective (such as 16 adjacent video frames) can be grouped together to obtain a video clip, thus allowing for the creation of multiple video clips.

[0147] Each frame of a game match video can display different character perspectives within different display areas, allowing for simultaneous viewing of the match from the individual angles of multiple characters. For example, the top left area could show the perspective of character A, the bottom left area the perspective of teammate character B, the top right area the perspective of teammate character C, and the bottom right area the perspective of teammate character D. By segmenting the video, each area can be divided into separate video clips, resulting in multiple video clips.

[0148] After dividing the game into multiple video segments, the corresponding segment execution data of each video segment can be selected from the game execution data to achieve the goal of dividing the game execution data into multiple segment execution data and matching the video segments with the segment execution data one by one.

[0149] For multiple video clips, the following steps are performed separately: extracting subsets of behavior data, event data, and state data for the corresponding game characters from the segment execution data of each video clip. Therefore, based on the subsets of behavior data, event data, and state data obtained from multiple video clips, at least one set of behavior feature datasets, event feature datasets, and state feature datasets corresponding to each game character can be established.

[0150] By extracting feature data from the game's execution data based on the game content presented in the game video, the content described in the generated game commentary text is all that can be directly seen in the game video. This allows the commentary text and the game video to complement each other and achieve the purpose of commentary. It also avoids unnecessary misunderstandings caused by the commentary text containing game content not shown in the game video, and improves the accuracy of commentary when using the trained target prediction model.

[0151] As an example, when segmenting video clips, in addition to considering the perspective of the characters, more segmentation conditions can be added according to the actual use scenario of the text prediction model to improve the accuracy of narration when using the trained target prediction model for narration.

[0152] The following section introduces three segmentation conditions as examples; other segmentation conditions will not be listed here.

[0153] Fragment segmentation condition one:

[0154] The duration of the segments formed by the multiple video frames is within a preset range.

[0155] For example, if the preset range is 5-16 seconds, then multiple consecutive video frames can be selected from the perspective of one game character to the perspective of another game character, ensuring that the duration of the resulting segment is within 5-16 seconds. If the video frame showing the perspective of a single game character is less than 5 seconds, then that perspective is discarded. If the video frame showing the perspective of a single game character is more than 16 seconds, then multiple consecutive video frames can be selected in 16-second intervals. This can be done by starting with the video frame showing the perspective of one game character, ending with the video frame showing the perspective of another game character, selecting according to other segmentation conditions, or selecting multiple consecutive video frames containing a large number of other opposing characters. If the video frame showing the perspective of a single game character is a multiple of any value within the 5-16 second range, then multiple video frames within each 16-second interval can be divided into a video segment to obtain multiple video segments from the perspective of that single game character, etc., without any specific restrictions.

[0156] By limiting the duration of video segments within a preset range, the text prediction model can be trained on video segments with relatively uniform durations, without having to adapt to the durations of many video segments. This avoids the situation where the text prediction model is too complex and difficult to train. At the same time, through iterative training, the trained target prediction model can find a descriptive key point in the video every 5 to 16 seconds to output the commentary text. This avoids situations where there is a lot of blank commentary due to long periods without outputting commentary text, and also avoids the instability caused by the target prediction model consuming a lot of running memory due to outputting commentary text every second, thus reducing the commentary limitations of the target prediction model.

[0157] Fragment segmentation condition two:

[0158] The segment formed by the multiple video frames is presented with at least one set game event from the set game event set.

[0159] The set of defined match events can include all possible match events configured for the target game, such as defeat events and knockdown events, which are directly related to winning the game. This set of defined match events represents the most exciting match events. When a segmented video contains at least one defined match event from this set, it indicates that the video segment contains content worthy of commentary. Therefore, training a text prediction model based on such video segments enables the model to learn to capture exciting content, improving the accuracy of the commentary provided by the trained target prediction model.

[0160] The segmentation conditions may also include: the segment formed by the segmented multiple video frames presents at least one set of set character behavior from the set character behavior set; and may also include: the segment formed by the segmented multiple video frames presents at least one set of set game events from the set game event set, and / or presents at least one set of set character behavior from the set character behavior set, etc., without any specific limitations.

[0161] Segmentation condition three:

[0162] The video segments formed by the split video frames present the game process as a preset game type.

[0163] The preset match type can be either team battle or individual battle. Team battles represent matches where multiple teammates and multiple opponents fight, one team member and multiple opponents fight, or multiple teammates and one opponent fight. Team battles typically attract more viewer attention; therefore, presenting the match in a team battle format in the video clip allows the text prediction model to learn to capture viewer attention, improving the accuracy of the trained target prediction model's commentary.

[0164] Individual combat type is characterized by a battle between a player's character and an opponent's character during a match, or it may only include the actions of the player's character from their perspective. Individual combat type usually reflects a player's operating habits against a particular character. Therefore, if the match process presented in the video clip is of individual combat type, it can enable the text prediction model to learn to capture the player's operating characteristics, thereby improving the interpretation accuracy of the trained target prediction model.

[0165] The preset match type can also represent matches between specified characters, including matches with specified match events, etc. There are no restrictions on the specifics. The specified match event can be the same as or different from the set match event introduced earlier. For example, a specified match event is to defeat multiple other opponent characters in succession, and the time interval between defeating each other opponent character is less than the interval threshold; another example is to knock down other opponent characters while both the player character and the other opponent characters are moving, and the straight-line distance between the player character and the other opponent characters is greater than the distance threshold; yet another example is that the player character uses a high-level skill to defeat multiple other opponent characters in succession, etc. There are no restrictions on the specifics.

[0166] S203, based on multiple game video recordings, combined with the obtained behavioral feature datasets, event feature datasets, and state feature datasets, performs multiple rounds of iterative training on the text prediction model to obtain the target prediction model.

[0167] After obtaining multiple game match videos and at least one behavioral feature dataset, event feature dataset, and state feature dataset for each game character extracted from the match data, the text prediction model can be iteratively trained multiple times based on the multiple game match videos and the obtained behavioral feature dataset, event feature dataset, and state feature dataset to obtain the target prediction model. The target prediction model is used to output match commentary text based on the received match video streams.

[0168] Multiple game videos, or video segments as described above, can be used as sample datasets. The obtained behavioral feature datasets, event feature datasets, and state feature datasets can generate sample labels associated with each sample data according to the set training task. Thus, the text prediction model can be trained iteratively in multiple rounds based on the sample datasets and the sample labels associated with each sample data to obtain the target prediction model.

[0169] Training tasks can be set according to the actual use scenario of the target prediction model. For example, when the target prediction model focuses on the explanation of game scenes, training tasks related to scene description can be set; when the target prediction model focuses on the explanation of team battle summaries, training tasks related to team battle summaries can be set; when the target prediction model focuses on the explanation of team battle analysis, training tasks related to team battle analysis can be set; when the target prediction model focuses on the explanation of the final circle, training tasks related to the review of the final circle can be set, etc. Multiple training tasks can also be combined, and the text prediction model can be trained in stages.

[0170] Please refer to Figure 5A The training tasks include team battle summary, team battle analysis, and final round review tasks. Since these three training tasks are all based on game scenario tasks, in the first stage, based on the obtained behavioral feature datasets, event feature datasets, and state feature datasets, scene description texts are generated according to the scene description task. Then, the text prediction model is trained iteratively multiple times based on multiple game videos and scene description texts to obtain the first-stage prediction model. In the second stage, based on the obtained behavioral feature datasets, event feature datasets, state feature datasets, and scene description texts, corresponding team battle summary texts, team battle analysis texts, and final round review texts are generated according to the team battle summary task, team battle analysis task, and final round review task, respectively. Then, based on multiple game videos and the obtained team battle summary texts, team battle analysis texts, and final round review texts, the first-stage prediction model is trained iteratively multiple times to obtain the target prediction model.

[0171] The following is an example of a training process; other training processes are similar and will not be listed here.

[0172] If each game match video belongs to the perspective of a single game character, then a text prediction model can be directly trained based on multiple game match videos. If each game match video contains the perspectives of multiple game characters, then each game match video can be divided into multiple video segments according to the segmentation method described above, and a text prediction model can be trained based on each video segment. In this embodiment, an example is given where each game match video contains multiple video segments, and each video segment belongs to the perspective of a single game character.

[0173] For each game match video containing multiple video segments, the following steps are performed: Using a trained question-answering model, based on the obtained behavioral feature datasets, event feature datasets, and state feature datasets, text descriptions are generated for at least one of the character behaviors and game events presented in the video segments, as well as the changes in game states presented in the video segments, resulting in segment summary text. Based on the multiple video segments contained in each of the multiple game match videos, and the obtained segment summary texts, combined with the behavioral feature datasets and event feature datasets, the text prediction model is trained iteratively through multiple rounds to obtain the target prediction model.

[0174] The trained question-answering model can be a visual question-answering model downloaded from online resources, or it can be trained using explanatory text collected from online resources, etc., with no specific restrictions. The training task is given a prompt word. The question-answering model can then output the text corresponding to the training task based on the input prompt word. For example, the question-answering model can be used for scene description tasks, outputting a summary text of a video clip, etc. The question-answering model can be a Generative Pretrained Transformer 4 (GPT-4) model, a General Language Model 4 (GLM-4) model, etc., with no specific restrictions.

[0175] Changes in game state represent changes in the state of the game, such as changes in remaining health, changes in the position of the game character, and changes in the relative position of the game character with other opponent characters.

[0176] For example, using a trained question-answering model, based on the obtained datasets of behavioral features and state features, textual descriptions are generated of the behaviors of each character presented in the video clip, as well as the changes in the game state presented in the video clip, resulting in a clip summary text. Similarly, using a trained question-answering model, based on the obtained datasets of event features and the changes in the game state presented in the video clip, textual descriptions are generated of the behaviors of each character and the game events presented in the video clip, as well as the changes in the game state presented in the video clip, resulting in a clip summary text.

[0177] Through the trained question-answering model, a full semantic understanding can be achieved on the obtained behavioral feature datasets, event feature datasets, and state feature datasets. This allows the feature data to be described in rich and varied language, achieving the goal of providing a textual description of the game scene of the target game from the perspective of feature data. The obtained fragment summary text can serve as a reference for the text prediction model to understand video fragments, which helps to assist in training the text prediction model.

[0178] As one example, in the process of text description for each video segment, the reasoning process and logical steps in the text description process can be demonstrated through the Chain of Thought (COT) method, instead of directly giving the conclusion. By describing different types of event behaviors and changes in health points and positions separately, and then synthesizing them into an overall description, it is not only interpretable, but also ensures that no important information is omitted. It covers the dynamic changes of various aspects in the game scene, which conforms to human thinking and analysis habits, making the description more complete and rich, and helping to understand the game scene at that time more accurately.

[0179] Using a trained question-answering model, based on the obtained datasets of behavioral features and event features, and with a preset duration, the model provides textual descriptions of at least one of the character behaviors and game events presented in each video segment within each period, obtaining periodic description text. Using the same question-answering model, based on the obtained datasets of state features, the model provides textual descriptions of the game state changes presented in the video segment, obtaining state description text. Finally, the model summarizes the obtained periodic description text and state description text to obtain a segment summary text for the video segment.

[0180] The preset duration can be 1 second, 1 minute, etc. By providing textual descriptions of at least one of the character behaviors and game events presented in each cycle, it avoids omitting any character behaviors and game events, provides comprehensive reference information for the summary description, and improves the comprehensiveness and accuracy of the text description.

[0181] As one example, to train the visual content understanding ability of the text prediction model, the model can be trained in stages using various behavioral feature datasets, event feature datasets, and the obtained summary text of each segment. The first stage trains the model to identify character behaviors corresponding to behavioral feature data and game events corresponding to event feature data from video segments, obtaining an intermediate prediction model. The second stage trains the intermediate prediction model to summarize video segments, obtaining the target prediction model. By refining the training objectives in stages, and conducting multiple rounds of training from coarse to fine and from simple to complex, the trained target prediction model possesses rich game knowledge. Combined with this game knowledge, it gains a deeper understanding of the game content, resulting in more accurate game commentary text.

[0182] Phase 1: Based on multiple video segments contained in each of the multiple game match videos, combined with various behavioral feature datasets and event feature datasets, the text prediction model is trained iteratively through multiple rounds, and an intermediate prediction model is obtained through supervised fine-tuning. Phase 2: Based on multiple video segments contained in each of the multiple game match videos, and the obtained summary text of each segment, the intermediate prediction model is trained iteratively through multiple rounds, and the target prediction model is obtained through supervised fine-tuning.

[0183] As one example, the text prediction model can be trained in multiple rounds using the output scene description text as the training task, based on a training dataset constructed from each video segment, configuration behavior data extracted from the configuration data of the target game, configuration event data, and the segment execution data corresponding to each video segment in the game execution data. During the training process, at least one of the following metrics can be used to evaluate the output scene description text to obtain the initially trained text prediction model.

[0184] The configuration data of the target game is the configuration data written during the development of the target game. Each configuration behavior data represents all possible character behaviors that can be triggered in the target game, and each configuration event data represents all possible game events that can be participated in in the target game.

[0185] For example, the training dataset contains 3573 training data points. The deep learning optimization library (deepspeedstage3) is used to accelerate the training process of the deep learning model and reduce memory usage. During training, the deep learning model completes eight epochs of forward and backward propagation on the 3573 training data points. After each epoch, the deep learning model adjusts its parameters based on the training loss, aiming for better evaluation results on the output scene description text. During training, the deep learning model adjusts its parameters by relatively small increments, such as 0.000001. If the learning rate is set too high, the deep learning model may fail to converge or even diverge during training; if the learning rate is set too low, although the deep learning model may converge more stably, the training process becomes very slow, requiring more training time and computational resources. Using the fp16 data type during training can reduce the memory space occupied by the deep learning model during training and can accelerate computation on some hardware that supports half-precision computing, thus improving training efficiency.

[0186] Please refer to Figure 5B The training process is divided into three stages. Stage A: Based on each video segment, configuration behavior data and configuration event data extracted from the configuration data of the target game, as well as the segment operation data corresponding to each video segment in the game operation data, the training task is set as a scene description task. The basic prediction model is trained in multiple rounds of iteration to obtain a text prediction model with basic game knowledge of the target game.

[0187] Phase B: Based on each behavioral feature dataset, the training task is set as a behavior recognition task, and based on each event feature dataset, the training task is set as an event recognition task. Based on multiple video segments contained in each game video, the text prediction model is trained in multiple rounds of iterations, combining the behavior recognition task and the event recognition task, to obtain an intermediate prediction model. The intermediate prediction model can output whether the video segment contains a game event corresponding to an event feature data, and whether the video segment contains a character behavior corresponding to a behavior feature data, etc.

[0188] Phase C: Based on the obtained summary text of each segment, the training task is set as the game summary task. Based on each video segment, the intermediate prediction model is trained in multiple rounds of iteration to obtain the target prediction model. The target prediction model can output the game commentary text for the video segment.

[0189] As one example, each iteration of training for the text prediction model can include various training methods. If each game match video is divided into multiple video segments, then the corresponding match execution data can be divided into segment execution data corresponding to each video segment. For each segment execution data, a subset of the game character's behavior data, event data, and state data is extracted, thereby obtaining a behavior feature dataset, event feature dataset, and state feature dataset corresponding to at least one game character in the game match video. That is, each behavior feature dataset contains at least one subset of behavior data. Each behavior feature data in each subset of behavior data represents the character behaviors triggered by the corresponding game character during a match presented in a video segment. Based on this, two training methods are described below as examples.

[0190] Method 1:

[0191] In each iteration of training for the text prediction model, the model can first predict the game character corresponding to the perspective presented in the video clip, based on the selected video clip and various behavioral feature datasets, and then predict at least one predicted character behavior triggered in the video clip. For example, using the text prediction model, based on the video clip, it can predict the game character corresponding to the perspective presented in the video clip, the trigger probability of triggering the corresponding character behavior in each behavioral feature dataset within the video clip, and select at least one predicted character behavior whose trigger probability is greater than a trigger threshold.

[0192] Then, based on at least one predicted character behavior, and the behavior of each character represented by a subset of behavior data corresponding to video clips obtained from the behavior feature dataset corresponding to the game characters, the behavior recognition loss of the text prediction model is determined. For example, the behavior difference between at least one predicted character behavior and the behavior of each character represented by the subset of behavior data corresponding to the video clips is determined, and the behavior recognition loss is determined based on the obtained behavior difference. Thus, the model parameters of the text prediction model can be adjusted based on the behavior recognition loss.

[0193] Method 2:

[0194] In each iteration of training for the text prediction model, the configuration data of the target game can be acquired first, from which the configuration behavior data of all character behaviors that can be triggered in the target game can be extracted. Based on each configuration behavior data and the behavior data subset corresponding to the video segment, as well as the selected video segment, the game character corresponding to the character's perspective presented in the video segment is predicted, and at least one predicted character behavior is triggered in the video segment. For example, using the text prediction model, based on the video segment, the probability of triggering the game character corresponding to the character's perspective presented in the video segment and the corresponding character behavior of each configuration behavior data in the video segment is predicted, and at least one predicted character behavior with a trigger probability greater than a trigger threshold is selected.

[0195] Based on at least one predicted character's behavior, and the behavior of each character represented by a subset of video clips obtained from the behavioral feature dataset corresponding to the game character, the behavior recognition loss of the text prediction model is determined. Therefore, the model parameters of the text prediction model can be adjusted based on the behavior recognition loss.

[0196] As one example, each event feature dataset also contains at least one subset of event data. Each event feature data within each subset of event data represents the various game events participated in by the corresponding game character during a match presented in a video clip. Based on this, two training methods are described below as examples.

[0197] Method 1:

[0198] Using a text prediction model, based on selected video clips and event feature datasets, the model first predicts the game character's participation in at least one predicted match event within the video clip, corresponding to the character's perspective presented in the clip. For example, using a text prediction model, based on a video clip, the model predicts the probability of the game character's participation in each match event corresponding to a specific event feature dataset within the video clip, and selects at least one predicted match event with a participation probability greater than a participation threshold.

[0199] Then, based on at least one predicted game event and the game events represented by a subset of event data corresponding to video clips obtained from the event feature dataset corresponding to game characters, the event recognition loss of the text prediction model is determined. For example, the event differences between at least one predicted game event and the game events represented by the subset of event data corresponding to video clips are determined, and the event recognition loss is determined based on the obtained event differences. Thus, the model parameters of the text prediction model can be adjusted based on the event recognition loss.

[0200] Method 2:

[0201] In each iteration of the text prediction model's training, the configuration data of the target game can be acquired first, from which the configuration event data for all possible game events can be extracted. Based on each configuration event data and the event data subset corresponding to the video clip, as well as the selected video clip, the probability of the game character corresponding to the perspective presented in the video clip participating in at least one predicted game event within the video clip can be predicted. For example, using the text prediction model, based on the video clip, the probability of the game character corresponding to the perspective presented in the video clip participating in each configuration event within the video clip can be predicted, and at least one predicted game event with a participation probability greater than a participation threshold can be selected.

[0202] Based on at least one predicted game event, and each game event represented by a subset of event data corresponding to video clips obtained from the event feature dataset corresponding to the game character, the event recognition loss of the text prediction model is determined. Therefore, the model parameters of the text prediction model can be adjusted based on the event recognition loss.

[0203] As an example, there are several methods for training the intermediate prediction model in each iteration. Two of them will be introduced below.

[0204] Method 1:

[0205] An intermediate prediction model is used to extract content features from selected video segments, obtaining their visual features. Based on these visual features, the intermediate prediction model predicts the game description text for each video segment. The model parameters are then adjusted based on the textual differences between the game description text and the segment summary text.

[0206] Method 2:

[0207] First, acquire the configuration data of the target game, extracting the configuration behavior data for all character behaviors that can be triggered in the target game, and extracting the configuration event data for all match events that can be participated in in the target game. Using an intermediate prediction model, extract content features from selected video clips to obtain content visual features. Then, using the intermediate prediction model, based on the content visual features, predict the game character corresponding to the character's perspective presented in the video clip, at least one predicted character behavior triggered in the video clip, and / or at least one predicted match event participated in in the video clip.

[0208] For example, predicting the game character corresponding to the perspective of the character presented in a video clip, determining the trigger probability of each configured behavior data corresponding to the character's behavior in the video clip, and selecting at least one predicted character behavior with a trigger probability greater than a trigger threshold. As another example, using a text prediction model, based on a video clip, predicting the game character corresponding to the perspective of the character presented in the video clip, determining the participation probability of each configured event data corresponding to the game event in the video clip, and selecting at least one predicted game event with a participation probability greater than a participation threshold.

[0209] An intermediate prediction model is used to predict the game description text of video clips based on content visual features, at least one predicted character behavior, and / or at least one predicted game event. The model parameters of the intermediate prediction model are adjusted based on the textual differences between the game description text and the clip summary text of the video clip.

[0210] As one example, since the target prediction model is a large multimodal model with multimodal recognition and text description capabilities, it cannot be deployed in some lightweight scenarios. Therefore, the target prediction model can be used to output the game commentary text corresponding to each of the multiple game videos based on multiple game video recordings and corresponding game operation data.

[0211] Please refer to Figure 5C A sample dataset is established using each game's execution data as sample data and the game commentary text output based on each game's execution data as the sample label for the corresponding sample data. Based on the sample dataset, a pre-set initial prediction model is trained iteratively through multiple rounds to obtain a trained candidate prediction model. The candidate prediction model is used to output game commentary text based on the received execution data stream of the target game. The parameter size of the candidate prediction model is smaller than that of the target prediction model.

[0212] Thus, by training a small alternative prediction model to possess the multimodal recognition and text description capabilities of the target prediction model, and without requiring video input, it can output game commentary text based on the target game's runtime data stream, thereby improving the applicability of the target prediction model and further reducing the limitations of commentary.

[0213] The following example uses the InternVL model for text prediction to illustrate the training method of the text prediction model provided in this application. Please refer to [link / reference]. Figure 6A .

[0214] Acquire a massive amount of gameplay videos of target FPS games, and download the gameplay data corresponding to each video. Segment each gameplay video to obtain multiple video clips. Each video clip represents the perspective of a single game character, contains 16 adjacent video frames, and includes at least one knockdown or defeat event, as well as team-based gameplay content.

[0215] From the game execution data corresponding to each game video, select the segment execution data corresponding to each of the multiple video segments contained in each game video.

[0216] Extract the behavior data subset, event data subset, and state data subset of the corresponding game character from the segment execution data corresponding to each video segment.

[0217] Using a trained question-answering model, based on the behavioral data subset and event data subset corresponding to each video segment, at least one of the character behaviors and game events presented per second in the video segment is described in text, obtaining periodic description text within one second. Using the same question-answering model, based on the state data subset corresponding to each video segment, the changes in the game state presented in the video segment are described in text, obtaining state description text. Finally, using the same question-answering model, the obtained periodic description text and state description text are summarized to obtain the segment summary text of the video segment.

[0218] Based on each video segment, and combining subsets of behavioral data and event data, the text prediction model is trained iteratively multiple times to obtain an intermediate prediction model. Based on each video segment, and combining the summarized text from each segment, the intermediate prediction model is trained iteratively multiple times to obtain the target prediction model.

[0219] The training process can be implemented using the open-source framework Swift. Swift provides solutions for model training, inference, evaluation, and deployment, eliminating the need for frequent switching between different tools or frameworks and improving development efficiency. Please refer to [link / reference]. Figure 6B The target prediction model outputs game commentary text for video clips on the test set. The figure shows four video frames from a video clip as an example.

[0220] Based on the same inventive concept, after outputting the target prediction model using the above training method, the target prediction model can be used to perform game commentary tasks. Please refer to [link / reference needed]. Figure 7A This is a flowchart illustrating a game commentary method provided in an embodiment of this application.

[0221] S701 receives the game video stream and corresponding runtime data stream of the target game.

[0222] S702, when a trained target prediction model is deployed, uses the target prediction model to generate game commentary text based on the game video stream and runtime data stream. The target prediction model is trained using the training method for the text prediction model described above.

[0223] Determine whether a trained target prediction model is deployed. If a trained target prediction model is deployed, use it to generate commentary text based on the game video stream and runtime data stream. If both a trained target prediction model and an alternative prediction model trained based on the target prediction model are deployed, then the current runtime memory usage can be calculated. If the memory usage is below a first threshold, use the target prediction model to generate commentary text; if the memory usage is above a second threshold, use the alternative prediction model to generate commentary text. The first and second thresholds can be the same, or the first threshold can be less than the second threshold, etc., without specific restrictions.

[0224] The S703, based on the game video stream, presents the game process of the target game in video form and uses preset timbres to broadcast the game commentary text in audio form.

[0225] As one embodiment, when a trained alternative prediction model is deployed, it is used to generate game commentary text based on the runtime data stream. The alternative prediction model is trained using the game runtime data input to the target prediction model as sample data and the game commentary text output by the target prediction model as sample labels. The parameter size of the alternative prediction model is smaller than that of the target prediction model. Without requiring video input, it can output game commentary text based on the runtime data stream of the target game. The smaller alternative prediction model improves the applicability of the target prediction model and further reduces the limitations of commentary.

[0226] Please refer to Figure 7B , which is a video frame in the target game's video stream, and the game commentary text generated by the target prediction model.

[0227] In this embodiment of the application, the trained target prediction model can provide rich game commentary techniques during the commentary process of games similar to FPS video games, reduce the limitations of the commentary, and enhance the multiple experiences of the game's visual appeal and the commentary's auditory appeal, making the commentary process more attractive.

[0228] By introducing visual information, the game commentary process based on the target prediction model can provide rich possibilities for future technological development and market expansion, and is expected to further promote the innovation and development of the game industry, bringing a more ultimate gaming experience.

[0229] Based on the same inventive concept, embodiments of this application provide a training apparatus for a text prediction model, capable of realizing the functions corresponding to the aforementioned text prediction model training method. Please refer to... Figure 8A The device includes an acquisition module 81 and a processing module 82, wherein:

[0230] Acquisition module 81: Used to acquire multiple game match videos and corresponding match operation data respectively;

[0231] Processing module 82: For each game run data, perform the following operations: extract at least one behavioral feature dataset, event feature dataset, and state feature dataset corresponding to each game character from the game run data; wherein, each behavioral feature dataset represents a character behavior triggered by the corresponding game character; each event feature dataset represents a game event participated in by the corresponding game character; and each state feature dataset represents the character state of the corresponding game character within a time interval.

[0232] Processing module 82 is also used to: perform multiple rounds of iterative training on the text prediction model based on multiple game video recordings, combined with the obtained behavioral feature datasets, event feature datasets and state feature datasets, to obtain the target prediction model; the target prediction model is used to: output game commentary text based on the received game video stream.

[0233] In one possible embodiment, each game video contains multiple video clips, each video clip belonging to the perspective of a game character;

[0234] The processing module 82 is specifically used for:

[0235] For each game video containing multiple video segments, the following steps are performed: using a trained question-answering model, based on the obtained datasets of behavioral features, event features, and state features, text descriptions are generated for at least one of the character behaviors and game events presented in the video segments, as well as the changes in game state presented in the video segments, to obtain a summary text of the segments.

[0236] Based on multiple video segments contained in each of the game's video recordings, as well as the summary text of each segment, and combined with various behavioral feature datasets and event feature datasets, the text prediction model is trained iteratively in multiple rounds to obtain the target prediction model.

[0237] In one possible embodiment, the processing module 82 is specifically used for:

[0238] Using a trained question-answering model, based on the obtained datasets of behavioral features and event features, and with a preset duration as the period, textual descriptions are performed on at least one of the character behaviors and game events presented in the video clips in each period, to obtain the periodic description text for each period.

[0239] Using a question-answering model, based on the obtained dataset of state features, textual descriptions of the game state changes presented in the video clips are generated to obtain state description text.

[0240] A question-and-answer model is used to summarize and describe the obtained period description text and state description text to obtain the segment summary text of the video segment.

[0241] In one possible embodiment, the processing module 82 is specifically used for:

[0242] Based on multiple video segments contained in each of the game videos, and combined with various behavioral feature datasets and event feature datasets, the text prediction model is trained in multiple rounds of iterations to obtain an intermediate prediction model.

[0243] Based on multiple video segments contained in each of the game videos, and the obtained summary text of each segment, the intermediate prediction model is trained iteratively in multiple rounds to obtain the target prediction model.

[0244] In one possible embodiment, each behavioral feature dataset contains at least one subset of behavioral data; each behavioral feature data in each subset of behavioral data represents the various character behaviors triggered by the corresponding game character during a game in a video clip.

[0245] The processing module 82 is specifically used for:

[0246] Using a text prediction model, based on selected video clips and various behavioral feature datasets, the game character corresponding to the perspective presented in the video clip is predicted, and at least one predicted character behavior is triggered in the video clip.

[0247] Based on at least one predicted character behavior, and the behavior of each character represented by a subset of video clips obtained from the behavior feature dataset corresponding to the game character, the behavior recognition loss of the text prediction model is determined.

[0248] The model parameters of the text prediction model are adjusted based on the behavior recognition loss.

[0249] In one possible embodiment, each event feature dataset contains at least one subset of event data; each event feature data in each subset of event data represents the various game events in which the corresponding game character participates during a game presented in a video clip;

[0250] The processing module 82 is specifically used for:

[0251] Using a text prediction model, based on selected video clips and event feature datasets, the game character corresponding to the perspective presented in the video clip is predicted, and at least one predicted game event is involved in the video clip.

[0252] Based on at least one predicted game event, and each game event represented by a subset of event data corresponding to video clips obtained from the event feature dataset corresponding to the game character, determine the event recognition loss of the text prediction model.

[0253] Adjust the model parameters of the text prediction model based on the event recognition loss.

[0254] In one possible embodiment, for each iteration of training the intermediate prediction model, the processing module 82 is specifically used for:

[0255] An intermediate prediction model is used to extract content features from selected video segments to obtain content visual features;

[0256] An intermediate prediction model is used to predict the game description text of video clips based on the visual features of the content.

[0257] Based on the textual differences between the game description text and the video clip summary text, the model parameters of the intermediate prediction model are adjusted.

[0258] In one possible embodiment, the processing module 82 is specifically used for:

[0259] Based on preset segmentation conditions, the game video corresponding to the game operation data is segmented to obtain multiple video segments; each video segment belongs to the perspective of a game character.

[0260] Select the segment execution data corresponding to each of the multiple video segments from the game execution data;

[0261] For multiple video clips, perform the following steps respectively: extract the behavior data subset, event data subset, and state data subset of the corresponding game character from the clip execution data corresponding to the video clip;

[0262] Based on the obtained subsets of behavioral data, event data, and state data, establish at least one behavioral feature dataset, event feature dataset, and state feature dataset corresponding to each game character.

[0263] In one possible embodiment, the fragment segmentation conditions include at least one of the following:

[0264] The duration of the segments formed by the multiple video frames is within a preset range;

[0265] The segment formed by the multiple video frames is presented with at least one set game event from the set game event set;

[0266] The video segments formed by the split video frames present the game process as a preset game type.

[0267] In one possible embodiment, the processing module 82 is further configured to:

[0268] After obtaining the target prediction model, the target prediction model is used to output the game commentary text corresponding to each of the multiple game videos and the corresponding game operation data.

[0269] A sample dataset is established using the game execution data of each game as sample data and the game commentary text output based on the game execution data as the sample label of the corresponding sample data.

[0270] Based on the sample dataset, the preset initial prediction model is trained in multiple rounds to obtain a trained alternative prediction model. The alternative prediction model is used to output game commentary text based on the received target game's running data stream. The parameter size of the alternative prediction model is smaller than that of the target prediction model.

[0271] Based on the same inventive concept, this application provides a game commentary device capable of performing the functions corresponding to the aforementioned game commentary method. Please refer to... Figure 8B The device includes a transceiver module 801 and a processing module 802, wherein:

[0272] Transceiver module: Used to receive the game's video stream and corresponding runtime data stream;

[0273] Processing module 802: When a trained target prediction model is deployed, it uses the target prediction model to generate game commentary text based on the game video stream and the running data stream; wherein the target prediction model is trained based on the method of any one of claims 1 to 10;

[0274] The transceiver module is also used to: present the game process of the target game in video form based on the game video stream, and broadcast the game commentary text in audio form using preset timbres.

[0275] Optionally, the processing module 802 is also used for:

[0276] When a pre-trained alternative prediction model is deployed, the alternative prediction model is used to generate game commentary text based on the running data stream. The alternative prediction model is trained using the game running data input to the target prediction model as sample data and the game commentary text output by the target prediction model as sample labels. The parameter size of the alternative prediction model is smaller than that of the target prediction model.

[0277] Please refer to Figure 9 This is a computer device 900 provided in the embodiments of this application. The computer device 900 can, for example, be... Figure 1CThe client 102 or server 101 in the system. The current and historical versions of the data storage program and the application software corresponding to the data storage program can be installed on a computer device 900, which includes a processor 980 and a memory 920. In some embodiments, the computer device 900 may include a display unit 940, which includes a display panel 941 for displaying a user-interactive interface, etc.

[0278] In one possible embodiment, the display panel 941 may be configured in the form of a liquid crystal display (LCD) or an organic light-emitting diode (OLED).

[0279] The processor 980 is used to read a computer program and then execute the methods defined by the computer program. For example, the processor 980 reads a data storage program or file, thereby running the data storage program on the computer device 900 and displaying the corresponding interface on the display unit 940. The processor 980 may include one or more general-purpose processors, and may also include one or more digital signal processors (DSPs) for performing related operations to implement the technical solutions provided in the embodiments of this application.

[0280] The memory 920 generally includes main memory and secondary storage. Main memory can be random access memory (RAM), read-only memory (ROM), and cache, etc. Secondary storage can be a hard disk, optical disk, USB flash drive, floppy disk, or magnetic tape drive, etc. The memory 920 is used to store computer programs and other data. The computer programs include applications corresponding to each client, and other data may include data generated after the operating system or applications are run, including system data (e.g., operating system configuration parameters) and user data. In this embodiment, the computer program is stored in the memory 920, and the processor 980 executes the computer program in the memory 920 to implement any of the methods described in the preceding figures.

[0281] As one embodiment, the memory 920 can store multiple game match videos and corresponding match operation data. The processor 980 can retrieve multiple game match videos and corresponding match operation data from the memory 920, and for each match operation data, perform the following operations: extract at least one behavioral feature dataset, event feature dataset, and state feature dataset corresponding to each game character from the match operation data; wherein, each behavioral feature data represents a character behavior triggered by the corresponding game character; each event feature data represents a match event participated in by the corresponding game character; and each state feature data represents the character state of the corresponding game character within a time interval.

[0282] The processor 980 can perform multiple rounds of iterative training on the text prediction model based on multiple game video recordings, combined with the obtained behavioral feature datasets, event feature datasets, and state feature datasets, to obtain the target prediction model; the target prediction model is used to output game commentary text based on the received game video stream.

[0283] As one embodiment, the memory 920 may store the received video stream of the target game and the corresponding runtime data stream. The processor 980 may retrieve the video stream of the target game and the corresponding runtime data stream from the memory 920, and when a trained target prediction model is deployed, use the target prediction model to generate game commentary text based on the video stream and runtime data stream.

[0284] The aforementioned display unit 940 is used to receive input digital information, character information, or contact touch operations / non-contact gestures, and to generate signal inputs related to user settings and function control of the computer device 900. Specifically, in this embodiment, the display unit 940 may include a display panel 941. The display panel 941, for example, is a touch screen, which can collect touch operations performed by the user on or near it (such as operations performed by the user using a finger, stylus, or any suitable object or accessory on or on the display panel 941), and drive corresponding connection devices according to a pre-set program.

[0285] In one possible embodiment, the display panel 941 may include two parts: a touch detection device and a touch controller. The touch detection device detects the player's touch position and the signal generated by the touch operation, and transmits the signal to the touch controller. The touch controller receives touch information from the touch detection device, converts it into touch point coordinates, and sends it to the processor 980. It can also receive and execute commands from the processor 980.

[0286] The display panel 941 can be implemented using various types such as resistive, capacitive, infrared, and surface acoustic wave. In addition to the display unit 940, in some embodiments, the computer device 900 may also include an input unit 930. The input unit 930 may include an image input device 931 and other input devices 932, wherein the other input devices may include, but are not limited to, one or more of the following: a physical keyboard, function keys (such as volume control buttons, power buttons, etc.), a trackball, a mouse, and a joystick.

[0287] As one embodiment, the display unit 940 can present the game process of the target game in video form based on the game video stream, and use a preset tone to broadcast the game commentary text in audio form.

[0288] In addition to the above, the computer device 900 may also include a power supply 990 for powering other modules, an audio circuit 960, a near-field communication module 970, and an RF circuit 910. The computer device 900 may also include one or more sensors 950, such as an accelerometer, a light sensor, and a pressure sensor. The audio circuit 960 specifically includes a speaker 961 and a microphone 962, for example, the computer device 900 can use the microphone 962 to collect the user's voice and perform corresponding operations.

[0289] As one embodiment, the number of processors 980 can be one or more, and the processors 980 and the memory 920 can be coupled together or relatively independent.

[0290] As one example, Figure 9 The processor 980 in the middle can be used to implement, for example Figure 8A The functions of the acquisition module 81 and the processing module 82 can also be used to implement, for example... Figure 8B The functions of the transceiver module 801 and the processing module 802 in the middle.

[0291] As one example, Figure 9 The processor 980 in the text can be used to implement the functions of the server or terminal devices discussed above.

[0292] Those skilled in the art will understand that all or part of the steps of the above method embodiments can be implemented by a computer program. The aforementioned computer program can be stored in a computer-readable storage medium. When the computer program is executed, it performs the steps of the above method embodiments. The aforementioned storage medium includes various media capable of storing program code, such as mobile storage devices, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0293] Alternatively, if the integrated units of this invention are implemented as software functional modules and sold or used as independent products, they can also be stored in a computer-readable storage medium. Based on this understanding, the technical solutions of the embodiments of this invention, or the parts that contribute to the prior art, can be embodied in the form of software products, for example, through computer program products. These computer program products are stored in a storage medium and include computer programs used to cause a computer device to execute all or part of the methods described in the various embodiments of this invention. The aforementioned storage medium includes various media capable of storing program code, such as mobile storage devices, ROM, RAM, magnetic disks, or optical disks.

[0294] Obviously, those skilled in the art can make various modifications and variations to this application without departing from the spirit and scope of this application. Therefore, if such modifications and variations fall within the scope of the claims of this application and their equivalents, this application also intends to include such modifications and variations.

Claims

1. A training method for a text prediction model, characterized in that, include: Acquire multiple game match videos and corresponding match execution data; For each of the aforementioned game operation data, the following operations are performed: extract at least one behavioral feature dataset, event feature dataset, and state feature dataset corresponding to each game character from the game operation data; wherein, each behavioral feature dataset represents a character behavior triggered by the corresponding game character; each event feature dataset represents a game event participated in by the corresponding game character; and each state feature dataset represents the character state of the corresponding game character within a time interval. Based on the multiple game match videos, and combined with the obtained behavioral feature datasets, event feature datasets, and state feature datasets, the text prediction model is trained in multiple rounds of iterations to obtain the target prediction model; the target prediction model is used to: output match commentary text based on the received match video stream.

2. The method according to claim 1, characterized in that, Each game video contains multiple video clips, and each video clip belongs to the perspective of a game character. The process of training the text prediction model through multiple rounds of iterative training based on the multiple game video recordings, combined with the obtained behavioral feature datasets, event feature datasets, and state feature datasets, to obtain the target prediction model includes: For each game video containing multiple video segments, the following steps are performed: using a trained question-answering model, based on the obtained behavioral feature datasets, event feature datasets, and state feature datasets, to perform textual descriptions of at least one of the character behaviors and game events presented in the video segment, as well as the changes in the game state presented in the video segment, to obtain a segment summary text. Based on the multiple video segments contained in each of the multiple game match videos, and the obtained summary text of each segment, combined with the behavioral feature datasets and the event feature datasets, the text prediction model is trained in multiple rounds of iterations to obtain the target prediction model.

3. The method according to claim 2, characterized in that, The method employs a trained question-answering model, based on the obtained datasets of behavioral features, event features, and state features, to provide textual descriptions of at least one of the character behaviors and game events presented in the video clip, as well as the changes in the game state presented in the video clip, to obtain a clip summary text, including: Using a trained question-answering model, based on the obtained datasets of behavioral features and event features, and with a preset duration as the period, textual descriptions are performed on at least one of the character behaviors and game events presented in the video segment in each period, to obtain the periodic description text in each period; Using the question-answering model, based on the obtained dataset of state features, the game state changes presented in the video segment are described in text, and state description text is obtained. Using the question-and-answer model, the obtained period description text and state description text are summarized to obtain the segment summary text of the video segment.

4. The method according to claim 2, characterized in that, The text prediction model is trained iteratively through multiple rounds based on the multiple video segments contained in each of the multiple game match videos, and the obtained summary text of each segment, combined with the behavioral feature datasets and the event feature datasets, to obtain the target prediction model, including: Based on the multiple video segments contained in each of the multiple game videos, and combined with the behavioral feature datasets and the event feature datasets, the text prediction model is trained in multiple rounds of iterations to obtain an intermediate prediction model. Based on the multiple video segments contained in each of the multiple game match videos, and the obtained summary text of each segment, the intermediate prediction model is trained in multiple rounds of iterations to obtain the target prediction model.

5. The method according to claim 4, characterized in that, Each of the behavioral feature datasets contains at least one subset of behavioral data; each behavioral feature data in each subset of behavioral data represents the various character behaviors triggered by the corresponding game character during a game in a video clip. Each iteration of training for the text prediction model includes: Using the text prediction model, based on the selected video clips and the behavioral feature datasets, the game character corresponding to the character's perspective presented in the video clip is predicted, and at least one predicted character behavior is triggered in the video clip. Based on the at least one predicted character behavior, and the behavior of each character represented by the subset of behavior data corresponding to the video segment obtained from the behavior feature dataset corresponding to the game character, the behavior recognition loss of the text prediction model is determined. Based on the behavior recognition loss and combined with the event feature datasets, the model parameters of the text prediction model are adjusted.

6. The method according to claim 4, characterized in that, Each of the event feature datasets contains at least one subset of event data; each event feature data in each subset of event data represents the various game events that the corresponding game character participates in during a game in a video clip. Each iteration of training for the text prediction model includes: Using the text prediction model, based on the selected video clips and the event feature datasets, the game character corresponding to the character's perspective presented in the video clip is predicted to participate in at least one predicted game event in the video clip. Based on the at least one predicted game event, and each game event represented by the subset of event data corresponding to the video segment obtained from the event feature dataset corresponding to the game character, the event recognition loss of the text prediction model is determined. Based on the event recognition loss and combined with the behavioral feature datasets, the model parameters of the text prediction model are adjusted.

7. The method according to claim 4, characterized in that, Each iteration of training for the intermediate prediction model includes: The intermediate prediction model is used to extract content features from the selected video segments to obtain content visual features; Using the intermediate prediction model, based on the visual features of the content, predict the game description text of the video segment; The model parameters of the intermediate prediction model are adjusted based on the textual differences between the game description text and the video clip summary text.

8. The method according to any one of claims 1 to 7, characterized in that, The step of extracting at least one behavioral feature dataset, event feature dataset, and state feature dataset corresponding to each game character from the game operation data includes: Based on preset segmentation conditions, the game video corresponding to the game operation data is segmented to obtain multiple video segments; wherein, each video segment belongs to the perspective of a game character. Select the segment execution data corresponding to each of the multiple video segments from the game execution data; For each of the multiple video segments, the following steps are performed: extracting a subset of the behavior data, a subset of the event data, and a subset of the state data of the corresponding game character from the segment execution data corresponding to the video segment; Based on the obtained subsets of behavioral data, event data, and state data, establish at least one behavioral feature dataset, event feature dataset, and state feature dataset corresponding to each game character.

9. The method according to claim 8, characterized in that, The segmentation conditions include at least one of the following: The duration of the video segment formed by the multiple video frames is within a preset range; The video clip formed by the segmentation of multiple video frames presents at least one set game event from the set game event set; The video segments formed by the split video frames present the game process as a preset game type.

10. The method according to any one of claims 1 to 7, characterized in that, After obtaining the target prediction model, the following is also included: Using the target prediction model, based on the multiple game match videos and corresponding match operation data, output the match commentary text corresponding to each of the multiple game match videos; A sample dataset is established using each game operation data as sample data and the game commentary text output based on each game operation data as the sample label of the corresponding sample data. Based on the sample dataset, the preset initial prediction model is trained through multiple rounds of iteration to obtain a trained alternative prediction model; wherein, the alternative prediction model is used to: output game commentary text based on the received target game's running data stream; the parameter size of the alternative prediction model is smaller than the parameter size of the target prediction model.

11. A method for game commentary, characterized in that, include: Receive the game video stream and corresponding runtime data stream of the target game; When a trained target prediction model is deployed, the target prediction model is used to generate game commentary text based on the game video stream and the running data stream; wherein, the target prediction model is trained based on the method described in any one of claims 1 to 10; Based on the game video stream, the game process of the target game is presented in video form, and the game commentary text is broadcast in audio form using a preset tone.

12. The method according to claim 11, characterized in that, The method further includes: When a trained alternative prediction model is deployed, the alternative prediction model is used to generate game commentary text based on the running data stream; wherein, the alternative prediction model is trained using the game running data input to the target prediction model as sample data and the game commentary text output by the target prediction model as sample labels, and the parameter size of the alternative prediction model is smaller than the parameter size of the target prediction model.

13. A training device for a text prediction model, characterized in that, include: Acquisition module: Used to acquire multiple game match videos and corresponding match execution data respectively; Processing module: For each of the game operation data, perform the following operations: extract at least one behavioral feature dataset, event feature dataset, and state feature dataset corresponding to each game character from the game operation data; wherein, each behavioral feature dataset represents a character behavior triggered by the corresponding game character; each event feature dataset represents a game event participated in by the corresponding game character; and each state feature dataset represents the character state of the corresponding game character within a time interval. The processing module is further configured to: perform multiple rounds of iterative training on the text prediction model based on the multiple game video streams, combined with the obtained behavioral feature datasets, event feature datasets and state feature datasets, to obtain a target prediction model; the target prediction model is configured to: output game commentary text based on the received game video streams.

14. A game commentary device, characterized in that, include: Transceiver module: Used to receive the game's video stream and corresponding runtime data stream; Processing module: When a trained target prediction model is deployed, it uses the target prediction model to generate game commentary text based on the game video stream and the running data stream; wherein, the target prediction model is trained based on the method described in any one of claims 1 to 10; The transceiver module is also used to: present the game process of the target game in video form based on the game video stream, and broadcast the game commentary text in audio form using a preset tone.

15. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by the processor, it implements the method as described in any one of claims 1 to 12.

16. A computer device, characterized in that, include: Memory, used to store computer programs; A processor is configured to invoke a computer program stored in the memory and execute the method as described in any one of claims 1 to 12 according to the obtained computer program.

17. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that causes a computer to perform the method as described in any one of claims 1 to 12.