Streaming media generation method and apparatus, and terminal equipment

The terminal device automates the creation of streaming media by acquiring images or videos and generating music that matches the content, addressing the complexity of composing lyrics and arranging music, thereby improving user experience and efficiency.

JP2026521602APending Publication Date: 2026-06-30BEIJING ZITIAO NETWORK TECH CO LTD

Patent Information

Authority / Receiving Office
JP · JP
Patent Type
Applications
Current Assignee / Owner
BEIJING ZITIAO NETWORK TECH CO LTD
Filing Date
2024-09-26
Publication Date
2026-06-30

AI Technical Summary

Technical Problem

The complexity of creating streaming media, particularly in composing lyrics and arranging music, is high, making it difficult for users to generate streaming media efficiently.

Method used

A method and apparatus that allows a terminal device to acquire images or videos, determine target music elements, and generate streaming media in response to user input, incorporating the acquired media with target music that matches the content, thereby reducing the need for users to compose lyrics and arrange music.

Benefits of technology

This approach simplifies the creation of streaming media by automating the process of generating music and lyrics that match the content of the images or videos, enhancing user experience and efficiency while reducing complexity.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 2026521602000001_ABST
    Figure 2026521602000001_ABST
Patent Text Reader

Abstract

This disclosure provides a streaming media generation method and apparatus, and terminal equipment, the method comprising acquiring an image or video, determining a target music element, and generating streaming media in response to user input, wherein the streaming media includes video or images and target music, the target music includes target music elements, and the target music is related to the content of the video or images.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure claims the priority of Chinese Patent Application No. 202311261968.5 filed on September 27, 2023, and hereby incorporates by reference in its entirety the content disclosed in the above Chinese patent application as part of this disclosure.

[0002] [Technical Field] Embodiments of this disclosure relate to a streaming media generation method and apparatus, and a terminal device.

Background Art

[0003] [[ID=I7]] In the field of streaming media creation, a user can create one piece of music in advance, and after creating one piece of music, can also generate one video based on the music.

[0004] Currently, when a user creates the lyrics of a song, the user can input the main part (such as structure, content, etc.) of the lyrics created in advance into the terminal device, and the terminal device can supplement the main part of the lyrics created by the user to obtain one complete set of lyrics. However, in the above method, the user also needs to perform complex lyric creation, increasing the complexity of streaming media creation.

Summary of the Invention

[0005] This disclosure provides a streaming media generation method and apparatus, and a terminal device for solving one or more technical problems.

[0006] According to a first aspect, this disclosure provides a streaming media generation method, the method comprising: [[ID=3S]]acquiring an image or a video; determining target music elements; The process includes generating streaming media in response to user input, wherein the streaming media includes the video or image and target music, the target music includes target music elements, and the target music relates to the content of the video or image.

[0007] According to a second aspect, the present disclosure provides a streaming media generation device, which is a streaming media generation device. It includes an acquisition module, a decision module, and a generation module, where, The acquisition module is used to acquire images or videos. The aforementioned decision module is used to determine the target musical element. The generation module is used to generate streaming media in response to user input, the streaming media comprising the video or image and target music, the target music comprising target music elements, and the target music relating to the content of the video or image.

[0008] According to a third aspect, an embodiment of the present disclosure provides a terminal device comprising a processor and memory, The aforementioned memory stores computer execution instructions. The processor executes computer execution instructions stored in the memory to cause at least one processor to execute the first embodiment and each of the streaming media generation methods relating to the first embodiment described above.

[0009] According to a fourth aspect, an embodiment of the present disclosure provides a computer-readable storage medium in which computer execution instructions are stored, and when a processor executes the computer execution instructions, the first aspect and each of the streaming media generation methods relating to the first aspect are realized. To more clearly explain the technical concepts in the embodiments of this disclosure, the following is a brief introduction of the drawings necessary for describing the embodiments. Obviously, the drawings in the following description are some embodiments of this disclosure, and those skilled in the art can obtain other drawings based on these without expending any creative effort. [Brief explanation of the drawing]

[0010] [Figure 1] This is a schematic diagram of an application scene according to the embodiments of this disclosure. [Figure 2] This is a flowchart of a streaming media generation method according to an embodiment of the present disclosure. [Figure 3] This is a schematic diagram of image acquisition according to an embodiment of the present disclosure. [Figure 4] This is a schematic diagram of another image acquisition method according to an embodiment of the present disclosure. [Figure 5] This is a schematic diagram of a method for generating streaming media according to an embodiment of the present disclosure. [Figure 6] This is a schematic diagram of the process for obtaining multiple sets of first lyrics according to the embodiments of this disclosure. [Figure 7] This is a schematic diagram illustrating how to determine the matching value of the first lyrics according to the embodiments of this disclosure. [Figure 8] This is a schematic diagram of the process for determining target lyrics according to the embodiments of this disclosure. [Figure 9] This is a schematic diagram of the process of a streaming media generation method according to an embodiment of the present disclosure. [Figure 10] This is a schematic diagram of the configuration of a streaming media generation device according to an embodiment of the present disclosure. [Figure 11] This is a schematic diagram of the configuration of a terminal device according to an embodiment of the present disclosure. [Modes for carrying out the invention]

[0011] Herein, exemplary embodiments are described in detail, and these examples are shown in the drawings. Where the following description relates to the drawings, unless otherwise stated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with some aspects of the present disclosure detailed in the appended claims.

[0012] To facilitate understanding, the concepts related to the embodiments of this disclosure are explained below.

[0013] Terminal devices are devices that have wireless transmission and reception capabilities. Terminal devices may be deployed on land and include indoor or outdoor devices, handheld devices, wearable devices, or in-vehicle devices. The terminal devices may include mobile phones, tablet computers, computers with wireless transmission and reception capabilities, virtual reality (VR) terminal devices, augmented reality (AR) terminal devices, wireless terminals in industrial control, in-vehicle terminal devices, wireless terminals in self-driving, wireless terminal devices in remote medical care, wireless terminal devices in smart grids, wireless terminal devices in transportation safety, wireless terminal devices in smart cities, wireless terminal devices in smart homes, wearable terminal devices, and the like. The terminal equipment relating to the embodiments of this disclosure may further be referred to as terminals, user equipment (UE), access terminal equipment, in-vehicle terminals, industrial control terminals, UE units, UE stations, mobile stations, mobile tables, remote stations, remote terminal equipment, mobile devices, UE terminal equipment, wireless communication equipment, UE agents, or UE devices. The terminal equipment may be fixed or mobile.

