CN114969375A - Method and system for giving artificial intelligence learning to machine based on psychological knowledge - Google Patents

Method and system for giving artificial intelligence learning to machine based on psychological knowledge Download PDF

Info

Publication number
CN114969375A
CN114969375A CN202210652233.4A CN202210652233A CN114969375A CN 114969375 A CN114969375 A CN 114969375A CN 202210652233 A CN202210652233 A CN 202210652233A CN 114969375 A CN114969375 A CN 114969375A
Authority
CN
China
Prior art keywords
mental state
mental
data
information
psychological
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210652233.4A
Other languages
Chinese (zh)
Inventor
马世登
敬朝晖
胡文清
巫晓霞
郑君君
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Ironman Technology Co ltd
Neusoft Institute Guangdong
Institute of Psychology of CAS
Original Assignee
Beijing Ironman Technology Co ltd
Neusoft Institute Guangdong
Institute of Psychology of CAS
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Ironman Technology Co ltd, Neusoft Institute Guangdong, Institute of Psychology of CAS filed Critical Beijing Ironman Technology Co ltd
Priority to CN202210652233.4A priority Critical patent/CN114969375A/en
Publication of CN114969375A publication Critical patent/CN114969375A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/36Creation of semantic tools, e.g. ontology or thesauri
    • G06F16/367Ontology
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F17/00Digital computing or data processing equipment or methods, specially adapted for specific functions
    • G06F17/10Complex mathematical operations
    • G06F17/16Matrix or vector computation, e.g. matrix-matrix or matrix-vector multiplication, matrix factorization
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/279Recognition of textual entities
    • G06F40/289Phrasal analysis, e.g. finite state techniques or chunking
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N20/00Machine learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N5/00Computing arrangements using knowledge-based models
    • G06N5/02Knowledge representation; Symbolic representation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2218/00Aspects of pattern recognition specially adapted for signal processing
    • G06F2218/02Preprocessing
    • G06F2218/04Denoising
    • G06F2218/06Denoising by applying a scale-space analysis, e.g. using wavelet analysis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2218/00Aspects of pattern recognition specially adapted for signal processing
    • G06F2218/08Feature extraction
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2218/00Aspects of pattern recognition specially adapted for signal processing
    • G06F2218/12Classification; Matching

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Mathematical Physics (AREA)
  • Data Mining & Analysis (AREA)
  • Software Systems (AREA)
  • Computing Systems (AREA)
  • Computational Linguistics (AREA)
  • Artificial Intelligence (AREA)
  • Evolutionary Computation (AREA)
  • Computational Mathematics (AREA)
  • Mathematical Optimization (AREA)
  • Health & Medical Sciences (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Pure & Applied Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • Mathematical Analysis (AREA)
  • General Health & Medical Sciences (AREA)
  • Biomedical Technology (AREA)
  • Biophysics (AREA)
  • Molecular Biology (AREA)
  • Medical Informatics (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Animal Behavior & Ethology (AREA)
  • Algebra (AREA)
  • Measurement Of The Respiration, Hearing Ability, Form, And Blood Characteristics Of Living Organisms (AREA)

Abstract

本发明属于机器人工智能学习技术领域,公开了一种基于心理学知识赋予机器人工智能学习的方法及系统,本发明通过心理学知识图谱构建方法使得海量心理疾病数据可以得到有效的管理与利用,并可在该知识图谱的基础上开展知识搜索、智能问答等多个应用;针对缺少大量标注数据训练的深度学习模型,本发明使用ALBERT语言模型对心理疾病语料进行预训练,为深度学习模型带来了丰富的语义信息,可有效地提高实体识别的精度;同时,通过对用户心理状态进行评估方法消除了个体主观因素对数据收集的影响,有助于更加准确地进行心理健康状态评估。

Figure 202210652233

The invention belongs to the technical field of machine artificial intelligence learning, and discloses a method and system for giving machine artificial intelligence learning based on psychological knowledge. The invention enables the effective management and utilization of massive psychological disease data through the method of constructing a psychological knowledge map. Multiple applications such as knowledge search and intelligent question and answer can be carried out on the basis of the knowledge graph; for the deep learning model lacking a large amount of labeled data training, the present invention uses the ALBERT language model to pre-train the mental illness corpus, which is a useful tool for the deep learning model. The rich semantic information can effectively improve the accuracy of entity recognition; at the same time, the influence of individual subjective factors on data collection is eliminated by evaluating the user's mental state, which is helpful for more accurate mental health state evaluation.

Figure 202210652233

Description

一种基于心理学知识赋予机器人工智能学习的方法及系统A method and system for giving machine artificial intelligence learning based on psychological knowledge

技术领域technical field

本发明属于机器人工智能学习技术领域,尤其涉及一种基于心理学知识赋予机器人工智能学习的方法及系统。The invention belongs to the technical field of machine artificial intelligence learning, and in particular relates to a method and system for giving machine artificial intelligence learning based on psychological knowledge.

背景技术Background technique

机器是指由零部件组装成的装置,可以运转,用来代替人的劳动、作能量变换或产生有用功。机器一般由动力部分、传动部分、执行部分和控制部分组成。从能量角度定义,机器为利用或转换机械能的装置,将其他形式的能量转换为机械能的称原动机,如内燃机、蒸汽机,电动机等,利用机械能来完成有用功的称工作机,如各种机床、起重机、压缩机等。随着科学技术的发展,机器的概念也在不断地更新和变化。然而,现有基于心理学知识赋予机器人工智能学习的方法采用的心理疾病数据标注成本高,缺少大量标注数据训练的神经网络往往识别精度不高;心理疾病知识图谱属于专业领域知识图谱,要求知识质量更高,现有的实体识别算法由于缺乏先验知识的指导,在抽取复杂实体时难免会出错,需要专业人员进行二次纠正,耗费人力物力;同时,对心理健康状态评估不准确。A machine refers to a device assembled from parts, which can run and be used to replace human labor, transform energy or generate useful work. The machine is generally composed of power part, transmission part, execution part and control part. Defined from the perspective of energy, a machine is a device that utilizes or converts mechanical energy. It is called a prime mover that converts other forms of energy into mechanical energy, such as an internal combustion engine, a steam engine, an electric motor, etc., and a machine that uses mechanical energy to complete useful work is called a working machine, such as various machine tools. , cranes, compressors, etc. With the development of science and technology, the concept of machines is constantly updated and changed. However, the mental illness data labeling cost is high in the existing methods of giving machine artificial intelligence learning based on psychological knowledge, and neural networks that lack a large amount of labelled data training often have low recognition accuracy; the mental illness knowledge graph belongs to the professional domain knowledge graph, which requires knowledge The quality is higher. Due to the lack of guidance of prior knowledge, the existing entity recognition algorithms will inevitably make mistakes when extracting complex entities, requiring professionals to make secondary corrections, which consumes manpower and material resources; at the same time, the assessment of mental health status is inaccurate.

综上所述,现有技术存在的问题是:现有基于心理学知识赋予机器人工智能学习的方法采用的心理疾病数据标注成本高,缺少大量标注数据训练的神经网络往往识别精度不高;心理疾病知识图谱属于专业领域知识图谱,要求知识质量更高,现有的实体识别算法由于缺乏先验知识的指导,在抽取复杂实体时难免会出错,需要专业人员进行二次纠正,耗费人力物力;同时,对心理健康状态评估不准确。To sum up, the problems existing in the existing technology are: the mental illness data labeling cost used by the existing methods based on psychological knowledge to give machine artificial intelligence learning is high, and the neural network lacking a large amount of labeling data training often has low recognition accuracy; The disease knowledge map belongs to the knowledge map of the professional field, which requires higher quality of knowledge. Due to the lack of guidance of prior knowledge, the existing entity recognition algorithm will inevitably make mistakes when extracting complex entities, which requires professionals to make secondary corrections, which consumes manpower and material resources; At the same time, the assessment of mental health status is inaccurate.

发明内容SUMMARY OF THE INVENTION

针对现有技术存在的问题,本发明提供了一种基于心理学知识赋予机器人工智能学习的方法及系统。In view of the problems existing in the prior art, the present invention provides a method and system for imparting artificial intelligence learning to a machine based on psychological knowledge.

本发明是这样实现的,一种基于心理学知识赋予机器人工智能学习的方法包括以下步骤:The present invention is implemented in this way, a method for giving machine artificial intelligence learning based on psychological knowledge includes the following steps:

步骤一,获取监控对象的基本信息、情绪信息以及位置信息;其中,所述基本信息至少包括所述监控对象的姓名与头像画面;Step 1: Obtain the basic information, emotional information and location information of the monitoring object; wherein, the basic information includes at least the name and avatar picture of the monitoring object;

步骤二,以所述位置信息为依据,匹配相应的场景关联事件;以预设的心理状态分析模型对所述基本信息、所述情绪信息、所述位置信息、所述场景关联事件进行分析,得到所述监控对象的心理状态;并建立心理状态文档库;Step 2, matching the corresponding scene-related events based on the location information; analyzing the basic information, the emotional information, the location information, and the scene-related events with a preset mental state analysis model, Obtain the psychological state of the monitoring object; and establish a psychological state document library;

步骤三,对心理状态文档库中的文档进行分词和智能摘要预处理,得到关键词,对得到的关键词进行相关性分析,处理上述步骤提供的值,计算得出关键词针对该篇文档的关键度分值,得到带有赋值的关键词;Step 3: Perform word segmentation and intelligent abstract preprocessing on the documents in the mental state document library to obtain keywords, perform correlation analysis on the obtained keywords, process the values provided in the above steps, and calculate the value of the keywords for the document. Criticality score, get keywords with assignments;

步骤四,按照心理学知识图谱对用户性格分析得用户性格倾向值,并对用户心理状态进行评估;Step 4, analyze the user's personality according to the psychological knowledge map to obtain the user's personality tendency value, and evaluate the user's psychological state;

步骤五,将得到的性格倾向值与得到的关键词关键度分值匹配,得到带有性格倾向属性的文档库;用户发起访问请求时,所述带有性格倾向属性的文档库给出带有性格倾向属性的文档。Step 5: Match the obtained character tendency value with the obtained keyword criticality score to obtain a document library with a character tendency attribute; when the user initiates an access request, the document library with the character tendency attribute provides a document library with a character tendency attribute. Documentation of Personality Attributes.

进一步,在步骤二中,心理状态分析模型包括:Further, in step 2, the mental state analysis model includes:

第一步,利用小波包变换在时频域分解心理状态信号,提取心理状态波的心理状态变化规律;The first step is to use the wavelet packet transform to decompose the mental state signal in the time-frequency domain, and extract the mental state change law of the mental state wave;

第二步,采用一对一策略将公共空间模式从两类模式扩展到多类模式,利用一对一公共空间模式对心理状态变化规律心理状态提取特征向量;In the second step, the one-to-one strategy is used to expand the public space model from two types of models to multiple types of models, and the one-to-one public space model is used to extract the feature vector of the mental state of the mental state change law;

第三步,根据特征值的分布特点对特征向量的维数进行选择;The third step is to select the dimension of the eigenvectors according to the distribution characteristics of the eigenvalues;

所述用于心理状态信号情感分析的改进公共空间模式特征提取方法对原始心理状态信号提取心理状态变化规律心理状态,包括:采用小波包变换在时频域对心理状态信号进行分解,将心理状态变化频段对应的若干子带的节点系数进行组合重构,从而提取出与原始心理状态信号形式一致的心理状态变化规律心理状态信号;The improved public space pattern feature extraction method for mental state signal sentiment analysis extracts the mental state of the original mental state signal, the mental state changing law, including: using wavelet packet transform to decompose the mental state signal in the time-frequency domain, and decompose the mental state The node coefficients of several sub-bands corresponding to the changing frequency band are combined and reconstructed, so as to extract the mental state signal of the mental state change law consistent with the original mental state signal;

所述用于心理状态信号情感分析的改进公共空间模式特征提取方法基于公共空间模式对心理状态变化规律心理状态区域数据提取特征向量,具体包括:设情绪心理状态的类别个数为n,则针对n类情绪识别问题,采用一对一方法对传统的两类公共空间模式进行扩展。The improved public space pattern feature extraction method for mental state signal sentiment analysis is based on the public space pattern to extract feature vectors from mental state region data of mental state change laws, specifically including: assuming that the number of categories of emotional mental states is n, then for For the n-type emotion recognition problem, a one-to-one approach is used to extend the traditional two types of public space patterns.

一对一公共空间模式算法的步骤为:The steps of the one-to-one common space pattern algorithm are:

(1)用Ei来表示心理状态变化规律情绪心理状态区域数据,i指第i类(i=1,2,...,n);矩阵Ei的大小为N*T,其中N为记录心理状态信号所使用的通道数,T为在每个通道上采集的区域点数目,满足约束条件N≤T;分别对每个区域数据计算归一化协方差矩阵,记为Ri(1) Use E i to represent the mental state change law emotional and mental state area data, i refers to the i-th type (i=1,2,...,n); the size of the matrix E i is N*T, where N is The number of channels used to record the mental state signal, T is the number of regional points collected on each channel, and the constraint condition N≤T is satisfied; the normalized covariance matrix is calculated for each regional data, denoted as R i :

Figure BDA0003688145730000031
Figure BDA0003688145730000031

式中,trace(X)表示对角矩阵X的迹;In the formula, trace(X) represents the trace of the diagonal matrix X;

然后对每一类所有区域数据的归一化协方差矩阵求平均值作为该类数据的平均归一化空间协方差矩阵

Figure BDA0003688145730000032
则任意两类区域数据的混合空间协方差矩阵R为:Then the normalized covariance matrix of all regional data of each class is averaged as the average normalized spatial covariance matrix of this class of data
Figure BDA0003688145730000032
Then the mixed spatial covariance matrix R of any two types of regional data is:

Figure BDA0003688145730000033
Figure BDA0003688145730000033

(2)首先对R进行主分量分解:(2) First perform principal component decomposition on R:

R=UVUTR= UVUT ;

其中V为特征值对角矩阵,U为由与V中特征值相对应的特征向量构成的特征向量矩阵;Wherein V is the eigenvalue diagonal matrix, and U is the eigenvector matrix composed of the eigenvectors corresponding to the eigenvalues in V;

然后对特征值按降序排序,并对特征向量的排列顺序做相应的调整,得到新的V和U;定义白化矩阵P为:Then sort the eigenvalues in descending order, and adjust the arrangement order of the eigenvectors accordingly to obtain new V and U; define the whitening matrix P as:

Figure BDA0003688145730000034
Figure BDA0003688145730000034

(3)首先用白化矩阵P对

Figure BDA0003688145730000041
Figure BDA0003688145730000042
进行白化变换:(3) First use the whitening matrix P to
Figure BDA0003688145730000041
and
Figure BDA0003688145730000042
Perform a whitening transformation:

Figure BDA0003688145730000043
Figure BDA0003688145730000043

Figure BDA0003688145730000044
Figure BDA0003688145730000044

然后对S1和S2进行主分量分解:Then do principal component decomposition for S1 and S2 :

Figure BDA0003688145730000045
Figure BDA0003688145730000045

Figure BDA0003688145730000046
Figure BDA0003688145730000046

对S1和S2做主分量分解得到的两个特征向量矩阵是相等的,即U1=U2=B;两个特征值对角矩阵之和为单位矩阵,即V1+V2=I;The two eigenvector matrices obtained by decomposing S 1 and S 2 are equal, namely U 1 =U 2 =B; the sum of the two eigenvalue diagonal matrices is the identity matrix, namely V 1 +V 2 =I ;

将V1中的特征值按照降序排列,则V2中的特征值就是按照升序排列的;定义投影矩阵W为:Arrange the eigenvalues in V 1 in descending order, then the eigenvalues in V 2 are in ascending order; define the projection matrix W as:

W=BTP;W= BTP ;

对任意两类区域数据都计算一个投影矩阵Wj(j=1,2,...,n(n-1)/2),并将得到的所有投影矩阵纵向拼接,构建一个n类空间滤波器SF;Calculate a projection matrix W j (j=1,2,...,n(n-1)/2) for any two types of regional data, and splicing all the obtained projection matrices vertically to construct an n-type spatial filter device SF;

(4)对每个区域数据Ei使用SF进行滤波:(4) Use SF to filter each region data E i :

Zi=SFEi;i=1,2,...n;Z i =SFE i ; i=1,2,...n;

得到的Zi表示单个区域的模式特征矩阵,其中一行表示一个通道上的特征分布情况;取每个通道特征向量的方差作为提取的心理状态信号特征,再对特征值进行对数运算,特征向量如下式所示:The obtained Z i represents the pattern feature matrix of a single area, and one row represents the feature distribution on a channel; the variance of each channel feature vector is taken as the extracted mental state signal feature, and then the logarithmic operation is performed on the feature value, and the feature vector As shown in the following formula:

fi=log(var(Zi));i=1,2,...n。f i =log(var(Z i )); i=1,2,...n.

进一步,所述心理学知识图谱构建方法如下:Further, the method for constructing the psychological knowledge graph is as follows:

(1)采集与患者心理疾病病情相关的数据;对所述采集的数据进行分析,建立心理疾病语料集;根据所述心理疾病语料集,确定实体、关系以及属性指示词表;(1) collect data related to the patient's mental illness condition; analyze the collected data to establish a mental illness corpus; determine an entity, relationship and attribute indicator vocabulary according to the mental illness corpus;

(2)利用语言模型对所述心理疾病语料集中的数据进行微调,构建心理疾病命名实体识别数据集,提取所述命名实体识别数据集的特征值,将微调后的数据和提取的特征进行融合,利用融合后的数据对预先构建的深度学习模型进行训练;(2) Using the language model to fine-tune the data in the mental illness corpus, construct a mental illness named entity recognition dataset, extract the feature values of the named entity recognition dataset, and fuse the fine-tuned data and the extracted features , using the fused data to train the pre-built deep learning model;

(3)利用训练后的深度学习模型对待处理的心理疾病语料进行预测,将预测得到的实体类别索引序列转换为实体类型序列,并将各实体词存入实体词表,并依据关系类型以及属性类型,分别抽取实体关系和属性数据,进行分别存储。(3) Use the trained deep learning model to predict the mental illness corpus to be processed, convert the predicted entity category index sequence into an entity type sequence, and store each entity word in the entity vocabulary, and according to the relationship type and attribute Type, extract entity relationship and attribute data respectively, and store them separately.

进一步,所述获取心理疾病相关已有信息,建立心理疾病语料集的具体过程包括:根据心理疾病相关书籍设置心理疾病术语种子词集;根据心理疾病术语种子集,遍历搜索医疗网站中的相关内容,记录相关网页url,存为url集合;对url集合使用爬虫技术进行网页内容的爬取;对爬取的网页内容采用正则表达式、xpath解析器进行内容提取,对于非结构化数据存储至数据库中,对于半结构化数据,直接抽取出三元组进行存储,不同的关系类型、不同的属性类型进行区分存储;对已经处理好的语料进行至少一部分的标注。Further, the specific process of obtaining existing information related to mental illness and establishing a mental illness corpus includes: setting a mental illness term seed word set according to a book related to mental illness; traversing and searching related content in a medical website according to the mental illness term seed set , record the url of the relevant webpage and save it as a url collection; use crawler technology to crawl the content of the url collection; use regular expressions and xpath parser to extract the content of the crawled webpage, and store the unstructured data in the database For semi-structured data, triples are directly extracted for storage, and different relation types and attribute types are stored separately; at least part of the processed corpus is annotated.

进一步,所述对用户心理状态进行评估方法如下:Further, the described method for evaluating the user's psychological state is as follows:

1),获取网络用户的所有上网行为,分别为每种类型的上网行为设置对应的节点;通过边连接与网络用户触发的两个相邻上网行为相对应的两个节点,并根据两个相邻上网行为之间的交互总次数为两个节点之间的边设置权重值;基于各个节点以及各个节点之间的具有权重值的边,建立与网络用户相对应的个体上网行为网络,并获取个体网络行为特征;1), obtain all online behaviors of network users, and set corresponding nodes for each type of online behavior; connect two nodes corresponding to two adjacent online behaviors triggered by network users through edges, and according to the two The total number of interactions between neighboring online behaviors sets the weight value for the edge between the two nodes; based on each node and the edge with the weight value between each node, establishes an individual online behavior network corresponding to the network user, and obtains Individual network behavior characteristics;

