Enterprise information acquisition method and acquisition system

By obtaining and updating the links of the enterprise's official website based on the information collection frequency, the problems of untimely collection of information on different enterprises and waste of resources have been solved, and comprehensive and timely collection of enterprise information on different update frequencies have been achieved.

CN119166914APending Publication Date: 2024-12-20SHANGHAI WEIWENJIA INFORMATION TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310692524.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-06-12
Publication Date
2024-12-20

AI Technical Summary

Technical Problem

It is difficult to effectively obtain information on the official websites of different enterprises, especially due to the different update frequency, the problem of untimely information collection and resource waste.

Method used

By obtaining the link to be accessed on the enterprise official website based on the preset weight value of the information collection frequency, we will determine whether it is the first visit, use keyword recognition technology to extract the target link, open the display page, extract the enterprise information, and compare it with the database, and update it Information collection frequency to adapt to different update frequencies.

Benefits of technology

It realizes comprehensive and timely collection of information from enterprises with different update frequencies, avoids waste of resources and ensures timely update of information.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119166914A_ABST
    Figure CN119166914A_ABST
Patent Text Reader

Abstract

The invention provides an enterprise information acquisition method and acquisition system. The method comprises the following steps: acquiring a link to be accessed of an enterprise official website according to a preset weight value of an information acquisition frequency; if the to-be-accessed link is a first access link, opening a first display page corresponding to the to-be-accessed link, and extracting a target link corresponding to a preset keyword in the first display page; if the to-be-accessed link is not the first access link, determining that the to-be-accessed link is a target link; opening a second display page corresponding to the target link and obtaining target enterprise information; comparing the target enterprise information with enterprise information corresponding to a link to be accessed in a preset first database; and if the target enterprise information is different from the enterprise information, updating the enterprise information and subtracting a preset step length from a preset weight value corresponding to the to-be-accessed link. Different acquisition frequencies are set for enterprise official websites with different updating frequencies, and links including enterprise information are accessed according to the acquisition frequencies, so that the enterprise information with different updating frequencies is extracted comprehensively and timely.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of information updating, and in particular to a method and system for collecting enterprise information. Background Art

[0002] If you want to obtain a company's contact information and other corporate information, the general way is to directly visit the company's official website and extract the company's corporate information from the homepage of the company's official website. However, due to the different structures of different official websites, corporate information may not be directly displayed on the homepage. Extracting the company's contact information directly from the homepage of the company's official website can only obtain surface data, and cannot accurately locate the location of the required corporate information, which is prone to data loss. At the same time, the update time of each corporate official website is different. If the same information extraction cycle is used for all corporate official websites, it will cause a lot of waste of resources, and for those companies with high web page information update frequency, their corporate information cannot be extracted in time. Summary of the invention

[0003] In view of this, an object of the present invention is to provide a method and system for collecting enterprise information, so as to comprehensively and timely extract enterprise information of enterprises with different update frequencies, thereby avoiding waste of resources.

[0004] In a first aspect, an embodiment of the present invention provides a method for collecting enterprise information, including: obtaining a link to be visited of an enterprise official website according to a preset weight value of an information collection frequency; determining whether the link to be visited is a first-time visited link; if the link to be visited is a first-time visited link, opening a first display page corresponding to the link to be visited, and extracting a target link corresponding to a preset keyword in the first display page through keyword recognition technology; if the link to be visited is not a first-time visited link, determining that the link to be visited is a target link; opening a second display page corresponding to the target link, and extracting target enterprise information in the second display page; comparing the target enterprise information with the enterprise information corresponding to the link to be visited in a preset first database; if the target enterprise information is different from the enterprise information, updating the enterprise information according to the target enterprise information, and subtracting a preset step size from the preset weight value of the information collection frequency corresponding to the link to be visited to obtain an updated weight value, so as to update the enterprise information corresponding to the link to be visited based on the updated weight value.