[0014] In related technologies, the creation of streaming media is highly difficult. For example, when creating music, it is difficult for users to create lyrics and compose music. Currently, in order to reduce the difficulty of lyric creation, users can pre-create the main content of one lyric (for example, users can pre-create the main structure of the lyric, the main sentences in the lyric, etc.). The terminal device supplements the main content of the lyric created by the user to obtain a complete lyric, and further, based on the lyric, audio or video can be generated. However, in the above method, users need to conceive the structure and main content of the lyric, and the complexity of lyric creation is still high, and further, the complexity of creating streaming media is increased.

[0015] To solve the above technical problems, the present disclosure provides a method for generating streaming media. The terminal device can display a shooting page and obtain an image in response to a touch operation on the shooting control on the shooting page. The terminal device determines target music elements, and in response to the user's operation, generates a target lyric based on the image and the target music elements, performs a text-to-speech conversion process on the target lyric to obtain a target voice, adds background music to the target voice to obtain target music, and the terminal device can perform a synthesis process on the target music and the image to obtain a synthesized video. Here, the video includes the image and the target music. In this way, the terminal device can generate a video related to the image based on one image captured by the user. The video further includes music related to the image content, improving the diversity of interaction, improving the user experience, and the lyrics of the music in the video are created based on the content of the image, with high accuracy of the lyrics, without requiring users to create lyrics and compose music, reducing the complexity of music creation, and further reducing the complexity of video creation.

[0016] Hereinafter, the application scenario of the embodiments of the present disclosure will be described with reference to FIG. 1.

[0017] FIG. 1 is a schematic diagram of an application scenario according to an embodiment of the present disclosure. Referring to FIG. 1, it includes a terminal device. Here, the display page of the terminal device is a music creation page, and the music creation page may include controls for rap style, folk style, pop style, and creation controls. After the terminal device acquires an image, the user can click on the rap style control (the rap style control is highlighted) and then click on the creation control. The terminal device can obtain keywords describing the content of the image and create a set of lyrics based on the keywords. The terminal device can match background music to the set of lyrics and further obtain rap music related to the content of the image. In this way, the terminal device can generate rap music related to the content of the image based on a single image, reducing the complexity of music creation and improving the user experience.

[0018] Note that FIG. 1 only exemplarily shows the application scenario of the embodiment of the present disclosure. The application scenario of the embodiment of the present disclosure may further include video creation, etc., and the embodiment of the present disclosure does not limit this.

[0019] This disclosure provides a streaming media generation method and apparatus and a terminal device, the terminal device being able to acquire an image or video, determine a target music element, and generate streaming media in response to user input, wherein the streaming media includes a video or image and target music, the target music includes a target music element, and the target music is related to the content of the video or image. In the above method, the terminal device can generate music that matches the image or video content based on the image or video input by the user, and the terminal device can further generate streaming media including the image or video and target music, so that the user does not need to compose complex lyrics and arrange music, reducing the complexity of music creation, reducing the complexity of streaming media generation, improving the efficiency of streaming media generation, improving the diversity of interactions, and enhancing the user experience.

[0020] The technical proposal of this disclosure and how it solves the above technical problems will be described in detail below with reference to specific embodiments. Some of these specific embodiments can be combined with one another, and some embodiments may omit explanation of the same or similar concepts or processes. The embodiments of this disclosure will be described below with reference to the drawings.

[0021] Figure 2 is a flowchart of a streaming media generation method according to an embodiment of the present disclosure. Referring to Figure 2, the method may include the following:

[0022] S201, retrieve image or video.

[0023] The implementer of the embodiments of this disclosure may be a terminal device, or a streaming media generation device installed on a terminal device. Here, the streaming media generation device can be implemented based on software, and the streaming media creation device can be implemented based on a combination of software and hardware, and the embodiments of this disclosure are not limited thereto.

[0024] Here, the image may be an image used for generating streaming media. For example, a user can create streaming media based on any single image, or a user can take a single image and create streaming media based on that image, and the embodiments of this disclosure are not limited thereto.

[0025] In the embodiments of this disclosure, the terminal device may generate streaming media based on a single image, or it may generate streaming media based on multiple images, and the embodiments of this disclosure are not limited to this.

[0026] Here, the video may be a video for generating streaming media. For example, a user may generate streaming media based on any one video on a terminal device, or a user may generate streaming media based on a single video they have taken, and the embodiments of this disclosure are not limited thereto.

[0027] The streaming media generated by the terminal device based on images or videos may be music or videos containing music, and the embodiments of this disclosure are not limited thereto.

[0028] The terminal device can optionally acquire an image based on a feasible implementation that displays a shooting page and obtains the image in response to a touch operation on the shooting control on the shooting page.

[0029] Here, the shooting page may include a shooting control. For example, if the user clicks the shooting control on the shooting page, the terminal device can obtain an image based on the imaging device. For example, the streaming media generation page may include a control to display the shooting page, and if the user clicks the control, the terminal device can display the shooting page.

[0030] The following explains the image acquisition process using terminal devices, referring to Figure 3.

[0031] Figure 3 is a schematic diagram of image acquisition according to an embodiment of the present disclosure. Referring to Figure 3, a terminal device is included. Here, the display page of the terminal device is the shooting page. The shooting page includes a shooting control and a target waiting to be photographed. When the user clicks the shooting control on the shooting page, the terminal device can take a photograph of the target waiting to be photographed and obtain an image, which may include the target waiting to be photographed. In this way, the terminal device can generate streaming media based on images collected in real time, improving the flexibility of streaming media generation.

[0032] The terminal device can optionally acquire an image based on a feasible implementation that displays an image page and obtains the image in response to a touch operation on the image page to be selected.

[0033] Here, the image page may contain at least one image to be selected. For example, the image to be selected may be an image previously taken by the terminal device, or an image received by the terminal device from another device, and the embodiments of this disclosure are not limited thereto. For example, the image page may be an album page, and when a user clicks an image acquisition control on a streaming media generation page, the terminal device can jump to the image page.

[0034] Optionally, a streaming media generation page may include an image upload control, and if the user clicks the image upload control, the device can display the image page. For example, a video generation page may include an "Image Upload" control, and if the user clicks the "Image Upload" control, the device can jump to an album page.

[0035] For example, an image page may contain Image 1, Image 2, and Image 3. If the user clicks Image 1, the image acquired by the device is Image 1. If the user clicks Image 2, the image acquired by the device is Image 2. If the user clicks Image 3, the image acquired by the device is Image 3.

