Enterprise person relationship extraction method, device, equipment and readable storage medium
By constructing and expanding the basic model of corporate characters and generalizing keyword replacement, the accuracy of character relationship extraction in the company is solved, and efficient relationship extraction is achieved.
Patent Information
- Application Number
- CN202310302940.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-23
- Publication Date
- 2025-08-15
- Estimated Expiration
- 2043-03-23
AI Technical Summary
The prior art cannot accurately and efficiently extract the relationship between persons in enterprises, especially due to the differences in organizational structure and departmental distribution, which leads to inaccurate extraction.
Build the basic model of the target enterprise, perform character expansion and keyword replacement generalization processing, use the generalization pattern to match the enterprise-related data sets, and extract the entity relationships in the target text.
It improves the accuracy and efficiency of character relationship extraction, and can quickly and accurately extract character relationships from the company from the target text.
Smart Images

Figure CN116451693B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing technology, and in particular to a method, device, electronic device and computer-readable storage medium for extracting enterprise person relationships. Background Art
[0002] With the rise of artificial intelligence, various data in the digital age are growing exponentially. Data mining and relationship mining are becoming increasingly important, for example, building a personal relationship network in an enterprise.
[0003] Existing technologies extract relationships between people, the foundation for building relationship networks, primarily rely on artificial intelligence (AI) technology, combining machine learning methods with rules to extract entity information relationships. However, due to significant differences in organizational structure, departmental distribution, and other factors across enterprises, accurate and efficient extraction of relationships within companies is difficult. Summary of the Invention
[0004] The present invention provides a method, device, electronic device and readable storage medium for extracting corporate person relationships, the main purpose of which is to improve the accuracy of person relationship extraction.
[0005] To achieve the above objectives, the present invention provides a method for extracting corporate person relationships, comprising:
[0006] Constructing a basic model of corporate characters in the target enterprise, and performing character extension on the basic model to obtain an extended model of the corporate characters;
[0007] Performing keyword replacement generalization processing and keyword segmentation generalization processing on the extended pattern of the enterprise character to obtain a generalized pattern of the enterprise character;
[0008] Acquire an enterprise-related data set of the target enterprise, and match target text in the enterprise-related data set using the generalized pattern;
[0009] A target entity corresponding to the generalization pattern in the target text is extracted, and a relationship in the generalization pattern is determined to be a target relationship of the target entity.
[0010] Optionally, the basic model of constructing corporate personas in the target enterprise includes:
[0011] Constructing a basic employee model based on the social relationships among employees in the target enterprise;
[0012] Constructing a basic departmental model based on the structural relationship between departments in the target enterprise;
[0013] Constructing a basic employee department model based on the organizational relationship between employees and departments in the target enterprise;
[0014] The employee basic model, the department basic model and the employee department basic model are determined as the basic models of corporate characters in the target enterprise.
[0015] Optionally, the character expansion of the basic model to obtain an extended model of the enterprise character includes:
[0016] The basic model is expanded based on the department organization relationship and personnel organization relationship in the target enterprise to obtain an expanded model of enterprise characters.
[0017] Optionally, performing keyword replacement generalization processing and keyword segmentation generalization processing on the extended pattern of the corporate persona to obtain a generalized pattern of the corporate persona includes:
[0018] Replacing entities in the extended pattern with preset keywords to obtain a first generalized pattern;
[0019] Performing word segmentation processing on the relations in the extended pattern and re-using the word segmentations as relations to obtain a second generalized pattern;
[0020] The first generalization pattern and the second generalization pattern are determined to be generalization patterns of the corporate persona.
[0021] Optionally, performing word segmentation processing on the relationship in the extended pattern and re-using the word segmentations as the relationship to obtain a second generalized pattern includes:
[0022] Performing word segmentation processing on the relationship in the extended pattern to obtain relationship word segmentations;
[0023] The extended pattern of the enterprise personages in the target enterprise is reconstructed based on the relational participles, and the entities in the newly constructed extended pattern are replaced with preset keywords to obtain a second generalized pattern.
[0024] Optionally, the acquiring of the enterprise-related data set of the target enterprise and matching the target text in the enterprise-related data set using the generalized pattern includes:
[0025] Using a preset crawling tool to crawl the enterprise-related data set of the target enterprise;
[0026] The target text in the enterprise-related data set is matched based on the keywords in the generalized pattern.
[0027] Optionally, extracting a target entity corresponding to the generalization pattern in the target text and determining a relationship in the generalization pattern as a target relationship of the target entity includes:
[0028] Extracting target entities from the target text using a preset entity extraction model;
[0029] The target entity is filled into the generalization schema, and a relationship in the generalization schema is determined to be a target relationship of the target entity.
[0030] In order to solve the above problems, the present invention further provides a device for extracting corporate person relationships, the device comprising:
[0031] A model extension module is used to construct a basic model of enterprise characters in the target enterprise, and to extend the basic model to obtain an extended model of the enterprise characters;
[0032] A pattern generalization module is used to perform keyword replacement generalization processing and keyword segmentation generalization processing on the extended pattern of the enterprise character to obtain a generalized pattern of the enterprise character;
[0033] A text matching module, configured to obtain an enterprise-related data set of the target enterprise and match a target text in the enterprise-related data set using the generalized pattern;
[0034] The entity relationship extraction module is used to extract the target entity corresponding to the generalization pattern in the target text, and determine that the relationship in the generalization pattern is the target relationship of the target entity.
[0035] In order to solve the above problem, the present invention further provides an electronic device, comprising:
[0036] a memory storing at least one computer program; and
[0037] The processor executes the computer program stored in the memory to implement the above-mentioned enterprise person relationship extraction method.
[0038] In order to solve the above problems, the present invention also provides a computer-readable storage medium, in which at least one computer program is stored. The at least one computer program is executed by a processor in an electronic device to implement the above-mentioned enterprise person relationship extraction method.
[0039] This embodiment expands the basic schema of a persona in a target enterprise to obtain an expanded schema for the persona. This expanded schema is then generalized using keyword replacement and keyword segmentation to obtain a generalized schema for the persona. This allows for continuous and in-depth exploration of the entity relationships between different people in the target enterprise. Finally, the generalized schema is used to match target text in the enterprise-related data set, enabling rapid and accurate extraction of persona relationships from the target text. Therefore, the method, device, electronic device, and computer-readable storage medium for extracting persona relationships in the enterprise proposed by the present invention can improve the accuracy of persona relationship extraction. BRIEF DESCRIPTION OF THE DRAWINGS
[0040] Figure 1 A flowchart of a method for extracting corporate person relationships provided by one embodiment of the present invention;
[0041] Figure 2 A functional module diagram of an enterprise person relationship extraction device provided by one embodiment of the present invention;
[0042] Figure 3 A schematic diagram of the structure of an electronic device for implementing the enterprise person relationship extraction method provided in one embodiment of the present invention.
[0043] The purpose, features and advantages of the present invention will be further described with reference to the accompanying drawings and in conjunction with the embodiments. DETAILED DESCRIPTION
[0044] It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.
[0045] The embodiment of the present application provides a method for extracting corporate person relationships. The execution subject of the method for extracting corporate person relationships includes but is not limited to at least one of the electronic devices such as a server and a terminal that can be configured to execute the method provided by the embodiment of the present application. In other words, the method for extracting corporate person relationships can be executed by software or hardware installed on a terminal device or a server device, and the software can be a blockchain platform. The server includes but is not limited to: a single server, a server cluster, a cloud server or a cloud server cluster, etc. The server can be an independent server, or it can be a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (CDNs), and big data and artificial intelligence platforms.
[0046] Reference Figure 1 FIG. 1 is a flow chart of a method for extracting corporate person relationships according to an embodiment of the present invention. In this embodiment, the method for extracting corporate person relationships includes:
[0047] S1. Construct a basic model of corporate characters in the target enterprise, and perform character expansion on the basic model to obtain an expanded model of the corporate characters.
[0048] In this embodiment of the present invention, the basic schema of an enterprise persona refers to a single triple in an enterprise relationship, consisting of a head entity, a relationship, and a tail entity. For example, <Entity 1> - Colleague - <Entity 2>, where "<Entity 1>" is the head entity, "Colleague" represents the relationship, and "<Entity 2>" represents the tail entity. The extended schema of an enterprise persona refers to a set of multiple hierarchical triples formed according to the enterprise organizational structure, for example, <Entity A> - Sales Department - <Entity B> - Sales Person - <Entity C> - Colleague - <Entity D>.
[0049] Specifically, the basic model of constructing corporate personas in the target enterprise includes:
[0050] Constructing a basic employee model based on the social relationships among employees in the target enterprise;
[0051] Constructing a basic departmental model based on the structural relationship between departments in the target enterprise;
[0052] Constructing a basic employee department model based on the organizational relationship between employees and departments in the target enterprise;
[0053] The employee basic model, the department basic model and the employee department basic model are determined as the basic models of corporate characters in the target enterprise.
[0054] In an optional embodiment of the present invention, the employee basic model represents the entity relationship between employees, for example, <entity a>-colleague-<entity b>; the department basic model represents the entity relationship between departments, for example, <entity A>-sales department-<entity B>; the employee department basic model represents the entity relationship between departments and employees, for example, <entity B>-sales staff-<entity C>.
[0055] Specifically, the character expansion of the basic model to obtain the extended model of the enterprise character includes:
[0056] The basic model is expanded based on the department organization relationship and personnel organization relationship in the target enterprise to obtain an expanded model of enterprise characters.
[0057] In this embodiment of the present invention, the departmental organizational relationship includes entity relationships between different departments. For example, Company A includes Department B, the "Sales Department," which in turn includes Group C, the "Sales Team." The personnel organizational relationship includes entity relationships between different employees and departments. For example, the extended model is <Entity A> - Sales Department - <Entity B> - Sales Personnel - <Entity C>. Because organizational relationships vary across enterprises, establishing basic and extended models for person relationships can further improve the efficiency and accuracy of entity recognition.
[0058] S2. Perform keyword replacement generalization processing and keyword segmentation generalization processing on the extended pattern of the corporate persona to obtain a generalized pattern of the corporate persona.
[0059] Specifically, the keyword replacement generalization processing and keyword segmentation generalization processing are performed on the extended pattern of the enterprise persona to obtain the generalized pattern of the enterprise persona, including:
[0060] Replacing entities in the extended pattern with preset keywords to obtain a first generalized pattern;
[0061] Performing word segmentation processing on the relations in the extended pattern and re-using the word segmentations as relations to obtain a second generalized pattern;
[0062] The first generalization pattern and the second generalization pattern are determined to be generalization patterns of the corporate persona.
[0063] In an optional embodiment of the present invention, the preset keywords may be a company abbreviation, an employee nickname, a personal pronoun "you," "I," "he," "she," "you," "they," etc. For example, the first generalized pattern may be: you-sales department-<entity B>.
[0064] Furthermore, the relationship in the extended pattern is segmented and the segmented words are used as relationships again to obtain a second generalized pattern, including:
[0065] Performing word segmentation processing on the relationship in the extended pattern to obtain relationship word segmentations;
[0066] The extended pattern of the enterprise personages in the target enterprise is reconstructed based on the relational participles, and the entities in the newly constructed extended pattern are replaced with preset keywords to obtain a second generalized pattern.
[0067] In an embodiment of the present invention, a second generalized pattern can be constructed by replacing entities with preset keywords, for example, his colleague - <entity 2>; the second generalized pattern is obtained by segmenting the relationship, for example, the relationship is "salesperson", and the second generalized patterns obtained through segmentation and replacement include your-sales-<entity C>, <entity B>-sales-<entity C>, etc.
[0068] In an embodiment of the present invention, by performing keyword replacement generalization processing and keyword segmentation generalization processing on the extended pattern of the enterprise person, a generalized pattern of the enterprise person is obtained, which can further improve the accuracy of enterprise person relationship extraction based on the actual situation of the target enterprise.
[0069] S3. Obtain an enterprise-related data set of the target enterprise, and use the generalized pattern to match the target text in the enterprise-related data set.
[0070] In an embodiment of the present invention, the enterprise-related data set refers to information related to the target enterprise searched from different platforms, for example, text information captured from social platforms, company official websites, etc., including company department classification information, employee basic information, social platform communication information, etc.
[0071] In detail, the step of obtaining the enterprise-related data set of the target enterprise and matching the target text in the enterprise-related data set using the generalized pattern includes:
[0072] Using a preset crawling tool to crawl the enterprise-related data set of the target enterprise;
[0073] The target text in the enterprise-related data set is matched based on the keywords in the generalized pattern.
[0074] In an optional embodiment of the present invention, the matching of target text in the enterprise-related data set based on keywords in the generalized pattern includes:
[0075] Performing word segmentation and vectorization processing on the text in the enterprise-related data set to obtain a first vector;
[0076] Performing word segmentation and vectorization processing on the keywords in the generalization pattern to obtain a second vector;
[0077] The similarity between the first vector and the second vector is calculated, and the text corresponding to the second vector having a similarity greater than a preset threshold is determined as the target text.
[0078] In an embodiment of the present invention, relevant information of the target enterprise on the Internet can be crawled using a preset crawler tool, and relevance matching can be performed using keywords in the generalization model (including personal pronouns, relational segmentation after segmentation processing, etc.), and text with high similarity can be determined as the target text.
[0079] S4. Extracting a target entity corresponding to the generalization pattern in the target text, and determining a relationship in the generalization pattern as a target relationship of the target entity.
[0080] Specifically, extracting the target entity corresponding to the generalization pattern in the target text and determining the relationship in the generalization pattern as the target relationship of the target entity includes:
[0081] Extracting target entities from the target text using a preset entity extraction model;
[0082] The target entity is filled into the generalization schema, and a relationship in the generalization schema is determined to be a target relationship of the target entity.
[0083] In the embodiments of the present invention, the preset entity extraction model can be a Lattice LSTM model, a CAN-NER model, etc. For example, based on the keyword "sales" in the generalization pattern <Entity B>-Sales-<Entity C>, the target text "Company A hires Employee B as a salesperson" is found. The target entities are determined as "Company A" and "Employee B" through the entity extraction model and filled into the generalization pattern <Entity B>-Sales-<Entity C>, resulting in <Company A>-Sales-<Employee B>.
[0084] In this embodiment, by expanding the basic pattern of enterprise figures in the target enterprise, an extended pattern of enterprise figures is obtained. Through keyword replacement generalization processing and keyword tokenization generalization processing on the extended pattern of enterprise figures, a generalization pattern of enterprise figures is obtained, which can continuously and deeply explore the entity relationships between different figures in the target enterprise. Finally, by using the generalization pattern to match the target text in the enterprise-related data set of the enterprise, the figure relationships can be quickly and accurately extracted from the target text. Therefore, the enterprise figure relationship extraction method proposed by the present invention can improve the accuracy of figure relationship extraction.
[0085] As Figure 2 shown, it is a functional module diagram of an enterprise figure relationship extraction device provided by an embodiment of the present invention.
[0086] The enterprise figure relationship extraction device 100 of the present invention can be installed in an electronic device. According to the functions achieved, the enterprise figure relationship extraction device 100 can include a pattern expansion module 101, a pattern generalization module 102, a text matching module 103, and an entity relationship extraction module 104. The modules of the present invention can also be referred to as units, which refer to a series of computer program segments that can be executed by a processor of an electronic device and can complete fixed functions, and are stored in the memory of the electronic device.
[0087] In this embodiment, the functions of each module / unit are as follows:
[0088] The pattern expansion module 101 is used to construct the basic pattern of enterprise figures in the target enterprise and expand the basic pattern to obtain an extended pattern of enterprise figures;
[0089] The pattern generalization module 102 is used to perform keyword replacement generalization processing and keyword tokenization generalization processing on the extended pattern of enterprise figures to obtain a generalization pattern of enterprise figures;
[0090] The text matching module 103 is used to obtain the enterprise-related data set of the target enterprise and use the generalization pattern to match the target text in the enterprise-related data set;
[0091] The entity relationship extraction module 104 is configured to extract the target entity corresponding to the generalization pattern in the target text, and determine the relationship in the generalization pattern as the target relationship of the target entity.
[0092] In detail, the specific implementation of each module of the enterprise person relationship extraction device 100 is as follows:
[0093] Step 1: The model extension module 101 constructs a basic model of enterprise characters in the target enterprise, and performs character extension on the basic model to obtain an extended model of the enterprise characters.
[0094] In this embodiment of the present invention, the basic schema of an enterprise persona refers to a single triple in an enterprise relationship, consisting of a head entity, a relationship, and a tail entity. For example, <Entity 1> - Colleague - <Entity 2>, where "<Entity 1>" is the head entity, "Colleague" represents the relationship, and "<Entity 2>" represents the tail entity. The extended schema of an enterprise persona refers to a set of multiple hierarchical triples formed according to the enterprise organizational structure, for example, <Entity A> - Sales Department - <Entity B> - Sales Person - <Entity C> - Colleague - <Entity D>.
[0095] Specifically, the basic model of constructing corporate personas in the target enterprise includes:
[0096] Constructing a basic employee model based on the social relationships among employees in the target enterprise;
[0097] Constructing a basic departmental model based on the structural relationship between departments in the target enterprise;
[0098] Constructing a basic employee department model based on the organizational relationship between employees and departments in the target enterprise;
[0099] The employee basic model, the department basic model and the employee department basic model are determined as the basic models of corporate characters in the target enterprise.
[0100] In an optional embodiment of the present invention, the employee basic model represents the entity relationship between employees, for example, <entity a>-colleague-<entity b>; the department basic model represents the entity relationship between departments, for example, <entity A>-sales department-<entity B>; the employee department basic model represents the entity relationship between departments and employees, for example, <entity B>-sales staff-<entity C>.
[0101] Specifically, the character expansion of the basic model to obtain the extended model of the enterprise character includes:
[0102] The basic model is expanded based on the department organization relationship and personnel organization relationship in the target enterprise to obtain an expanded model of enterprise characters.
[0103] In this embodiment of the present invention, the departmental organizational relationship includes entity relationships between different departments. For example, Company A includes Department B, the "Sales Department," which in turn includes Group C, the "Sales Team." The personnel organizational relationship includes entity relationships between different employees and departments. For example, the extended model is <Entity A> - Sales Department - <Entity B> - Sales Personnel - <Entity C>. Because organizational relationships vary across enterprises, establishing basic and extended models for person relationships can further improve the efficiency and accuracy of entity recognition.
[0104] Step 2: The pattern generalization module 102 performs keyword replacement generalization processing and keyword segmentation generalization processing on the extended pattern of the corporate persona to obtain a generalized pattern of the corporate persona.
[0105] Specifically, the keyword replacement generalization processing and keyword segmentation generalization processing are performed on the extended pattern of the enterprise persona to obtain the generalized pattern of the enterprise persona, including:
[0106] Replacing entities in the extended pattern with preset keywords to obtain a first generalized pattern;
[0107] Performing word segmentation processing on the relations in the extended pattern and re-using the word segmentations as relations to obtain a second generalized pattern;
[0108] The first generalization pattern and the second generalization pattern are determined to be generalization patterns of the corporate persona.
[0109] In an optional embodiment of the present invention, the preset keywords may be a company abbreviation, an employee nickname, a personal pronoun "you," "I," "he," "she," "you," "they," etc. For example, the first generalized pattern may be: you-sales department-<entity B>.
[0110] Furthermore, the relationship in the extended pattern is segmented and the segmented words are used as relationships again to obtain a second generalized pattern, including:
[0111] Performing word segmentation processing on the relationship in the extended pattern to obtain relationship word segmentations;
[0112] The extended pattern of the enterprise personages in the target enterprise is reconstructed based on the relational participles, and the entities in the newly constructed extended pattern are replaced with preset keywords to obtain a second generalized pattern.
[0113] In an embodiment of the present invention, a second generalized pattern can be constructed by replacing entities with preset keywords, for example, his colleague - <entity 2>; the second generalized pattern is obtained by segmenting the relationship, for example, the relationship is "salesperson", and the second generalized patterns obtained through segmentation and replacement include your-sales-<entity C>, <entity B>-sales-<entity C>, etc.
[0114] In an embodiment of the present invention, by performing keyword replacement generalization processing and keyword segmentation generalization processing on the extended pattern of the enterprise person, a generalized pattern of the enterprise person is obtained, which can further improve the accuracy of enterprise person relationship extraction based on the actual situation of the target enterprise.
[0115] Step 3: The text matching module 103 obtains the enterprise-related data set of the target enterprise and matches the target text in the enterprise-related data set using the generalized pattern.
[0116] In an embodiment of the present invention, the enterprise-related data set refers to information related to the target enterprise searched from different platforms, for example, text information captured from social platforms, company official websites, etc., including company department classification information, employee basic information, social platform communication information, etc.
[0117] In detail, the step of obtaining the enterprise-related data set of the target enterprise and matching the target text in the enterprise-related data set using the generalized pattern includes:
[0118] Using a preset crawling tool to crawl the enterprise-related data set of the target enterprise;
[0119] The target text in the enterprise-related data set is matched based on the keywords in the generalized pattern.
[0120] In an optional embodiment of the present invention, the matching of target text in the enterprise-related data set based on keywords in the generalized pattern includes:
[0121] Performing word segmentation and vectorization processing on the text in the enterprise-related data set to obtain a first vector;
[0122] Perform word segmentation and vectorization processing on the keywords in the generalization pattern to obtain a second vector;
[0123] The similarity between the first vector and the second vector is calculated, and the text corresponding to the second vector having a similarity greater than a preset threshold is determined as the target text.
[0124] In an embodiment of the present invention, relevant information of a target enterprise on the Internet can be crawled through a preset crawler tool, and the generalization pattern is used to perform relevance matching on keywords (including personal pronouns, relational participles after participle processing, etc.), and the text with high similarity is determined as the target text.
[0125] Step 4: The entity relationship extraction module 104 extracts the target entities corresponding to the generalization pattern in the target text, and determines the relationship in the generalization pattern as the target relationship of the target entities.
[0126] Specifically, the extraction of the target entities corresponding to the generalization pattern in the target text, and the determination of the relationship in the generalization pattern as the target relationship of the target entities includes:
[0127] Using a preset entity extraction model to extract the target entities in the target text;
[0128] Filling the target entities into the generalization pattern, and determining the relationship in the generalization pattern as the target relationship of the target entities.
[0129] In an embodiment of the present invention, the preset entity extraction model can be a Lattice LSTM model, a CAN-NER model, etc. For example, based on the keyword "sales" in the generalization pattern <Entity B>-sales-<Entity C>, the target text is found to be "Company A hires Employee B as a salesperson". The target entities are determined as "Company A" and "Employee B" through the entity extraction model, and filled into the generalization pattern <Entity B>-sales-<Entity C> to obtain <Company A>-sales-<Employee B>.
[0130] In this embodiment, by expanding the basic pattern of enterprise figures in the target enterprise, an extended pattern of enterprise figures is obtained. Through keyword replacement generalization processing and keyword participle generalization processing on the extended pattern of enterprise figures, a generalization pattern of enterprise figures is obtained, which can continuously and deeply挖掘 the entity relationships between different figures in the target enterprise. Finally, using the generalization pattern to match the target text in the enterprise-related data set, the figure relationships can be quickly and accurately extracted from the target text. Therefore, the enterprise figure relationship extraction device proposed by the present invention can improve the accuracy of figure relationship extraction.
[0131] As Figure 3 shown, it is a schematic structural diagram of an electronic device for implementing the enterprise figure relationship extraction method provided by an embodiment of the present invention.
[0132] The electronic device may include a processor 10, a memory 11, a communication interface 12, and a bus 13, and may further include a computer program stored in the memory 11 and executable on the processor 10, such as an enterprise figure relationship extraction program.
[0133] Among them, the memory 11 includes at least one type of readable storage medium, and the readable storage medium includes a flash memory, a mobile hard disk, a multimedia card, a card-type memory (for example: SD or DX memory, etc.), a magnetic memory, a disk, an optical disk, etc. In some embodiments, the memory 11 can be an internal storage unit of an electronic device, such as a mobile hard disk of the electronic device. In other embodiments, the memory 11 can also be an external storage device of an electronic device, such as a plug-in mobile hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (SecureDigital, SD) card, a flash card (Flash Card), etc. equipped on the electronic device. Furthermore, the memory 11 can also include both an internal storage unit of the electronic device and an external storage device. The memory 11 can not only be used to store application software and various types of data installed in the electronic device, such as the code of the enterprise person relationship extraction program, but can also be used to temporarily store data that has been output or is to be output.
[0134] In some embodiments, the processor 10 may be composed of an integrated circuit, for example, a single packaged integrated circuit, or a plurality of packaged integrated circuits with the same or different functions, including one or more central processing units (CPUs), microprocessors, digital processing chips, graphics processors, and a combination of various control chips. The processor 10 is the control core (Control Unit) of the electronic device, connecting the various components of the entire electronic device using various interfaces and lines, and executing or executing programs or modules stored in the memory 11 (such as a corporate person relationship extraction program, etc.), as well as calling data stored in the memory 11, to perform various functions of the electronic device and process data.
[0135] The communication interface 12 is used for communication between the above-mentioned electronic device and other devices, including a network interface and a user interface. Optionally, the network interface may include a wired interface and / or a wireless interface (such as a WI-FI interface, a Bluetooth interface, etc.), which is generally used to establish a communication connection between the electronic device and other electronic devices. The user interface may be a display (Display), an input unit (such as a keyboard (Keyboard)), optionally, the user interface may also be a standard wired interface, a wireless interface. Optionally, in some embodiments, the display may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, and an OLED (Organic Light-Emitting Diode, organic light-emitting diode) touch device, etc. Among them, the display may also be appropriately referred to as a display screen or a display unit, which is used to display information processed in the electronic device and to display a visual user interface.
[0136] The bus 13 may be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus. The bus 13 may be divided into an address bus, a data bus, a control bus, etc. The bus 13 is configured to enable communication between the memory 11 and at least one processor 10.
[0137] Figure 3 Only the electronic device with components is shown, and it can be understood by those skilled in the art that Figure 3 The structure shown does not limit the electronic device, and may include fewer or more components than shown in the figure, or combine certain components, or arrange the components differently.
[0138] For example, although not shown, the electronic device may further include a power source (such as a battery) for powering various components. Preferably, the power source may be logically connected to the at least one processor 10 via a power management device, thereby implementing functions such as charge management, discharge management, and power consumption management through the power management device. The power source may further include any components such as one or more DC or AC power sources, a recharging device, a power failure detection circuit, a power converter or inverter, a power status indicator, etc. The electronic device may further include various sensors, Bluetooth modules, Wi-Fi modules, etc., which will not be described in detail here.
[0139] Furthermore, the electronic device may also include a network interface. Optionally, the network interface may include a wired interface and / or a wireless interface (such as a WI-FI interface, a Bluetooth interface, etc.), which is generally used to establish a communication connection between the electronic device and other electronic devices.
[0140] Optionally, the electronic device may further include a user interface, which may be a display or an input unit (such as a keyboard). Optionally, the user interface may also be a standard wired interface or a wireless interface. Optionally, in some embodiments, the display may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, or an OLED (Organic Light-Emitting Diode) touch device. The display may also be appropriately referred to as a display screen or a display unit, which is used to display information processed in the electronic device and to display a visual user interface.
[0141] It should be understood that the embodiment is for illustration only and the scope of the patent application is not limited to this structure.
[0142] The enterprise person relationship extraction program stored in the memory 11 of the electronic device is a combination of multiple instructions. When running in the processor 10, it can achieve the following:
[0143] Constructing a basic model of corporate characters in the target enterprise, and performing character extension on the basic model to obtain an extended model of the corporate characters;
[0144] Performing keyword replacement generalization processing and keyword segmentation generalization processing on the extended pattern of the enterprise character to obtain a generalized pattern of the enterprise character;
[0145] Acquire an enterprise-related data set of the target enterprise, and match target text in the enterprise-related data set using the generalized pattern;
[0146] A target entity corresponding to the generalization pattern in the target text is extracted, and a relationship in the generalization pattern is determined to be a target relationship of the target entity.
[0147] Specifically, the specific implementation method of the processor 10 for the above instructions can refer to the description of the relevant steps in the corresponding embodiment of the accompanying drawings, which will not be repeated here.
[0148] Furthermore, if the module / unit integrated into the electronic device is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. The computer-readable storage medium can be volatile or non-volatile. For example, the computer-readable medium may include: any entity or device capable of carrying the computer program code, a recording medium, a USB flash drive, a mobile hard drive, a magnetic disk, an optical disk, a computer memory, or a read-only memory (ROM).
[0149] The present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program. When the computer program is executed by a processor of an electronic device, the computer program can implement:
[0150] Constructing a basic model of corporate characters in the target enterprise, and performing character extension on the basic model to obtain an extended model of the corporate characters;
[0151] Performing keyword replacement generalization processing and keyword segmentation generalization processing on the extended pattern of the enterprise character to obtain a generalized pattern of the enterprise character;
[0152] Acquire an enterprise-related data set of the target enterprise, and match target text in the enterprise-related data set using the generalized pattern;
[0153] A target entity corresponding to the generalization pattern in the target text is extracted, and a relationship in the generalization pattern is determined to be a target relationship of the target entity.
[0154] In the several embodiments provided by the present invention, it should be understood that the disclosed devices, apparatuses, and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the module division is merely a logical function division, and other division methods may be used in actual implementation.
[0155] The modules described as separate components may or may not be physically separate, and the components shown as modules may or may not be physical units, that is, they may be located in one place or distributed across multiple network elements. Some or all of the modules may be selected to achieve the purpose of the solution of this embodiment according to actual needs.
[0156] In addition, the functional modules in various embodiments of the present invention may be integrated into a single processing unit, each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or hardware plus software functional modules.
[0157] It will be apparent to those skilled in the art that the present invention is not limited to the details of the exemplary embodiments described above, and that the present invention can be implemented in other specific forms without departing from the spirit or essential characteristics of the present invention.
[0158] Therefore, the embodiments should be considered in all respects as illustrative and non-restrictive, and the scope of the invention is defined by the appended claims rather than the foregoing description, and all changes that come within the meaning and range of equivalents of the claims are intended to be embraced therein. Any reference to a figure in a claim should not be construed as limiting the claim to which it relates.
[0159] The embodiments of the present application can acquire and process relevant data based on artificial intelligence technology. Artificial Intelligence (AI) is the theory, method, technology, and application system that uses digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use knowledge to achieve optimal results.
[0160] Fundamental AI technologies generally include sensors, dedicated AI chips, cloud computing, distributed storage, big data processing, operating / interaction systems, and mechatronics. AI software technologies primarily encompass computer vision, robotics, biometrics, speech processing, natural language processing, and machine learning / deep learning.
[0161] Furthermore, it is clear that the word "comprising" does not exclude other units or steps, and the singular does not exclude the plural. Multiple units or devices recited in a system claim may also be implemented by a single unit or device through software or hardware. Second-order terms are used to indicate names and do not imply any particular order.
[0162] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not limiting. Although the present invention has been described in detail with reference to the preferred embodiments, those skilled in the art should understand that the technical solutions of the present invention may be modified or replaced by equivalents without departing from the spirit and scope of the technical solutions of the present invention.
Claims
1. A method for extracting corporate person relationships, characterized in that: The method comprises: Obtaining an employee basic model, a department basic model, and an employee-department basic model of an enterprise persona in a target enterprise in an enterprise organizational structure, constructing a basic model of an enterprise persona in the target enterprise based on the employee basic model, the department basic model, and the employee-department basic model, and performing persona expansion on the basic model to obtain an expanded model of the enterprise persona; Replacing entities in the extended pattern with preset keywords to obtain a first generalized pattern, performing word segmentation on the relations in the extended pattern, and reusing the word segmentations as relations to obtain a second generalized pattern, and determining the first generalized pattern and the second generalized pattern as generalized patterns of the corporate person; Obtaining a data set related to the target enterprise, performing word segmentation on text in the data set, calculating the similarity between a first vector of the word segmentation of the text and a second vector of a keyword of the generalized pattern, and selecting a text corresponding to a similarity greater than a preset threshold as a target text; A target entity corresponding to the generalization pattern in the target text is extracted, and a relationship in the generalization pattern is determined to be a target relationship of the target entity.
2. The method for extracting corporate person relationships as claimed in claim 1, wherein: The acquisition of the employee basic model, department basic model, and employee department basic model of the corporate person in the target enterprise's organizational structure includes: Constructing a basic employee model based on the social relationships among employees in the target enterprise; Constructing a basic departmental model based on the structural relationship between departments in the target enterprise; A basic employee department model is constructed based on the organizational relationship between employees and departments in the target enterprise.
3. The method for extracting corporate person relationships according to claim 1, wherein: The character expansion of the basic model to obtain the extended model of the enterprise character includes: The basic model is expanded based on the department organization relationship and personnel organization relationship in the target enterprise to obtain an expanded model of enterprise characters.
4. The method for extracting corporate person relationships according to claim 1, wherein: The process of performing word segmentation processing on the relationship in the extended pattern and reusing the word segmentation as a relationship to obtain a second generalized pattern includes: Performing word segmentation processing on the relationship in the extended pattern to obtain relationship word segmentations; The extended pattern of the enterprise personages in the target enterprise is reconstructed based on the relational participles, and the entities in the newly constructed extended pattern are replaced with preset keywords to obtain a second generalized pattern.
5. The method for extracting corporate person relationships according to claim 1, wherein: Before calculating the similarity between the first vector of the word segment of the text and the second vector of the keyword of the generalization pattern, the method further includes: Vectorizing the word segmentation of the text to obtain a first vector; The keywords in the generalized pattern are segmented and vectorized to obtain a second vector.
6. The method for extracting corporate person relationships as claimed in claim 1, wherein: The step of extracting a target entity corresponding to the generalization pattern in the target text and determining a relationship in the generalization pattern as a target relationship of the target entity includes: Extracting target entities from the target text using a preset entity extraction model; The target entity is filled into the generalization schema, and a relationship in the generalization schema is determined to be a target relationship of the target entity.
7. A device for extracting corporate person relationships, characterized in that: The device comprises: A model expansion module is used to obtain the employee basic model, department basic model and employee department basic model of the enterprise person in the enterprise organizational structure of the target enterprise, construct the basic model of the enterprise person based on the employee basic model, the department basic model and the employee department basic model, and perform character expansion on the basic model to obtain the extended model of the enterprise person; a pattern generalization module, configured to replace entities in the extended pattern with preset keywords to obtain a first generalized pattern, perform word segmentation on relations in the extended pattern, and re-use the word segmentations as relations to obtain a second generalized pattern, and determine that the first generalized pattern and the second generalized pattern are generalized patterns of the corporate persona; a text matching module configured to obtain a set of enterprise-related data of the target enterprise, segment text in the set of enterprise-related data, calculate the similarity between a first vector of the segmented text and a second vector of a keyword of the generalized pattern, and select a text having a similarity greater than a preset threshold as a target text; The entity relationship extraction module is used to extract the target entity corresponding to the generalization pattern in the target text, and determine that the relationship in the generalization pattern is the target relationship of the target entity.
8. An electronic device, characterized in that: The electronic device comprises: at least one processor; and, a memory communicatively connected to the at least one processor; wherein, The memory stores a computer program that can be executed by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can execute the enterprise person relationship extraction method as described in any one of claims 1 to 6.
9. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the method for extracting enterprise person relationships as described in any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Data expansion method, device and equipment and storage medium
CN111506623A
Intelligence information acquisition method surrounding specific target
CN111967250A