2),利用机器学习的方法,基于已知区域中个体网络行为特征和人口统计学特征,建立和训练基于网络行为特征的心理状态评估模型;2), use the method of machine learning to establish and train a mental state assessment model based on network behavior characteristics based on individual network behavior characteristics and demographic characteristics in known areas;

3),获取新个体的网络行为特征和人口统计学特征,根据所述的基于网络行为特征的心理状态评估模型,得到该新个体的心理状况;3), obtain the network behavior characteristics and demographic characteristics of the new individual, and obtain the psychological state of the new individual according to the described mental state assessment model based on the network behavior characteristics;

其中:所述网络行为特征是反映个体所使用的网络媒介/服务工具的功能结果和使用路径的特征集合;所述网络行为特征从记录个体的网络日志中提取;以及所述网络行为特征包括个体的网络信息和时间序列数据,所述个体的网络信息包括:时间信息、各类即时通讯工具信息、邮件信息、所访问网页类别的信息和搜索信息;所述时间序列数据包括:每天的上网时间信息、每天的网络请求个数信息和每天的网页信息;所述时间信息包括:工作日平均每日上网时长和周末平均每日上网时长;所述邮件信息包括是否用客户端收发邮件。Wherein: the network behavior feature is a feature set that reflects the functional results and usage paths of the network media/service tools used by the individual; the network behavior feature is extracted from the network log of the individual; and the network behavior feature includes the individual The network information and time series data of the individual, the individual network information includes: time information, information of various instant messaging tools, mail information, information of visited webpage categories and search information; the time series data includes: daily online time information, information on the number of network requests per day, and information on daily web pages; the time information includes: the average daily Internet access time on weekdays and the average daily Internet access time on weekends; the email information includes whether to use the client to send and receive emails.