[0036] The image acquisition process will be explained below, referencing Figure 4.

[0037] Figure 4 is a schematic diagram of another image acquisition according to an embodiment of the present disclosure. Referring to Figure 4, a terminal device is included. Here, the display page of the terminal device includes page 401 and page 402. Page 401 is a music creation page, and may include an image capture control and an image upload control. When the user clicks the image upload control, the display page of the terminal device jumps from page 401 to page 402. Page 402 may be an image storage page, and may include image 1, image 2, image 3, and image 4. When the user clicks image 2, the terminal device can determine image 2 as the first image. In this way, the terminal device can create music based on previously acquired images, improving the flexibility of music creation and improving the quality of the created music by allowing the user to screen images.

[0038] The terminal device can optionally acquire an image based on a feasible implementation that involves acquiring video, extracting video frame images from the video, and obtaining an image.

[0039] Here, the terminal device can acquire video in response to user touch operations. For example, the terminal device can display a video page, which may include Video 1 and Video 2 to select. If the user clicks Video 1, the video acquired by the terminal device is Video 1. If the user clicks both Video 1 and Video 2, the video acquired by the terminal device is Video 1 and Video 2. For example, the terminal device can display a shooting page, and if the user clicks the video recording control on the shooting page, the terminal device can record one video and acquire additional videos.

[0040] Furthermore, terminal devices can acquire video based on any executable implementation (for example, by receiving video transmitted by other devices), and the embodiments of this disclosure are not limited thereto.

[0041] The terminal device can optionally extract any one video frame image from the video and obtain an image. For example, the video may include video frame image 1, video frame image 2, and video frame image 3, and the terminal device may decide that video frame image 1 is the image to be obtained, or the terminal device may decide that video frame image 2 is the image to be obtained, and the embodiments of this disclosure are not limited thereto.

[0042] Optionally, the terminal device can identify video content, obtain keyframes in the video, and determine the keyframes as images to be acquired. For example, the terminal device can identify an object contained in the video, and if the object is included in video frame image 1, the terminal device can determine that video frame image 1 is a keyframe and acquire an image. Similarly, if the object is included in video frame image 2, the terminal device can determine that video frame image 2 is a keyframe and acquire an image. In this way, the terminal device can accurately acquire rich images based on the acquired video, further improving the accuracy and effectiveness of the generated streaming media and enhancing the user experience.

[0043] Furthermore, terminal devices can determine keyframes in video based on any executable implementation, and the embodiments of this disclosure are not limited thereto.

[0044] S202 determines the target musical elements.

[0045] The target musical element may optionally be a musical style. For example, the target musical element may be a rap style, a folk style, a classical style, or a pop style, and the embodiments of this disclosure are not limited thereto.

[0046] Optionally, the music style may be the style of the music awaiting generation. For example, since streaming media may contain music, if the target music element is in the style of rap music, the streaming media generated by the terminal device may contain rap-style music, and if the target music element is in the style of pop music, the streaming media generated by the terminal device may contain pop-style music.

[0047] Furthermore, the terminal device can determine the target music element based on user operation (in the embodiment shown in Figure 1, the user clicks a rap style control, and the terminal device determines that the target music element is a rap music style), and the terminal device can also acquire the target music element based on any feasible implementation (for example, another device can send a rap music style identifier to the terminal device, and the terminal device can determine that the target music element is a rap music style), and the embodiments of this disclosure are not limited thereto.

[0048] S203 generates streaming media in response to user input.

[0049] Optionally, the streaming media may include video or images and target music. For example, the streaming media may include video and target music, or the streaming media may include images and target music, and the embodiments of this disclosure are not limited thereto.

[0050] Optionally, target music may include target music elements. For example, if the target music element is the style of rap music, the target music on streaming media may be rap music; if the target music element is the style of pop music, the target music on streaming media may be pop music.

[0051] Optionally, the target music may relate to the content of a video or image. For example, if the image includes a kitten, the lyrics of the target music may relate to the kitten; if the image is a rainy sky, the lyrics of the target music may be the same as a rainy sky; similarly, the lyrics of the target music may relate to the content of a video, and the embodiments of this disclosure are not limited thereto.

[0052] Embodiments of this disclosure provide a streaming media generation method that includes displaying a shooting page, obtaining an image in response to a touch operation on the shooting control on the shooting page, determining a target music element, and generating streaming media in response to user operation, wherein the streaming media may include video or images and target music, the target music may include target music elements, and the target music is related to the content of the video or images. In this way, a terminal device can generate streaming media based on images or videos input by the user, the streaming media may include music related to the image or video content, and the streaming media may further include images or videos, thereby improving the diversity of interactions and enhancing the user experience, and the terminal device can automatically generate music or videos containing music based on images or videos, further reducing the complexity of streaming media generation and improving the efficiency of streaming media generation.

[0053] The method for generating streaming media in the above-described streaming media generation method will be explained below, referencing the embodiment shown in Figure 2 and Figure 5.

[0054] Figure 5 is a schematic diagram of a method for generating streaming media according to an embodiment of the present disclosure. Referring to Figure 5, the flow of the method includes the following:

[0055] S501 generates target lyrics based on an image or video and target music elements.

[0056] Here, the target lyrics may be lyrics that match the target musical elements. For example, if the target musical elements are in the style of rap music, the target lyrics may be rap lyrics, and if the target musical elements are in the style of pop music, the target lyrics may be pop lyrics.

[0057] Here, the terminal device can perform identification processing on image or video content, obtain multiple keywords related to the content, generate multiple sets of first lyrics based on a language model, target music elements, and multiple keywords, and then generate target lyrics based on a feasible implementation that identifies the target lyrics from the multiple sets of first lyrics.

[0058] Optionally, keywords can be used to describe the content of an image. For example, keywords may include subjects, scenes, and people. For instance, a keyword might be "a kitten sitting next to a puppy," or it could be "kitten," "puppy," and "butterfly."

[0059] Optionally, a terminal device may perform identification processing on the content of an image or video to obtain multiple keywords related to the content. Specifically, this may involve performing convolutional processing on the image or video to obtain image features or video features, and then determining multiple keywords based on the image features or video features. For example, a terminal device may perform convolutional processing on an image based on a pre-trained image recognition model to obtain image features related to the image, and then determine multiple keywords related to the content of the image based on these image features. Here, the image recognition model is a model obtained by training on multiple sets of samples, where each set of samples may include a sample image and at least one keyword corresponding to the sample image.

