基于遗传算法的资源信息推荐方法、装置、终端及介质Resource information recommendation method, device, terminal and medium based on genetic algorithm
本申请要求于2019年6月19日提交中国专利局、申请号为201910533742.3,发明名称为“基于遗传算法的资源信息推荐方法、装置、终端及介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of a Chinese patent application filed with the Chinese Patent Office on June 19, 2019, the application number is 201910533742.3, and the invention title is "Resource information recommendation method, device, terminal and medium based on genetic algorithm", and its entire content Incorporated in this application by reference.
技术领域Technical field
本申请涉及人工智能预测分析技术领域,尤其涉及一种基于遗传算法的资源信息推荐方法、装置、终端及介质。This application relates to the technical field of artificial intelligence predictive analysis, and in particular to a method, device, terminal and medium for recommending resource information based on genetic algorithms.
背景技术Background technique
在资源信息的推广过程中,多采用推荐人员推荐,推荐人员通常只能根据经验值向用户推荐资源名称。然而,发明人发现,由于社会人员的个人情况各不相同,而资源的种类繁多,各个资源之间具有不同的产品条款和适用场景,推荐人员很难在短时间内自行分析出更适合用户的资源,资源推荐准确性低。In the promotion of resource information, recommendations by recommenders are often used, and recommenders usually only recommend resource names to users based on experience values. However, the inventor found that due to the different personal circumstances of social workers and the wide variety of resources, each resource has different product terms and applicable scenarios, it is difficult for recommenders to analyze by themselves what is more suitable for users in a short time. Resource, resource recommendation accuracy is low.
上述内容仅用于辅助理解本申请的技术方案,并不代表承认上述内容是现有技术。The above content is only used to assist the understanding of the technical solution of this application, and does not mean that the above content is recognized as prior art.
发明内容Summary of the invention
本申请的主要目的在于提供了一种基于遗传算法的资源信息推荐方法、装置、终端及介质,旨在解决现有技术资源信息推荐过程中难以在短时间确定适合用户的资源名称、资源推荐准确性低的技术问题。The main purpose of this application is to provide a method, device, terminal and medium for recommending resource information based on genetic algorithm, which aims to solve the difficulty in determining the resource name suitable for users in a short time in the resource information recommendation process of the prior art and the accuracy of resource recommendation Technical problems of low sex.
为实现上述目的,本申请提供了一种基于遗传算法的资源信息推荐方法,包括如下步骤:In order to achieve the above objective, this application provides a method for recommending resource information based on genetic algorithm, which includes the following steps:
获取待推荐用户的数据信息;Obtain data information of users to be recommended;
根据所述数据信息,确定所述待推荐用户适用的资源类型;According to the data information, determine the resource type applicable to the user to be recommended;
根据所述资源类型,确定与所述资源类型对应的各资源名称、以及与所述资源类型对应的适应度函数;According to the resource type, determine each resource name corresponding to the resource type and the fitness function corresponding to the resource type;
根据确定的适应度函数,更新预设的遗传算法模型;Update the preset genetic algorithm model according to the determined fitness function;
将所述各资源名称作为所述遗传算法模型的输入参数并运行所述遗传算法模型,得到待推荐资源名称;Using the resource names as input parameters of the genetic algorithm model and running the genetic algorithm model to obtain the resource name to be recommended;
将所述待推荐资源名称对应的资源信息发送至待推荐用户。The resource information corresponding to the name of the resource to be recommended is sent to the user to be recommended.
基于上述发明目的,本申请还提供一种基于遗传算法的资源信息推荐装置,包括:Based on the above-mentioned purpose of the invention, this application also provides a resource information recommendation device based on genetic algorithm, including:
获取模块,用于获取待推荐用户的数据信息;The obtaining module is used to obtain the data information of the user to be recommended;
确定模块,用于根据所述数据信息,确定所述待推荐用户适用的资源类 型;The determining module is configured to determine the type of resource applicable to the user to be recommended according to the data information;
选择模块,用于根据所述资源类型,确定与所述资源类型对应的各资源名称、以及与所述资源类型对应的适应度函数;The selection module is configured to determine, according to the resource type, each resource name corresponding to the resource type and a fitness function corresponding to the resource type;
更新模块,用于根据确定的适应度函数,更新预设的遗传算法模型;The update module is used to update the preset genetic algorithm model according to the determined fitness function;
计算模块,用于将所述各资源名称作为所述遗传算法模型的输入参数并运行所述遗传算法模型,得到待推荐资源名称;A calculation module, configured to use the name of each resource as an input parameter of the genetic algorithm model and run the genetic algorithm model to obtain the name of the resource to be recommended;
推荐模块,用于将所述待推荐资源名称对应的资源信息发送至待推荐用户。The recommendation module is used to send the resource information corresponding to the name of the resource to be recommended to the user to be recommended.
基于上述发明目的,本申请还提供一种终端,所述终端包括:存储器、处理器及存储在所述存储器上并可在所述处理器上运行的基于遗传算法的资源信息推荐程序,所述基于遗传算法的资源信息推荐程序配置为实现如上述的基于遗传算法的资源信息推荐方法的步骤。Based on the above-mentioned object of the invention, the present application also provides a terminal, the terminal including: a memory, a processor, and a genetic algorithm-based resource information recommendation program stored on the memory and running on the processor, the The genetic algorithm-based resource information recommendation program is configured to implement the steps of the above-mentioned genetic algorithm-based resource information recommendation method.
基于上述发明目的,本申请还提供一种存储介质,所述存储介质上存储有基于遗传算法的资源信息推荐程序,所述基于遗传算法的资源信息推荐程序被处理器执行时实现如上述的基于遗传算法的资源信息推荐方法的步骤。Based on the above-mentioned purpose of the invention, this application also provides a storage medium on which a genetic algorithm-based resource information recommendation program is stored. When the genetic algorithm-based resource information recommendation program is executed by a processor, the above-mentioned The steps of the genetic algorithm resource information recommendation method.
本发明通过获取待推荐用户的数据信息,再根据所述数据信息,确定所述待推荐用户适用的资源类型,根据所述资源类型,确定与所述资源类型对应的各资源名称、以及与所述资源类型对应的适应度函数,再根据确定的适应度函数,更新预设的遗传算法模型,再将所述各资源名称作为所述遗传算法模型的输入参数并运行所述遗传算法模型,得到待推荐资源名称,最后将所述待推荐资源名称对应的资源信息发送至待推荐用户,能快速确定适合用户的资源名称、推荐效果佳。The present invention obtains the data information of the user to be recommended, and then determines the resource type applicable to the user to be recommended according to the data information, and determines the name of each resource corresponding to the resource type according to the resource type and the corresponding resource type. According to the fitness function corresponding to the resource type, update the preset genetic algorithm model according to the determined fitness function, and then use the resource name as the input parameter of the genetic algorithm model and run the genetic algorithm model to obtain The resource name to be recommended, and finally the resource information corresponding to the resource name to be recommended is sent to the user to be recommended, the resource name suitable for the user can be quickly determined, and the recommendation effect is good.
附图说明Description of the drawings
图1是本申请实施例方案涉及的硬件运行环境的终端的结构示意图;FIG. 1 is a schematic structural diagram of a terminal of a hardware operating environment involved in a solution of an embodiment of the present application;
图2为本申请基于遗传算法的资源信息推荐方法第一实施例的流程示意图;2 is a schematic flowchart of a first embodiment of a method for recommending resource information based on genetic algorithms according to this application;
图3为本申请基于遗传算法的资源信息推荐方法第二实施例的流程示意图;3 is a schematic flowchart of a second embodiment of a method for recommending resource information based on genetic algorithms according to this application;
图4为本申请基于遗传算法的资源信息推荐方法第三实施例的流程示意图;4 is a schematic flowchart of a third embodiment of a method for recommending resource information based on genetic algorithms according to this application;
图5为本申请基于遗传算法的资源信息推荐方法第四实施例的流程示意图;FIG. 5 is a schematic flowchart of a fourth embodiment of a method for recommending resource information based on genetic algorithms according to this application;
图6为本申请基于遗传算法的资源信息推荐方法第五实施例的流程示意图;6 is a schematic flowchart of a fifth embodiment of a method for recommending resource information based on a genetic algorithm according to this application;
图7为本申请基于遗传算法的资源信息推荐装置第一实施例的结构框图。Fig. 7 is a structural block diagram of a first embodiment of a resource information recommendation device based on a genetic algorithm in this application.
具体实施方式Detailed ways
应当理解,此处所描述的具体实施例仅用以解释本申请,并不用于限定 本申请。It should be understood that the specific embodiments described herein are only used to explain the application, but not to limit the application.
参照图1,图1为本申请实施例方案涉及的硬件运行环境的终端结构示意图。Referring to FIG. 1, FIG. 1 is a schematic diagram of a terminal structure of a hardware operating environment involved in a solution of an embodiment of the application.
如图1所示,该终端可以包括:处理器1001,例如中央处理器(Central Processing Unit,CPU),通信总线1002、用户接口1003,网络接口1004,存储器1005。其中,通信总线1002用于实现这些组件之间的连接通信。用户接口1003可以包括显示屏(Display)、输入模块比如键盘(Keyboard),可选用户接口1003还可以包括标准的有线接口、无线接口。网络接口1004可选的可以包括标准的有线接口、无线接口(如无线保真(WIreless-FIdelity,WI-FI)接口)。存储器1005可以是高速的随机存取存储器(Random Access Memory,RAM)存储器,也可以是稳定的非易失性存储器(Non-Volatile Memory,NVM),例如磁盘存储器。存储器1005可选的还可以是独立于前述处理器1001的存储装置。As shown in FIG. 1, the terminal may include: a processor 1001, such as a central processing unit (CPU), a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. Among them, the communication bus 1002 is used to implement connection and communication between these components. The user interface 1003 may include a display screen (Display) and an input module such as a keyboard (Keyboard), and the optional user interface 1003 may also include a standard wired interface and a wireless interface. The network interface 1004 may optionally include a standard wired interface and a wireless interface (such as a wireless fidelity (WI-FI) interface). The memory 1005 may be a high-speed random access memory (Random Access Memory, RAM) memory, or a stable non-volatile memory (Non-Volatile Memory, NVM), such as a disk memory. Optionally, the memory 1005 may also be a storage device independent of the foregoing processor 1001.
本领域技术人员可以理解,图1中示出的结构并不构成对终端的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。Those skilled in the art can understand that the structure shown in FIG. 1 does not constitute a limitation on the terminal, and may include more or less components than shown in the figure, or combine some components, or arrange different components.
如图1所示,作为一种存储介质的存储器1005中可以包括操作系统、数据存储模块、网络通信模块、用户接口模块以及基于遗传算法的资源信息推荐程序。As shown in FIG. 1, the memory 1005 as a storage medium may include an operating system, a data storage module, a network communication module, a user interface module, and a resource information recommendation program based on genetic algorithms.
在图1所示的终端中,网络接口1004主要用于与网络服务器进行数据通信;用户接口1003主要用于与用户进行数据交互;本申请终端中的处理器1001、存储器1005可以设置在终端中,所述终端通过处理器1001调用存储器1005中存储的基于遗传算法的资源信息推荐程序,并执行本申请实施例提供的基于遗传算法的资源信息推荐方法。In the terminal shown in FIG. 1, the network interface 1004 is mainly used for data communication with a network server; the user interface 1003 is mainly used for data interaction with users; the processor 1001 and the memory 1005 in the terminal of this application can be set in the terminal The terminal calls the genetic algorithm-based resource information recommendation program stored in the memory 1005 through the processor 1001, and executes the genetic algorithm-based resource information recommendation method provided in the embodiment of the present application.
本申请实施例提供了一种基于遗传算法的资源信息推荐方法,参照图2,图2为本申请基于遗传算法的资源信息推荐方法第一实施例的流程示意图。The embodiment of the present application provides a method for recommending resource information based on a genetic algorithm. Referring to FIG. 2, FIG. 2 is a schematic flowchart of a first embodiment of the method for recommending resource information based on a genetic algorithm.
本实施例中,所述基于遗传算法的资源信息推荐方法包括如下步骤:In this embodiment, the resource information recommendation method based on genetic algorithm includes the following steps:
步骤S10:获取待推荐用户的数据信息;应该理解的是,本实施例方法的执行主体为终端,待推荐用户即资源业务员推荐资源名称的用户,待推荐用户的数据信息通常可以包括待推荐用户的年龄、公司、住址、子女等;还可以包括待推荐用户的家族信息、好友、是否携带遗传病或其他重大疾病等信息。Step S10: Obtain the data information of the user to be recommended; it should be understood that the subject of the method in this embodiment is the terminal, and the user to be recommended is the user whose resource name is recommended by the resource clerk. The data information of the user to be recommended can usually include The user’s age, company, address, children, etc.; it can also include family information, friends, whether to carry genetic diseases or other major diseases of the user to be recommended.
步骤S20:根据所述数据信息,确定所述待推荐用户适用的资源类型;Step S20: Determine the resource type applicable to the user to be recommended according to the data information;
应该理解的是,在本实施例中,资源类型包括返还型资源和消费型资源,在其他实施例中,也可以按照其他规则分类。其中资源可以为保险产品,下面以保险产品为例,返还型资源也称储蓄型资源,即被保险生存至约定年限后,保险公司有返还所交保费或者合同列明的保险使用转换值;消费型保险即一种消费型的保险,即用户(投保人)跟保险公司(保险人)签定合同,在约定时间内如发生合同约定的保险事故,保险公司按原先约定的额度进行 补偿或给付;如果在约定时间内未发生保险事故,保险公司不返还所交保费。It should be understood that, in this embodiment, the resource types include return-type resources and consumption-type resources. In other embodiments, they may also be classified according to other rules. The resources can be insurance products. Taking insurance products as an example below, return resources are also called savings resources, that is, after being insured to survive for the agreed period, the insurance company has to return the premiums paid or the insurance use conversion value specified in the contract; Type insurance is a type of consumer insurance, that is, the user (the applicant) signs a contract with the insurance company (the insurer). If an insurance accident occurs within the agreed time, the insurance company will compensate or pay according to the originally agreed amount ; If no insurance accident occurs within the agreed time, the insurance company will not refund the premium paid.
具体实现时,所述数据信息包括待推荐用户的年龄、收入、子女、事业情况、以及花钱习惯;所述资源类型包括返还型资源和消费型资源;相应地,所述根据所述数据信息,确定所述待推荐用户适用的资源类型的步骤,包括如下步骤:根据所述待推荐用户的年龄、收入、子女、事业情况、以及花钱习惯,确定所述待推荐用户的资源类型。In specific implementation, the data information includes the age, income, children, career status, and spending habits of the user to be recommended; the resource types include return-type resources and consumption-type resources; accordingly, the data information , The step of determining the resource type applicable to the user to be recommended includes the following steps: determining the resource type of the user to be recommended according to the age, income, children, career situation, and spending habits of the user to be recommended.
在本实施例中,根据所述数据信息,若确定所述待推荐用户属于年纪尚轻、收入丰厚、花钱大手大脚的人,这类用户通常适用于买返还型资源;若确定所述待推荐用户属于年纪尚轻、事业处于成长期、收入较低的人群,这类用户适用于买消费型。其中,所述数据信息可以包括待推荐用户的年龄、性别、事业发展和收入情况、生活习惯、子女等。In this embodiment, according to the data information, if it is determined that the user to be recommended is someone who is still young, has a good income, and spends a lot of money, this type of user is usually suitable for buying back resources; if it is determined that the user to be recommended Users belong to people who are still young, have a growing career, and have low incomes. This type of user is suitable for purchase and consumption. Wherein, the data information may include the age, gender, career development and income, life habits, children, etc. of the user to be recommended.
步骤S30:根据所述资源类型,确定与所述资源类型对应的各资源名称、以及与所述资源类型对应的适应度函数;应该理解的是,以保险产品为例,消费型资源通常包括消费型意外险、消费型医疗保险、消费型重疾险以及消费型寿险,具体可以根据资源公司的具体推出产品调整;返还型资源通常包括两全寿险、养老金、教育金资源等,具体可以根据资源公司的具体推出产品调整。Step S30: According to the resource type, determine each resource name corresponding to the resource type and the fitness function corresponding to the resource type; it should be understood that taking insurance products as an example, consumer resources usually include consumption Accident insurance, consumer medical insurance, consumer critical illness insurance, and consumer life insurance can be adjusted according to the specific products launched by the resource company; return-type resources usually include life insurance, pension, education funds, etc., which can be specifically based on Resource company's specific product launch adjustment.
具体实现时,以资源为保险产品为例,当资源类型为消费型资源时,与该消费型资源对应的保险产品有消费型意外险、消费型医疗保险、消费型重疾险以及消费型寿险等产品;而当资源类型为返还型资源时,与该返还型资源对应的保险产品保险有两全寿险、养老金、教育金保险等产品。In specific implementation, take the resource as an insurance product as an example. When the resource type is a consumer resource, the insurance products corresponding to the consumer resource include consumer accident insurance, consumer medical insurance, consumer critical illness insurance, and consumer life insurance When the resource type is a return-type resource, the insurance product insurance corresponding to the return-type resource includes life insurance, pension, education insurance and other products.
遗传算法(Genetic Algorithm)是模拟达尔文生物进化论的自然选择和遗传学机理的生物进化过程的计算模型,是一种通过模拟自然进化过程搜索最优解的方法。遗传算法是从代表问题可能潜在的解集的一个种群(population)开始的,而一个种群则由经过基因(gene)编码的一定数目的个体(individual)组成。每个个体实际上是染色体(chromosome)带有特征的实体。适应度函数是求解出最优解或次优解的保证,根据资源类型,确定于资源类型对应的适应度函数。Genetic Algorithm (Genetic Algorithm) is a computational model that simulates the biological evolution process of natural selection and genetic mechanism of Darwin's biological evolution theory, and is a method of searching for the optimal solution by simulating the natural evolution process. The genetic algorithm starts from a population that represents the possible potential solution set of the problem, and a population is composed of a certain number of individuals coded by genes. Each individual is actually an entity with chromosome characteristics. The fitness function is the guarantee for solving the optimal solution or the suboptimal solution. According to the resource type, the fitness function corresponding to the resource type is determined.
步骤S40:根据确定的适应度函数,更新预设的遗传算法模型;应该理解的是,不同的资源类型对应不同的适应度函数,对应地,不同的资源类型对应不同的遗传算法模型。Step S40: Update the preset genetic algorithm model according to the determined fitness function; it should be understood that different resource types correspond to different fitness functions, and correspondingly, different resource types correspond to different genetic algorithm models.
步骤S50:将所述各资源名称作为所述遗传算法模型的输入参数并运行所述遗传算法模型,得到待推荐资源名称;Step S50: Use the name of each resource as an input parameter of the genetic algorithm model and run the genetic algorithm model to obtain the name of the resource to be recommended;
应该理解的是,遗传算法的求解步骤如下:1)初始化种群;2)计算群体上每个个体的适应度值;3)按由个体适应度值所决定的某个规则选择将进入下一代的个体;4)按概率Pc进行交叉操作;5)按概率Pc进行突变操作;6)若没有满足某种停止条件,则转不转2),否则进入下一步;7)输出群体中适应度值最优的染色体作为问题的满意解或最优解。It should be understood that the solving steps of the genetic algorithm are as follows: 1) Initialize the population; 2) Calculate the fitness value of each individual in the population; 3) Select according to a certain rule determined by the individual fitness value to enter the next generation Individual; 4) Crossover operation according to probability Pc; 5) Mutation operation according to probability Pc; 6) If a certain stopping condition is not met, then switch to no switch 2), otherwise go to the next step; 7) Output the fitness value in the population The optimal chromosome is regarded as the satisfactory solution or optimal solution of the problem.
具体实现时,将确定的所述各资源名称作为所述遗传算法模型的输入参 数并运行所述遗传算法模型,得到待推荐资源名称,对各资源名称进行编码,可以采用常规的二进制编码,也可以针对每种资源名称制定对应的编号;初始化种群可以根据确定的资源名称以及资源名称的保费随机生成的初始染色体;再进行遗传运算(选择操作、交叉操作、变异操作),最后得到最优解,即最优的资源方案。In specific implementation, the determined resource names are used as the input parameters of the genetic algorithm model and the genetic algorithm model is run to obtain the names of the resources to be recommended. The names of the resources are coded. Conventional binary codes can be used, or The corresponding number can be formulated for each resource name; the initial population can be randomly generated initial chromosomes based on the determined resource name and the premium of the resource name; then genetic operations (selection operations, crossover operations, mutation operations) are performed, and the optimal solution is finally obtained , The optimal resource plan.
步骤S60:将所述待推荐资源名称对应的资源信息发送至待推荐用户。Step S60: Send the resource information corresponding to the name of the resource to be recommended to the user to be recommended.
应该理解的是,在本实施例中,将所述待推荐资源名称对应的资源信息发送至待推荐用户,在其他实施例中,也可以是将所述所述待推荐资源名称对应的资源信息发送至实施推荐资源的人员,例如业务员。It should be understood that, in this embodiment, the resource information corresponding to the resource name to be recommended is sent to the user to be recommended. In other embodiments, the resource information corresponding to the resource name to be recommended may also be Send to the person who implements the recommended resource, such as a salesperson.
本申请通过获取待推荐用户的数据信息,再根据所述数据信息,确定所述待推荐用户适用的资源类型,根据所述资源类型,确定与所述资源类型对应的各资源名称、以及与所述资源类型对应的适应度函数,再根据确定的适应度函数,更新预设的遗传算法模型,再将所述各资源名称作为所述遗传算法模型的输入参数并运行所述遗传算法模型,得到待推荐资源名称,最后将所述待推荐资源名称对应的资源信息发送至待推荐用户,能快速确定适合用户的资源名称、推荐效果佳。This application obtains the data information of the user to be recommended, and then determines the resource type applicable to the user to be recommended according to the data information, and determines the name of each resource corresponding to the resource type according to the resource type, and the name of each resource corresponding to the resource type. According to the fitness function corresponding to the resource type, update the preset genetic algorithm model according to the determined fitness function, and then use the resource name as the input parameter of the genetic algorithm model and run the genetic algorithm model to obtain The resource name to be recommended, and finally the resource information corresponding to the resource name to be recommended is sent to the user to be recommended, the resource name suitable for the user can be quickly determined, and the recommendation effect is good.
参考图3,图3为本申请基于遗传算法的资源信息推荐方法第二实施例的流程示意图。基于上述第一实施例,所述数据信息包括待推荐用户以及与其相关人员的信息;在本实施例中,所述步骤S20,包括:Referring to FIG. 3, FIG. 3 is a schematic flowchart of a second embodiment of a method for recommending resource information based on a genetic algorithm according to this application. Based on the above-mentioned first embodiment, the data information includes information about the user to be recommended and related persons; in this embodiment, the step S20 includes:
步骤S201:以所述数据信息中实体为节点,各实体之间的关系为边长,建立所述待推荐用户的知识图谱;应该理解的是,知识图谱(Knowledge Graph)就是把所有不同种类的信息(Heterogeneous Information)连接在一起而得到的一个关系网络。本实施例中,知识图谱的数据源可以是所述数据信息,还可以包括在网络上公开、抓取的数据。每个节点表示现实世界中存在的“实体”,每条边为实体与实体之间的“关系”。Step S201: Using the entities in the data information as nodes and the relationship between the entities as side lengths, the knowledge graph of the user to be recommended is established; it should be understood that the knowledge graph (Knowledge Graph) is to combine all different types of Information (Heterogeneous Information) is a relational network connected together. In this embodiment, the data source of the knowledge graph may be the data information, and may also include data published and captured on the Internet. Each node represents an "entity" that exists in the real world, and each edge is a "relationship" between an entity and an entity.
需要说明的是,与待推荐用户相关人员可以是亲属、朋友等;而待推荐用户以及与其相关人员的信息,可以是包括年龄、性别、子女、工作、疾病史等等。It should be noted that the people related to the user to be recommended may be relatives, friends, etc.; and the information of the user to be recommended and the related personnel may include age, gender, children, work, medical history, etc.
步骤S202:根据所述知识图谱,确定所述待推荐用户适用的资源类型。Step S202: Determine the resource type applicable to the user to be recommended according to the knowledge graph.
具体实现时,根据所述知识图谱,确定所述待推荐用户适用的资源类型,由于消费型资源考虑的是花钱买一个保障,一般较常见的是消费型重疾险,特别是对于家族有遗传病,重疾可能性较大的用户,通过预估用户重疾可能性,来判断用户是否更适用消费性重疾险。而预估用户重疾可能性可以通过计算知识图谱中得重疾的实体与用户实体的关联关系(通常是通过计算待推荐用户实体与知识图谱中携带重疾标记的实体之间的距离,来确定得重疾的实体与用户实体的关联关系),作为重疾指标(重疾命中率),当重疾指标达到预设阀值时,则确定待推荐用户适用消费型资源。在其他实施例中,也可以根据具体资源类型产品的特点,设定计算规则,例如还可以是通过知识图谱计算待推荐用户的固定资产实体(房产等)、子女教育等负担,综合考虑待 推荐用户的经济压力及经济条件,判断待推荐用户是否适用返还型资源。In specific implementation, the type of resources applicable to the user to be recommended is determined according to the knowledge graph. Since consumer resources consider spending money to buy a guarantee, the more common one is consumer critical illness insurance, especially for families Users with genetic diseases and serious illnesses are more likely to judge whether the user is more suitable for consumer critical illness insurance by estimating the possibility of the user's serious illness. The possibility of a user’s critical illness can be estimated by calculating the relationship between the entity suffering from a serious illness in the knowledge graph and the user entity (usually by calculating the distance between the user entity to be recommended and the entity carrying the critical illness mark in the knowledge graph. Determine the association relationship between the entity with a serious illness and the user entity) as a critical illness index (critical illness hit rate). When the critical illness index reaches a preset threshold, it is determined that the user to be recommended is suitable for consumption resources. In other embodiments, the calculation rules can also be set according to the characteristics of the specific resource type product. For example, it can also be used to calculate the fixed asset entity (real estate, etc.) and the education of children of the user to be recommended through the knowledge graph, and comprehensively consider the burden of the user to be recommended. The user’s economic pressure and economic conditions determine whether the user to be recommended is suitable for return-type resources.
参考图4,图4为本申请基于遗传算法的资源信息推荐方法第三实施例的流程示意图。Referring to FIG. 4, FIG. 4 is a schematic flowchart of a third embodiment of a method for recommending resource information based on a genetic algorithm in this application.
基于上述第二实施例,所述数据信息包括待推荐用户以及与其相关人员是否携带遗传病的信息;在本实施例中,所述步骤S202,包括:Based on the above second embodiment, the data information includes information about whether the user to be recommended and their related personnel carry genetic diseases; in this embodiment, the step S202 includes:
步骤S2021:计算所述知识图谱中携带有遗传病的实体与所述待推荐用户的边长,确定待推荐用户与携带有遗传病的实体的关联程度;应该理解的是,计算所述知识图谱中携带有遗传病的实体与所述待推荐用户的边长(通常两个实体之间的关系关联程度,用边长来表示),即计算携带遗传病的实体与待推荐用户的关联程度,以此判断待推荐用户患病的概率,特别是针对一些重大疾病。在其他实施例中,也可以是计算所述知识图谱中携带有重大疾病的实体与所述待推荐用户的关联程度。Step S2021: Calculate the side length between the entity carrying the genetic disease in the knowledge graph and the user to be recommended, and determine the degree of association between the user to be recommended and the entity carrying the genetic disease; it should be understood that the knowledge graph is calculated The side length between the entity carrying the genetic disease and the user to be recommended (usually the degree of association between the two entities is expressed by side length), that is, the degree of association between the entity carrying the genetic disease and the user to be recommended is calculated, In this way, the probability of the user to be recommended is judged, especially for some serious diseases. In other embodiments, the degree of association between the entity carrying a major disease in the knowledge graph and the user to be recommended may also be calculated.
步骤S2022:将关联程度计算结果,作为所述待推荐用户的遗传病命中率;Step S2022: Use the correlation degree calculation result as the genetic disease hit rate of the user to be recommended;
应该理解的是,将知识图谱中携带有遗传病的实体与待推荐用户的关联程度,作为待推荐用户患遗传病的可能性,并将该待推荐用户患遗传病的可能性作为所述待推荐用户的遗传病命中率。It should be understood that the degree of association between the entity carrying the genetic disease in the knowledge graph and the user to be recommended is taken as the probability of the user to be recommended suffering from the genetic disease, and the probability of the user to be recommended suffering from the genetic disease is taken as the Recommend users' genetic disease hit rate.
步骤S2023:根据所述遗传病命中率,确定所述待推荐用户适用的资源类型。具体实现时,当遗传病命中率达到预设阀值时,确定待推荐用户患遗传病的可能性较大,若该遗传病为大病,则待推荐用户更适用消费型资源。Step S2023: Determine the resource type applicable to the user to be recommended according to the genetic disease hit rate. In specific implementation, when the genetic disease hit rate reaches the preset threshold, it is determined that the user to be recommended is more likely to suffer from the genetic disease. If the genetic disease is a serious disease, the user to be recommended is more suitable for consumer resources.
参考图5,图5为本申请基于遗传算法的资源信息推荐方法第四实施例的流程示意图。基于上述第一实施例,所述资源类型为消费型资源;在本实施例中,所述步骤S10之前,还包括:Referring to FIG. 5, FIG. 5 is a schematic flowchart of a fourth embodiment of a method for recommending resource information based on a genetic algorithm in this application. Based on the foregoing first embodiment, the resource type is a consumer resource; in this embodiment, before step S10, it further includes:
步骤S01:建立遗传算法模型,其中,所述遗传算法模型的适应度函数为:Step S01: Establish a genetic algorithm model, where the fitness function of the genetic algorithm model is:
M
i为资源使用期望转换值(以保险产品为例,可以为保险金额),T
i为资源使用有效期限(以保险产品为例,可以为保险期限),N
i为资源获取转换值(以保险产品为例,可以为保险费用),X
i为资源数量,i=1,2,……,n,其中i为预设的资源数量,R
m为资源使用期望转换值的权值,R
t为资源使用有效期限的权值,R
i为风险保障的权值,R
mf为资源获取转换值的权值,I(x)为资源使用实际转换值(以保险产品为例,可以为补偿额度)。
M i is the expected conversion value of resource use (in the case of an insurance product, it can be the insurance amount), T i is the effective period of resource use (in the case of an insurance product, it can be the insurance period), and N i is the conversion value of the resource acquisition (take Example insurance products, insurance costs may be), X-i is the number of resources, i = 1,2, ......, n , where i desired using the weight conversion value of a predetermined amount of resources for the resource, R m, R t is the weight of the effective period of resource use, R i is the weight of the risk protection, R mf is the weight of the conversion value obtained by the resource, and I(x) is the actual conversion value of the resource use (taking insurance products as an example, it can be compensation Quota).
应该理解的是,遗传算法模型的适应度函数中各参数,通常是根据所述资源类型对应的资源名称确定的,例如消费型资源有消费型意外险,而消费型意外险对应的资源使用期望转换值、资源使用有效期限、资源获取转换值等可以是根据资源公司针对具体资源名称的具体规定而设置。It should be understood that the parameters in the fitness function of the genetic algorithm model are usually determined according to the resource name corresponding to the resource type. For example, consumption-type resources have consumption-type accident insurance, and consumption-type accident insurance corresponds to resource usage expectations The conversion value, the effective period of the resource use, the conversion value of the resource acquisition, etc. may be set according to the specific provisions of the resource company for the specific resource name.
参考图6,图6为本申请基于遗传算法的资源信息推荐方法第五实施例的流程示意图。基于上述第一实施例,所述资源类型为返还型资源;在本实施 例中,所述步骤S10之前,还包括:Referring to FIG. 6, FIG. 6 is a schematic flowchart of a fifth embodiment of a method for recommending resource information based on a genetic algorithm according to this application. Based on the foregoing first embodiment, the resource type is a return type resource; in this embodiment, before step S10, it further includes:
步骤S01':建立遗传算法模型,其中,所述遗传算法模型的适应度函数为:Step S01': Establish a genetic algorithm model, wherein the fitness function of the genetic algorithm model is:
其中,M'
i为资源使用期望转换值(以保险产品为例,可以为保险金额),T
i'为资源使用有效期限(以保险产品为例,可以为保险期限),N
i'为资源获取转换值(以保险产品为例,可以为保险费用),X
i'为资源数量,i=1,2,……,n,其中n为预设的资源数量,R
m'为资源使用期望转换值的权值,R
t'为资源使用有效期限的权值,R
i'为风险保障的权值,R
mf'为资源获取转换值的权值,I'(x)为资源使用实际转换值,Rs'为资源返还概率。
Among them, M'i is the expected conversion value of resource usage (in the case of an insurance product, it can be the insurance amount), T i 'is the effective period of resource usage (in the case of an insurance product, it can be the insurance period), and N i ' is the resource Get the conversion value (take insurance product as an example, it can be insurance cost), X i 'is the number of resources, i = 1, 2, ..., n, where n is the preset number of resources, R m ' is the expected use of resources The weight of the conversion value, R t 'is the weight of the effective period of resource use, R i ' is the weight of the risk protection, R mf 'is the weight of the resource to obtain the conversion value, I'(x) is the actual conversion of the resource use Value, Rs' is the probability of resource return.
应该理解的是,遗传算法模型的适应度函数中各参数,通常是根据所述资源类型对应的资源名称确定的,例如以资源为保险产品为例,返还型保险有教育金保险,而教育金保险对应的保险金额、保险期限、保险费用等可以是根据保险公司针对具体保险产品的具体规定而设置。而对于资源返还概率的确定在本实施例中可以采用如下方式:It should be understood that the various parameters in the fitness function of the genetic algorithm model are usually determined according to the resource name corresponding to the resource type. For example, taking resources as an insurance product as an example, the return type insurance includes education fund insurance, while education fund The insurance amount, insurance period, insurance cost, etc. corresponding to the insurance may be set according to the specific regulations of the insurance company for specific insurance products. The following methods can be used to determine the resource return probability in this embodiment:
所述数据信息包括待推荐用户的饮食习惯以及当前健康指数;相应地,所述根据所述资源类型,确定与所述资源类型对应的各资源名称、以及与所述资源类型对应的适应度函数的步骤之后,所述方法还包括如下步骤:The data information includes the eating habits and current health index of the user to be recommended; accordingly, the resource name corresponding to the resource type and the fitness function corresponding to the resource type are determined according to the resource type After the steps, the method further includes the following steps:
根据所述知识图谱中携带家族遗传病的实体与所述待推荐用户的关联程度、所述待推荐用户的饮食习惯、当前健康指数以及预设的寿命预测模型,确定所述待推荐用户的寿命预测值;应该理解的是,所述根据所述知识图谱中携带家族遗传病的实体与所述待推荐用户的关联程度、所述待推荐用户的饮食习惯、当前健康指数以及预设的寿命预测模型,确定所述待推荐用户的寿命预测值的步骤之前,还包括:建立寿命预测模型;其中,所述寿命预测模型可以为:Determine the lifespan of the user to be recommended according to the degree of association between the entity carrying the family genetic disease in the knowledge graph and the user to be recommended, the eating habits of the user to be recommended, current health index, and a preset lifespan prediction model Predicted value; it should be understood that the degree of association between the entity carrying family genetic diseases in the knowledge map and the user to be recommended, the eating habits of the user to be recommended, the current health index, and the preset life expectancy Model, before the step of determining the life prediction value of the user to be recommended, it further includes: establishing a life prediction model; wherein, the life prediction model may be:
其中,X表示携带家族遗传病的实体与所述待推荐用户的关联程度,Y表示待推荐用户的饮食习惯值(在本实施例中,素食主义者,Y取1,肉食主义者,Y取0.5),Z表示当前健康指数,λ1、λ2、λ3分别为X、Y、Z的权值。根据寿命预测值,确定各资源名称的所述资源返还概率。此外,本申请实施例还提出一种存储介质,所述存储介质上存储有基于遗传算法的资源信息推荐程序,所述基于遗传算法的资源信息推荐程序被处理器执行时实现如上文所述的基于遗传算法的资源信息推荐方法的步骤。Where X represents the degree of association between the entity carrying the family genetic disease and the user to be recommended, and Y represents the eating habit value of the user to be recommended (in this embodiment, vegetarian, Y is 1, carnivores, Y is 0.5), Z represents the current health index, λ1, λ2, and λ3 are the weights of X, Y, and Z respectively. According to the life prediction value, the resource return probability of each resource name is determined. In addition, an embodiment of the present application also proposes a storage medium that stores a genetic algorithm-based resource information recommendation program, and when the genetic algorithm-based resource information recommendation program is executed by a processor, the above-mentioned The steps of the method of resource information recommendation based on genetic algorithm.
参照图7,图7为本申请基于遗传算法的资源信息推荐装置第一实施例的结构框图。Referring to Fig. 7, Fig. 7 is a structural block diagram of a first embodiment of a resource information recommendation device based on a genetic algorithm in this application.
如图7所示,本申请实施例提出的基于遗传算法的资源信息推荐装置包括:获取模块701,用于获取待推荐用户的数据信息;As shown in FIG. 7, the genetic algorithm-based resource information recommendation device proposed in the embodiment of the present application includes: an acquisition module 701, configured to acquire data information of users to be recommended;
应该理解的是,待推荐用户即资源业务员推荐资源名称的用户,待推荐用户的数据信息通常可以包括待推荐用户的年龄、公司、住址、子女等;还可以包括待推荐用户的家族信息、好友等信息。It should be understood that the user to be recommended is the user whose resource clerk recommends the resource name. The data information of the user to be recommended can usually include the age, company, address, children, etc. of the user to be recommended; it can also include family information, Friends and other information.
确定模块702,用于根据所述数据信息,确定所述待推荐用户适用的资源类型;The determining module 702 is configured to determine the resource type applicable to the user to be recommended according to the data information;
应该理解的是,在本实施例中,资源类型包括返还型资源和消费型资源,在其他实施例中,也可以按照其他规则分类。其中资源可以为保险产品,下面以保险产品为例,返还型资源也称储蓄型资源,即被保险生存至约定年限后,保险公司有返还所交保费或者合同列明的保险使用转换值;消费型保险即一种消费型的保险,即用户(投保人)跟保险公司(保险人)签定合同,在约定时间内如发生合同约定的保险事故,保险公司按原先约定的额度进行补偿或给付;如果在约定时间内未发生保险事故,保险公司不返还所交保费。It should be understood that, in this embodiment, the resource types include return-type resources and consumption-type resources. In other embodiments, they may also be classified according to other rules. The resources can be insurance products. Taking insurance products as an example below, return resources are also called savings resources, that is, after being insured to survive for the agreed period, the insurance company has to return the premiums paid or the insurance use conversion value specified in the contract; Type insurance is a type of consumer insurance, that is, the user (the applicant) signs a contract with the insurance company (the insurer). If an insurance accident occurs within the agreed time, the insurance company will compensate or pay according to the originally agreed amount ; If no insurance accident occurs within the agreed time, the insurance company will not refund the premium paid.
具体实现时,所述数据信息包括待推荐用户的年龄、收入、子女、事业情况、以及花钱习惯;所述资源类型包括返还型资源和消费型资源;相应地,所述根据所述数据信息,确定所述待推荐用户适用的资源类型的步骤,包括如下步骤:根据所述待推荐用户的年龄、收入、子女、事业情况、以及花钱习惯,确定所述待推荐用户的资源类型。In specific implementation, the data information includes the age, income, children, career status, and spending habits of the user to be recommended; the resource types include return-type resources and consumption-type resources; accordingly, the data information , The step of determining the resource type applicable to the user to be recommended includes the following steps: determining the resource type of the user to be recommended according to the age, income, children, career situation, and spending habits of the user to be recommended.
在本实施例中,根据所述数据信息,若确定所述待推荐用户属于年纪尚轻、收入丰厚、花钱大手大脚的人,这类用户通常适用于买返还型资源;若确定所述待推荐用户属于年纪尚轻、事业处于成长期、收入较低的人群,这类用户适用于买消费型。其中,所述数据信息可以包括待推荐用户的年龄、性别、事业发展和收入情况、生活习惯、子女等。In this embodiment, according to the data information, if it is determined that the user to be recommended is someone who is still young, has a good income, and spends a lot of money, this type of user is usually suitable for buying back resources; if it is determined that the user to be recommended Users belong to people who are still young, have a growing career, and have low incomes. This type of user is suitable for purchase and consumption. Wherein, the data information may include the age, gender, career development and income, life habits, children, etc. of the user to be recommended.
选择模块703,用于根据所述资源类型,确定与所述资源类型对应的各资源名称、以及与所述资源类型对应的适应度函数;The selection module 703 is configured to determine each resource name corresponding to the resource type and the fitness function corresponding to the resource type according to the resource type;
应该理解的是,以保险产品为例,消费型资源通常包括消费型意外险、消费型医疗保险、消费型重疾险以及消费型寿险,具体可以根据资源公司的具体推出产品调整;返还型资源通常包括两全寿险、养老金、教育金资源等,具体可以根据资源公司的具体推出产品调整。It should be understood that, taking insurance products as an example, consumer resources usually include consumer accident insurance, consumer medical insurance, consumer critical illness insurance, and consumer life insurance, which can be adjusted according to the specific product launches of the resource company; return resources It usually includes life insurance, pension, education fund, etc., which can be adjusted according to the specific products launched by the resource company.
具体实现时,以资源为保险产品为例,当资源类型为消费型资源时,与该消费型资源对应的保险产品有消费型意外险、消费型医疗保险、消费型重疾险以及消费型寿险等产品;而当资源类型为返还型资源时,与该返还型保险对应的保险产品保险有两全寿险、养老金、教育金保险等产品。In specific implementation, take the resource as an insurance product as an example. When the resource type is a consumer resource, the insurance products corresponding to the consumer resource include consumer accident insurance, consumer medical insurance, consumer critical illness insurance, and consumer life insurance When the resource type is a return-type resource, the insurance product insurance corresponding to the return-type insurance includes life insurance, pension, education insurance and other products.
遗传算法(Genetic Algorithm)是模拟达尔文生物进化论的自然选择和遗传学机理的生物进化过程的计算模型,是一种通过模拟自然进化过程搜索最优解的方法。遗传算法是从代表问题可能潜在的解集的一个种群(population)开始的,而一个种群则由经过基因(gene)编码的一定数目的个体(individual)组成。每个个体实际上是染色体(chromosome)带有特征的实体。适应度函数是 求解出最优解或次优解的保证,根据资源类型,确定于资源类型对应的适应度函数。Genetic Algorithm (Genetic Algorithm) is a computational model that simulates the biological evolution process of natural selection and genetic mechanism of Darwin's biological evolution theory, and is a method of searching for the optimal solution by simulating the natural evolution process. The genetic algorithm starts from a population that represents the possible potential solution set of the problem, and a population is composed of a certain number of individuals coded by genes. Each individual is actually an entity with chromosome characteristics. The fitness function is the guarantee for solving the optimal or suboptimal solution. According to the resource type, the fitness function corresponding to the resource type is determined.
更新模块704,根据确定的适应度函数,更新预设的遗传算法模型;应该理解的是,不同的资源类型对应不同的适应度函数,对应地,不同的资源类型对应不同的遗传算法模型。计算模块705,用于将所述各资源名称作为所述遗传算法模型的输入参数并运行所述遗传算法模型,得到待推荐资源名称;遗传运算得到最优解,作为最优资源推荐方案。The update module 704 updates the preset genetic algorithm model according to the determined fitness function; it should be understood that different resource types correspond to different fitness functions, and correspondingly, different resource types correspond to different genetic algorithm models. The calculation module 705 is configured to use the name of each resource as an input parameter of the genetic algorithm model and run the genetic algorithm model to obtain the name of the resource to be recommended; the genetic operation obtains the optimal solution, which is used as the optimal resource recommendation plan.
应该理解的是,遗传算法的求解步骤如下:1)初始化种群;2)计算群体上每个个体的适应度值;3)按由个体适应度值所决定的某个规则选择将进入下一代的个体;4)按概率Pc进行交叉操作;5)按概率Pc进行突变操作;6)若没有满足某种停止条件,则转不转2),否则进入下一步;7)输出群体中适应度值最优的染色体作为问题的满意解或最优解。It should be understood that the solving steps of the genetic algorithm are as follows: 1) Initialize the population; 2) Calculate the fitness value of each individual in the population; 3) Select according to a certain rule determined by the individual fitness value to enter the next generation Individual; 4) Crossover operation according to probability Pc; 5) Mutation operation according to probability Pc; 6) If a certain stopping condition is not met, then switch to no switch 2), otherwise go to the next step; 7) Output the fitness value in the population The optimal chromosome is regarded as the satisfactory solution or optimal solution of the problem.
具体实现时,将确定的所述各资源名称作为所述遗传算法模型的输入参数并运行所述遗传算法模型,得到待推荐资源名称;对各资源名称进行编码,可以采用常规的二进制编码,也可以针对每种资源名称制定对应的编号;初始化种群可以根据确定的资源名称以及资源名称的保费随机生成的初始染色体;再进行遗传运算(选择操作、交叉操作、变异操作),最后得到最优解,即最优的资源名称方案。In specific implementation, the determined resource names are used as the input parameters of the genetic algorithm model and the genetic algorithm model is run to obtain the resource names to be recommended; the resource names can be coded using conventional binary codes or The corresponding number can be formulated for each resource name; the initial population can be randomly generated initial chromosomes based on the determined resource name and the premium of the resource name; then genetic operations (selection operations, crossover operations, mutation operations) are performed, and the optimal solution is finally obtained , The optimal resource name scheme.
推荐模块706,将所述待推荐资源名称对应的资源信息发送至待推荐用户。The recommendation module 706 sends the resource information corresponding to the name of the resource to be recommended to the user to be recommended.
应该理解的是,在本实施例中,将所述待推荐资源名称对应的资源信息发送至待推荐用户,在其他实施例中,也可以是将所述所述待推荐资源名称对应的资源信息发送至实施推荐资源的人员,例如业务员。It should be understood that, in this embodiment, the resource information corresponding to the resource name to be recommended is sent to the user to be recommended. In other embodiments, the resource information corresponding to the resource name to be recommended may also be Send to the person who implements the recommended resource, such as a salesperson.
本发明本申请通过获取待推荐用户的数据信息,再根据所述数据信息,确定所述待推荐用户适用的资源类型,根据所述资源类型,确定与所述资源类型对应的各资源名称、以及与所述资源类型对应的适应度函数,再根据确定的适应度函数,更新预设的遗传算法模型,再将所述各资源名称作为所述遗传算法模型的输入参数并运行所述遗传算法模型,得到待推荐资源名称,最后将所述待推荐资源名称对应的资源信息发送至待推荐用户,能快速确定适合用户的资源名称、推荐效果佳。The present application of the present invention obtains data information of the user to be recommended, and then determines the resource type applicable to the user to be recommended according to the data information, and determines the resource name corresponding to the resource type according to the resource type, and According to the fitness function corresponding to the resource type, update the preset genetic algorithm model according to the determined fitness function, and then use the resource name as the input parameter of the genetic algorithm model and run the genetic algorithm model , Obtain the name of the resource to be recommended, and finally send the resource information corresponding to the resource name to be recommended to the user to be recommended, which can quickly determine the resource name suitable for the user and the recommendation effect is good.
本发明基于遗传算法的资源信息推荐装置的其他实施例或具体实现方式可参照上述各方法实施例,此处不再赘述。For other embodiments or specific implementations of the device for recommending resource information based on the genetic algorithm of the present invention, reference may be made to the foregoing method embodiments, which will not be repeated here.
需要说明的是,在本文中,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者系统不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者系统所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括该要素的过 程、方法、物品或者系统中还存在另外的相同要素。It should be noted that in this article, the terms "include", "include" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or system including a series of elements not only includes those elements, It also includes other elements that are not explicitly listed, or elements inherent to the process, method, article, or system. If there are no more restrictions, the element defined by the sentence "including a..." does not exclude the existence of other identical elements in the process, method, article or system that includes the element.
上述本发明实施例序号仅仅为了描述,不代表实施例的优劣。The sequence numbers of the foregoing embodiments of the present invention are only for description, and do not represent the superiority of the embodiments.
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质(如只读存储器/随机存取存储器、磁碟、光盘)中,包括若干指令用以使得一台终端设备(可以是手机,计算机,服务器,空调器,或者网络设备等)执行本申请各个实施例所述的方法。其中,所述存储介质可以是非易失性可读存储介质,也可以是可读存储介质Through the description of the above embodiments, those skilled in the art can clearly understand that the method of the above embodiments can be implemented by means of software plus the necessary general hardware platform. Of course, it can also be implemented by hardware, but in many cases the former is better.的实施方式。 Based on this understanding, the technical solution of this application essentially or the part that contributes to the existing technology can be embodied in the form of a software product, and the computer software product is stored in a storage medium (such as read-only memory/random access The memory, magnetic disk, and optical disk) includes several instructions to make a terminal device (which can be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) execute the methods described in the various embodiments of the present application. Wherein, the storage medium may be a non-volatile readable storage medium or a readable storage medium
以上仅为本发明的优选实施例,并非因此限制本发明的专利范围,凡是利用本发明说明书及附图内容所作的等效结构或等效流程变换,或直接或间接运用在其他相关的技术领域,均同理包括在本发明的专利保护范围内。所述方法包括:S10、获取待推荐用户的数据信息;S20、根据所述数据信息,确定所述待推荐用户适用的资源类型;S30、根据所述资源类型,确定与所述资源类型对应的各资源名称、以及与所述资源类型对应的适应度函数;S40、根据确定的适应度函数,更新预设的遗传算法模型;S50、将所述各资源名称作为所述遗传算法模型的输入参数并运行所述遗传算法模型,得到待推荐资源名称;S60、将所述待推荐资源名称对应的资源信息发送至待推荐用户。The above are only the preferred embodiments of the present invention, and do not limit the scope of the present invention. Any equivalent structure or equivalent process transformation made by using the contents of the description and drawings of the present invention, or directly or indirectly applied to other related technical fields , The same reason is included in the scope of patent protection of the present invention. The method includes: S10, obtaining data information of the user to be recommended; S20, determining the resource type applicable to the user to be recommended according to the data information; S30, determining the resource type corresponding to the resource type according to the resource type The name of each resource and the fitness function corresponding to the resource type; S40, update the preset genetic algorithm model according to the determined fitness function; S50, use the name of each resource as an input parameter of the genetic algorithm model And run the genetic algorithm model to obtain the name of the resource to be recommended; S60. Send the resource information corresponding to the name of the resource to be recommended to the user to be recommended.