本发明另一目的在于提供一种实施所述基于心理学知识赋予机器人工智能学习的方法的基于心理学知识赋予机器人工智能学习系统。Another object of the present invention is to provide an artificial intelligence learning system based on psychological knowledge that implements the method for assigning artificial intelligence to machines based on psychological knowledge.

本发明另一目的在于提供一种计算机设备,所述计算机设备包括存储器和处理器,所述存储器存储有计算机程序,所述计算机程序被所述处理器执行时,使得所述处理器执行所述基于心理学知识赋予机器人工智能学习的方法步骤。Another object of the present invention is to provide a computer device, the computer device includes a memory and a processor, the memory stores a computer program, and when the computer program is executed by the processor, the processor causes the processor to execute the The method steps of giving machine artificial intelligence learning based on psychological knowledge.

本发明另一目的在于提供一种计算机可读存储介质,存储有计算机程序,所述计算机程序被处理器执行时,使得所述处理器执行所述基于心理学知识赋予机器人工智能学习的方法。Another object of the present invention is to provide a computer-readable storage medium storing a computer program, which, when executed by a processor, causes the processor to execute the method for imparting artificial intelligence learning to a machine based on psychological knowledge.

本发明另一目的在于提供一种信息数据处理终端,所述信息数据处理终端用于实现所述基于心理学知识赋予机器人工智能学习的方法。Another object of the present invention is to provide an information data processing terminal, the information data processing terminal is used to implement the method for imparting artificial intelligence learning to a machine based on psychological knowledge.