[0060] Furthermore, the terminal device may determine multiple keywords based on any other feasible implementation (for example, based on the DLSapce platform, which is an all-in-one, full-stack AI development platform, and the terminal device can upload an image to an image host, generate an accessible HTTP link, send the link to the DLSapce platform, and further obtain keywords related to the image), and the embodiments of this disclosure are not limited thereto.

[0061] Here, the first lyrics may be candidate lyrics. For example, a terminal device can obtain multiple sets of candidate first lyrics, and further identify a target lyric from multiple sets of candidate first lyrics, where each set of candidate first lyrics may be related to image or video content.

[0062] Optionally, the terminal device can input target music elements and multiple keywords into a language model and obtain multiple sets of first lyrics. In this way, the terminal device can accurately obtain the lyrics that best match the image or video content based on the multiple sets of first lyrics, thereby improving the quality of streaming media.

[0063] The language model in the embodiments of this disclosure may be any single large-scale language model, and the embodiments of this disclosure are not limited thereto.

[0064] Furthermore, the terminal device may also obtain multiple sets of first lyrics based on any other feasible implementation, and the embodiments of this disclosure are not limited thereto.

[0065] The process of obtaining multiple sets of the first lyrics will be explained below, referencing Figure 6.

[0066] Figure 6 is a schematic diagram of the process for obtaining multiple sets of first lyrics according to an embodiment of the present disclosure. Referring to Figure 6, a large language model is included. A terminal device (not shown in Figure 6) can input a rap style and multiple keywords into the large language model, which can generate a first set of lyrics, a second set of lyrics, ..., a tenth set of lyrics based on the rap style and multiple keywords. Here, the style of each set of lyrics is a rap style, and each set of lyrics is the lyrics of a single song.

[0067] Here, the terminal device identifying target lyrics from multiple sets of first lyrics may specifically involve determining the matching value between each set of first lyrics and the target musical element, and then selecting the set of first lyrics with the highest matching value as the target lyrics. In this way, the matching value can accurately reflect the degree of matching between the lyrics and the target musical element, resulting in higher quality lyrics for the target lyrics determined by the terminal device, and further improving the quality of the generated streaming media.

[0068] Optionally, the matching value can be used to indicate the degree of matching between the first lyrics and the target musical element. For example, the target musical element may be the style of rap music, and a higher matching value for the first lyrics indicates a higher degree of similarity between the first lyrics and the lyrics of the rap music, while a lower matching value indicates a lower degree of similarity between the first lyrics and the lyrics of the rap music.

[0069] If the target musical element is optionally a rap style, the terminal device can determine the matching value for each set of first lyrics based on a feasible implementation in which it determines the number of sentences and the number of rhymes in any one set of first lyrics, and determines the ratio of the number of rhymes to the number of sentences as the degree of matching for the first lyrics.

[0070] Here, the number of sentences may be the total number of sentences included in the first set of lyrics. For example, if the first set of lyrics contains 10 sentences, the number of sentences is 10, and if the first set of lyrics contains 20 sentences, the number of sentences is 20.

[0071] Optionally, the terminal device can determine the number of sentences in the first set of lyrics based on the number of punctuation marks in the first set of lyrics. For example, the terminal device can determine the number of sentences in the first set of lyrics based on the number of commas and periods in the first set of lyrics. For example, if the first set of lyrics contains two commas and one period, the terminal device can determine that the number of sentences in the first set of lyrics is three.

[0072] Furthermore, the terminal device may also determine the number of sentences in a set of first lyrics based on any other feasible implementation, and the embodiments of this disclosure are not limited thereto.

[0073] Here, the rhyme count may be the number of sentences in which the last word is a rhyme. For example, if the last word of 10 sentences in the first lyric of the set is a rhyme, the terminal device can determine that the rhyme count for the first lyric of the set is 10, and if the last word of 20 sentences in the first lyric of the set is a rhyme, the terminal device can determine that the rhyme count for the first lyric of the set is 20.

[0074] Optionally, the terminal device can detect the pinyin of the last word of each sentence based on a pre-configured rhyme table and obtain the rhyme count. For example, if the pinyin of the last word of a sentence contains a word from the rhyme table, the terminal device can determine that the sentence rhymes; if the pinyin of the last word of a sentence does not contain a word from the rhyme table, the terminal device can determine that the sentence does not rhyme.

[0075] Furthermore, the terminal device can determine the number of rhymes in a set of first lyrics based on any executable implementation, and the embodiments of this disclosure are not limited thereto.

[0076] Optionally, the matching value may be the ratio of the number of rhymes to the number of sentences. In this way, high-quality lyrics can be obtained based on the matching value (i.e., the lyrics have a high degree of matching with the style of the rap music, and the lyrical phrases are rich), and the quality of the streaming media can be further improved. For example, if the first set of lyrics has 10 rhymes and 20 sentences, the terminal device can determine that the matching value corresponding to the first set of lyrics is 0.5. If the first set of lyrics has 40 rhymes and 50 sentences, the terminal device can determine that the matching value corresponding to the first set of lyrics is 0.8.

[0077] Furthermore, before the terminal device determines the matching value of the first lyrics for each set, the terminal device can also detect the number of words in the first lyrics for each set. If the number of words is less than a first threshold, the terminal device can determine that the matching value of the lyrics for that set is 0. If the number of words is greater than a second threshold, the terminal device can determine that the matching value of the lyrics for that set is 0.1, where the second threshold is greater than the first threshold. For example, if the first threshold is 50 and the second threshold is 100, and the number of words in a pair of first lyrics is 40, it indicates that the lyrics are short, and the terminal device determines that the matching value for the lyrics is 0 (there is no need to calculate the matching value based on the number of rhymes and sentences). If the number of words in a pair of first lyrics is 120, it indicates that the lyrics are long, and the terminal device determines that the matching value for the lyrics is 0.1 (there is no need to calculate the matching value based on the number of rhymes and sentences). In this way, the efficiency of determining target lyrics can be improved, and the efficiency of generating streaming media can be improved.

[0078] The following explains the process of determining the matching value corresponding to a first set of lyrics, referring to Figure 7.

[0079] Figure 7 is a schematic diagram illustrating how the matching value of the first lyrics is determined according to an embodiment of the present disclosure. Referring to Figure 7, the first lyrics include sentence 1, sentence 2, ..., sentence 20. A terminal device (not shown in Figure 7) can obtain the pinyin of the last word of each sentence, match the pinyin of the last word of each sentence against a rhyme table, and further determine that 15 sentences rhyme. Based on the 15 rhymes and 20 sentences, the terminal device can determine that the matching value of the first lyrics is 0.75.