[0005] Furthermore, the preset weight value of the information collection frequency is determined by the following steps: obtaining the corporate official website link in the preset second database; extracting the target domain name information in the corporate official website link, and comparing the target domain name information with the domain name information in the first database; if the target domain name information is different from the domain name information, saving the target domain name information to the first database, determining the corporate official website link corresponding to the target domain name information as the link to be visited, and determining the preset weight value of the information collection frequency corresponding to the link to be visited as the initial weight value.

[0006] Furthermore, the step of determining whether the link to be accessed is the first access link includes: obtaining enterprise information corresponding to the link to be accessed in the first database; if the enterprise information is empty, determining that the link to be accessed is the first access link.

[0007] Furthermore, the target enterprise information includes enterprise contact information; opening the second display page corresponding to the target link, and extracting the target enterprise information in the second display page includes: accessing the second display page corresponding to the target link; extracting the enterprise contact information in the second display page according to a preset regular expression.

[0008] Furthermore, the target enterprise information also includes a web page snapshot file; the step of opening the second display page corresponding to the target link and extracting the target enterprise information in the second display page also includes: confirming that the second display page has been loaded; traversing all web page content elements in the second display page and obtaining web page snapshot elements corresponding to the web page content elements; synthesizing all web page snapshot elements to obtain a web page snapshot file corresponding to the second display page. Furthermore, the target enterprise information also includes a hash value of the page bytecode of the enterprise's official website; the step of opening the second display page corresponding to the target link and extracting the target enterprise information in the second display page also includes: accessing the second display page corresponding to the target link; encrypting all page bytecodes in the second display page using a preset encryption algorithm to obtain a target hash value of the enterprise's official website.

[0009] Furthermore, if the target enterprise information is different from the enterprise information, after the step of updating the enterprise information according to the target enterprise information, the method further includes: if the weight value is 1, keeping the preset weight value unchanged.

[0010] Furthermore, the method also includes: if the target enterprise information is the same as the enterprise information, or the enterprise information is empty, keeping the preset weight value of the information collection frequency corresponding to the link to be accessed unchanged.

[0011] In a second aspect, an embodiment of the present invention provides a system for collecting enterprise information, including: a link acquisition module, which is used to obtain a link to be visited of an enterprise official website according to a preset weight value of an information collection frequency; a target link determination module, which is used to determine whether the link to be visited is a first-time visited link; if the link to be visited is a first-time visited link, open a first display page corresponding to the link to be visited, and extract a target link corresponding to a preset keyword in the first display page through keyword recognition technology; if the link to be visited is not a first-time visited link, determine that the link to be visited is the target link; an enterprise information acquisition module, which is used to open a second display page corresponding to the target link, and extract target enterprise information in the second display page; an enterprise information comparison module, which is used to compare the target enterprise information with the enterprise information corresponding to the link to be visited in a preset first database; an enterprise information collection module, which is used to update the enterprise information according to the target enterprise information if the target enterprise information is different from the enterprise information, and subtract the preset step size from the preset weight value of the information collection frequency corresponding to the link to be visited to obtain an updated weight value, so as to update the enterprise information corresponding to the link to be visited based on the updated weight value.

[0012] In a third aspect, an embodiment of the present invention provides an electronic device, including a memory and a processor, wherein the memory stores a computer program executable on the processor, and the processor implements the method described above when executing the computer program.

[0013] The embodiment of the present invention provides a method and system for collecting enterprise information, including: obtaining a link to be visited of an enterprise official website according to a preset weight value of information collection frequency; judging whether the link to be visited is a link to be visited for the first time; if the link to be visited is a link to be visited for the first time, opening a first display page corresponding to the link to be visited, and extracting a target link corresponding to a preset keyword in the first display page through a keyword recognition technology; if the link to be visited is not a link to be visited for the first time, determining that the link to be visited is a target link; opening a second display page corresponding to the target link, and obtaining target enterprise information in the second display page; comparing the target enterprise information with the enterprise information corresponding to the link to be visited in a preset first database; if the target enterprise information is different from the enterprise information, updating the enterprise information according to the target enterprise information, and subtracting a preset step length from a preset weight value of the information collection frequency corresponding to the link to be visited to obtain an updated weight value, so as to update the enterprise information corresponding to the link to be visited based on the updated weight value. In this method, by setting different collection frequencies for enterprise official websites with different update frequencies, and accessing links including enterprise information according to the collection frequencies, enterprise information with different update frequencies can be comprehensively and timely extracted.