本发明的优点及积极效果为:本发明通过心理学知识图谱构建方法使得海量心理疾病数据可以得到有效的管理与利用,并可在该知识图谱的基础上开展知识搜索、智能问答等多个应用;针对缺少大量标注数据训练的深度学习模型,本发明使用ALBERT语言模型对心理疾病语料进行预训练,为深度学习模型带来了丰富的语义信息,可有效地提高实体识别的精度;同时,通过对用户心理状态进行评估方法消除了个体主观因素对数据收集的影响,有助于更加准确地进行心理健康状态评估。The advantages and positive effects of the present invention are as follows: the present invention can effectively manage and utilize massive psychological disease data through the method of constructing a psychological knowledge graph, and can carry out multiple applications such as knowledge search and intelligent question and answer on the basis of the knowledge graph. ; For the deep learning model lacking a large amount of labeled data training, the present invention uses the ALBERT language model to pre-train the mental illness corpus, which brings rich semantic information to the deep learning model, which can effectively improve the accuracy of entity recognition; The method of evaluating the user's mental state eliminates the influence of individual subjective factors on data collection, which is helpful for more accurate evaluation of mental health state.

心理状态分析模型包括:利用小波包变换在时频域分解心理状态信号,提取心理状态波的心理状态变化规律;采用一对一策略将公共空间模式从两类模式扩展到多类模式,利用一对一公共空间模式对心理状态变化规律心理状态提取特征向量;根据特征值的分布特点对特征向量的维数进行选择;可获得准确的数据。The mental state analysis model includes: using the wavelet packet transform to decompose the mental state signal in the time-frequency domain, and extracting the mental state change law of the mental state wave; using a one-to-one strategy to expand the public space mode from two types of Extract eigenvectors from a public space pattern to the mental state changing law; select the dimension of the eigenvectors according to the distribution characteristics of the eigenvalues; obtain accurate data.

附图说明Description of drawings

图1是本发明实施提供的基于心理学知识赋予机器人工智能学习的方法流程图。FIG. 1 is a flowchart of a method for imparting artificial intelligence learning to a machine based on psychological knowledge provided by the implementation of the present invention.

图2是本发明实施提供的心理学知识图谱构建方法流程图。FIG. 2 is a flowchart of a method for constructing a psychological knowledge graph provided by the implementation of the present invention.

图3是本发明实施提供的对用户心理状态进行评估方法流程图。FIG. 3 is a flowchart of a method for evaluating a user's psychological state provided by the implementation of the present invention.

具体实施方式Detailed ways

为了使本发明的目的、技术方案及优点更加清楚明白,以下结合实施例,对本发明进行进一步详细说明。应当理解,此处所描述的具体实施例仅仅用以解释本发明,并不用于限定本发明。In order to make the objectives, technical solutions and advantages of the present invention clearer, the present invention will be further described in detail below with reference to the embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention, but not to limit the present invention.

下面结合附图对本发明的应用原理作进一步描述。The application principle of the present invention will be further described below in conjunction with the accompanying drawings.

如图1所示,本发明提供一种基于心理学知识赋予机器人工智能学习的方法包括以下步骤:As shown in Figure 1, the present invention provides a method for giving machine artificial intelligence learning based on psychological knowledge, comprising the following steps:

S101,获取监控对象的基本信息、情绪信息以及位置信息;其中,所述基本信息至少包括所述监控对象的姓名与头像画面;S101, acquiring basic information, emotional information, and location information of a monitoring object; wherein, the basic information includes at least the name and avatar picture of the monitoring object;

S102,以所述位置信息为依据,匹配相应的场景关联事件;以预设的心理状态分析模型对所述基本信息、所述情绪信息、所述位置信息、所述场景关联事件进行分析,得到所述监控对象的心理状态;并建立心理状态文档库;S102, match the corresponding scene-related events based on the location information; analyze the basic information, the emotional information, the location information, and the scene-related events with a preset mental state analysis model, and obtain the psychological state of the monitoring object; and establish a psychological state document library;

S103,对心理状态文档库中的文档进行分词和智能摘要预处理,得到关键词,对得到的关键词进行相关性分析,处理上述步骤提供的值,计算得出关键词针对该篇文档的关键度分值,得到带有赋值的关键词;S103: Perform word segmentation and intelligent abstract preprocessing on the documents in the mental state document library to obtain keywords, perform correlation analysis on the obtained keywords, process the values provided in the above steps, and calculate the key words of the keywords for the document. Degree scores, get keywords with assignments;

S104,按照心理学知识图谱对用户性格分析得用户性格倾向值,并对用户心理状态进行评估;S104, analyze the user's personality according to the psychological knowledge map to obtain the user's personality tendency value, and evaluate the user's psychological state;

S105,将得到的性格倾向值与得到的关键词关键度分值匹配,得到带有性格倾向属性的文档库;用户发起访问请求时,所述带有性格倾向属性的文档库给出带有性格倾向属性的文档。S105, match the obtained character tendency value with the obtained keyword criticality score to obtain a document library with a character tendency attribute; when the user initiates an access request, the document library with the character tendency attribute provides a document library with a character tendency attribute Documentation of the propensity attribute.

在步骤S102中,心理状态分析模型包括:In step S102, the mental state analysis model includes:

第一步,利用小波包变换在时频域分解心理状态信号,提取心理状态波的心理状态变化规律;The first step is to use the wavelet packet transform to decompose the mental state signal in the time-frequency domain, and extract the mental state change law of the mental state wave;

第二步,采用一对一策略将公共空间模式从两类模式扩展到多类模式,利用一对一公共空间模式对心理状态变化规律心理状态提取特征向量;In the second step, the one-to-one strategy is used to expand the public space model from two types of models to multiple types of models, and the one-to-one public space model is used to extract the feature vector of the mental state of the mental state change law;

第三步,根据特征值的分布特点对特征向量的维数进行选择;The third step is to select the dimension of the eigenvectors according to the distribution characteristics of the eigenvalues;

所述用于心理状态信号情感分析的改进公共空间模式特征提取方法对原始心理状态信号提取心理状态变化规律心理状态,包括:采用小波包变换在时频域对心理状态信号进行分解,将心理状态变化频段对应的若干子带的节点系数进行组合重构,从而提取出与原始心理状态信号形式一致的心理状态变化规律心理状态信号;The improved public space pattern feature extraction method for mental state signal sentiment analysis extracts the mental state of the original mental state signal, the mental state changing law, including: using wavelet packet transform to decompose the mental state signal in the time-frequency domain, and decompose the mental state The node coefficients of several sub-bands corresponding to the changing frequency band are combined and reconstructed, so as to extract the mental state signal of the mental state change law consistent with the original mental state signal;