[0080] The terminal device can optionally determine the first set of lyrics with the highest matching value as the target lyrics. For example, if the matching value of the first set of lyrics 1 generated by the terminal device is 0.1, the matching value of the first set of lyrics 2 is 0.6, and the matching value of the first set of lyrics 3 is 0.9, the terminal device can determine the first set of lyrics 3 as the target lyrics.

[0081] Optionally, the terminal device may screen the first lyrics before determining the first set of lyrics with the highest matching value as the target lyrics. If, among the multiple sets of first lyrics, no first lyrics have a matching value equal to or greater than a preset threshold, the terminal device obtains multiple sets of second lyrics based on a language model, a rap music style identifier, multiple keywords, and multiple rhyming preset phrases. It then determines the matching value between each set of second lyrics and the rap music style, and selects the multiple sets of second lyrics whose matching value is equal to or greater than a preset threshold as the multiple sets of first lyrics.

[0082] Optionally, the pre-set phrases may be rhyming phrases. For example, if the target musical element is a rap music style, the pre-set phrases may be rhyming phrases. For example, the pre-set phrases may include phrases that rhyme with the vowel ai, such as "come together," "colorful," "really magnificent," "genuinely fun," and "colorful."

[0083] Furthermore, if the target musical element is a rap music style, the pre-set phrase may be a phrase that rhymes with other rhymes, and the embodiments of this disclosure are not limited thereto.

[0084] If, optionally, no first lyric in any of the multiple sets of first lyric has a matching value equal to or greater than a preset threshold, it indicates that the lyric quality of the multiple sets of first lyric is poor, and the terminal device can regenerate new lyric based on the language model. For example, if the language model generates first lyrics 1, first lyrics 2, and first lyrics 3 based on a rap music style identifier and multiple keywords, where the matching value for first lyrics 1 is 0, the matching value for first lyrics 2 is 0.2, and the matching value for first lyrics 3 is 0.3, and the preset threshold is 0.6, the terminal device will determine that the quality of the current three sets of first lyrics is poor and that the degree of matching with the rap music style is low. The terminal device can then re-input the rap music style identifier, multiple keywords, and multiple rhyming preset phrases into the language model, and the language model can output multiple sets of second lyrics (new lyrics). The terminal device can then determine that the lyrics in the second lyrics whose matching value is equal to or greater than the preset threshold will be the new first lyrics. In this way, the quality of the target lyrics can be improved, and the quality of the generated streaming media can be further improved.

[0085] The method for determining the matching value corresponding to the second set of lyrics by the terminal device is the same as the method for determining the matching value corresponding to the first set of lyrics by the terminal device, and this is omitted from the explanation in the embodiments of this disclosure.

[0086] The process of determining the target lyrics will be explained below, referencing Figure 8.

[0087] Figure 8 is a schematic diagram of the process for determining target lyrics according to an embodiment of the present disclosure. Referring to Figure 8, a language model is included. Here, a terminal device (not shown in Figure 8) can input a rap style identifier and several keywords into the language model, and the language model can output a set of lyrics, where the set of lyrics includes lyrics 1, lyrics 2, and lyrics 3, with a matching value of 0 for lyrics 1, a matching value of 0.1 for lyrics 2, and a matching value of 0.2 for lyrics 3.

[0088] Referring to Figure 8, if the preset threshold is 0.6, the terminal device re-inputs the rap style identifier, multiple keywords, and multiple rhyming preset phrases into the language model, and the language model can output lyrics 4, lyrics 5, and lyrics 6. Here, the matching value for lyrics 4 is 0.5, the matching value for lyrics 5 is 0.7, and the matching value for lyrics 6 is 0.9. The terminal device determines that the lyrics set contains lyrics 5 and lyrics 6 (both with matching values ​​greater than 0.6), and since the matching value for lyrics 6 is the largest, the terminal device can determine lyrics 6 as the target lyrics.

[0089] In this way, the terminal device can determine the target lyrics that best match the style of rap music based on matching values ​​corresponding to each set of lyrics. If the quality of the lyrics obtained by the language model based on multiple keywords is poor, the terminal device can add multiple keywords and multiple pre-set phrases that match the rap music style to the language model. In this way, the quality of the target lyrics can be guaranteed, and the quality of the streaming media can be improved.

[0090] S502 performs a text-to-speech conversion process on the target lyrics to obtain the target audio, adds background music to the target audio, and obtains the target music.

[0091] Here, the target audio may be an audio that matches the target lyrics. Optionally, the terminal device can obtain the target audio by performing a text-to-speech (TTS) conversion process on the target lyrics based on a text-to-speech (TTS) algorithm, and then obtaining a target audio that matches the target lyrics, thereby achieving a feasible implementation.

[0092] Here, TTS technology is a technology that can convert text into audible speech output. For example, TTS technology can convert text information such as the characters in written documents, electronic documents, and web page content into speech information, thus allowing users to acquire information based on auditory methods.

[0093] For example, a terminal device can process target lyrics based on a TTS module, which can convert target lyrics into target speech, where the TTS module generates target speech that matches the rhymes, rhymes, and rhythm of the target lyrics. For example, if the target lyrics are in 4 / 4 time, the rhythm of the target speech will also be in 4 / 4 time; if the rhyme scheme of the target lyrics is simple rhymes, the rhyme scheme of the target speech will also be simple rhymes; if the rhyme scheme of the target lyrics is ai, then the speech ai in the target speech will also be ai rhymes.

[0094] Optionally, the terminal device can also process the target audio after acquiring it, based on the style of rap music. For example, the terminal device can adjust the pitch, speaking speed, and rhythm of the target audio to match the style of rap music.

[0095] Furthermore, the terminal device can convert target lyrics into target audio based on any feasible implementation, and the embodiments of this disclosure are not limited thereto.

[0096] Optionally, a terminal device can add background music to a target speech and generate music in the style of the target speech, based on a feasible implementation in which the terminal device can acquire the rhyme scheme and rhythm of the target speech and acquire background music that matches the rhyme scheme and rhythm of the target speech based on the TTS module. For example, the TTS module can acquire background music that matches the rhyme scheme and rhythm of the target speech from a background music library. For example, the background music library may contain multiple pairs of correspondences, where the correspondence may be that background music 1 corresponds to 4 / 4 time, simple rhyme, and the rhyme foot a, and background music 2 corresponds to 4 / 4 time, double rhyme, and the rhyme foot a.

