Information flow processing method, device and electronic device
By obtaining and filling the keywords of information in the information flow, generating keyword materials, and presenting them in the human-computer interactive interface, the problem of difficulty for users to identify the information of interest is solved and the utilization rate of computing resources is improved.
Patent Information
- Application Number
- CN202011015730.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-09-24
- Publication Date
- 2025-02-07
- Estimated Expiration
- 2040-09-24
AI Technical Summary
The presentation of information in the information flow makes it difficult for users to quickly identify the information of interest, and the computing resource utilization rate of electronic devices when presenting the information flow is low.
By obtaining the keywords of the information in the information flow and filling them into the material template, the keyword material is generated and presented in the human-computer interactive interface combined with the original information.
It improves users' ability to quickly understand the core meaning of information through keyword materials, reduces the situation where users ignore information, and improves the computing resource utilization rate of electronic devices when presenting information flow.
Smart Images

Figure CN112100501B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to information technology, and more particularly to a method, device, electronic device and computer-readable storage medium for processing information flow. Background Art
[0002] Artificial Intelligence (AI) is the theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results. Computer Vision (CV) is an important branch of artificial intelligence, mainly studying machine vision such as using cameras and computers to replace human eyes to identify, track and measure targets.
[0003] With the development of computer vision technology and Internet technology, information flow (such as feed flow) as a fragmented form of information push is now widely used in various social and information applications. However, the information in the information flow is often presented in the form of titles and / or images, and the meaning of the presented content is relatively broad. Users usually browse the information in the information flow at a fast speed, which makes it easy for users to ignore the information they are actually interested in. The actual utilization rate of the computing resources consumed by electronic devices in the process of presenting the information flow is low.
[0004] In view of this, the relevant technology has not yet provided an effective solution. Summary of the invention
[0005] The embodiments of the present application provide a method, device, electronic device and computer-readable storage medium for processing information flow, which can improve the utilization rate of computing resources consumed by the electronic device when presenting information flow.
[0006] The technical solution of the embodiment of the present application is implemented as follows:
[0007] The present application provides a method for processing an information flow, including:
[0008] Obtain keywords of at least one piece of information in the information flow;
[0009] Filling the keyword of the at least one piece of information into the material template to obtain the keyword material of the at least one piece of information;
[0010] The at least one piece of information in the information flow and the keyword material of the at least one piece of information are presented on a human-computer interaction interface.
[0011] The present application provides an information flow processing device, including:
[0012] A keyword acquisition module, used to acquire keywords of at least one piece of information in the information flow;
[0013] A filling module, used to fill the keyword of the at least one piece of information into the material template to obtain the keyword material of the at least one piece of information;
[0014] A presentation module is used to present the at least one piece of information in the information flow and the keyword material of the at least one piece of information on a human-computer interaction interface.
[0015] An embodiment of the present application provides an electronic device, including:
[0016] A memory for storing executable instructions;
[0017] The processor is used to implement the information flow processing method provided in the embodiment of the present application when executing the executable instructions stored in the memory.
[0018] An embodiment of the present application provides a computer-readable storage medium storing executable instructions for causing a processor to execute the information flow processing method provided in the embodiment of the present application.
[0019] The embodiments of the present application have the following beneficial effects:
[0020] The keywords of at least one piece of information in the information flow are filled into the material template to obtain the keyword material, and the keyword material and at least one piece of information are presented together in the human-computer interaction interface. This allows users to quickly learn the core meaning of the information through the keyword material and determine whether the information is in line with their own interests, thereby reducing the occurrence of directly ignoring information and improving the actual utilization rate of computing resources consumed by electronic devices. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] Figure 1 It is a schematic diagram of the architecture of the information flow processing system provided in the embodiment of the present application;
[0022] Figure 2 It is a schematic diagram of the architecture of a terminal device provided in an embodiment of the present application;
[0023] Figure 3A It is a flowchart of the information flow processing method provided in the embodiment of the present application;
[0024] Figure 3B It is a flowchart of the information flow processing method provided in the embodiment of the present application;
[0025] Figure 3C It is a flowchart of the information flow processing method provided in the embodiment of the present application;
[0026] Figure 3DIt is a flowchart of the information flow processing method provided in the embodiment of the present application;
[0027] Figure 4 is a schematic diagram of synthesizing and presenting a text post provided by an embodiment of the present application;
[0028] Figure 5 is a schematic diagram of an image template corresponding to a dialogue type provided in an embodiment of the present application;
[0029] Figure 6 It is a schematic diagram of an image template corresponding to the network hot word type provided in an embodiment of the present application;
[0030] Figure 7 is a schematic diagram of an image template including a static image and a dynamic image provided in an embodiment of the present application;
[0031] Figure 8 This is a schematic diagram of adding a text sticker provided in an embodiment of the present application;
[0032] Fig. 9 is a schematic diagram of synthesizing and presenting a text sticker provided by an embodiment of the present application;
[0033] Fig.10 It is a schematic diagram of presenting a text sticker provided in an embodiment of the present application;
[0034] Fig.11 It is a schematic diagram of presenting a text sticker provided in an embodiment of the present application;
[0035] Fig.12 It is a schematic diagram of presenting a text sticker provided in an embodiment of the present application;
[0036] Fig.13 It is a schematic diagram of presenting a text sticker provided in an embodiment of the present application;
[0037] Fig.14 It is a schematic diagram of presenting a text sticker provided in an embodiment of the present application;
[0038] Fig.15 It is a schematic diagram of presenting a text sticker provided in an embodiment of the present application;
[0039] Fig.16 It is a flowchart of synthesizing and presenting text stickers provided in an embodiment of the present application. DETAILED DESCRIPTION
[0040] In order to make the purpose, technical solutions and advantages of the present application clearer, the present application will be further described in detail below in conjunction with the accompanying drawings. The described embodiments should not be regarded as limiting the present application. All other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of this application.
[0041] In the following description, reference is made to “some embodiments”, which describe a subset of all possible embodiments, but it can be understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.
[0042] In the following description, the terms "first\second\third" are only used to distinguish similar objects and do not represent a specific order of the objects. It is understandable that "first\second\third" can be interchanged with a specific order or sequence where permitted, so that the embodiments of the present application described here can be implemented in an order other than that illustrated or described here. In the following description, the term "multiple" refers to "at least two".
[0043] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein are only for the purpose of describing the embodiments of this application and are not intended to limit this application.
[0044] Before further describing the embodiments of the present application in detail, the nouns and terms involved in the embodiments of the present application are explained. The nouns and terms involved in the embodiments of the present application are subject to the following interpretations.
[0045] 1) Information flow: Presents several pieces of information in a streaming manner. For example, the information flow can be a feed flow. The application scenarios of information flow include, but are not limited to, friend dynamic recommendations in Moments and information recommendations in information applications (such as Weibo and Kandian). The information in the information flow can include at least one of text, images, and videos.
[0046] 2) Keywords: Keywords in information are used to reflect the core meaning of the information. The embodiment of the present application does not limit the length of keywords. Keywords can be words or a combination of words and punctuation marks. When performing keyword recognition, supervised or unsupervised methods can be used, which are not limited.
[0047] 3) Material template: includes a to-be-filled area for filling keywords, after which keyword materials are formed to reflect the core meaning of the corresponding information. The present application embodiment does not limit the materials in the material template, for example, it can be at least one of text, image and video; for another example, it can be static material (such as static image), dynamic material (such as dynamic image), or a combination of static material and dynamic material.
[0048] 4) Text format: the form of presentation of text, for example, the text format may include at least one of font size, font color and font.
[0049] 5) Text classification model: A model built based on machine learning principles, used to classify keywords to obtain keyword types. The present application embodiment does not limit the type of text classification model, for example, it can be a Transformer-based bidirectional encoder representation (Bidirectional Encoder Representation from Transformers, BERT) model.
[0050] The embodiments of the present application provide a method, device, electronic device and computer-readable storage medium for processing information flow, which can improve the utilization rate of computing resources consumed by the electronic device when presenting information flow. The following describes an exemplary application of the electronic device provided by the embodiments of the present application. The electronic device provided by the embodiments of the present application can be implemented as various types of terminal devices or as a server.
[0051] See also Figure 1 , Figure 1 It is a schematic diagram of the architecture of the information flow processing system 100 provided in the embodiment of the present application, wherein the terminal device 400 is connected to the server 200 via the network 300, and the server 200 is connected to the database 500. The network 300 may be a wide area network or a local area network, or a combination of the two; a database is a collection of data stored together in a certain way, which can be shared with multiple users, has as little redundancy as possible, and is independent of the application program.
[0052] In some embodiments, taking the electronic device as a terminal device as an example, the information flow processing method provided in the embodiment of the present application can be implemented by the terminal device. For example, the terminal device 400 runs the client 410 (an application for providing information flow), and for the information flow stored locally by the client 410 (for example, the information flow cached when the information application is online), the client 410 obtains the keyword of at least one piece of information in the information flow, and fills it into the material template to obtain the keyword material. Then, the client 410 presents at least one piece of information in the information flow and the keyword material of at least one piece of information in the human-computer interaction interface.
[0053] In some embodiments, taking the electronic device as a server as an example, the information flow processing method provided in the embodiment of the present application can be implemented by the server and the terminal device. For example, the server 200 can filter the multiple pieces of information stored in the database 500 according to the user portrait of the client 410, and construct the information flow to be sent to the client 410 according to the filtered information. Then, the server 200 fills the keyword of at least one piece of information in the information flow into the material template to obtain the keyword material, and sends the at least one piece of information and the keyword material to the client 410 to be presented in the human-computer interaction interface.
[0054] Here, keyword materials can also be obtained by relying on the local computing power of the terminal device 400. For example, the server 200 can send the information stream to the client 410, and the client 410 fills the keyword of at least one piece of information in the information stream into the material template to obtain the keyword material and present it in the human-computer interaction interface. This method is suitable for application scenarios where the local computing power of the terminal device 400 is strong.
[0055] As an example, in the graphical interface (i.e., human-computer interaction interface) of the client 410, an information flow including information 1 is shown, and information 1 includes image 11, title "Baby seal asks for a head pat, my heart is melted, seal: Can I go home with you?", source information, and number of comments. In image 11, keyword material 12 including the keyword "Can I go home with you?" is shown. In this way, when the user browses to keyword material 12, he can quickly learn the core meaning of information 1 and determine whether information 1 is the type that the user is interested in. For electronic devices, in the process of presenting information flows, the probability of computing resources being wasted can be reduced, that is, the actual utilization rate of computing resources can be improved.
[0056] In some embodiments, the terminal device 400 can implement the information flow processing method provided in the embodiments of the present application by running a computer program. For example, the computer program can be a native program or software module in the operating system; it can be a native application (APP, Application), that is, a program that needs to be installed in the operating system to run, such as an instant messaging application including a circle of friends function, an information application (i.e., the above-mentioned client 410); it can also be a small program, that is, a program that can be run only by downloading it to a browser environment; it can also be a small program that can be embedded in any APP. In short, the above-mentioned computer program can be an application, module or plug-in in any form.
[0057] The embodiments of the present application can be implemented with the help of cloud technology, which refers to a hosting technology that unifies a series of resources such as hardware, software, and network in a wide area network or a local area network to realize the calculation, storage, processing, and sharing of data. In another sense, cloud technology is also a general term for network technology, information technology, integration technology, management platform technology, and application technology based on the cloud computing business model application, which can form a resource pool and be used on demand, flexibly and conveniently. Cloud computing technology will become an important support. The background services of the technical network system require a large amount of computing and storage resources.
[0058] In some embodiments, the server 200 may be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms, wherein the cloud service may be an information flow service for the terminal device 400 to call to send the information flow to the terminal device 400. The terminal device 400 may be a smart phone, a tablet computer, a laptop computer, a desktop computer, a smart speaker, a smart watch, a smart TV, etc., but is not limited thereto. The terminal device and the server may be directly or indirectly connected via wired or wireless communication, which is not limited in the embodiments of the present application.
[0059] Taking the electronic device provided in the embodiment of the present application as a terminal device as an example, it can be understood that in the case where the electronic device is a server, Figure 2 Some of the structures shown in FIG. 1 (such as the user interface, the presentation module, and the input processing module) may be omitted. Figure 2 , Figure 2 is a schematic diagram of the structure of a terminal device 400 provided in an embodiment of the present application, Figure 2 The terminal device 400 shown includes: at least one processor 410, a memory 450, at least one network interface 420 and a user interface 430. The various components in the terminal device 400 are coupled together via a bus system 440. It is understood that the bus system 440 is used to achieve connection and communication between these components. In addition to the data bus, the bus system 440 also includes a power bus, a control bus and a status signal bus. However, for the sake of clarity, the bus system 440 is not shown in FIG. Figure 2 Various buses are labeled as bus system 440 .
[0060] Processor 410 can be an integrated circuit chip with signal processing capabilities, such as a general-purpose processor, a digital signal processor (DSP), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc., where the general-purpose processor can be a microprocessor or any conventional processor, etc.
[0061] The user interface 430 includes one or more output devices 431 that enable presentation of media content, including one or more speakers and / or one or more visual display screens. The user interface 430 also includes one or more input devices 432, including user interface components that facilitate user input, such as a keyboard, mouse, microphone, touch screen display, camera, other input buttons and controls.
[0062] The memory 450 may be removable, non-removable, or a combination thereof. Exemplary hardware devices include solid-state memory, hard disk drives, optical disk drives, etc. The memory 450 may optionally include one or more storage devices that are physically remote from the processor 410.
[0063] The memory 450 includes a volatile memory or a non-volatile memory, and may also include both volatile and non-volatile memories. The non-volatile memory may be a read-only memory (ROM), and the volatile memory may be a random access memory (RAM). The memory 450 described in the embodiments of the present application is intended to include any suitable type of memory.
[0064] In some embodiments, memory 450 can store data to support various operations, examples of which include programs, modules, and data structures, or a subset or superset thereof, as exemplarily described below.
[0065] Operating system 451, including system programs for processing various basic system services and performing hardware-related tasks, such as a framework layer, a core library layer, a driver layer, etc., for implementing various basic services and processing hardware-based tasks;
[0066] A network communication module 452, for reaching other computing devices via one or more (wired or wireless) network interfaces 420, exemplary network interfaces 420 include: Bluetooth, Wireless Compatibility Authentication (WiFi), and Universal Serial Bus (USB);
[0067] a presentation module 453 for enabling presentation of information via one or more output devices 431 (e.g., display screen, speaker, etc.) associated with the user interface 430 (e.g., a user interface for operating peripherals and displaying content and information);
[0068] The input processing module 454 is used to detect one or more user inputs or interactions from one of the one or more input devices 432 and translate the detected inputs or interactions.
[0069] In some embodiments, the device provided in the embodiments of the present application can be implemented in software. Figure 2 The processing device 455 of the information flow stored in the memory 450 is shown, which can be software in the form of a program and a plug-in, etc., including the following software modules: a keyword acquisition module 4551, a filling module 4552 and a presentation module 4553. These modules are logical, so they can be arbitrarily combined or further split according to the functions implemented. The functions of each module will be explained below.
[0070] The information flow processing method provided by the embodiment of the present application will be explained in combination with the exemplary application and implementation of the electronic device provided by the embodiment of the present application.
[0071] See also Figure 3A , Figure 3A This is a flow chart of the information flow processing method provided by the embodiment of the present application, which will be combined with Figure 3A The steps shown are explained.
[0072] In step 101, keywords of at least one piece of information in an information stream are obtained.
[0073] Here, the information stream includes multiple pieces of information, wherein the content of the information can be at least one of text, image and video. For example, in information applications, information can be divided into four categories: 1) pure text; 2) combination of text and image; 3) combination of text and video; 4) combination of text, image and video.
[0074] The information for which keywords need to be obtained may be all the information in the information stream, or may be part of the information in the information stream. Taking the above four categories of information as an example, keywords of information of categories 2), 3) and 4) in the information stream may be obtained, and information of category 1) may not be processed. Of course, this does not constitute a limitation on the embodiments of the present application, and the information for which keywords need to be obtained may be set according to the actual application scenario.
[0075] In this step, the keywords of the information can be manually marked or obtained through keyword recognition. In the process of keyword recognition, since the keywords are for the text of the information, keyword recognition can be performed on the text of the information, or optical character recognition (OCR) can be performed on the images or video frames in the information to obtain text, and keyword recognition can be performed on the obtained text. The above two methods can be applied either at will or at the same time. For the latter method, for example, the images or videos in some information include subtitles, and the text in the subtitles can also represent the actual meaning of the information. Among them, the video frames for OCR can be all the video frames included in the video in the information, or they can be part of the video frames obtained through frame extraction, for example, the video is subjected to frame extraction according to a set frame extraction frequency (such as extracting a frame every 1 second, 3 seconds or 5 seconds).
[0076] In some embodiments, the text of at least one piece of information includes a title, body content, comments and tags; the above-mentioned acquisition of keywords of at least one piece of information in the information flow can be achieved by performing any of the following processing: performing keyword recognition on the title of at least one piece of information to obtain keywords of at least one piece of information; performing keyword recognition on the title, body content, comments and tags of at least one piece of information to obtain keywords of at least one piece of information.
[0077] Here, the text of the information may include the title, body content, comments and tags, where the tags are used to reflect the type of information and may be manually annotated or automatically annotated by a machine learning algorithm. For example, in information applications, the tags of information may be entertainment news, social news, travel news or game news, etc. When determining the keywords of the information, you may use either of the following two methods:
[0078] 1) Since the title of the information usually indicates the core meaning of the information, keyword recognition can be performed on the title of the information to obtain the keywords of the information. This method can obtain the keywords of the information relatively quickly and is suitable for scenarios with high processing efficiency requirements.
[0079] 2) Keyword recognition can be performed on all texts included in the information, namely the title, text content, comments and tags. Keyword recognition can be performed on the title, text content, comments and tags separately, or the title, text content, comments and tags can be taken as a whole and keyword recognition can be performed on the whole. This method can improve the accuracy of the obtained keywords and is suitable for scenarios with high processing accuracy requirements.
[0080] In step 102, keywords of at least one piece of information are filled into a material template to obtain keyword materials of at least one piece of information.
[0081] After the keyword of the information is obtained in step 101, the keyword is filled into the material template to obtain the keyword material of the information. When the information includes multiple keywords, the multiple keywords can be filled into the material template respectively to obtain multiple keyword materials of the information.
[0082] It is worth noting that the material in the material template can be set according to the actual application scenario. For example, the material in the material template can include at least one of text, image and video. For example, the material can include at least one of static material (such as static image) and dynamic material (such as dynamic image). For example, the material in the material template can be the text "[area to be filled]". When the keyword of the information is determined to be "pampering", it is filled to obtain the keyword material "[pampering]"; the material in the material template can also be an image, which includes a set area for filling in keywords.
[0083] In addition, the number of material templates may be one or more. When the number of material templates is multiple, a material template for filling in keywords may be screened out from the multiple material templates, for example, by random selection.
[0084] In some embodiments, the material template corresponds to a set text format; the above-mentioned filling of keywords of at least one piece of information into the material template to obtain keyword material of at least one piece of information can be achieved in the following way: according to the text format corresponding to the material template, the format of the keywords of at least one piece of information is updated; the keywords after the format update are filled into the material template to obtain keyword material of at least one piece of information.
[0085] In order to unify the style of the keywords filled in the keyword material with the material template, the text format corresponding to the material template can be pre-set, wherein the text format includes at least one of the font size, the font color (the color of the text) and the font. For example, a certain text format may include a font size of four, a blue color and a regular font. After obtaining the keywords of the information, the format of the keywords is updated according to the text format corresponding to the material template. Then, the keywords with the updated format are filled into the material template to obtain the keyword material of the information. In the above manner, the style of the keywords and the material template can be unified, and the visual effect of the keyword material obtained by filling in can be optimized.
[0086] In some embodiments, the material template includes static material and dynamic material; the static material includes an area to be filled in for filling in keywords; the above-mentioned filling of keywords of at least one piece of information into the material template to obtain the keyword material of at least one piece of information can be achieved in the following way: the keywords of at least one piece of information are filled in the area to be filled in the static material, so that the filled static material and dynamic material are used together as the keyword material of at least one piece of information.
[0087] In an embodiment of the present application, a material template may include both static materials and dynamic materials, wherein static materials such as static images of stickers include areas to be filled with keywords, and the format of the static materials may be Photoshop Document (PSD) format or other file formats, without limitation; dynamic materials are used to present dynamic effects, such as sugar-sprinkling special effects or fireworks special effects, and the format of the dynamic materials may be Graphics Interchange Format (GIF) format or other file formats, also without limitation. When filling in keywords for a piece of information, the keywords are filled into the areas to be filled in the static materials, and the filled static materials and dynamic materials are used together as the keyword materials for the information, so that the obtained keyword materials include dynamic effects, which can enhance the attractiveness to users when finally presented, and help users quickly understand the core meaning of the information.
[0088] In step 103, at least one piece of information in the information flow and keyword material of at least one piece of information are presented on the human-computer interaction interface.
[0089] For the information in the information flow, after the keyword material is filled, the information and the corresponding keyword material are presented in the human-computer interaction interface, wherein the positional relationship between the information and the corresponding keyword material when presented is not limited, for example, it can be a containment relationship (the keyword material is located in the information) or a parallel relationship (such as vertical parallel, horizontal parallel, etc.). In some cases, for part of the information that is set not to obtain keywords, steps 101 to 102 can be omitted, and this part of the information can be directly presented in the human-computer interaction interface.
[0090] In some embodiments, at least one piece of information includes a cover and main content; the above-mentioned presentation of at least one piece of information in the information flow and the keyword material of at least one piece of information in the human-computer interaction interface can be achieved in the following manner: in the presentation area corresponding to the at least one piece of information in the human-computer interaction interface, the cover and keyword material of the at least one piece of information are presented; after presenting the cover and keyword material of the at least one piece of information, it also includes: in response to a trigger operation for the presentation area corresponding to the at least one piece of information, the main content of the at least one piece of information is presented in the human-computer interaction interface.
[0091] Here, the information may include a cover for initial presentation and a body content presented after being triggered. For the cover and body content, at least one of text, image and video may be included. For example, the cover may include a title (in text form) and an image. In the human-computer interaction interface, a separate presentation area may be divided for each piece of information in the information stream, for example, the presentation area may be divided in a list form. For information that has obtained keyword materials, the cover and keyword materials of the information are presented in the presentation area corresponding to the information in the human-computer interaction interface. The user may perform a trigger operation (such as a click operation) on the presentation area in the human-computer interaction interface. When the electronic device receives the trigger operation, it determines the information corresponding to the triggered presentation area and presents the body content of the information, for example, presents a new interface and presents the body content of the information in the new interface. In the above manner, under the premise of expressing the core meaning of the information, the presentation area occupied by each piece of information can be saved, so that more information can be presented simultaneously in the human-computer interaction interface.
[0092] It is worth noting that the same presentation method can also be applied to some information that does not perform steps 101 to 102. For example, if some information that does not perform steps 101 to 102 includes a cover and text content, the cover of the information is presented in the presentation area corresponding to the information in the human-computer interaction interface. In response to a trigger operation on the presentation area corresponding to the information, the text content of the information is presented in the human-computer interaction interface.
[0093] like Figure 3A As shown, the embodiment of the present application, by presenting keyword materials, enables users to quickly learn the core meaning of the information corresponding to the keyword materials (i.e., the meaning represented by the keywords), and determine whether the information is in line with their own interests, thereby reducing the occurrence of users directly ignoring or skipping information. At the same time, it can also improve the actual utilization rate of computing resources consumed by electronic devices in the process of presenting information flows.
[0094] In some embodiments, see Figure 3B , Figure 3B is a flowchart of a method for processing information flow provided in an embodiment of the present application. Figure 3A The illustrated step 103 can be implemented through steps 201 to 202 , which will be described in conjunction with each step.
[0095] In step 201, keyword material of at least one piece of information is added to the cover of at least one piece of information.
[0096] Here, for the information in the information stream, if the keyword material is obtained through step 101 to step 102, the keyword material can be added to the cover of the information. The cover of the information can include at least one of text, image and video.
[0097] For example, the cover of the information includes the title "The cat is so brave that it is not afraid of the height of more than 20 floors and makes people cry in anxiety", and the obtained keyword material is the text "[crying in anxiety]", then the keyword material can be added to the title to obtain "[crying in anxiety] The cat is so brave that it is not afraid of the height of more than 20 floors and makes people cry in anxiety"; for another example, the cover of the information includes an image, then the obtained keyword material can be added to a certain area of the image, for example, adding the keyword material in the form of text to the bottom area or top area set in the image to serve as subtitles of the image.
[0098] It is worth noting that when adding keyword materials to the cover of information, they can be added to all the contents included in the cover, or to part of the contents included in the cover, depending on the actual application scenario. For example, if the cover of information includes multiple images, keyword materials can be added to each image included in the cover, or keyword materials can be added only to the first image included in the cover.
[0099] In some embodiments, the cover of at least one piece of information includes an image; the above-mentioned method of adding the keyword material of at least one piece of information to the cover of at least one piece of information can be implemented in the following manner: obtaining the area where the target in the image is located; obtaining the area where the control corresponding to the image is located; the control includes at least one of a playback control and a duration control; adding the keyword material to the area of the image except the area where the target is located and the area where the control is located.
[0100] When the cover of the information includes an image, in order to ensure that the added keyword material does not adversely affect the original meaning of the image, in an embodiment of the present application, the area where the target in the image is located can be obtained, wherein the area where the artificially marked target is located can be obtained, or the image can be subjected to target detection to obtain the area where the target in the image is located. Target detection can be multi-classification target detection (for example, identifiable targets include faces, cats, dogs, vehicles, and buildings, etc.), or it can be binary classification target detection (such as face detection). Among them, target detection can be achieved through a machine learning model, and the type of machine learning model is not limited here, for example, it can be a regional convolutional neural network (Region-ConvolutionalNeural Network, R-CNN) model or a one-time detection (You Only Live Once, YOLO) model, etc.
[0101] At the same time, for the case where the image is a video frame of a video in the information (i.e., the image is used as the cover image of the video), the area where the control corresponding to the image is located can also be obtained, wherein the control includes at least one of a play control and a duration control. The area where the control is located can be pre-set according to the actual application scenario. For example, in an information APP, when the image included in the cover is displayed in the human-computer interaction interface, the position of the control is usually fixed, such as the play control is located in the center of the image, and the duration control is located in the lower right corner of the image.
[0102] Then, keyword material is added to any area of the image except the area where the target and the area where the control are located. It is worth noting that in the case where the cover image is not a video frame of the video, keyword material can also be added to any area of the image except the area where the target is located. In the above manner, the added keyword material can avoid the original content in the image, ensuring that the original meaning of the image is not affected.
[0103] In step 202, at least one piece of information and keyword material added to the cover of the at least one piece of information are presented on a human-computer interaction interface.
[0104] After the keyword material is added to the cover of the information, the information and the keyword material added to the cover of the information are presented on the human-computer interaction interface.
[0105] like Figure 3B As shown, the embodiment of the present application adds the keyword material of the information to the cover of the information without occupying additional presentation position, thereby ensuring that the original presentation structure of the information flow does not need to be changed; at the same time, it enables the user to pay attention to the keyword material in the cover while browsing the cover of the information, thereby improving the presentation effect of the keyword material and enhancing its appeal to users.
[0106] In some embodiments, see Figure 3C , Figure 3C is a flowchart of a method for processing information flow provided in an embodiment of the present application. Figure 3A Before step 102 shown, in step 301, the keywords of at least one piece of information may be classified to obtain a target keyword type.
[0107] In the embodiment of the present application, multiple keyword types can be pre-set, and according to the characteristics of each keyword type, the material template corresponding to the keyword type can be set, wherein the number of material templates corresponding to a keyword type can be one or more. For example, the set keyword types can include "Internet hot words" and "emotional words".
[0108] After identifying the keywords of the information in the information flow, the keywords are classified and processed to obtain keyword types. For the sake of easy distinction, the keyword types obtained here are named target keyword types. Among them, the keywords can be classified and processed by a text classification model, such as a BERT model.
[0109] In some embodiments, the above-mentioned classification processing of keywords of at least one piece of information to obtain a target keyword type can be achieved in the following manner: matching the keywords of at least one piece of information with a keyword data set; wherein the keyword data set includes multiple sample keywords and a keyword type of each sample keyword; the keyword type of the sample keyword is obtained by classifying the sample keywords through a text classification model; when the keywords of at least one piece of information successfully match any sample keyword in the keyword data set, the keyword type corresponding to the successfully matched sample keyword is used as the target keyword type; when the keywords of at least one piece of information fail to match multiple sample keywords in the keyword data set, the keywords of at least one piece of information are classified through a text classification model to obtain a target keyword type.
[0110] For example, multiple sample keywords can be pre-set, and each sample keyword can be classified and processed by the BERT model to obtain a keyword type. Then, multiple sample keywords and the keyword type of each sample keyword are added to the keyword data set, wherein the keyword type of the sample keyword can also be obtained by manual annotation.
[0111] It is worth noting that before the sample keywords are classified and processed by the BERT model, the BERT model can be trained. For example, multiple training keywords and the annotated keyword type of each training keyword (such as obtained by manual annotation) are obtained, and each training keyword is classified and processed by the BERT model to obtain the keyword type to be compared. Then, the difference between the annotated keyword type of the training keyword and the keyword type to be compared (that is, the loss value, which can be calculated by the loss function of the BERT model) is used to perform back propagation in the BERT model, and in the process of back propagation, the weight parameters of the BERT model are updated along the gradient descent direction.
[0112] After obtaining the keywords of the information in the information flow, match the keywords with the keyword data set. When the keyword successfully matches any sample keyword in the keyword data set (if they are the same), the keyword type corresponding to the successfully matched sample keyword is used as the target keyword type. In this way, the target keyword type can be obtained relatively quickly. When the keyword fails to match all sample keywords in the keyword data set, the keyword is classified and processed by the BERT model to obtain the target keyword type. Here, the keyword and the target keyword type can be added to the keyword data set to realize the continuous updating of the keyword data set. By constructing the keyword data set in the above way, the efficiency of obtaining the target keyword type can be improved; classification processing by the BERT model can improve the accuracy of the obtained target keyword type.
[0113] In step 302, a material template corresponding to a target keyword type is determined from among material templates corresponding to a plurality of keyword types, to be used as a material template for filling in the keyword of at least one piece of information.
[0114] Here, when the number of target keyword types obtained is only one, if the number of material templates corresponding to the target keyword type is only one, then this material template will be used as the material template for filling the keyword; if the number of material templates corresponding to the target keyword type includes multiple material templates, then a random selection will be made among the multiple material templates corresponding to the target keyword type, and the selected material template will be used as the material template for filling the keyword.
[0115] After determining the material template for filling keywords, if there are multiple keywords in the information (ie, the target keyword types of the multiple keywords are the same), the multiple keywords can be filled into the material template respectively to obtain multiple keyword materials.
[0116] In some embodiments, at least one piece of information includes multiple keywords corresponding to different target keyword types; the above-mentioned determination of the material template corresponding to the target keyword type among the material templates corresponding to the multiple keyword types can be achieved in the following way: obtaining the set weight of each target keyword type; among the material templates corresponding to the multiple keyword types, determining the material template corresponding to the target keyword type with the largest set weight as the material template for filling the keyword of at least one piece of information.
[0117] Here, if the information includes multiple keywords corresponding to different target keyword types, the set weight of each target keyword type can be obtained, and the set weight can be adjusted according to the actual application scenario, for example, the set weight of "Internet hot words" is greater than the set weight of "emotional words". Then, among the material templates corresponding to the multiple keyword types, the material template corresponding to the target keyword type with the largest set weight is determined as the material template for filling the keyword.
[0118] After determining the material template for filling in keywords, the keywords in the information that meet the target keyword type with the largest set weight can be filled into the material template to obtain keyword materials, or all the keywords in the information can be filled into the material template separately to obtain multiple keyword materials. For example, the keywords of the information include keywords A and B, the target keyword type of keyword A is "Internet hot words", and the target keyword type of keyword B is "emotional words". If the set weight of "Internet hot words" is greater than the set weight of "emotional words", keyword A can be filled into the material template corresponding to "Internet hot words" to obtain keyword materials, or keywords A and B can be filled into the material template corresponding to "Internet hot words" respectively to obtain two keyword materials. In the above manner, when the information includes multiple keywords, the material template for filling in keywords can be selected according to the importance of the keyword type (set weight).
[0119] In some embodiments, the target keyword type corresponds to multiple material templates, and the word count conditions of different material templates are different; the above-mentioned determination of the material template corresponding to the target keyword type among the material templates corresponding to the multiple keyword types can be achieved in the following way: among the material templates corresponding to the multiple keyword types, a material template corresponding to the target keyword type and having a word count condition that matches the word count of the keyword of at least one piece of information is determined as the material template for filling the keyword of at least one piece of information.
[0120] In the embodiment of the present application, for a keyword type, multiple corresponding material templates can be set, wherein different material templates have different word count conditions, for example, the word count condition of a material template is 2 words, and the word count condition of another material template is 3 words. After determining the target keyword type of the keyword, the material template corresponding to the target keyword type and whose word count condition matches the word count of the keyword is used as the material template for filling the keyword.
[0121] For example, the keyword of the information is "spoiling", the target keyword type is "internet buzzword", and the material templates corresponding to "internet buzzword" include template A with a character count condition of 2 characters and template B with a character count condition of 3 characters. Then, template A whose character count condition matches the character count of the keyword is used as the material template for filling the keyword "spoiling". By the above method, setting material templates corresponding to different character count conditions can improve the diversity of material templates and adapt to keywords with different character counts.
[0122] As Figure 3C shown, the embodiments of the present application pre-set corresponding material templates for different keyword types, which can make the style of the material templates for filling keywords conform to the actual meaning of the keywords, improve the final visual effect, and enhance the attraction to users.
[0123] In some embodiments, referring to Figure 3D , Figure 3D is a schematic flowchart of a method for processing information flow provided by the embodiments of the present application, Figure 3A and the shown step 101 can be implemented through steps 401 to 404, which will be described in combination with each step.
[0124] In step 401, word segmentation processing is performed on the text of at least one piece of information to obtain a plurality of candidate words.
[0125] Here, the method for keyword recognition in the embodiments of the present application is described. First, word segmentation processing is performed on the text of the information to obtain a plurality of candidate words. Among them, the method of word segmentation processing is not limited. For example, multiple character count conditions (such as 1 character, 2 characters, 3 characters... 8 characters) can be preset in advance, and all words in the text that meet each character count condition are extracted as candidate words; for another example, an open-source word segmentation processing tool can be used for word segmentation processing.
[0126] In step 402, the candidate words are matched with a plurality of sample keywords.
[0127] Here, prior knowledge can be introduced, that is, a plurality of sample keywords, such as core commodity words, place names, book names, and movie names, etc. For each candidate word obtained in step 401, the candidate word is matched with a plurality of sample keywords.
[0128] In step 403, when a candidate word matches any one of the plurality of sample keywords, the candidate word is determined as the keyword of at least one piece of information.
[0129] When a candidate word matches any one of the plurality of sample keywords (such as being the same), the candidate word is directly determined as the keyword of the information. In this way, keyword recognition can be quickly achieved.
[0130] In step 404, when the candidate word fails to match multiple sample keywords, classification processing is performed based on the characteristics of the candidate word to obtain a classification result of whether the candidate word is a keyword; wherein the characteristics of the candidate word include at least one of frequency characteristics, position characteristics, language characteristics and context characteristics.
[0131] When a candidate word fails to match multiple sample keywords, the features of the candidate word are extracted, and classification processing is performed according to the features of the candidate word to obtain a classification result, which indicates whether the candidate word is a keyword. Among them, the features of the candidate word include at least one of a frequency feature, a position feature, a language feature, and a context feature. The frequency feature may include at least one of a term frequency (TF) and an inverse document frequency index (IDF); the position feature includes the position where the candidate word first appears, whether the candidate word is in the title, and the span between the position where the candidate word first appears and the position where the candidate word last appears; the language feature includes at least one of part of speech, whether it is a stop word, morphological features, stem features, radicals, and semantics.
[0132] When classifying the candidate words according to their features, an unsupervised or supervised approach may be used. In the unsupervised approach, a feature condition is set in advance, and when the feature of the candidate word meets the feature condition, the candidate word is used as a keyword. For example, the feature condition may be that the TF of the candidate word is greater than a set threshold.
[0133] In a supervised manner, a keyword recognition model can be called to perform classification processing based on the features of candidate words to obtain a classification result of whether the candidate words are keywords. Prior to this, the keyword recognition model can be pre-trained through a training set to improve the recognition ability of the model. The training set can include the features of words marked as keywords and the features of words marked as non-keywords.
[0134] like Figure 3D As shown, the embodiment of the present application can improve the efficiency of keyword recognition by introducing prior knowledge; when the keyword is not recognized by prior knowledge, the features of the candidate words are extracted for classification processing to ensure recognition accuracy.
[0135] Below, we will explain an exemplary application of the embodiment of the present application in a practical application scenario. For ease of understanding, we will use a viewing app (i.e., an information app) as an example. Figure 4 The schematic diagram of the synthetic text sticker (corresponding to the keyword material above) shown in Figure 4In the process, when the background server of the Kandian APP determines the information flow to be recommended, it performs semantic analysis on the information in the information flow (corresponding to the information above), that is, performs keyword recognition, and obtains the keywords of the information. Among them, the type of information that needs to be synthesized into text posts can be preset, for example, it can include graphic information (including text and images) and video information (including text, video and video frames in the video as cover images); keyword recognition can be performed on the title, text content, comments, tags and cover images in the information, of course, it is not limited to this, and can be set according to the actual application scenario, among which the cover image refers to the image on the cover of the information.
[0136] After obtaining the keywords of the information, the keywords are classified and processed to obtain the target keyword type. In the embodiment of the present application, multiple keyword types can be pre-set. Here, six keyword types, including Internet hot words, emotional words, numbers / symbols, dialogues, hot events, and intellectual property (IP) nouns (such as IP nouns related to celebrities and film and television variety shows), are used as examples. For each keyword type, according to the characteristics of the keyword type itself, the corresponding material template is pre-set to facilitate management, and it can also improve the presentation effect of the final text post. Among them, the number of material templates corresponding to a keyword type can be one or more.
[0137] As an example, the present application embodiment provides the following Figure 5 Schematic diagram of the image template corresponding to the "dialogue" type (i.e., the material template whose material is an image), Figure 5 The image template 51 and the image template 52 are shown, both of which are images in the form of dialog boxes. In addition, when setting the material template, material templates corresponding to different word count conditions can also be set. As an example, Figure 6 Image templates corresponding to the "Internet hot words" type are shown, including image template 61 and image template 62 corresponding to the word count condition of 2 words (that is, image template 61 and image template 62 are used to fill in keywords including 2 words), and also including image template 63 corresponding to the word count condition of 3 words.
[0138] The image template may include at least one of static material and dynamic material. As an example, the embodiment of the present application provides the following Figure 7 The schematic diagram of the image template shown in Figure 7 In the figure, the image template includes a static image 71 in a square shape and a dynamic image 72 for reflecting the sugar-sprinkling special effect, wherein the static image 71 may be in PSD format and the dynamic image 72 may be in GIF format, but this does not constitute a limitation on the embodiments of the present application.
[0139] If multiple keywords corresponding to different target keyword types are obtained after keyword recognition of the information, the set weights of multiple target keyword types can be obtained, and the material template corresponding to the target keyword type with the largest set weight is used as the material template for filling the keywords. The set weights of keyword types can be adjusted according to the actual application scenario. For example, after sorting the above 6 keyword types in descending order of set weight, a sequence of "Internet buzzwords - emotional words - numbers / symbols - conversations - hot events - IP nouns" can be obtained.
[0140] In the process of filling the keywords into the material template, the keywords can be format-updated according to the text format corresponding to the material template, and then the format-updated keywords are filled into the area to be filled in the material template to obtain a text sticker. In this way, it can be ensured that the format-updated keywords are unified with the style of the material template, where the text format includes at least one of font size, font color, and font type.
[0141] After obtaining the text sticker, the text sticker can be added to the cover of the information. Taking the image added to the cover as an example, when adding, the area where the control corresponding to the image in the cover (such as at least one of the play control and the duration control) is located can be obtained, and at the same time, target detection (such as face detection) is performed on the image to obtain the area where the target is located. Then, the text sticker is added in the area other than the area where the control is located and the area where the target is located. As an example, the embodiments of the present application provide a schematic diagram of adding a text sticker as shown in Figure 8 shown. After keyword recognition of the title of the information in Figure 8 , the keyword "spoiling" is obtained, and then the text sticker 86 is filled. In the cover image 81 of the information, after avoiding the areas where the controls (including the play control 82 and the duration control 83) are located and the area where the face is located, the addable areas 84 and 85 are obtained. In the embodiments of the present application, the text sticker 86 can be added to any one of the addable areas 84 and 85. Figure 8 Two addition examples are shown.
[0142] As an example, the embodiments of the present application also provide a schematic diagram of synthesizing a text sticker as shown in Fig. 9 shown. In Fig. 9In the example, after keyword recognition of the title of news 93, the keyword "Can I go home with you?" is obtained. Then, the keyword is classified and processed to obtain the target keyword type of "dialogue". In the image template library corresponding to "dialogue", there are multiple image templates such as image template 91 and image template 92. These image templates are randomly selected to obtain an image template for filling keywords. Here, image template 92 is taken as an example. According to the text format corresponding to the selected image template 92, the format of the keyword is updated, and the keywords with the updated format are filled into the to-be-filled area of the image template 92 to obtain text post 95. Finally, text post 95 is added to the cover image 94 of news 93 and sent to the client (the client of the Kandian APP) to be presented in the human-computer interaction interface of the client, wherein the position of text post 95 avoids the main object (i.e., seal), playback control and duration control in the cover image 94.
[0143] As an example, the present application also provides the following Fig.10 The schematic diagram of presenting text stickers is shown below, which will be described separately:
[0144] 1) After keyword recognition of the title "Zhang kicked Han in public, who noticed Zhang's behavior, too doting" in the news 100, the keyword "doting" is obtained, and further classification is obtained to obtain the target keyword type as "Internet hot words". "Doting" is filled into the image template corresponding to "Internet hot words" to obtain text post 101, which is presented in the cover image of the news 100.
[0145] 2) After performing keyword recognition on the title "The cat is so brave, it is not afraid of the height of more than 20 floors, which makes people cry anxiously" in the news 110, the keyword "crying anxiously" is obtained, and further classified to obtain the target keyword type as "emotional words". "Crying anxiously" is filled into the image template corresponding to "emotional words" to obtain text post 111, which is presented in the cover image of the news 110.
[0146] 3) After keyword recognition of the title "A loud noise came from the deep sea, Army A sank Army B's strongest nuclear submarine, 10 billion US dollars calmed the storm" in the news 120, the keywords "Army A" and "10 billion US dollars" were obtained, and further classified to obtain the target keyword type as "number / symbol". "Army A" and "10 billion US dollars" were filled into the image template corresponding to "number / symbol" respectively, and text posts 121 and text posts 122 were obtained, and presented in the cover image of the news 120.
[0147] 4) After performing keyword recognition on the title "Baby seal asks for a head pat, my heart is melted, seal: Can I go home with you?" in the news 130, the keyword "Can I go home with you?" is obtained, and further classified to obtain the target keyword type as "dialogue". "Can I go home with you?" is filled into the image template corresponding to "dialogue" to obtain text post 131, which is presented in the cover image of the news 130.
[0148] 5) After keyword recognition of the title "Relax! 30 days left before the college entrance examination, 10.71 million students start sprinting and prepare for the exam" in the news 140, the keyword "college entrance examination countdown" is obtained, and further classification is performed to obtain the target keyword type as "hot events". "College entrance examination countdown" is filled into the image template corresponding to "hot events" to obtain text post 141, which is presented in the cover image of the news 140.
[0149] 6) After keyword recognition for the title "How did Yang sign a contract with the company and who is his current boss? Yang became famous and earned so much in a year" in the news 150, the keyword "Yang" (here "Yang" is the name of the star) is obtained, and the target keyword type is further classified as "IP noun". "Yang" is filled into the image template corresponding to "IP noun" to obtain text post 151, which is presented in the cover image of the news 150.
[0150] As an example, the present application also provides the following embodiments: Fig.11 The schematic diagram of presenting text stickers in the human-computer interaction interface of the Kandian APP is shown in FIG. Fig.11 In the figure, the human-computer interaction interface of the "kandian" function in the instant messaging APP is shown, taking the "kandian" function in the instant messaging APP as an example. In the "recommendation" column of the "kandian" function, multiple pieces of information are presented in the form of information flow, including information 111 and information 113. Among them, information 111 is video information (i.e., large picture information card), and information 113 is picture and text information. Fig.11 Only the cover of the information is presented, and the text content is not presented. Here, taking the example of adding text posts to video information in the information flow, text posts 112 added to the image included in the cover of information 111 are shown. Compared with information 113, information 111 with text posts 112 added can enable users to understand the core meaning of the information more quickly, and help users quickly determine whether the information is of interest to them.
[0151] It is worth noting that in the embodiment of the present application, the text post can also be presented in a parallel relationship with the cover of the information, wherein the parallel relationship is such as vertical parallel or horizontal parallel. As an example, the embodiment of the present application provides the following Fig.12 The schematic diagram of presenting text stickers is shown in Fig.12In FIG. 1 , information 121 and a text post 122 corresponding to the information 121 are shown, and the two are presented in a vertically parallel manner.
[0152] The above mainly introduces the case where the material template is an image template, but in the embodiment of the present application, the material template can also be a text template, for example, the text template can be "[area to be filled]", so that the obtained text post is also in text form. For the text post in text form, it can also be added to the cover of the information, or it can be presented in parallel with the cover. For the former case, the embodiment of the present application provides the following Fig.13 The schematic diagram of presenting the text post is shown in Fig.13 In the figure, information 131 and text 132 added to the cover image of information 131 are shown. The text 132 can express the core meaning of the information 131 in a form similar to subtitles. The position of adding the text in the cover image can be pre-set and there is no limitation on this.
[0153] In addition to being added to the cover image of the news, text posts in text form can also be added to the text (such as the title) included in the cover of the news. As an example, the present application embodiment provides the following Fig.14 The schematic diagram of presenting the text post is shown in Fig.14 In the figure, information 141 and text 142 added to the title of information 141 are shown. By presenting text 142, the content of the title can be further refined, so that the user can quickly know the core meaning of the information.
[0154] The text post in the form of text can also be presented in parallel with the cover of the information. As an example, the embodiment of the present application provides the following Fig.15 The schematic diagram of presenting the text post is shown in Fig.15 In FIG. 1 , information 151 and text posts 152 arranged vertically and horizontally with the information 151 are shown.
[0155] In terms of underlying implementation, the embodiments of the present application provide Fig.16 The process diagram of synthesizing text is shown in the figure. For ease of understanding, it is explained in steps:
[0156] 1) Perform semantic analysis on the title of the information (of course, it can also be other content included in the information, this is just an example), that is, perform keyword recognition to obtain the keywords of the information. Here, the natural language processing (NLP) interface of the cloud server can be called to realize keyword recognition. The embodiment of the present application does not limit the method of keyword recognition, and an unsupervised or supervised method can be used. For example, the title of the information can be segmented to obtain multiple candidate words. For each candidate word, the candidate word is judged by extracting its features to determine whether it is a keyword, wherein the features of the candidate word include statistical features (such as TF, IDF), position features (the position where the candidate word first appears, the span between the position where the candidate word first appears and the position where the last appears), language features (part of speech, whether it is a stop word, morphological features, stem features, radicals, semantics) and contextual features (context features) at least one of them, wherein the statistical features correspond to the word frequency features above, and the morphological features can include suffixes and abbreviations, etc. In addition, prior knowledge, namely sample keywords, can also be introduced, such as core product words, place names, book titles, and movie titles. If a candidate word is the same as a sample keyword, the candidate word will be used as the keyword of the information.
[0157] 2) Classify the keywords of the information to obtain the target keyword type. Here, multiple sample keywords can be classified in advance through the BERT model to obtain the keyword type of each sample keyword. Then, multiple sample keywords and the keyword type of each sample keyword are added to the keyword data set and stored, such as cached. After obtaining the keywords of the information, the keywords are matched with the sample keywords in the keyword data set. If the keywords of the information are the same as a sample keyword (corresponding to Fig.16 ), the keyword type corresponding to the sample keyword is used as the target keyword type of the information keyword; if the information keyword is different from all sample keywords (corresponding Fig.16 If there is a miss in the information), the BERT model is used to classify the keywords of the information in real time to obtain the target keyword type, and the keywords of the information and the target keyword type are added to the keyword dataset to achieve continuous updating of the keyword dataset.
[0158] 3) Fill the keywords of the information into the material template corresponding to the target keyword type.
[0159] 4) After the filling is completed, a text frame is obtained. The embodiment of the present application does not limit the format of the text frame, for example, it can be a portable network graphics (PNG) format.
[0160] 5) The obtained text post is loaded and displayed, for example, the text post is added to the cover image of the information, and the cover image with the added information is presented in the human-computer interaction interface of the client.
[0161] The embodiment of the present application can extract the content of information to obtain keywords, and present the keywords in a graphical form (text posts in image form), which can enhance visual appeal, help users to quickly filter information in the information flow, and promote an increase in click consumption; at the same time, the embodiment of the present application makes use of the capabilities of machine learning to achieve automatic synthesis and automatic addition of text posts, which can save a lot of labor costs.
[0162] The following continues to describe the exemplary structure of the information flow processing device 455 provided in the embodiment of the present application implemented as a software module. In some embodiments, such as Figure 2 As shown, the software modules in the information flow processing device 455 stored in the memory 450 may include: a keyword acquisition module 4551, used to obtain keywords of at least one piece of information in the information flow; a filling module 4552, used to fill the keywords of at least one piece of information into the material template to obtain the keyword material of at least one piece of information; a presentation module 4553, used to present at least one piece of information in the information flow and the keyword material of at least one piece of information in the human-computer interaction interface.
[0163] In some embodiments, at least one piece of information includes a cover; the presentation module 4553 is also used to: add keyword material of at least one piece of information to the cover of at least one piece of information; present at least one piece of information and the keyword material added to the cover of at least one piece of information in the human-computer interaction interface.
[0164] In some embodiments, the cover of at least one message includes an image; the presentation module 4553 is also used to: obtain the area where the target in the image is located; obtain the area where the control corresponding to the image is located; the control includes at least one of a playback control and a duration control; and add keyword materials to the area of the image other than the area where the target is located and the area where the control is located.
[0165] In some embodiments, the material template corresponds to a set text format; the filling module 4552 is also used to: update the format of the keywords of at least one piece of information according to the text format corresponding to the material template; fill the keywords with the updated format into the material template to obtain the keyword material of at least one piece of information.
[0166] In some embodiments, at least one piece of information includes a cover and text content; the presentation module 4553 is also used to: present the cover and keyword materials of at least one piece of information in the presentation area corresponding to the at least one piece of information in the human-computer interaction interface; the information flow processing device 455 also includes: a response module, which is used to present the text content of at least one piece of information in the human-computer interaction interface in response to a trigger operation on the presentation area corresponding to the at least one piece of information.
[0167] In some embodiments, the material template includes static material and dynamic material; the static material includes an area to be filled with keywords; the filling module 4552 is also used to: fill the keywords of at least one piece of information into the area to be filled in the static material, so that the filled static material and dynamic material are used together as keyword materials for at least one piece of information.
[0168] In some embodiments, the information flow processing device 455 also includes: a classification module, which is used to classify the keywords of at least one piece of information to obtain a target keyword type; a template determination module, which is used to determine the material template corresponding to the target keyword type among the material templates corresponding to multiple keyword types, as a material template for filling the keywords of at least one piece of information.
[0169] In some embodiments, at least one piece of information includes multiple keywords corresponding to different target keyword types; the template determination module is also used to: obtain a set weight for each target keyword type; and among the material templates corresponding to the multiple keyword types, determine the material template corresponding to the target keyword type with the largest set weight as the material template for filling in the keywords of at least one piece of information.
[0170] In some embodiments, the target keyword type corresponds to multiple material templates, and the word count conditions of different material templates are different; the template determination module is also used to: determine, among the material templates corresponding to the multiple keyword types, a material template corresponding to the target keyword type and whose word count condition matches the word count of the keyword of at least one piece of information, as the material template for filling in the keyword of at least one piece of information.
[0171] In some embodiments, the classification module is also used to: match the keywords of at least one piece of information with a keyword data set; wherein the keyword data set includes multiple sample keywords and a keyword type for each sample keyword; the keyword type of the sample keyword is obtained by classifying the sample keywords using a text classification model; when the keywords of at least one piece of information successfully match any one of the sample keywords in the keyword data set, the keyword type corresponding to the successfully matched sample keyword is used as the target keyword type; when the keywords of at least one piece of information fail to match multiple sample keywords in the keyword data set, the keywords of at least one piece of information are classified using a text classification model to obtain the target keyword type.
[0172] In some embodiments, the keyword acquisition module 4551 is also used to: perform word segmentation processing on the text of at least one piece of information to obtain multiple candidate words; for each candidate word, perform the following processing: match the candidate word with multiple sample keywords; when the candidate word successfully matches any one of the multiple sample keywords, determine the candidate word as a keyword of at least one piece of information; when the candidate word fails to match multiple sample keywords, perform classification processing based on the characteristics of the candidate word to obtain a classification result of whether the candidate word is a keyword; wherein the characteristics of the candidate word include at least one of word frequency characteristics, position characteristics, language characteristics and context characteristics.
[0173] In some embodiments, the text of at least one piece of information includes a title, body content, comments and tags; the keyword acquisition module 4551 is also used to: perform any of the following processing: perform keyword recognition on the title of at least one piece of information to obtain keywords of at least one piece of information; perform keyword recognition on the title, body content, comments and tags of at least one piece of information to obtain keywords of at least one piece of information.
[0174] The embodiment of the present application provides a computer program product or a computer program, which includes a computer instruction stored in a computer-readable storage medium. The processor of the computer device reads the computer instruction from the computer-readable storage medium, and the processor executes the computer instruction, so that the computer device executes the information flow processing method described above in the embodiment of the present application.
[0175] The present application embodiment provides a computer-readable storage medium storing executable instructions, wherein the executable instructions are stored. When the executable instructions are executed by a processor, the processor will be caused to execute the method provided by the present application embodiment, for example, Figure 3A , Figure 3B , Figure 3C or Figure 3DIt is worth noting that computers include various computing devices including terminal devices and servers.
[0176] In some embodiments, the computer-readable storage medium may be a memory such as FRAM, ROM, PROM, EP ROM, EEPROM, flash memory, magnetic surface storage, optical disk, or CD-ROM; or it may be various devices including one or any combination of the above memories.
[0177] In some embodiments, executable instructions may be in the form of a program, software, software module, script or code, written in any form of programming language (including compiled or interpreted languages, or declarative or procedural languages), and may be deployed in any form, including as a stand-alone program or as a module, component, subroutine or other unit suitable for use in a computing environment.
[0178] As an example, executable instructions may, but need not, correspond to a file in a file system, may be stored as part of a file that stores other programs or data, such as in one or more scripts in a HyperText Markup Language (HTML) document, in a single file dedicated to the program in question, or in multiple coordinated files (e.g., files storing one or more modules, subroutines, or code portions).
[0179] By way of example, executable instructions may be deployed to be executed on one computing device, or on multiple computing devices located at one site, or on multiple computing devices distributed across multiple sites and interconnected by a communication network.
[0180] The above are only embodiments of the present application and are not intended to limit the protection scope of the present application. Any modifications, equivalent substitutions and improvements made within the spirit and scope of the present application are included in the protection scope of the present application.
Claims
1. A method for processing information flow, characterized in that: The method comprises: Obtain keywords of at least one piece of information in the information flow; Classifying the keywords of the at least one piece of information to obtain a target keyword type; Determining, among the material templates corresponding to the plurality of keyword types, a material template corresponding to the target keyword type as a material template for filling the keyword of the at least one piece of information; Filling the keyword of the at least one piece of information into the material template to obtain the keyword material of the at least one piece of information, wherein the material in the material template includes at least one of text, image and video, and the material template includes at least one of static material and dynamic material; The at least one piece of information in the information stream and the keyword material of the at least one piece of information are jointly presented on the human-computer interaction interface, wherein the at least one piece of information in the information stream and the keyword material of the at least one piece of information are jointly presented on the human-computer interaction interface, comprising: adding the keyword material of the at least one piece of information to the cover of the at least one piece of information; presenting the at least one piece of information and the keyword material added to the cover of the at least one piece of information on the human-computer interaction interface.
2. The method for processing information flow according to claim 1, characterized in that: The cover of the at least one message includes an image; The step of adding the keyword material of the at least one piece of information to the cover of the at least one piece of information includes: Acquire the area where the target in the image is located; Acquire an area where a control corresponding to the image is located; the control includes at least one of a play control and a duration control; The keyword material is added to the area of the image except the area where the target is located and the area where the control is located.
3. The method for processing information flow according to claim 1, characterized in that: The text format set corresponding to the material template; The step of filling the keyword of the at least one piece of information into the material template to obtain the keyword material of the at least one piece of information includes: updating the format of the keywords of the at least one piece of information according to the text format corresponding to the material template; The keywords in the updated format are filled into the material template to obtain the keyword material of the at least one piece of information.
4. The method for processing information flow according to claim 1, characterized in that: The at least one piece of information includes a cover and a body content; The presenting of the at least one piece of information in the information flow and the keyword material of the at least one piece of information on the human-computer interaction interface includes: In the presentation area corresponding to the at least one piece of information in the human-computer interaction interface, presenting the cover and keyword materials of the at least one piece of information; The method further comprises: In response to a triggering operation on a presentation area corresponding to the at least one piece of information, the body content of the at least one piece of information is presented in the human-computer interaction interface.
5. The method for processing information flow according to claim 1, characterized in that: The static material includes a to-be-filled area for filling keywords; The step of filling the keyword of the at least one piece of information into the material template to obtain the keyword material of the at least one piece of information includes: The keyword of the at least one piece of information is filled into the to-be-filled area of the static material, so that the filled static material and the dynamic material are used together as the keyword material of the at least one piece of information.
6. The method for processing information flow according to claim 1, characterized in that: The at least one piece of information includes a plurality of keywords corresponding to different target keyword types; The determining of the material template corresponding to the target keyword type from the material templates corresponding to the plurality of keyword types respectively includes: Obtaining a set weight for each of the target keyword types; Among the material templates corresponding to the plurality of keyword types, a material template corresponding to the target keyword type with the largest set weight is determined as a material template for filling in the keyword of the at least one piece of information.
7. The method for processing information flow according to claim 1, characterized in that: The target keyword type corresponds to multiple material templates, and different material templates have different word count requirements; The determining of the material template corresponding to the target keyword type from the material templates corresponding to the plurality of keyword types respectively includes: Among the material templates corresponding to multiple keyword types, a material template corresponding to the target keyword type and having a word count condition matching the word count of the keyword of the at least one piece of information is determined as a material template for filling the keyword of the at least one piece of information.
8. The method for processing information flow according to claim 1, characterized in that: The classifying and processing the keywords of the at least one piece of information to obtain the target keyword type includes: matching a keyword of the at least one piece of information with a keyword dataset; The keyword data set includes a plurality of sample keywords and a keyword type of each of the sample keywords; the keyword type of the sample keywords is obtained by classifying the sample keywords through a text classification model; When the keyword of the at least one piece of information successfully matches any sample keyword in the keyword data set, the keyword type corresponding to the successfully matched sample keyword is used as the target keyword type; When the keyword of the at least one piece of information fails to match the multiple sample keywords in the keyword data set, the keyword of the at least one piece of information is classified by the text classification model to obtain a target keyword type.
9. The method for processing information flow according to any one of claims 1 to 5, characterized in that: The step of obtaining a keyword of at least one piece of information in the information stream includes: Performing word segmentation processing on the text of the at least one piece of information to obtain a plurality of candidate words; For each candidate word, perform the following processing: Matching the candidate word with a plurality of sample keywords; When the candidate word successfully matches any one of the multiple sample keywords, determining the candidate word as a keyword of the at least one piece of information; When the candidate word fails to match the multiple sample keywords, classification processing is performed according to the characteristics of the candidate word to obtain a classification result of whether the candidate word is a keyword; The features of the candidate words include at least one of word frequency features, position features, language features and context features.
10. The method for processing information flow according to any one of claims 1 to 5, characterized in that: The text of the at least one piece of information includes a title, a body of content, comments and tags; The step of obtaining a keyword of at least one piece of information in the information stream includes: Perform any of the following: Performing keyword recognition on the title of the at least one piece of information to obtain keywords of the at least one piece of information; Keyword recognition is performed on the title, text content, comments and tags of the at least one piece of information to obtain keywords of the at least one piece of information.
11. An information flow processing device, characterized in that: The device comprises: A keyword acquisition module, used to acquire keywords of at least one piece of information in the information flow; A classification module, used for classifying the keywords of the at least one piece of information to obtain a target keyword type; A template determination module, configured to determine a material template corresponding to the target keyword type from among material templates corresponding to a plurality of keyword types, to serve as a material template for filling in the keyword of the at least one piece of information; a filling module, configured to fill the keyword of the at least one piece of information into the material template to obtain the keyword material of the at least one piece of information, wherein the material in the material template includes at least one of text, image and video, and the material template includes at least one of static material and dynamic material; A presentation module is used to jointly present the at least one piece of information in the information stream and the keyword material of the at least one piece of information in the human-computer interaction interface, wherein the jointly presenting the at least one piece of information in the information stream and the keyword material of the at least one piece of information in the human-computer interaction interface includes: adding the keyword material of the at least one piece of information to the cover of the at least one piece of information; presenting the at least one piece of information and the keyword material added to the cover of the at least one piece of information in the human-computer interaction interface.
12. An electronic device, characterized in that: include: A memory for storing executable instructions; A processor, configured to implement the information flow processing method according to any one of claims 1 to 10 when executing the executable instructions stored in the memory.
13. A computer-readable storage medium, characterized in that: Executable instructions are stored, and when executed by a processor, the method for processing the information flow described in any one of claims 1 to 10 is implemented.
14. A computer program product comprising executable instructions, characterized in that: When the executable instructions are executed by a processor, the information flow processing method according to any one of claims 1 to 10 is implemented.
Citation Information
Patent Citations
Task establishing method and mobile terminal
CN110223695A
Target processing method, target processing device, target processing equipment and medium
CN111339399A