所述用于心理状态信号情感分析的改进公共空间模式特征提取方法基于公共空间模式对心理状态变化规律心理状态区域数据提取特征向量,具体包括:设情绪心理状态的类别个数为n,则针对n类情绪识别问题,采用一对一方法对传统的两类公共空间模式进行扩展。The improved public space pattern feature extraction method for mental state signal sentiment analysis is based on the public space pattern to extract feature vectors from mental state region data of mental state change laws, specifically including: assuming that the number of categories of emotional mental states is n, then for For the n-type emotion recognition problem, a one-to-one approach is used to extend the traditional two types of public space patterns.

一对一公共空间模式算法的步骤为:The steps of the one-to-one common space pattern algorithm are:

(1)用Ei来表示心理状态变化规律情绪心理状态区域数据,i指第i类(i=1,2,...,n);矩阵Ei的大小为N*T,其中N为记录心理状态信号所使用的通道数,T为在每个通道上采集的区域点数目,满足约束条件N≤T;分别对每个区域数据计算归一化协方差矩阵,记为Ri(1) Use E i to represent the mental state change law emotional and mental state area data, i refers to the i-th type (i=1,2,...,n); the size of the matrix E i is N*T, where N is The number of channels used to record the mental state signal, T is the number of regional points collected on each channel, and the constraint condition N≤T is satisfied; the normalized covariance matrix is calculated for each regional data, denoted as R i :

Figure BDA0003688145730000081
Figure BDA0003688145730000081

式中,trace(X)表示对角矩阵X的迹;In the formula, trace(X) represents the trace of the diagonal matrix X;

然后对每一类所有区域数据的归一化协方差矩阵求平均值作为该类数据的平均归一化空间协方差矩阵

Figure BDA0003688145730000082
则任意两类区域数据的混合空间协方差矩阵R为:Then the normalized covariance matrix of all regional data of each class is averaged as the average normalized spatial covariance matrix of this class of data
Figure BDA0003688145730000082
Then the mixed spatial covariance matrix R of any two types of regional data is:

Figure BDA0003688145730000091
Figure BDA0003688145730000091

(2)首先对R进行主分量分解:(2) First perform principal component decomposition on R:

R=UVUTR= UVUT ;

其中V为特征值对角矩阵,U为由与V中特征值相对应的特征向量构成的特征向量矩阵;Wherein V is the eigenvalue diagonal matrix, and U is the eigenvector matrix composed of the eigenvectors corresponding to the eigenvalues in V;

然后对特征值按降序排序,并对特征向量的排列顺序做相应的调整,得到新的V和U;定义白化矩阵P为:Then sort the eigenvalues in descending order, and adjust the arrangement order of the eigenvectors accordingly to obtain new V and U; define the whitening matrix P as:

Figure BDA0003688145730000092
Figure BDA0003688145730000092

(3)首先用白化矩阵P对

Figure BDA0003688145730000093
Figure BDA0003688145730000094
进行白化变换:(3) First use the whitening matrix P to
Figure BDA0003688145730000093
and
Figure BDA0003688145730000094
Perform a whitening transformation:

Figure BDA0003688145730000095
Figure BDA0003688145730000095

Figure BDA0003688145730000096
Figure BDA0003688145730000096

然后对S1和S2进行主分量分解:Then do principal component decomposition for S1 and S2 :

Figure BDA0003688145730000097
Figure BDA0003688145730000097

Figure BDA0003688145730000098
Figure BDA0003688145730000098

对S1和S2做主分量分解得到的两个特征向量矩阵是相等的,即U1=U2=B;两个特征值对角矩阵之和为单位矩阵,即V1+V2=I;The two eigenvector matrices obtained by decomposing S 1 and S 2 are equal, namely U 1 =U 2 =B; the sum of the two eigenvalue diagonal matrices is the identity matrix, namely V 1 +V 2 =I ;

将V1中的特征值按照降序排列,则V2中的特征值就是按照升序排列的;定义投影矩阵W为:Arrange the eigenvalues in V 1 in descending order, then the eigenvalues in V 2 are in ascending order; define the projection matrix W as:

W=BTP;W= BTP ;

对任意两类区域数据都计算一个投影矩阵Wj(j=1,2,...,n(n-1)/2),并将得到的所有投影矩阵纵向拼接,构建一个n类空间滤波器SF;Calculate a projection matrix W j (j=1,2,...,n(n-1)/2) for any two types of regional data, and splicing all the obtained projection matrices vertically to construct an n-type spatial filter device SF;

(4)对每个区域数据Ei使用SF进行滤波:(4) Use SF to filter each region data E i :

Zi=SFEi;i=1,2,...n;Z i =SFE i ; i=1,2,...n;

得到的Zi表示单个区域的模式特征矩阵,其中一行表示一个通道上的特征分布情况;取每个通道特征向量的方差作为提取的心理状态信号特征,再对特征值进行对数运算,特征向量如下式所示:The obtained Z i represents the pattern feature matrix of a single area, and one row represents the feature distribution on a channel; the variance of each channel feature vector is taken as the extracted mental state signal feature, and then the logarithmic operation is performed on the feature value, and the feature vector As shown in the following formula:

fi=log(var(Zi));i=1,2,...n。f i =log(var(Z i )); i=1,2,...n.

如图2所示,本发明提供的心理学知识图谱构建方法如下:As shown in Figure 2, the psychological knowledge graph construction method provided by the present invention is as follows:

S201,采集与患者心理疾病病情相关的数据;对所述采集的数据进行分析,建立心理疾病语料集;根据所述心理疾病语料集,确定实体、关系以及属性指示词表;S201, collect data related to the patient's mental illness condition; analyze the collected data to establish a mental illness corpus; determine an entity, relationship, and attribute indicator vocabulary according to the mental illness corpus;

S202,利用语言模型对所述心理疾病语料集中的数据进行微调,构建心理疾病命名实体识别数据集,提取所述命名实体识别数据集的特征值,将微调后的数据和提取的特征进行融合,利用融合后的数据对预先构建的深度学习模型进行训练;S202, using a language model to fine-tune the data in the mental illness corpus, construct a mental illness named entity recognition data set, extract feature values of the named entity recognition data set, and fuse the fine-tuned data with the extracted features, Use the fused data to train a pre-built deep learning model;

S203,利用训练后的深度学习模型对待处理的心理疾病语料进行预测,将预测得到的实体类别索引序列转换为实体类型序列,并将各实体词存入实体词表,并依据关系类型以及属性类型,分别抽取实体关系和属性数据,进行分别存储。S203, use the trained deep learning model to predict the mental illness corpus to be processed, convert the predicted entity category index sequence into an entity type sequence, and store each entity word in the entity vocabulary, and according to the relationship type and attribute type , extract entity relationship and attribute data respectively, and store them separately.

本发明提供的获取心理疾病相关已有信息,建立心理疾病语料集的具体过程包括:根据心理疾病相关书籍设置心理疾病术语种子词集;根据心理疾病术语种子集,遍历搜索医疗网站中的相关内容,记录相关网页url,存为url集合;对url集合使用爬虫技术进行网页内容的爬取;对爬取的网页内容采用正则表达式、xpath解析器进行内容提取,对于非结构化数据存储至数据库中,对于半结构化数据,直接抽取出三元组进行存储,不同的关系类型、不同的属性类型进行区分存储;对已经处理好的语料进行至少一部分的标注。The specific process of obtaining the existing information related to mental illness and establishing a mental illness corpus provided by the present invention includes: setting a mental illness term seed word set according to a mental illness related book; traversing and searching the relevant content in the medical website according to the mental illness term seed set , record the url of the relevant webpage and save it as a url collection; use crawler technology to crawl the content of the url collection; use regular expressions and xpath parser to extract the content of the crawled webpage, and store the unstructured data in the database For semi-structured data, triples are directly extracted for storage, and different relation types and attribute types are stored separately; at least part of the processed corpus is annotated.

如图3所示,本发明提供的对用户心理状态进行评估方法如下:As shown in Figure 3, the method for evaluating the user's psychological state provided by the present invention is as follows:

S301,获取网络用户的所有上网行为,分别为每种类型的上网行为设置对应的节点;通过边连接与网络用户触发的两个相邻上网行为相对应的两个节点,并根据两个相邻上网行为之间的交互总次数为两个节点之间的边设置权重值;基于各个节点以及各个节点之间的具有权重值的边,建立与网络用户相对应的个体上网行为网络,并获取个体网络行为特征;S301: Acquire all online behaviors of the network user, and set corresponding nodes for each type of online behavior; connect two nodes corresponding to two adjacent online behaviors triggered by the network user through edges, and connect the nodes according to the two adjacent online behaviors. The total number of interactions between surfing behaviors sets a weight value for the edge between two nodes; based on each node and the edge with a weight value between each node, establishes an individual surfing behavior network corresponding to network users, and obtains the individual surfing behavior network. network behavior characteristics;

S302,利用机器学习的方法,基于已知区域中个体网络行为特征和人口统计学特征,建立和训练基于网络行为特征的心理状态评估模型;S302, using the method of machine learning, based on the individual network behavior characteristics and demographic characteristics in the known area, establish and train a mental state evaluation model based on the network behavior characteristics;

S303,获取新个体的网络行为特征和人口统计学特征,根据所述的基于网络行为特征的心理状态评估模型,得到该新个体的心理状况;S303, obtain the network behavior characteristics and demographic characteristics of the new individual, and obtain the psychological state of the new individual according to the mental state evaluation model based on the network behavior characteristics;

其中:所述网络行为特征是反映个体所使用的网络媒介/服务工具的功能结果和使用路径的特征集合;所述网络行为特征从记录个体的网络日志中提取;以及所述网络行为特征包括个体的网络信息和时间序列数据,所述个体的网络信息包括:时间信息、各类即时通讯工具信息、邮件信息、所访问网页类别的信息和搜索信息;所述时间序列数据包括:每天的上网时间信息、每天的网络请求个数信息和每天的网页信息;所述时间信息包括:工作日平均每日上网时长和周末平均每日上网时长;所述邮件信息包括是否用客户端收发邮件。Wherein: the network behavior feature is a feature set that reflects the functional results and usage paths of the network media/service tools used by the individual; the network behavior feature is extracted from the network log of the individual; and the network behavior feature includes the individual The network information and time series data of the individual, the individual network information includes: time information, information of various instant messaging tools, mail information, information of visited webpage categories and search information; the time series data includes: daily online time information, information on the number of network requests per day, and information on daily web pages; the time information includes: the average daily Internet access time on weekdays and the average daily Internet access time on weekends; the email information includes whether to use the client to send and receive emails.

以上所述仅为本发明的较佳实施例而已,并不用以限制本发明,凡在本发明的精神和原则之内所作的任何修改、等同替换和改进等,均应包含在本发明的保护范围之内。The above descriptions are only preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent replacements and improvements made within the spirit and principles of the present invention shall be included in the protection of the present invention. within the range.

Claims (10)