[0097] Optionally, the terminal device can perform synthesis processing on the target audio and background music to obtain the target music. For example, if the target music element is in the style of rap music, the terminal device can generate a target audio that matches the style of rap music, and can add background music in the style of rap music to that audio to obtain rap-style music.

[0098] S503 performs a synthesis process on the target music and images or video to obtain streaming media.

[0099] Optionally, the terminal device may add background music to the target audio, generate music in the style of the target music, and then perform a synthesis process on the target music and an image or video to obtain streaming media. For example, the terminal device may synthesize the target music and an image to obtain a video, the background image of the video may be an image acquired by the terminal device, and the background music of the video may be the target music.

[0100] Optionally, when a terminal device synthesizes a video, it may also add subtitles related to the lyrics of the target music to the video. Specifically, it may perform audio frame extraction processing in music of the target music style, perform speech recognition processing on the extracted audio frames, convert the audio frames into text, and the terminal device may segment the music based on the timestamps of the text. Based on the associated text and timestamp information, it may generate subtitles (sticker data) corresponding to the text. In this way, during the video playback process, the subtitles may be indicated based on the timestamp indications, and it may be confirmed that the subtitles are synchronized with the current playback progress. Thus, the video generated by the terminal device may not only include target music in the rap music style, but may also include subtitles of the lyrics of the target music, further improving the display effect of the video.

[0101] Optionally, the terminal device can perform frame extraction based on a preset time interval, thereby obtaining key segments in the music. For example, the terminal device can extract one keyframe every 30 milliseconds, and furthermore, obtain multiple keyframes corresponding to the music.

[0102] Optionally, the terminal device can segment the music based on the timestamps of the text, obtain a correspondence between the text and the timestamps, and associate different parts of the music with the corresponding text. In this way, it can ensure matching of subtitles and playback progress and improve the display effect of the video.

[0103] Embodiments of this disclosure provide a method for generating streaming media, in which a terminal device performs identification processing on image or video content, obtains multiple keywords related to the content, generates multiple sets of first lyrics based on a language model, target music elements and the multiple keywords, identifies target lyrics from the multiple sets of first lyrics, performs text-to-speech conversion processing on the target lyrics to obtain target audio, adds background music to the target audio to obtain target music, performs synthesis processing on the target music and image or video to obtain streaming media. In this way, the terminal device can generate streaming media based on images or videos input by the user, reducing the complexity of streaming media generation, and can generate multiple sets of lyrics related to image or video content based on a large-scale language model, identify target lyrics with the highest degree of matching to the style of rap music from the multiple sets of lyrics, improve the quality and accuracy of the target lyrics, and further improve the quality and accuracy of the streaming media.

[0104] The process of the above-described streaming media generation method will now be explained, referencing Figure 9, based on any one of the above-described embodiments.

[0105] Figure 9 is a schematic diagram of the process of a streaming media generation method according to an embodiment of the present disclosure. Referring to Figure 9, the process includes an image, an image recognition module, a large-scale language model, a text-to-speech conversion module, and a subtitle generation module. Here, a terminal device (not shown in Figure 9) can input a first image into the image recognition module, and the image recognition module can output multiple keywords describing the image content of the first image. The terminal device can input multiple keywords and wrap style identifiers into the large-scale language model.

[0106] Referring to Figure 9, the large-scale language model can output lyrics 1, lyrics 2, and lyrics 3. The terminal device can determine that the matching value for lyrics 1 is 05, the matching value for lyrics 2 is 0.7, and the matching value for lyrics 3 is 0.9. Since the matching value for lyrics 3 is the largest, the terminal device can determine that lyrics 3 is the target lyrics.

[0107] Referring to Figure 9, the terminal device can input lyrics 3 into a text-to-speech conversion module, which converts lyrics 3 into speech and further obtains rap-style music. The terminal device can input rap-style music into a subtitle generation module, which determines text subtitles corresponding to each audio frame and can synthesize the first image, rap-style music, and subtitles into a video, where the audio content of the video is rap-style music, and the video may include images and subtitles.

[0108] Thus, the device can generate music based on images and related to the image content, eliminating the need for the user to write lyrics and arrange the music, further improving the efficiency of music creation. Moreover, because the device can generate lyrics that match rap music styles based on a large-scale language model, it can reduce the complexity of music creation and improve the user experience.

[0109] Figure 10 is a schematic diagram of the configuration of a streaming media generation device according to an embodiment of the present disclosure. Referring to Figure 10, the streaming media generation device 100 includes an acquisition module 101, a determination module 102, and a generation module 103, where, The acquisition module 101 is used to acquire images or videos. The aforementioned decision module 102 is used to determine the target musical element. The generation module 103 is used to generate streaming media in response to user input, the streaming media comprising the video or image and target music, the target music comprising target music elements, and the target music relating to the content of the video or image.

[0110] According to one or more embodiments of this disclosure, the acquisition module 101 specifically, Display the shooting page, This is used to obtain the image in response to a touch operation on the shooting control on the aforementioned shooting page.

[0111] According to one or more embodiments of this disclosure, the acquisition module 101 specifically, Display the image page, This is used to obtain the image in response to a touch operation on the image page to be selected.

[0112] According to one or more embodiments of this disclosure, the acquisition module 101 specifically, The aforementioned video was obtained, This is used to extract video frame images from the aforementioned video and obtain the aforementioned images.

[0113] According to one or more embodiments of the present disclosure, the target musical element is a musical style.

[0114] According to one or more embodiments of this disclosure, the generation module 103 specifically, Based on the aforementioned image or video and target music elements, target lyrics are generated. The target lyrics are converted from text to audio to obtain the target audio, background music is added to the target audio to obtain the target music, This process is used to perform a synthesis operation on the target music and the image or video to obtain the streaming media.

[0115] According to one or more embodiments of this disclosure, the generation module 103 specifically, The content of the aforementioned image or video is subjected to identification processing to obtain multiple keywords related to the content, Based on the language model, the target musical elements, and the multiple keywords, multiple sets of first lyrics are generated. This is used to identify the target lyrics from the aforementioned multiple sets of first lyrics.

[0116] According to one or more embodiments of this disclosure, the generation module 103 specifically, Determine the matching value between the first lyrics of each group and the target musical element. The first set of lyrics with the highest matching value is used to determine the target lyrics.

[0117] According to one or more embodiments of this disclosure, the generation module 103 specifically, For any one set of first lyrics, determine the number of sentences in the first lyrics and the number of rhymes in the first lyrics. The ratio of the number of rhymes to the number of sentences is used to determine the matching value of the first lyrics.