[0014] Other features and advantages of the present invention will be described in the following description, and partly become apparent from the description, or understood by practicing the present invention. The purpose and other advantages of the present invention are realized and obtained by the structures particularly pointed out in the description, claims and drawings.

[0015] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, preferred embodiments are given below and described in detail with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0017] Figure 1 A flowchart of a method for collecting enterprise information provided in Embodiment 1 of the present invention;

[0018] Figure 2 A flowchart of a method for determining a preset weight value of information collection frequency provided in Embodiment 1 of the present invention;

[0019] Figure 3 A flowchart of a method for extracting target enterprise information when the target enterprise information is enterprise contact information provided in the first embodiment of the present invention;

[0020] Figure 4 A flowchart of a method for extracting target enterprise information when the target enterprise information is a web page snapshot file provided in the first embodiment of the present invention;

[0021] Figure 5 A flowchart of a method for extracting target enterprise information when the target enterprise information is a hash value of a page bytecode of an enterprise official website provided in the first embodiment of the present invention;

[0022] Figure 6 This is a schematic diagram of a system for collecting enterprise information provided in Embodiment 2 of the present invention.

[0023] Icons: 1-link acquisition module; 2-target link determination module; 3-enterprise information acquisition module; 4-enterprise information comparison module; 5-enterprise information collection module. DETAILED DESCRIPTION

[0024] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the accompanying drawings. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0025] To facilitate understanding of this embodiment, the embodiment of the present invention is described in detail below.

[0026] Embodiment 1:

[0027] Figure 1 This is a flow chart of the method for collecting enterprise information provided in Example 1 of the present invention.

[0028] Reference Figure 1 , the collection methods of enterprise information include:

[0029] Step S101, obtaining the to-be-visited link of the enterprise official website according to the preset weight value of the information collection frequency.

[0030] Here, the link to be visited is stored in the first database. The first database stores more than one link to be visited.

[0031] In one embodiment, referring to Figure 2 , the preset weight value of the information collection frequency is determined by the following steps:

[0032] Step S201, obtaining the corporate official website link in a preset second database.

[0033] Here, the preset second database stores all the enterprise official website links that need to be accessed in advance. These enterprise official website links are the official websites of the enterprises whose enterprise information actually needs to be obtained.

[0034] Step S202: extract the target domain name information in the corporate official website link, and compare the target domain name information with the domain name information in the first database.

[0035] Here, the target domain name information refers to the information up to ".com" in the company's official website link. For example, http: / / www.xxyyzz.com / is a domain name information.

[0036] Step S203, if the target domain name information is different from the domain name information, the target domain name information is saved to the first database, the corporate official website link corresponding to the target domain name information is determined as the link to be visited, and the preset weight value of the information collection frequency corresponding to the link to be visited is determined as the initial weight value.

[0037] Here, when the target domain name information is different from the domain name information, it means that the enterprise official website link corresponding to the target domain name information has not been stored in the first database before, and the enterprise official website link is determined as a link to be accessed and saved in the first database. At this time, only the enterprise official website link is saved and the link is not accessed.

[0038] The preset weight value of the information collection frequency indicates the number of times the link to be visited is accessed. The initial weight value can be set according to the actual situation. In this embodiment, the initial weight value can be set to 4, which means that the link to be visited is accessed once every 4 weeks to update the enterprise information.

[0039] Step S102, determining whether the link to be accessed is the first access link.

[0040] In one embodiment, step S102 includes:

[0041] The enterprise information corresponding to the link to be accessed in the first database is obtained.

[0042] Here, the enterprise information includes enterprise contact information, web page snapshot files, and hash values ​​of the page bytecodes of the enterprise's official website.

[0043] If the enterprise information is empty, determine that the link to be accessed is the first access link.

[0044] Step S103: if the link to be visited is the first time to be visited, open the first display page corresponding to the link to be visited, and extract the target link corresponding to the preset keyword in the first display page by using the keyword recognition technology.

[0045] Here, the preset keyword can be preset according to actual conditions. In order to extract the enterprise contact information, the preset keyword can be set to "Contact Us". There is at least one preset keyword. The target link is a link containing the enterprise contact information.

[0046] Specifically, if the first display page corresponding to the link to be accessed contains "Contact Us", and the "Contact Us" corresponds to an A tag (hyperlink), the A tag corresponding to "Contact Us" is found through keyword recognition technology, and the link corresponding to the A tag is extracted as the target link. The target link is a link containing the company's contact information. At the same time, the link to be accessed is replaced with the target link and saved in the first database.

[0047] If "Contact Us" in the first display page is not a hyperlink, it means that the first display page includes the enterprise contact information, and the link to be visited is determined to be the target link.

[0048] Step S104: if the link to be visited is not the first visited link, determine that the link to be visited is a target link.

[0049] Here, if the link to be visited is not the first time to visit the link, it means that the enterprise contact information can be directly obtained from the link to be visited, and the link to be visited is the target link.

[0050] Step S105: open the second display page corresponding to the target link, and extract the target enterprise information in the second display page.

[0051] Here, the target enterprise information includes enterprise contact information, web page snapshot files, and hash values ​​of page bytecodes of the enterprise's official website.

[0052] The second display page is a page containing the company's contact information.

[0053] In one embodiment, referring to Figure 3 When the target enterprise information is enterprise contact information, the steps of step S105 include:

[0054] Step S301, accessing a second display page corresponding to a target link.

[0055] Step S302: extracting the enterprise contact information in the second display page according to a preset regular expression.

[0056] Here, the company contact information can be telephone number, mobile phone number, email address and QQ number.

[0057] Specifically, the preset regular expressions may include:

[0058] (1) QQ number extraction regular formula ([Qq][]*[Qq])[::][]*(\\d+);

[0059] (2) Regular expression for extracting mobile phone numbers: \\b1[3-9][0-9]([-—]?\\d{4}[]?){2}\\b;

[0060] (3) Email extraction rules:

[0061] \\b\\w+([-+.]\\w+)*@\\w+([-.]\\w+)*\\.\\w+([-.]\\w+)*\\b;

[0062] (4) Fixed-line phone number extraction rules:

[0063] \\b(400|800|010|02\\d|85[2-3]|0[3-9]\\d{2})\\d? [--]? \\d{2,4}[--]? \\d{2,4}\\b

[0064] (1) The explanation of the QQ number extraction regular expression is as follows:

[0065] -([Qq][]*[Qq]): indicates a pattern matching "QQ" or "qq". Among them:

[0066] -[Qq]: matches either the uppercase or lowercase letter "Q" or "q".

[0067] -[]*: Matches zero or more spaces.

[0068] -[Qq]: means to match any one of the uppercase and lowercase letters "Q" or "q" again.

[0069] -[::]: means matching an English colon or a Chinese colon.

[0070] -[]*: Matches zero or more spaces.

[0071] -(\\d+): means matching one or more digits, used to match QQ numbers.

[0072] This regular expression can match QQ numbers in the following formats:

[0073] -QQ: 123456789

[0074] -qq:987654321

[0075] -QQ:456789012

[0076] Please note that this regular expression is just a pattern for extracting QQ numbers, it does not verify whether the number actually exists or is valid.

[0077] (2) The explanation of the regular expression for extracting mobile phone numbers is as follows:

[0078] -\\b: indicates a word boundary and is used to match the starting position of a mobile phone number.

[0079] -1: Indicates that the first digit of the mobile phone number must be 1.

[0080] -[3-9]: indicates that the second digit of the mobile phone number can be any number from 3 to 9.

[0081] -[0-9]: indicates that the third to tenth digits of the mobile phone number can be any digits.

[0082] -([--]?\\d{4}[]?){2}: means matching an optional connector (minus sign, period or space), followed by four consecutive digits, and optionally followed by a space. This pattern can be repeated twice.

[0083] -\\b: indicates a word boundary and is used to match the end position of a mobile phone number.

[0084] This regular expression can match mobile phone numbers in various formats, for example:

[0085] -13812345678

[0086] -159-1234-5678

[0087] -177 1234 5678

[0088] -186-1234-5678

[0089] Please note that this regular expression is just a pattern for extracting mobile numbers, it does not verify whether the number actually exists or is valid.

[0090] (3) The explanation of the mailbox extraction regular expression is as follows:

[0091] -\\b: Indicates a word boundary and is used to match the start position of an email address.

[0092] -\\w+: matches one or more letters, numbers, or underscores, and is used to match the username part of the mailbox.

[0093] -([-+.]\\w+)*: represents a pattern that matches an optional special character (minus sign, plus sign, or period) followed by one or more letters, numbers, or underscores. This pattern can be repeated zero or more times to match the special character portion of the username.

[0094] -@: Indicates matching the "at" symbol in the email address.

[0095] -\\w+: matches one or more letters, numbers, or underscores, and is used to match the domain name of the mailbox.

[0096] -([-.]\\w+)*: represents a pattern that matches an optional special character (minus sign or period) followed by one or more letters, numbers, or underscores. This pattern can be repeated zero or more times to match the special character part of the domain name.

[0097] -\\.: Indicates matching a period in an email address.

[0098] -\\w+: matches one or more letters, numbers, or underscores, and is used to match the top-level domain name of the mailbox.

[0099] -([-.]\\w+)*: represents a pattern that matches an optional special character (minus sign or period) followed by one or more letters, numbers, or underscores. This pattern can be repeated zero or more times to match the special character portion of the top-level domain name.

[0100] -\\b: Indicates a word boundary and is used to match the end of an email address.

[0101] This regular expression can match email addresses in various formats, for example:

[0102] -example@example.com

[0103] - john.doe@example.co.uk

[0104] -first.last+middle@example.com

[0105] -my.email@example-123.com

[0106] Note that this regular expression is just a pattern for extracting email addresses; it does not verify that the address actually exists or is valid.

[0107] (4) The explanation of the fixed-line phone extraction rule is as follows:

[0108] -\\b: Indicates a word boundary and is used to match the starting position of a number.

[0109] -(400|800|010|02\\d|85[2-3]|0[3-9]\\d{2}): This is the first group, which is used to match the prefix of the phone number.

[0110] -400, 800, 010: are three fixed number prefixes.

[0111] -02\\d: indicates a number starting with 02 and followed by a digit.

[0112] -85[2-3]: indicates a number starting with 85 and followed by 2 or 3.

[0113] -0[3-9]\\d{2}: represents a number that starts with 0 and is followed by a number and then two arbitrary numbers.

[0114] -\\d? : Indicates matching an optional number.

[0115] -[--]? : Indicates matching an optional connector, which can be -, - or space.

[0116] -\\d{2,4}: matches 2 to 4 consecutive digits.

[0117] -[--]?: Again, it matches an optional connector.

[0118] -\\d{2,4}: Again, it means match 2 to 4 consecutive digits.

[0119] -\\b: Indicates a word boundary and is used to match the end position of a number.

[0120] This regular expression can match landline numbers in various formats, for example:

[0121] -400-1234-5678

[0122] -800 1234 5678

[0123] -01012345678

[0124] -021-123456

[0125] -853-1234-5678

[0126] -03791234

[0127] Please note that this regular expression is just a pattern for extracting phone numbers, it does not verify whether the number actually exists or is valid.

[0128] In one embodiment, referring to Figure 4 When the target enterprise information is a web page snapshot file, the steps of step S105 include:

[0129] Step S401, confirming that the loading of the second display page is complete.

[0130] Step S402: traverse all web page content elements in the second display page, and obtain web page snapshot elements corresponding to the web page content elements.

[0131] Here, the webpage content element is obtained by traversing all webpage contents in the second display page according to the webpage content. The webpage content element content can be source code, text, image, video, etc. The webpage snapshot element includes the hypertext markup language HTML source code of the webpage and the resources in the webpage.

[0132] Step S403: synthesize all web page snapshot elements to obtain a web page snapshot file corresponding to the second display page.

[0133] In one embodiment, referring to Figure 5 When the target enterprise information is the hash value of the page bytecode of the enterprise's official website, the steps of step S105 include:

[0134] Step S501, accessing a second display page corresponding to a target link.

[0135] Step S502, encrypt all page bytecodes in the second display page using a preset encryption algorithm to obtain a target hash value of the enterprise official website.

[0136] Here, the preset encryption algorithm may be MD5 (Message Digest Algorithm MD5, message digest algorithm).

[0137] Specifically, the second display page content is converted into a byte array to obtain the bytecode of the second display page. The second display page bytecode is imported into the MD5 library or tool, and the MD5 encryption algorithm provided by the MD5 library is used to take the bytecode of the page as input to calculate the target hash value. This will generate a string consisting of hexadecimal numbers of a fixed length.

[0138] Step S106: compare the target enterprise information with the enterprise information corresponding to the link to be accessed in the preset first database.

[0139] Step S107, if the target enterprise information is different from the enterprise information, update the enterprise information according to the target enterprise information, and subtract the preset step size from the preset weight value of the information collection frequency corresponding to the link to be visited to obtain an updated weight value, so as to update the enterprise information corresponding to the link to be visited based on the updated weight value.

[0140] Here, if the target enterprise information is different from the enterprise information, it means that the enterprise information in the link to be visited has been updated, and the enterprise information is updated according to the target enterprise information, and the information collection frequency is adjusted by adjusting the preset weight value corresponding to the link to be visited.

[0141] The preset step size can be set according to actual conditions, and is set to 1 in this embodiment.

[0142] If the weight value is 1, keep the preset weight value unchanged.

[0143] Here, the preset weight value is at least 1, that is, the link to be visited is visited once every week.

[0144] In one embodiment, the method further comprises:

[0145] If the target enterprise information is the same as the enterprise information, or the enterprise information is empty, the preset weight value of the information collection frequency corresponding to the link to be accessed is kept unchanged.

[0146] Here, when the enterprise information of the enterprise corresponding to the link to be accessed is not updated or the link to be accessed is the first time to be accessed, the information collection frequency and its corresponding preset weight value remain unchanged.

[0147] The embodiment of the present invention provides a method for collecting enterprise information, including: obtaining a link to be visited of an enterprise official website according to a preset weight value of information collection frequency; judging whether the link to be visited is a link to be visited for the first time; if the link to be visited is a link to be visited for the first time, opening a first display page corresponding to the link to be visited, and extracting a target link corresponding to a preset keyword in the first display page through a keyword recognition technology; if the link to be visited is not a link to be visited for the first time, determining that the link to be visited is a target link; opening a second display page corresponding to the target link, and obtaining target enterprise information in the second display page; comparing the target enterprise information with the enterprise information corresponding to the link to be visited in a preset first database; if the target enterprise information is different from the enterprise information, updating the enterprise information according to the target enterprise information, and subtracting a preset step length from a preset weight value of the information collection frequency corresponding to the link to be visited to obtain an updated weight value, so as to update the enterprise information corresponding to the link to be visited based on the updated weight value. In this method, by setting different collection frequencies for enterprise official websites with different update frequencies, and accessing links including enterprise information according to the collection frequencies, enterprise information with different update frequencies can be comprehensively and timely extracted.

[0148] Embodiment 2:

[0149] Figure 6 This is a schematic diagram of a system for collecting enterprise information provided in Embodiment 2 of the present invention.

[0150] Reference Figure 6 , the enterprise information collection system includes:

[0151] The link acquisition module 1 is used to acquire the link to be visited of the enterprise official website according to the preset weight value of the information collection frequency.

[0152] The target link determination module 2 is used to determine whether the link to be accessed is the first access link.

[0153] If the link to be visited is the first visited link, open the first display page corresponding to the link to be visited, and extract the target link corresponding to the preset keyword in the first display page by using the keyword recognition technology;

[0154] If the link to be visited is not the first visited link, determining that the link to be visited is the target link;

[0155] The enterprise information acquisition module 3 is used to open the second display page corresponding to the target link and acquire the target enterprise information in the second display page.

[0156] The enterprise information comparison module 4 is used to compare the target enterprise information with the enterprise information corresponding to the link to be accessed in the preset first database.

[0157] The enterprise information collection module 5 is used to update the enterprise information according to the target enterprise information if the target enterprise information is different from the enterprise information, and to subtract the preset step size from the preset weight value of the information collection frequency corresponding to the link to be visited to obtain an updated weight value, so as to update the enterprise information corresponding to the link to be visited based on the updated weight value.

[0158] The embodiment of the present invention provides a system for collecting enterprise information, including: obtaining a link to be visited of an enterprise official website according to a preset weight value of information collection frequency; judging whether the link to be visited is a link to be visited for the first time; if the link to be visited is a link to be visited for the first time, opening a first display page corresponding to the link to be visited, and extracting a target link corresponding to a preset keyword in the first display page through a keyword recognition technology; if the link to be visited is not a link to be visited for the first time, determining that the link to be visited is a target link; opening a second display page corresponding to the target link, and obtaining target enterprise information in the second display page; comparing the target enterprise information with the enterprise information corresponding to the link to be visited in a preset first database; if the target enterprise information is different from the enterprise information, updating the enterprise information according to the target enterprise information, and subtracting a preset step length from a preset weight value of the information collection frequency corresponding to the link to be visited to obtain an updated weight value, so as to update the enterprise information corresponding to the link to be visited based on the updated weight value. In this method, by setting different collection frequencies for enterprise official websites with different update frequencies, and accessing links including enterprise information according to the collection frequencies, enterprise information with different update frequencies can be comprehensively and timely extracted.

[0159] An embodiment of the present invention also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the method for collecting enterprise information provided in the above embodiment are implemented.

[0160] The computer program product provided in the embodiment of the present invention includes a computer-readable storage medium storing program code. The instructions included in the program code can be used to execute the method described in the previous method embodiment. The specific implementation can be found in the method embodiment and will not be repeated here.

[0161] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the system and device described above can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.

[0162] In addition, in the description of the embodiments of the present invention, unless otherwise clearly specified and limited, the terms "installed", "connected", and "connected" should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection or an indirect connection through an intermediate medium, or it can be the internal communication of two components. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.

[0163] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc., which can store program codes.

[0164] In the description of the present invention, it should be noted that the terms "center", "upper", "lower", "left", "right", "vertical", "horizontal", "inner", "outer", etc., indicating the orientation or positional relationship, are based on the orientation or positional relationship shown in the drawings, and are only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as limiting the present invention. In addition, the terms "first", "second", and "third" are used for descriptive purposes only, and cannot be understood as indicating or implying relative importance.

[0165] Finally, it should be noted that the above-described embodiments are only specific implementations of the present invention, which are used to illustrate the technical solutions of the present invention, rather than to limit them. The protection scope of the present invention is not limited thereto. Although the present invention is described in detail with reference to the above-described embodiments, ordinary technicians in the field should understand that any technician familiar with the technical field can still modify the technical solutions recorded in the above-described embodiments within the technical scope disclosed by the present invention, or can easily think of changes, or make equivalent replacements for some of the technical features therein; and these modifications, changes or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention shall be based on the protection scope of the claims.

Claims

1. A method for collecting enterprise information, characterized in that: include: Obtain the link to be visited of the enterprise official website according to the preset weight value of the information collection frequency; Determine whether the link to be accessed is a link accessed for the first time; If the link to be visited is the first visited link, open a first display page corresponding to the link to be visited, and extract a target link corresponding to a preset keyword in the first display page by using a keyword recognition technology; If the link to be visited is not the first visited link, determining that the link to be visited is the target link; Opening a second display page corresponding to the target link, and extracting target enterprise information from the second display page; Comparing the target enterprise information with the enterprise information corresponding to the link to be accessed in the preset first database; If the target enterprise information is different from the enterprise information, the enterprise information is updated according to the target enterprise information, and the preset weight value of the information collection frequency corresponding to the link to be visited is subtracted from the preset step size to obtain an updated weight value, so as to update the enterprise information corresponding to the link to be visited based on the updated weight value.

2. The method for collecting enterprise information according to claim 1, characterized in that: The preset weight value of the information collection frequency is determined by the following steps: Obtain the official website link of the enterprise in the preset second database; Extracting target domain name information from the enterprise official website link, and comparing the target domain name information with the domain name information in the first database; If the target domain name information is different from the domain name information, the target domain name information is saved to the first database, the enterprise official website link corresponding to the target domain name information is determined to be the link to be visited, and the preset weight value of the information collection frequency corresponding to the link to be visited is determined to be the initial weight value.

3. The method for collecting enterprise information according to claim 1, characterized in that: The step of determining whether the link to be accessed is a link accessed for the first time includes: Acquire the enterprise information corresponding to the link to be accessed in the first database; If the enterprise information is empty, it is determined that the link to be accessed is a link accessed for the first time.

4. The method for collecting enterprise information according to claim 1, characterized in that: The target enterprise information includes enterprise contact information; The step of opening the second display page corresponding to the target link and extracting the target enterprise information in the second display page includes: Accessing the second display page corresponding to the target link; The enterprise contact information in the second display page is extracted according to a preset regular expression.

5. The method for collecting enterprise information according to claim 1, characterized in that: The target enterprise information also includes web page snapshot files; The step of opening the second display page corresponding to the target link and extracting the target enterprise information in the second display page also includes: Confirm that the second display page has been loaded; Traversing all web page content elements in the second display page, and obtaining web page snapshot elements corresponding to the web page content elements; All the web page snapshot elements are synthesized to obtain a web page snapshot file corresponding to the second display page.

6. The method for collecting enterprise information according to claim 1, characterized in that: The target enterprise information also includes the hash value of the page bytecode of the enterprise's official website; The step of opening the second display page corresponding to the target link and extracting the target enterprise information in the second display page also includes: Accessing the second display page corresponding to the target link; All page bytecodes in the second display page are encrypted using a preset encryption algorithm to obtain a target hash value of the enterprise official website.

7. The method for collecting enterprise information according to claim 1, characterized in that: After the step of updating the enterprise information according to the target enterprise information if the target enterprise information is different from the enterprise information, the method further includes: If the weight value is 1, the preset weight value is kept unchanged.

8. The method for collecting enterprise information according to claim 1, characterized in that: The method further comprises: If the target enterprise information is the same as the enterprise information, or the enterprise information is empty, the preset weight value of the information collection frequency corresponding to the link to be accessed is kept unchanged.

9. A system for collecting enterprise information, characterized in that: include: A link acquisition module is used to acquire the link to be visited of the enterprise official website according to the preset weight value of the information collection frequency; A target link determination module, used to determine whether the link to be accessed is a link accessed for the first time; If the link to be visited is the first visited link, open a first display page corresponding to the link to be visited, and extract a target link corresponding to a preset keyword in the first display page by using a keyword recognition technology; If the link to be visited is not the first visited link, determining that the link to be visited is the target link; An enterprise information acquisition module, used to open a second display page corresponding to the target link and extract target enterprise information from the second display page; An enterprise information comparison module, used to compare the target enterprise information with the enterprise information corresponding to the link to be accessed in the preset first database; The enterprise information collection module is used to update the enterprise information according to the target enterprise information if the target enterprise information is different from the enterprise information, and to subtract the preset step size from the preset weight value of the information collection frequency corresponding to the link to be visited to obtain an updated weight value, so as to update the enterprise information corresponding to the link to be visited based on the updated weight value.

10. An electronic device, characterized in that: It comprises a computer-readable storage medium storing a computer program and a processor, and when the computer program is read and executed by the processor, the method for updating enterprise information according to any one of claims 1 to 8 is implemented.