1.一种基于心理学知识赋予机器人工智能学习的方法,其特征在于,所述基于心理学知识赋予机器人工智能学习的方法包括以下步骤:1. a method for giving machine artificial intelligence learning based on psychological knowledge is characterized in that, the method for giving machine artificial intelligence learning based on psychological knowledge comprises the following steps: 步骤一,获取监控对象的基本信息、情绪信息以及位置信息;其中,所述基本信息至少包括所述监控对象的姓名与头像画面;Step 1: Obtain the basic information, emotional information and location information of the monitoring object; wherein, the basic information includes at least the name and avatar picture of the monitoring object; 步骤二,以所述位置信息为依据,匹配相应的场景关联事件;以预设的心理状态分析模型对所述基本信息、所述情绪信息、所述位置信息、所述场景关联事件进行分析,得到所述监控对象的心理状态;并建立心理状态文档库;Step 2, matching the corresponding scene-related events based on the location information; analyzing the basic information, the emotional information, the location information, and the scene-related events with a preset mental state analysis model, Obtain the psychological state of the monitoring object; and establish a psychological state document library; 步骤三,对心理状态文档库中的文档进行分词和智能摘要预处理,得到关键词,对得到的关键词进行相关性分析,处理上述步骤提供的值,计算得出关键词针对该篇文档的关键度分值,得到带有赋值的关键词;Step 3: Perform word segmentation and intelligent abstract preprocessing on the documents in the mental state document library to obtain keywords, perform correlation analysis on the obtained keywords, process the values provided in the above steps, and calculate the value of the keywords for the document. Criticality score, get keywords with assignments; 步骤四,按照心理学知识图谱对用户性格分析得用户性格倾向值,并对用户心理状态进行评估;Step 4, analyze the user's personality according to the psychological knowledge map to obtain the user's personality tendency value, and evaluate the user's psychological state; 步骤五,将得到的性格倾向值与得到的关键词关键度分值匹配,得到带有性格倾向属性的文档库;用户发起访问请求时,所述带有性格倾向属性的文档库给出带有性格倾向属性的文档。Step 5: Match the obtained character tendency value with the obtained keyword criticality score to obtain a document library with a character tendency attribute; when the user initiates an access request, the document library with the character tendency attribute provides a document library with a character tendency attribute. Documentation of Personality Attributes. 2.如权利要求1所述的基于心理学知识赋予机器人工智能学习的方法,其特征在于,在步骤二中,心理状态分析模型包括:2. the method for giving machine artificial intelligence learning based on psychological knowledge as claimed in claim 1, is characterized in that, in step 2, the mental state analysis model comprises: 第一步,利用小波包变换在时频域分解心理状态信号,提取心理状态波的心理状态变化规律;The first step is to use the wavelet packet transform to decompose the mental state signal in the time-frequency domain, and extract the mental state change law of the mental state wave; 第二步,采用一对一策略将公共空间模式从两类模式扩展到多类模式,利用一对一公共空间模式对心理状态变化规律心理状态提取特征向量;In the second step, the one-to-one strategy is used to expand the public space model from two types of models to multiple types of models, and the one-to-one public space model is used to extract the feature vector of the mental state of the mental state change law; 第三步,根据特征值的分布特点对特征向量的维数进行选择;The third step is to select the dimension of the eigenvectors according to the distribution characteristics of the eigenvalues; 所述用于心理状态信号情感分析的改进公共空间模式特征提取方法对原始心理状态信号提取心理状态变化规律心理状态,包括:采用小波包变换在时频域对心理状态信号进行分解,将心理状态变化频段对应的若干子带的节点系数进行组合重构,从而提取出与原始心理状态信号形式一致的心理状态变化规律心理状态信号;The improved public space pattern feature extraction method for mental state signal sentiment analysis extracts the mental state of the original mental state signal, the mental state changing law, including: using wavelet packet transform to decompose the mental state signal in the time-frequency domain, and decompose the mental state The node coefficients of several sub-bands corresponding to the changing frequency band are combined and reconstructed, so as to extract the mental state signal of the mental state change law consistent with the original mental state signal; 所述用于心理状态信号情感分析的改进公共空间模式特征提取方法基于公共空间模式对心理状态变化规律心理状态区域数据提取特征向量,具体包括:设情绪心理状态的类别个数为n,则针对n类情绪识别问题,采用一对一方法对传统的两类公共空间模式进行扩展。The improved public space pattern feature extraction method for mental state signal sentiment analysis is based on the public space pattern to extract feature vectors from mental state region data of mental state change laws, specifically including: assuming that the number of categories of emotional mental states is n, then for For the n-type emotion recognition problem, a one-to-one approach is used to extend the traditional two types of public space patterns. 3.如权利要求2所述的基于心理学知识赋予机器人工智能学习的方法,其特征在于,一对一公共空间模式算法的步骤为:3. the method for giving machine artificial intelligence learning based on psychological knowledge as claimed in claim 2, is characterized in that, the step of one-to-one public space pattern algorithm is: (1)用Ei来表示心理状态变化规律情绪心理状态区域数据,i指第i类(i=1,2,...,n);矩阵Ei的大小为N*T,其中N为记录心理状态信号所使用的通道数,T为在每个通道上采集的区域点数目,满足约束条件N≤T;分别对每个区域数据计算归一化协方差矩阵,记为Ri(1) Use E i to represent the mental state change law emotional and mental state area data, i refers to the i-th type (i=1,2,...,n); the size of the matrix E i is N*T, where N is The number of channels used to record the mental state signal, T is the number of regional points collected on each channel, and the constraint condition N≤T is satisfied; the normalized covariance matrix is calculated for each regional data, denoted as R i :
Figure FDA0003688145720000021
Figure FDA0003688145720000021
式中,trace(X)表示对角矩阵X的迹;In the formula, trace(X) represents the trace of the diagonal matrix X; 然后对每一类所有区域数据的归一化协方差矩阵求平均值作为该类数据的平均归一化空间协方差矩阵
Figure FDA0003688145720000022
则任意两类区域数据的混合空间协方差矩阵R为:
Then the normalized covariance matrix of all regional data of each class is averaged as the average normalized spatial covariance matrix of this class of data
Figure FDA0003688145720000022
Then the mixed spatial covariance matrix R of any two types of regional data is:
Figure FDA0003688145720000023
Figure FDA0003688145720000023
(2)首先对R进行主分量分解:(2) First perform principal component decomposition on R: R=UVUTR= UVUT ; 其中V为特征值对角矩阵,U为由与V中特征值相对应的特征向量构成的特征向量矩阵;Wherein V is the eigenvalue diagonal matrix, and U is the eigenvector matrix composed of the eigenvectors corresponding to the eigenvalues in V; 然后对特征值按降序排序,并对特征向量的排列顺序做相应的调整,得到新的V和U;定义白化矩阵P为:Then sort the eigenvalues in descending order, and adjust the arrangement order of the eigenvectors accordingly to obtain new V and U; define the whitening matrix P as:
Figure FDA0003688145720000024
Figure FDA0003688145720000024
(3)首先用白化矩阵P对
Figure FDA0003688145720000031
Figure FDA0003688145720000032
进行白化变换:
(3) First use the whitening matrix P to
Figure FDA0003688145720000031
and
Figure FDA0003688145720000032
Perform a whitening transformation:
Figure FDA0003688145720000033
Figure FDA0003688145720000033
Figure FDA0003688145720000034
Figure FDA0003688145720000034
然后对S1和S2进行主分量分解:Then do principal component decomposition for S1 and S2 :
Figure FDA0003688145720000035
Figure FDA0003688145720000035
Figure FDA0003688145720000036
Figure FDA0003688145720000036
对S1和S2做主分量分解得到的两个特征向量矩阵是相等的,即U1=U2=B;两个特征值对角矩阵之和为单位矩阵,即V1+V2=I;The two eigenvector matrices obtained by decomposing S 1 and S 2 are equal, namely U 1 =U 2 =B; the sum of the two eigenvalue diagonal matrices is the identity matrix, namely V 1 +V 2 =I ; 将V1中的特征值按照降序排列,则V2中的特征值就是按照升序排列的;定义投影矩阵W为:Arrange the eigenvalues in V 1 in descending order, then the eigenvalues in V 2 are in ascending order; define the projection matrix W as: W=BTP;W= BTP ; 对任意两类区域数据都计算一个投影矩阵Wj(j=1,2,...,n(n-1)/2),并将得到的所有投影矩阵纵向拼接,构建一个n类空间滤波器SF;Calculate a projection matrix W j (j=1,2,...,n(n-1)/2) for any two types of regional data, and splicing all the obtained projection matrices vertically to construct an n-type spatial filter device SF; (4)对每个区域数据Ei使用SF进行滤波:(4) Use SF to filter each region data E i : Zi=SFEi;i=1,2,...n;Z i =SFE i ; i=1,2,...n; 得到的Zi表示单个区域的模式特征矩阵,其中一行表示一个通道上的特征分布情况;取每个通道特征向量的方差作为提取的心理状态信号特征,再对特征值进行对数运算,特征向量如下式所示:The obtained Z i represents the pattern feature matrix of a single area, and one row represents the feature distribution on a channel; the variance of each channel feature vector is taken as the extracted mental state signal feature, and then the logarithmic operation is performed on the feature value, and the feature vector As shown in the following formula: fi=log(var(Zi));i=1,2,...n。f i =log(var(Z i )); i=1,2,...n.
4.如权利要求1所述的基于心理学知识赋予机器人工智能学习的方法,其特征在于,在步骤四中,心理学知识图谱构建方法如下:4. the method for giving machine artificial intelligence learning based on psychological knowledge as claimed in claim 1 is characterized in that, in step 4, the psychological knowledge graph construction method is as follows: (1)采集与患者心理疾病病情相关的数据;对所述采集的数据进行分析,建立心理疾病语料集;根据所述心理疾病语料集,确定实体、关系以及属性指示词表;(1) collect data related to the patient's mental illness condition; analyze the collected data to establish a mental illness corpus; determine an entity, relationship and attribute indicator vocabulary according to the mental illness corpus; (2)利用语言模型对所述心理疾病语料集中的数据进行微调,构建心理疾病命名实体识别数据集,提取所述命名实体识别数据集的特征值,将微调后的数据和提取的特征进行融合,利用融合后的数据对预先构建的深度学习模型进行训练;(2) Using the language model to fine-tune the data in the mental illness corpus, construct a mental illness named entity recognition dataset, extract the feature values of the named entity recognition dataset, and fuse the fine-tuned data and the extracted features , using the fused data to train the pre-built deep learning model; (3)利用训练后的深度学习模型对待处理的心理疾病语料进行预测,将预测得到的实体类别索引序列转换为实体类型序列,并将各实体词存入实体词表,并依据关系类型以及属性类型,分别抽取实体关系和属性数据,进行分别存储。(3) Use the trained deep learning model to predict the mental illness corpus to be processed, convert the predicted entity category index sequence into an entity type sequence, and store each entity word in the entity vocabulary, and according to the relationship type and attribute Type, extract entity relationship and attribute data respectively, and store them separately. 5.如权利要求4所述的基于心理学知识赋予机器人工智能学习的方法,其特征在于,所述获取心理疾病相关已有信息,建立心理疾病语料集的具体过程包括:根据心理疾病相关书籍设置心理疾病术语种子词集;根据心理疾病术语种子集,遍历搜索医疗网站中的相关内容,记录相关网页url,存为url集合;对url集合使用爬虫技术进行网页内容的爬取;对爬取的网页内容采用正则表达式、xpath解析器进行内容提取,对于非结构化数据存储至数据库中,对于半结构化数据,直接抽取出三元组进行存储,不同的关系类型、不同的属性类型进行区分存储;对已经处理好的语料进行至少一部分的标注。5. the method for giving machine artificial intelligence learning based on psychological knowledge as claimed in claim 4, it is characterized in that, described obtaining relevant existing information of mental illness, the concrete process of establishing mental illness corpus comprises: according to mental illness-related books Set the mental disease term seed word set; traverse and search the relevant content in the medical website according to the mental disease term seed set, record the relevant web page url, and save it as a url set; use the crawler technology to crawl the web content of the url set; The content of the web page is extracted using regular expressions and xpath parser. For unstructured data, it is stored in the database. For semi-structured data, triples are directly extracted for storage. Different relationship types and different attribute types are used for Differentiate storage; mark at least a part of the processed corpus. 6.如权利要求1所述的基于心理学知识赋予机器人工智能学习的方法,其特征在于,在步骤四中,所述对用户心理状态进行评估方法如下:6. the method for giving machine artificial intelligence learning based on psychological knowledge as claimed in claim 1, is characterized in that, in step 4, described to the user's mental state is carried out the evaluation method as follows: 1),获取网络用户的所有上网行为,分别为每种类型的上网行为设置对应的节点;通过边连接与网络用户触发的两个相邻上网行为相对应的两个节点,并根据两个相邻上网行为之间的交互总次数为两个节点之间的边设置权重值;基于各个节点以及各个节点之间的具有权重值的边,建立与网络用户相对应的个体上网行为网络,并获取个体网络行为特征;1), obtain all online behaviors of network users, and set corresponding nodes for each type of online behavior; connect two nodes corresponding to two adjacent online behaviors triggered by network users through edges, and according to the two The total number of interactions between neighboring online behaviors sets a weight value for the edge between two nodes; based on each node and the edge with a weight value between each node, an individual online behavior network corresponding to the network user is established, and obtains Individual network behavior characteristics; 2),利用机器学习的方法,基于已知区域中个体网络行为特征和人口统计学特征,建立和训练基于网络行为特征的心理状态评估模型;2), use the method of machine learning to establish and train a mental state assessment model based on network behavior characteristics based on individual network behavior characteristics and demographic characteristics in known areas; 3),获取新个体的网络行为特征和人口统计学特征,根据所述的基于网络行为特征的心理状态评估模型,得到该新个体的心理状况;3), obtain the network behavior characteristics and demographic characteristics of the new individual, and obtain the psychological state of the new individual according to the described mental state assessment model based on the network behavior characteristics; 其中:所述网络行为特征是反映个体所使用的网络媒介/服务工具的功能结果和使用路径的特征集合;所述网络行为特征从记录个体的网络日志中提取;以及所述网络行为特征包括个体的网络信息和时间序列数据,所述个体的网络信息包括:时间信息、各类即时通讯工具信息、邮件信息、所访问网页类别的信息和搜索信息;所述时间序列数据包括:每天的上网时间信息、每天的网络请求个数信息和每天的网页信息;所述时间信息包括:工作日平均每日上网时长和周末平均每日上网时长;所述邮件信息包括是否用客户端收发邮件。Wherein: the network behavior feature is a feature set that reflects the functional results and usage paths of the network media/service tools used by the individual; the network behavior feature is extracted from the network log of the individual; and the network behavior feature includes the individual The network information and time series data of the individual, the individual network information includes: time information, information of various instant messaging tools, mail information, information of visited webpage categories and search information; the time series data includes: daily Internet access time information, the number of daily network requests, and the daily web page information; the time information includes: the average daily online time on weekdays and the average daily online time on weekends; the email information includes whether to use the client to send and receive emails. 7.一种实施权利要求1~6任意一项所述基于心理学知识赋予机器人工智能学习的方法的基于心理学知识赋予机器人工智能学习系统。7. A psychological knowledge-based artificial intelligence learning system for implementing the method for imparting artificial intelligence learning to machines based on psychological knowledge according to any one of claims 1 to 6. 8.一种计算机设备,其特征在于,所述计算机设备包括存储器和处理器,所述存储器存储有计算机程序,所述计算机程序被所述处理器执行时,使得所述处理器执行权利要求1~6任意一项所述基于心理学知识赋予机器人工智能学习的方法步骤。8. A computer device, characterized in that the computer device comprises a memory and a processor, the memory stores a computer program, and when the computer program is executed by the processor, the processor is made to execute claim 1 ~6 any one of the method steps for giving a machine artificial intelligence learning based on psychological knowledge. 9.一种计算机可读存储介质,存储有计算机程序,所述计算机程序被处理器执行时,使得所述处理器执行权利要求1~6任意一项所述基于心理学知识赋予机器人工智能学习的方法。9. A computer-readable storage medium storing a computer program, which, when executed by a processor, causes the processor to perform the artificial intelligence learning given to a machine based on psychological knowledge according to any one of claims 1 to 6 Methods. 10.一种信息数据处理终端,其特征在于,所述信息数据处理终端用于实现权利要求1~6任意一项所述基于心理学知识赋予机器人工智能学习的方法。10 . An information data processing terminal, wherein the information data processing terminal is used to implement the method for imparting artificial intelligence learning to a machine based on psychological knowledge according to any one of claims 1 to 6 .
CN202210652233.4A 2022-06-10 2022-06-10 Method and system for giving artificial intelligence learning to machine based on psychological knowledge Pending CN114969375A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210652233.4A CN114969375A (en) 2022-06-10 2022-06-10 Method and system for giving artificial intelligence learning to machine based on psychological knowledge

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210652233.4A CN114969375A (en) 2022-06-10 2022-06-10 Method and system for giving artificial intelligence learning to machine based on psychological knowledge