[0118] According to one or more embodiments of this disclosure, the generation module 103 further: If, among the multiple sets of first lyrics, there is no first lyric whose matching value is equal to or greater than a preset threshold, then, based on the language model, the rap music style identifier, the multiple keywords, and the multiple rhyming preset phrases, multiple sets of second lyrics are obtained. This is used to determine the matching value between the second lyrics of each group and the rap music style, and to select the second lyrics of multiple groups whose matching value is above a predetermined threshold as the first lyrics of those groups.

[0119] The streaming media generation device according to this embodiment may also be used to implement the technical proposal of the embodiment of the above method, and since its implementation principle and technical effects are similar, this embodiment will not be described further here.

[0120] Figure 11 is a schematic diagram of the configuration of a terminal device according to an embodiment of the present disclosure. Referring to Figure 11, it shows a schematic diagram of the configuration of a terminal device 1100 suitable for realizing an embodiment of the present disclosure. Here, the terminal device may include, but is not limited to, mobile devices such as mobile phones, laptop computers, digital broadcast receivers, personal digital assistants (abbreviated as PDAs), tablet computers (abbreviated as Portable Android Devices, PADs), portable multimedia players (abbreviated as PMPs), and in-vehicle terminals (e.g., in-vehicle navigation terminals), as well as fixed terminals such as digital TVs and desktop computers. The terminal device shown in Figure 11 is merely an example and does not imply any limitation on the functions and scope of use of the embodiment of the present disclosure.

[0121] As shown in Figure 11, the terminal device 1100 may include a processing unit (e.g., a central processor, graphics processor, etc.) 1101, which can perform various appropriate operations and processes based on programs stored in read-only memory (ROM) 1102 or programs loaded from storage device 1108 into random access memory (RAM) 1103. The RAM 1103 further stores various programs and data necessary for the operation of the terminal device 1100. The processing unit 1101, ROM 1102, and RAM 1103 are connected to each other via bus 1104. An input / output (I / O) interface 1105 is also connected to bus 1104.

[0122] Generally, devices such as input devices 1106 including, for example, touchscreens, touchpads, keyboards, mice, cameras, microphones, accelerometers, and gyroscopes; output devices 1107 including, for example, liquid crystal displays (LCDs), speakers, and vibrators; storage devices 1108 including, for example, magnetic tapes and hard disks; and communication devices 1109 can be connected to the I / O interface 1105. The communication device 1109 can allow terminal equipment 1100 and other devices to exchange data via wireless or wired communication. Figure 11 shows terminal equipment 1100 with various devices, but it should be understood that it is not required to implement or have all of the devices shown. More or fewer devices may be implemented or have all of the devices instead.

[0123] In particular, according to embodiments of the present disclosure, the process described above with reference to the flowchart may be implemented as a computer software program. For example, embodiments of the present disclosure include a computer program product which includes a computer program on a computer-readable medium which includes program code for performing the method shown in the flowchart. In such embodiments, the computer program may be downloaded and installed from a network via a communication device 1109, or installed from a storage device 1108, or installed from a ROM 1102. When the computer program is executed by the processing unit 1101, the above-described functions, limited by the methods of embodiments of the present disclosure, are performed.

[0124] The computer-readable medium in this disclosure may be a computer-readable signal medium, a computer-readable storage medium, or any combination of both. The computer-readable storage medium may be, but is not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of computer-readable storage mediums may include, but are not limited to, an electrical connection having one or more wires, a portable computer magnetic disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact magnetic disk read-only memory (CD-ROM), an optical memory device, a magnetic memory device, or any suitable combination thereof. In this disclosure, the computer-readable storage medium may be any tangible medium containing or storing a program, the program may be used by or in combination with an instruction execution system, apparatus, or device. In this disclosure, a computer-readable signaling medium may include data signals propagated in the baseband or as part of a carrier, which carry computer-readable program code. The data signals propagated in this manner may include, but are not limited to, electromagnetic signals, optical signals, or any suitable combination thereof. The computer-readable signaling medium may be any computer-readable medium other than a computer-readable storage medium, which can transmit, propagate, or transmit programs for use by or in combination with instruction execution systems, apparatus, or devices. The program code contained in the computer-readable medium may be transmitted by any suitable medium, including, but not limited to, electric wires, optical cables, RF (radio frequency), or any suitable combination thereof.

[0125] The computer-readable medium described above may be included in the terminal device, or it may be a standalone entity not incorporated into the terminal device.

[0126] The computer-readable medium contains one or more programs, and when these one or more programs are executed by the terminal device, the terminal device is instructed to execute the method shown in the above embodiment.

[0127] Embodiments of this disclosure provide a computer-readable storage medium in which computer execution instructions are stored, and when a processor executes the computer execution instructions, various possible methods relating to the above embodiments are realized.

[0128] The embodiments of this disclosure provide a computer program product including a computer program, which, when executed by a processor, realizes various possible methods relating to the embodiments described above.

[0129] Computer program code for performing the operations of the Disclosure can be organized in one or a variety of programming languages ​​or a combination thereof, and such programming languages ​​include object-oriented programming languages, such as Java, Smalltalk, and C++, and further include general procedural programming languages, such as the "C" language or similar programming languages. The program code may run entirely on a user computer, partially on a user computer, run as a single standalone software package, run partially on a user computer and partially on a remote computer, or run entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user computer via any type of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or it may be connected to an external computer (for example, connected via the Internet using an Internet service provider).

[0130] The flowcharts and block diagrams in the drawings illustrate system architectures, functions, and operations that can be implemented according to the systems, methods, and computer program products of each embodiment of the present disclosure. In this regard, each block in the flowchart or block diagram may represent a module, program segment, or portion of code, which contains one or more executable instructions for implementing a defined logic function. Note that in some implementations as alternatives, the functions described in the blocks may occur in a different order than those shown in the drawings. For example, two blocks shown consecutively may actually be executed almost in parallel, or in some cases in reverse order, depending on the function. Note that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, may be implemented by a dedicated hardware-based system that performs the defined function or operation, or by a combination of dedicated hardware and computer instructions.

[0131] The units referred to in the descriptions of the embodiments of this disclosure may be implemented in software or in hardware. Herein, the names of the units are not limited in any case to the units themselves; for example, the first acquisition unit may be described as "a unit that acquires at least two Internet Protocol addresses."

[0132] The functions described above in this specification may be performed, at least in part, by one or more hardware logic components. For example, typical types of hardware logic components that can be used include, but are not limited to, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems on chips (SOCs), and composite programmable logic devices (CPLDs).

[0133] In the context of this disclosure, a machine-readable medium may be a tangible medium that contains or stores a program for use by or in combination with an instruction execution system, apparatus, or device. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any appropriate combination of the above. More specific examples of machine-readable storage media include one or more wire-based electrical connections, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any appropriate combination of the above.

[0134] The modifiers “one” and “multiple” as used in this disclosure are not restrictive but schematic. Those skilled in the art should understand that, unless otherwise explicitly stated in the context, they should be understood as “one or more.”

[0135] The names of messages or information exchanged between multiple devices in embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of such messages or information.

[0136] Before using any of the technical proposals disclosed in each embodiment of this disclosure, it is understood that the user should be informed in an appropriate manner, in accordance with applicable laws and regulations, of the type of personal information related to this disclosure, its scope of use, and the scenarios in which it may be used, and permission should be obtained from the user.

[0137] For example, in response to receiving a voluntary request from the user, prompt information is sent to the user to clearly prompt the user that the operation requested to be performed requires the acquisition and use of the user's personal information. This allows the user to choose whether or not to provide personal information to software or hardware such as terminal equipment, application programs, servers, or storage media that perform the operation of the proposed technical method of this disclosure based on the prompt information. As an optional but non-exclusive implementation, the method of sending prompt information to the user in response to receiving a voluntary request from the user may be, for example, a pop-up window, and the prompt information may be presented in text format within the pop-up window. The pop-up window may also include selection controls that allow the user to choose whether to "agree" or "disagree" to providing personal information to the terminal equipment.

[0138] The above notice and user permission acquisition process are merely illustrative and do not limit the forms in which this disclosure can be implemented. It should be understood that other methods that comply with applicable laws and regulations are also applicable to the implementation of this disclosure.

[0139] It is understood that the data relating to this proposed technology (including, but not limited to, the data itself, or the acquisition or use of the data) should comply with the requirements of applicable laws, regulations, and related provisions. The data may include information, parameters, and messages, such as cutover instruction information.

[0140] The above description is merely an explanation of preferred embodiments and the technical principles in which the present disclosure is applied. Those skilled in the art will understand that the scope of the disclosure is not limited to technical solutions formed by specific combinations of the above technical features, but should encompass other technical solutions formed by any combination of the above technical features or their equivalents, as long as they do not deviate from the disclosed concepts. For example, technical solutions formed by substituting the above features with similar functional technical features disclosed in this disclosure (but not limited to those disclosed).

[0141] While each operation is described using specific procedures, it should not be understood that these operations must be performed in a specific order or sequence. In certain environments, multitasking and parallel processing may be advantageous. Similarly, while some specific implementation details are included in the above discussion, these should not be understood as limiting the scope of this disclosure. Some features described in the context of a single embodiment may be implemented in combination within a single embodiment. Conversely, various features described in the context of a single embodiment may be implemented in multiple embodiments, either individually or in any suitable subcombination.

[0142] Although this topic has been described using terminology specific to structural features and / or the logical operation of the method, it should be understood that the topic limited to the attached claims is not limited to the specific features or operations described above. Rather, the specific features and operations described above are merely illustrative forms of realizing the claims.

Claims

1. A method for generating streaming media, To obtain images or videos, Determining the target musical elements, A method for generating streaming media, comprising generating streaming media in response to user input, wherein the streaming media includes the video or image and target music, the target music includes target music elements, and the target music is related to the content of the video or image.

2. The acquisition of the aforementioned image is Displaying the shooting page, The method according to claim 1, comprising obtaining the image in response to a touch operation on the shooting control on the shooting page.

3. The acquisition of the aforementioned image is Displaying the image page, The method according to claim 1 or 2, comprising obtaining the image in response to a touch operation on the image page to be selected.

4. The acquisition of the aforementioned image is To obtain the aforementioned video, The method according to any one of claims 1 to 3, comprising extracting video frame images from the video to obtain the image.

5. The method according to any one of claims 1 to 4, wherein the target musical element is a musical style.

6. The above-mentioned method of generating streaming media is Based on the aforementioned image or video and target music elements, generate target lyrics, The process involves converting the target lyrics from text to audio to obtain the target audio, adding background music to the target audio, and obtaining the target music. The method according to any one of claims 1 to 5, comprising performing a synthesis process on the target music and the image or video to obtain the streaming media.

7. Generating target lyrics based on the aforementioned image or video and target music elements is: The process involves performing identification on the content of the image or video and obtaining multiple keywords related to the content. Based on the language model, the target musical elements, and the multiple keywords, multiple sets of first lyrics are generated. The method according to claim 6, further comprising identifying the target lyrics from the multiple sets of first lyrics.

8. Identifying the target lyrics from the aforementioned multiple sets of first lyrics is: The matching value between the first lyrics of each group and the target musical element is determined, The method according to claim 7, further comprising determining the first set of lyrics with the highest matching value as the target lyrics.

9. The target musical element is a rap music style, and determining the matching value between each set of first lyrics and the target musical element is For any set of first lyrics, the number of sentences in the first lyrics and the number of rhymes in the first lyrics are determined. The method according to claim 8, further comprising determining the ratio of the number of rhymes to the number of sentences as the matching value of the first lyrics.

10. Before determining the first set of lyrics with the highest matching value as the target lyrics, the method, If, among the multiple sets of first lyrics, there is no first lyric whose matching value is equal to or greater than a preset threshold, then multiple sets of second lyrics are obtained based on the language model, the rap music style identifier, the multiple keywords, and the multiple rhyming preset phrases. The method according to claim 9, further comprising determining a matching value between the second lyrics of each set and the rap music style, and determining multiple sets of second lyrics whose matching value is greater than or equal to a predetermined threshold as multiple sets of first lyrics.

11. A streaming media generation device including an acquisition module, a determination module, and a generation module, The acquisition module is configured to acquire images or videos. The aforementioned decision module is configured to determine the target musical element, A streaming media generation device wherein the generation module is configured to generate streaming media in response to user input, the streaming media comprising the video or image and target music, the target music comprising target music elements, and the target music relating to the content of the video or image.

12. A terminal device, including a processor and memory, The memory is configured to store computer execution instructions. A terminal device wherein the processor executes computer execution instructions stored in the memory to cause the processor to execute the streaming media generation method according to any one of claims 1 to 10.

13. A computer-readable storage medium, wherein computer execution instructions are stored in the computer-readable storage medium, and when a processor executes the computer execution instructions, the streaming media generation method according to any one of claims 1 to 10 is realized.