Publications (1)

Publication Number Publication Date
CN114969375A true CN114969375A (en) 2022-08-30

Family

ID=82961634

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210652233.4A Pending CN114969375A (en) 2022-06-10 2022-06-10 Method and system for giving artificial intelligence learning to machine based on psychological knowledge

Country Status (1)

Country Link
CN (1) CN114969375A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116821287A (en) * 2023-08-28 2023-09-29 湖南创星科技股份有限公司 Knowledge graph and large language model-based user psychological portrait system and method

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116821287A (en) * 2023-08-28 2023-09-29 湖南创星科技股份有限公司 Knowledge graph and large language model-based user psychological portrait system and method
CN116821287B (en) * 2023-08-28 2023-11-17 湖南创星科技股份有限公司 Knowledge graph and large language model-based user psychological portrait system and method

Similar Documents

Publication Publication Date Title
Hashimi et al. Selection criteria for text mining approaches
JP6309644B2 (en) Method, system, and storage medium for realizing smart question answer
US7853594B2 (en) System and method for determining founders of an information aggregate
CN112989215B (en) A Knowledge Graph Enhanced Recommendation System Based on Sparse User Behavior Data
CN101655856A (en) Method for obtaining user specific metaknowledge interest
CN118797018B (en) Safety education and training question-answering optimization method and system based on demand feedback
CN111951079A (en) A credit rating method, device and electronic device based on knowledge graph
Hao et al. Semantic patterns for user‐interactive question answering
Rawat et al. Topic modelling of legal documents using NLP and bidirectional encoder representations from transformers
CN115982384A (en) Method and system for constructing product knowledge graph in industrial design field
CN114969375A (en) Method and system for giving artificial intelligence learning to machine based on psychological knowledge
KR102454261B1 (en) Collaborative partner recommendation system and method based on user information
Fathalla et al. A hybrid method for user query reformation and classification
CN118197402A (en) A method, device and apparatus for predicting drug-target relationship
Ceolin et al. Semi-automated assessment of annotation trustworthiness
Chen Tracking latent domain structures: An integration of Pathfinder and Latent Semantic Analysis
Pramono Sentiment Analysis of Political Discourse on Platform X using Graph Neural Network (GNN)
CN118839053B (en) Web page data collection method, system, computer device and readable storage medium
CN120163675A (en) Social network influence prediction method and system
Xia et al. User-driven filtering and ranking of topical datasets based on overall data quality
Sarkar et al. A synthetic search session generator for task-aware information seeking and retrieval
Mianowska et al. A method for user profile adaptation in document retrieval
Wu et al. Research on Application and Optimization Model of Knowledge Graph in Intelligent Question Answering System
Lu et al. KACTL: knowware based automated construction of a treelike library from web documents
CN106844616B (en) Calculation method of creative point generation by automatic classification and filtering of motivation words

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination