Resource extraction method and device, electronic equipment, storage medium and program product
By receiving resource extraction requests from the user side, searching and matching based on resource location information and description information, and directly returning to the target resource, solving the problems of traditional file transfer strong dependence, cumbersome process and slow speed, and achieving efficient and convenient resource extraction and transmission.
Patent Information
- Application Number
- CN202411863567.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-17
- Publication Date
- 2025-04-18
AI Technical Summary
In the prior art, file transfer is highly dependent, cumbersome and slow, especially in file transfer between private or group, which requires manual upload, link generation and sharing. The entire process is relatively cumbersome, and multiple transfers are usually involved in the file transfer process, which affects the transmission speed and user experience.
A resource extraction method is provided, by receiving a resource extraction request sent by the user, including resource location information and resource description information, retrieval based on resource location information, obtain candidate resources, and determine the target resource to be extracted from the candidate resources based on resource description information, and finally return the target resource to the user.
It realizes automated resource extraction, simplifies the sharing process, reduces intermediate links, enables users to obtain target resources faster and more directly, improves resource acquisition efficiency and convenience, and optimizes user experience.
Smart Images

Figure CN119847993A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a resource extraction method, device, electronic device, storage medium and program product. Background Art
[0002] In the current digital era, file transfer between devices has become an indispensable part of daily life and work. Traditional file transfer methods rely on third-party software, which is convenient but limited by the online status of both parties and the support of third-party software platforms.
[0003] File transfer between individuals or groups is mostly achieved through online cloud disk services. Users only need to upload files to the cloud disk and generate corresponding extraction links and connection keys to achieve multi-person sharing and independent downloading. This model is particularly common in the fields of learning resource sharing and team collaboration. However, although the current cloud disk sharing method is widely used, it requires users to manually upload files, generate links and share them. The whole process is relatively cumbersome, and the file transfer process usually involves multiple transfers, which affects the transmission speed and user experience. Summary of the invention
[0004] The present invention provides a resource extraction method, device, electronic device, storage medium and program product to solve the defects of the prior art in that the file transfer is highly dependent, the process is cumbersome and the speed is slow, and realizes automated resource extraction. The required target resources can be automatically obtained and returned according to the location guidance, which simplifies the sharing process, reduces the intermediate links, enables users to obtain the target resources more quickly and directly, and improves the efficiency and convenience of resource acquisition.
[0005] The present invention provides a resource extraction method, comprising: Receiving a resource extraction request sent by a user terminal, wherein the resource extraction request includes resource location information and resource description information; Perform resource retrieval based on the resource location information to obtain candidate resources; Based on the resource description information, a target resource to be extracted is determined from the candidate resources, and the target resource is returned to the user terminal.
[0006] According to a resource extraction method provided by the present invention, the resource description information includes resource type information and resource content description; The step of determining the target resource to be extracted from the candidate resources based on the resource description information includes: Determining a resource to be selected from the candidate resources based on the resource type information; The resource content description is matched with the resource content of the candidate resources, and based on the matching result, a target resource is determined from the candidate resources.
[0007] According to a resource extraction method provided by the present invention, the resource type information is used to reflect the type of the target resource, and the type includes at least one of a file, an image, and a text segment; the matching of the resource content description with the resource content of the candidate resource includes: In a case where the to-be-selected resources include file resources of the file type, matching the resource content description with a file header and a file title in the resource content of the file resource; In the case where the candidate resources include image resources of the image type, matching the resource content description with the image number and image content in the resource content of the image resource; In the case that the candidate resources include text resources of the type of text segments, semantic matching is performed between the resource content description and the text content in the resource content of the text resource.
[0008] According to a resource extraction method provided by the present invention, the resource retrieval based on the resource location information to obtain candidate resources includes: Determine the information type of the resource location information, the information type including at least one of a website address, a text description, a website address description, and a website address key; Based on the information type and the resource location information, a resource search is performed to obtain candidate resources.
[0009] According to a resource extraction method provided by the present invention, the resource retrieval is performed based on the resource location information based on the information type to obtain candidate resources, including: In the case where the information type is the website description, a web page search is performed based on the resource location information corresponding to the website in the website description, and a resource search is performed in the resource web pages obtained by the web page search based on the resource location information corresponding to the text description in the website description to obtain candidate resources; When the information type is the URL key, a web page search is performed based on the resource location information corresponding to the URL in the URL key, and candidate resources are extracted from the resource web pages obtained by the web page search based on the resource location information corresponding to the key in the URL key.
[0010] According to a resource extraction method provided by the present invention, returning the target resource to the user terminal includes: Storing the target resource locally or storing the target resource in the cloud; Return any one of the target resource, the local storage location of the target resource, or the storage location in the cloud to the user terminal.
[0011] The present invention also provides a resource extraction device, comprising: A request receiving unit, configured to receive a resource extraction request sent by a user terminal, wherein the resource extraction request includes resource location information and resource description information; A resource retrieval unit, configured to perform resource retrieval based on the resource location information to obtain candidate resources; The resource extraction unit is used to determine the target resource to be extracted from the candidate resources based on the resource description information, and return the target resource to the user terminal.
[0012] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and running on the processor, wherein the processor implements any of the resource extraction methods described above when executing the computer program.
[0013] The present invention also provides a non-transitory computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the resource extraction method described in any one of the above is implemented.
[0014] The present invention also provides a computer program product, comprising a computer program, wherein when the computer program is executed by a processor, the resource extraction method as described above is implemented.
[0015] The resource extraction method, device, electronic device, storage medium and program product provided by the present invention receive a resource extraction request sent by a user terminal, wherein the resource extraction request includes resource location information and resource description information; perform resource retrieval based on the resource location information to obtain candidate resources; determine target resources to be extracted from the candidate resources based on the resource description information, and return the target resources to the user terminal, thereby overcoming the defects of traditional solutions such as strong file transfer / resource extraction dependence, cumbersome procedures and slow speed, achieving efficient and convenient resource extraction, simplifying the resource transmission process, reducing intermediate links, and enabling users to obtain required resources more quickly and directly without multiple transfers through cloud disks, thereby greatly improving resource acquisition efficiency and convenience and optimizing user experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] In order to more clearly illustrate the technical solutions in the present invention or the prior art, a brief introduction will be given below to the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0017] Figure 1 It is a schematic diagram of the process of resource extraction method provided by the present invention; Figure 2 It is the overall flow chart of the resource extraction method provided by the present invention; Figure 3 It is a structural schematic diagram of the resource extraction device provided by the present invention; Figure 4 It is a structural schematic diagram of the electronic device provided by the present invention. DETAILED DESCRIPTION
[0018] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings of the present invention. 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.
[0019] Currently, file transfer between devices mainly relies on third-party software, which has a variety of options but is limited by the software platform and online status. Private file transfer is achieved through online cloud disks, which require manual uploading and link generation. The process is cumbersome and requires multiple transfers, which is inefficient.
[0020] In this regard, the present invention provides a resource extraction method, which aims to automatically obtain the required resources based on the location information provided by the user, and instantly return the obtained resources, thereby achieving more efficient and direct resource extraction, simplifying the resource transmission process, and reducing intermediate links, so that users can obtain the required resources more quickly and directly without multiple transfers through the cloud disk, greatly improving the efficiency and convenience of resource acquisition.
[0021] Figure 1 It is a schematic diagram of the process of resource extraction method provided by the present invention, such as Figure 1 As shown, the method can be applied to the server, and the method includes: Step 110, receiving a resource extraction request sent by a user terminal, wherein the resource extraction request includes resource location information and resource description information; Step 120, performing resource search based on resource location information to obtain candidate resources; Step 130: determine the target resource to be extracted from the candidate resources based on the resource description information, and return the target resource to the user end.
[0022] Specifically, considering that the current file transfer between devices relies on third-party software, the choices are diverse but limited by the software platform and online status, and the file transfer between individuals relies on cloud disk services, the process is cumbersome, and involves multiple transfers, slow transmission speed, and low efficiency. In the embodiment of the present invention, it is proposed that when extracting resources, resources can be automatically obtained according to location information, and stored and returned, so as to achieve fast and efficient resource extraction, simplify the resource transmission process, reduce intermediate links, enable users to obtain the required resources more quickly and directly, and provide users with a smoother and more efficient resource extraction experience.
[0023] It is understandable that when there is a need for resource extraction during actual application, the user can issue a request through the terminal device, that is, send a resource extraction request through the user end. The resource extraction request may include information about the resources that the user needs to extract, for example, it may be a content description of the resources to be extracted, or it may be a location guide for the resources to be extracted, or it may be an indication of the resources to be extracted from other angles, such as the resource number, purpose, and relationship with other information, etc. The embodiment of the present invention does not make specific limitations on this.
[0024] As a preferred method, in order to accurately locate and capture the resources required by the user, in the embodiment of the present invention, when extracting resources, the user may be required to provide information that clearly indicates the location of the resource, i.e., resource location information, and information that reflects its content, type, etc., i.e., resource description information. In short, the user sends a resource extraction request through the user terminal, which carries the resource location information that describes the location, and the resource description information that presents its overall content, gist, etc.
[0025] After that, the server can receive the resource extraction request sent by the user, and can extract resources according to the resource location information and resource description information carried in this resource extraction request, so as to obtain and return the resources that the user needs to extract. Specifically, here, after receiving the resource extraction request, it can first perform resource retrieval according to the resource location information in the resource extraction request, so as to locate the resources that the user needs to obtain according to the location guidance. However, considering that the resources retrieved through the resource location information may not be "unique", for example, when the resource location information provided by the user is a textual location description, such as A public account, B forum, etc., at this time, the information obtained through resource retrieval is large, and it is still impossible to accurately determine which ones are needed by the user and which ones are not. Therefore, the resource information retrieved in this step can be called candidate resources, pending further verification and confirmation.
[0026] Correspondingly, in some cases, a preliminary resource search can determine the "unique" resource information. For example, when the resource location information is a specific URL and is accompanied by a key, the "unique" resource information can be obtained through the URL and key. Here, "unique" does not refer to one or a category of resource information, but to the analysis of user needs. When the URL and key are provided, the user's needs are mostly clear, and the extracted resource information is the resource required by the user. Alternatively, in order to further clarify the demand direction and achieve more accurate resource positioning, the resource information initially retrieved can also be used as a candidate resource for further confirmation.
[0027] Furthermore, resource verification and confirmation can be performed based on the resource description information in the resource extraction request, that is, the resource description information can be used to confirm the resources that the user needs to extract, that is, the target resources to be extracted, from the candidate resources obtained by the preliminary resource retrieval. Here, specifically, the candidate resources can be analyzed based on the resource description information to accurately locate the target resources, that is, the attributes, content, etc. of the candidate resources are matched with the resource description information in corresponding dimensions to confirm whether the two match and whether the resource description information describes the corresponding candidate resource, thereby obtaining the result of the matching verification, and the target resource can be determined from the candidate resources based on this, and then the target resource can be returned to the user end, so that the user on the user end side can obtain the target resource immediately, and realize fast and accurate resource extraction.
[0028] Specifically, after obtaining the target resource, when returning the target resource to the user end, the target resource can be stored first, that is, the target resource can be downloaded from the website, public account, forum, etc. retrieved according to the provided resource location information to be stored locally, or the target resource can be directly stored in the cloud. The process of storing in the cloud can be local transfer or direct storage, which is not specifically limited in the embodiment of the present invention. Then, the target resource can be directly returned to the user end that sent the resource extraction request, or the storage address of the target resource in the local / cloud can be returned to the user end, so that the user can directly obtain the target resource according to the detailed and specific storage address, thereby achieving accurate capture of the target resource.
[0029] It should be noted that when storing the target resource, only the target resource may be downloaded and stored locally, or directly stored in the cloud; or all candidate resources may be downloaded, and after the target resource is determined, it may be stored locally, or transferred to the cloud, which is not specifically limited in the embodiment of the present invention. Here, the target resource may be a file, an image, a text or a combination of the above, which is not specifically limited in the embodiment of the present invention.
[0030] It is worth noting that the local storage process is actually the resource transmission process. In traditional solutions, when resources need to be uploaded to the server, users are usually required to download the resources to be transmitted first, and then, with the support of the software platform, use the platform's third-party software as a medium to transmit the resources from the user terminal to the server. In the embodiment of the present invention, the server directly extracts resources based on the resource location information provided by the user, obtains the target resources to be extracted / transmitted, and eliminates the pre-download and intermediate transmission processes, making resource transmission more efficient, convenient, and automated, bringing users a smoother and better resource transmission experience.
[0031] The resource extraction method provided by the present invention receives a resource extraction request sent by a user terminal, wherein the resource extraction request includes resource location information and resource description information; performs resource retrieval based on the resource location information to obtain candidate resources; determines a target resource to be extracted from the candidate resources based on the resource description information, and returns the target resource to the user terminal, thereby overcoming the defects of traditional solutions in that the file transmission / resource extraction is highly dependent, the process is cumbersome, and the speed is slow, thereby realizing efficient and convenient resource extraction, simplifying the resource transmission process, and reducing intermediate links, so that users can obtain the required resources more quickly and directly without multiple transfers through a cloud disk, thereby greatly improving the efficiency and convenience of resource acquisition and optimizing the user experience.
[0032] Based on the above embodiment, the resource description information includes resource type information and resource content description; In step 130, based on the resource description information, a target resource to be extracted is determined from the candidate resources, including: Determine the resource to be selected from the candidate resources based on the resource type information; The resource content description is matched with the resource content of the candidate resource, and based on the matching result, the target resource is determined from the candidate resources.
[0033] Specifically, in step 130, the process of determining the target resource from the candidate resources according to the resource description information may specifically include: First, type judgment can be made based on the resource type information in the resource description information to preliminarily find resource information of the corresponding type of resources that meet the user's needs; that is, resources can be selected from candidate resources based on the resource type information that reflects the type of resources to be extracted, specifically, resource information that matches the type of resources represented by the resource type information can be determined from the candidate resources as the selected resource.
[0034] Then, all the selected resources can be matched with the resource content description in the resource description information. Specifically, the resource description information is matched with the resource content of the selected resources to determine whether the two are consistent at the content level, that is, whether the resource content of the selected resources conforms to the description of the resource content description, thereby obtaining a matching result.
[0035] Afterwards, the target resource can be determined from the candidate resources according to the matching result. Specifically, the candidate resources that match and do not match the resource content description can be determined according to the matching result, and the matching candidate resources are used as the target resources.
[0036] Based on the above embodiment, the resource type information is used to reflect the type of the target resource, and the type includes at least one of a file, an image, and a text segment; Match the resource content description with the resource content of the candidate resource, including: In the case where the resources to be selected include a file resource of the file type, matching the resource content description with the file header and the file title in the resource content of the file resource; In the case where the resources to be selected include image resources of the type of image, matching the resource content description with the image number and the image content in the resource content of the image resource; In the case that the candidate resources include text resources of the type of text segments, semantic matching is performed between the resource content description and the text content in the resource content of the text resource.
[0037] Specifically, the above process of matching the resource content description with the resource content of the selected resource may include the following process: When the resources that the user needs to extract include files, that is, because the resources that need to be extracted include files, when performing preliminary screening based on resource type information, candidate resources of type / type file will be retained as selected resources. Therefore, when the selected resources obtained by preliminary screening contain resource information of type file, that is, when the selected resources contain file resources, the resource content description can be matched with the file header and file title of the file resource to determine whether the two match at the content level and obtain a matching result. The matching based on the file header and file title here is more efficient than the full-text matching, and the accuracy is sufficient under the aforementioned screening.
[0038] When the resources that the user needs to extract include images, that is, because the resources that need to be extracted include images, when performing preliminary screening based on resource type information, candidate resources of type / type image will be retained as selected resources. Therefore, when the selected resources obtained by preliminary screening contain resource information of type image, that is, when the selected resources contain image resources, the resource content description can be matched with the image resource's image number and image content to determine whether the two match by number and content. The image number here is the sequential number of the image in the web page, forum, etc., and the image content is the content explanation of the image.
[0039] When the resources that the user needs to extract include text segments, that is, because the resources that need to be extracted include text segments, when performing preliminary screening based on resource type information, candidate resources of type / type text / text segments will be retained as selected resources. Therefore, when the selected resources obtained by preliminary screening contain resource information of type text / text segments, that is, when the selected resources contain text resources, the resource content description can be matched with the text content of the text resource to determine whether the two are consistent at the content semantic level. It should be noted that since text segments are mostly sentences, paragraphs, etc., which are different from the large scale of files, content semantic matching can improve matching accuracy without affecting efficiency, achieve more accurate resource positioning, and thus extract resources more accurately.
[0040] Based on the above embodiment, step 120 includes: Determine the information type of the resource location information, the information type including at least one of a URL, a text description, a URL description, and a URL key; Based on the information type and resource location information, resource retrieval is performed to obtain candidate resources.
[0041] Specifically, in step 120, the process of performing resource retrieval according to the resource location information to obtain candidate resources may specifically include: In order to achieve more efficient and accurate resource retrieval and positioning, in the embodiment of the present invention, when performing resource retrieval, the type of resource location information provided by the user can be determined first, that is, the information type, whether it is a URL, or a text description, or a URL and a text description, that is, a URL description, or a URL and a key, that is, a URL key. The information type here can be provided by the user or automatically identified, and the embodiment of the present invention does not specifically limit this.
[0042] After that, you can perform resource retrieval based on this information type and resource location information to obtain candidate resources. That is, because different types of resource location information use different methods and means when searching, you can first determine the resource retrieval method based on this information type. For example, when a URL is provided, you can directly enter the URL to search for resources, and when a text description is provided, you need to first perform a large-scale search based on the text description. When a URL key is provided, you can directly extract resources based on the URL and key. Then, you can use the resource location information to perform resource retrieval according to this resource retrieval method to obtain the retrieved candidate resources.
[0043] Based on the above embodiment, based on the information type and the resource location information, resource retrieval is performed to obtain candidate resources, including: In the case where the information type is a website description, a web page search is performed based on the resource location information corresponding to the website in the website description, and a resource search is performed in the resource web pages obtained by the web page search based on the resource location information corresponding to the text description in the website description to obtain candidate resources; When the information type is a URL key, a web page search is performed based on the resource location information corresponding to the URL in the URL key, and candidate resources are extracted from the resource web pages obtained by the web page search based on the resource location information corresponding to the key in the URL key.
[0044] Specifically, the process of performing resource retrieval based on the resource location information based on the information type to obtain candidate resources specifically includes: When the information type is a URL description, when performing a specific resource search, you can first perform a web page search based on the resource location information corresponding to the URL in the URL description, that is, search based on the URL provided by the user to determine the resource web page corresponding to the URL; then, you can perform a resource search in the resource web page based on the resource location information corresponding to the text description in the URL description, so as to obtain candidate resources; that is, in the resource web pages obtained by the web search, use the text description provided by the user to perform a resource search, so as to obtain the resource information corresponding to the text description from the resource web page as a candidate resource.
[0045] When the information type is a URL key, when performing a specific resource search, you can first perform a web page search based on the resource location information corresponding to the URL in the URL key, that is, search based on the URL provided by the user to determine the resource web page corresponding to the URL; then, you can extract candidate resources from the resource web page based on the resource location information corresponding to the key in the URL key; here, specifically, in the resource web page obtained by the web search, enter the key provided by the user to directly extract resource information from the resource web page as a candidate resource.
[0046] Based on the above embodiment, step 130, returning the target resource to the user terminal, includes: Store the target resources locally or in the cloud; The target resource, the local storage location of the target resource, or the storage location in the cloud is returned to the user end.
[0047] Specifically, the above process of returning the target resource to the user end may be to first store the target resource, that is, download the target resource from the website, public account, forum, etc. retrieved according to the provided resource location information to store it locally, or directly store the target resource in the cloud. The process of storing in the cloud may be local transfer or direct storage, which is not specifically limited in the embodiment of the present invention.
[0048] After that, the target resource can be directly returned to the user end, or the storage address of the target resource locally / in the cloud can be returned to the user end, so that the user can directly obtain the target resource based on the detailed and specific storage address, thereby achieving accurate capture of the target resource.
[0049] Figure 2 is the overall flow chart of the resource extraction method provided by the present invention, such as Figure 2 As shown, the method includes: First, a resource extraction request sent by a user terminal is received, where the resource extraction request includes resource location information and resource description information.
[0050] Then, the information type of the resource location information is determined, and the information type includes at least one of a URL, a text description, a URL description, and a URL key.
[0051] Then, based on the information type, resource retrieval is performed based on the resource location information to obtain candidate resources.
[0052] Here, based on the information type and resource location information, resource retrieval is performed to obtain candidate resources, including: In the case where the information type is a website description, a web page search is performed based on the resource location information corresponding to the website in the website description, and a resource search is performed in the resource web pages obtained by the web page search based on the resource location information corresponding to the text description in the website description to obtain candidate resources; When the information type is a URL key, a web page search is performed based on the resource location information corresponding to the URL in the URL key, and candidate resources are extracted from the resource web pages obtained by the web page search based on the resource location information corresponding to the key in the URL key.
[0053] Afterwards, based on the resource type information in the resource description information, the resource to be selected is determined from the candidate resources.
[0054] Then, the resource content description in the resource description information is matched with the resource content of the candidate resource, and based on the matching result, the target resource is determined from the candidate resources.
[0055] Here, the resource type information is used to reflect the type of the target resource, and the type includes at least one of a file, an image, and a text segment; Match the resource content description with the resource content of the candidate resource, including: In the case where the resources to be selected include a file resource of the file type, matching the resource content description with the file header and the file title in the resource content of the file resource; In the case where the resources to be selected include image resources of the type of image, matching the resource content description with the image number and the image content in the resource content of the image resource; In the case that the candidate resources include text resources of the type of text segments, semantic matching is performed between the resource content description and the text content in the resource content of the text resource.
[0056] Then, the target resource is stored locally or in the cloud, and any one of the target resource, the local storage location of the target resource, or the storage location in the cloud is returned to the user end.
[0057] The method provided by the embodiment of the present invention receives a resource extraction request sent by a user terminal, wherein the resource extraction request includes resource location information and resource description information; performs resource retrieval based on the resource location information to obtain candidate resources; determines a target resource to be extracted from the candidate resources based on the resource description information, and returns the target resource to the user terminal, thereby overcoming the defects of traditional solutions such as strong dependence on file transfer / resource extraction, cumbersome procedures and slow speed, realizes efficient and convenient resource extraction, simplifies the resource transmission process, reduces intermediate links, and enables users to obtain required resources more quickly and directly without multiple transfers through cloud disks, thereby greatly improving resource acquisition efficiency and convenience and optimizing user experience.
[0058] The resource extraction device provided by the present invention is described below. The resource extraction device described below and the resource extraction method described above can be referenced to each other.
[0059] Figure 3 is a schematic diagram of the structure of the resource extraction device provided by the present invention, such as Figure 3 As shown, the device comprises: The request receiving unit 310 is used to receive a resource extraction request sent by a user terminal, wherein the resource extraction request includes resource location information and resource description information; A resource search unit 320, configured to search for resources based on the resource location information to obtain candidate resources; The resource extraction unit 330 is used to determine the target resource to be extracted from the candidate resources based on the resource description information, and return the target resource to the user terminal.
[0060] The resource extraction device provided by the present invention receives a resource extraction request sent by a user terminal, wherein the resource extraction request includes resource location information and resource description information; performs resource retrieval based on the resource location information to obtain candidate resources; determines a target resource to be extracted from the candidate resources based on the resource description information, and returns the target resource to the user terminal, thereby overcoming the defects of traditional solutions such as strong dependence on file transfer / resource extraction, cumbersome procedures and slow speed, realizes efficient and convenient resource extraction, simplifies the resource transmission process, reduces intermediate links, enables users to obtain required resources more quickly and directly, and does not need to be transferred multiple times through a cloud disk, thereby greatly improving resource acquisition efficiency and convenience, and optimizing user experience.
[0061] Based on the above embodiment, the resource description information includes resource type information and resource content description; the resource extraction unit 330 is used to: Determining a resource to be selected from the candidate resources based on the resource type information; The resource content description is matched with the resource content of the candidate resources, and based on the matching result, a target resource is determined from the candidate resources.
[0062] Based on the above embodiment, the resource type information is used to reflect the type of the target resource, and the type includes at least one of a file, an image, and a text segment; The resource extraction unit 330 is used to: In a case where the to-be-selected resources include file resources of the file type, matching the resource content description with a file header and a file title in the resource content of the file resource; In the case where the candidate resources include image resources of the image type, matching the resource content description with the image number and image content in the resource content of the image resource; In the case that the candidate resources include text resources of the type of text segments, semantic matching is performed between the resource content description and the text content in the resource content of the text resource.
[0063] Based on the above embodiment, the resource retrieval unit 320 is used to: Determine the information type of the resource location information, the information type including at least one of a website address, a text description, a website address description, and a website address key; Based on the information type and the resource location information, a resource search is performed to obtain candidate resources.
[0064] Based on the above embodiment, the resource retrieval unit 320 is used to: The step of performing resource retrieval based on the resource location information and taking the information type as a basis to obtain candidate resources includes: In the case where the information type is the website description, a web page search is performed based on the resource location information corresponding to the website in the website description, and a resource search is performed in the resource web pages obtained by the web page search based on the resource location information corresponding to the text description in the website description to obtain candidate resources; When the information type is the URL key, a web page search is performed based on the resource location information corresponding to the URL in the URL key, and candidate resources are extracted from the resource web pages obtained by the web page search based on the resource location information corresponding to the key in the URL key.
[0065] Based on the above embodiment, the resource extraction unit 330 is used to: Storing the target resource locally or storing the target resource in the cloud; Return any one of the target resource, the local storage location of the target resource, or the storage location in the cloud to the user terminal.
[0066] Figure 4 An example of a physical structure diagram of an electronic device is shown in FIG. Figure 4 As shown, the electronic device may include: a processor 410, a communication interface 420, a memory 430 and a communication bus 440, wherein the processor 410, the communication interface 420 and the memory 430 communicate with each other through the communication bus 440. The processor 410 may call the logic instructions in the memory 430 to execute the resource extraction method, which includes: receiving a resource extraction request sent by a user terminal, wherein the resource extraction request includes resource location information and resource description information; performing resource retrieval based on the resource location information to obtain candidate resources; determining a target resource to be extracted from the candidate resources based on the resource description information, and returning the target resource to the user terminal.
[0067] In addition, the logic instructions in the above-mentioned memory 430 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on this understanding, the technical solution of the present invention, in essence, 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, and the computer software product is stored in a storage medium, including a number of 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 method 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. Various media that can store program codes.
[0068] On the other hand, the present invention also provides a computer program product, which includes a computer program stored on a non-transitory computer-readable storage medium, and the computer program includes program instructions. When the program instructions are executed by a computer, the computer can execute the resource extraction method provided by the above-mentioned methods, and the method includes: receiving a resource extraction request sent by a user terminal, and the resource extraction request includes resource location information and resource description information; performing resource retrieval based on the resource location information to obtain candidate resources; based on the resource description information, determining the target resource to be extracted from the candidate resources, and returning the target resource to the user terminal.
[0069] On the other hand, the present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, it is implemented to execute the resource extraction method provided by the above-mentioned methods, the method comprising: receiving a resource extraction request sent by a user terminal, the resource extraction request comprising resource location information and resource description information; performing resource retrieval based on the resource location information to obtain candidate resources; determining a target resource to be extracted from the candidate resources based on the resource description information, and returning the target resource to the user terminal.
[0070] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative labor.
[0071] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0072] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A resource extraction method, characterized in that: include: Receiving a resource extraction request sent by a user terminal, wherein the resource extraction request includes resource location information and resource description information; Perform resource retrieval based on the resource location information to obtain candidate resources; Based on the resource description information, a target resource to be extracted is determined from the candidate resources, and the target resource is returned to the user terminal.
2. The resource extraction method according to claim 1, characterized in that: The resource description information includes resource type information and resource content description; The step of determining the target resource to be extracted from the candidate resources based on the resource description information includes: Determining a resource to be selected from the candidate resources based on the resource type information; The resource content description is matched with the resource content of the candidate resources, and based on the matching result, a target resource is determined from the candidate resources.
3. The resource extraction method according to claim 2, characterized in that: The resource type information is used to reflect the type of the target resource, and the type includes at least one of a file, an image, and a text segment; the matching of the resource content description with the resource content of the candidate resource includes: In a case where the to-be-selected resources include file resources of the file type, matching the resource content description with a file header and a file title in the resource content of the file resource; In the case where the candidate resources include image resources of the image type, matching the resource content description with the image number and image content in the resource content of the image resource; In the case that the candidate resources include text resources of the type of text segments, semantic matching is performed between the resource content description and the text content in the resource content of the text resource.
4. The resource extraction method according to any one of claims 1 to 3, characterized in that: The performing resource retrieval based on the resource location information to obtain candidate resources includes: Determine the information type of the resource location information, the information type including at least one of a website address, a text description, a website address description, and a website address key; Based on the information type and the resource location information, a resource search is performed to obtain candidate resources.
5. The resource extraction method according to claim 4, characterized in that: The step of performing resource retrieval based on the resource location information and taking the information type as a basis to obtain candidate resources includes: In the case where the information type is the website description, a web page search is performed based on the resource location information corresponding to the website in the website description, and a resource search is performed in the resource web pages obtained by the web page search based on the resource location information corresponding to the text description in the website description to obtain candidate resources; When the information type is the URL key, a web page search is performed based on the resource location information corresponding to the URL in the URL key, and candidate resources are extracted from the resource web pages obtained by the web page search based on the resource location information corresponding to the key in the URL key.
6. The resource extraction method according to any one of claims 1 to 3, characterized in that: The returning the target resource to the user terminal includes: Storing the target resource locally or storing the target resource in the cloud; Return any one of the target resource, the local storage location of the target resource, or the storage location in the cloud to the user terminal.
7. A resource extraction device, characterized in that: include: A request receiving unit, configured to receive a resource extraction request sent by a user terminal, wherein the resource extraction request includes resource location information and resource description information; A resource retrieval unit, configured to perform resource retrieval based on the resource location information to obtain candidate resources; The resource extraction unit is used to determine the target resource to be extracted from the candidate resources based on the resource description information, and return the target resource to the user terminal.
8. An electronic device comprising a memory, a processor, and a computer program stored in the memory and running on the processor, characterized in that: When the processor executes the computer program, the resource extraction method according to any one of claims 1 to 6 is implemented.
9. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the resource extraction method according to any one of claims 1 to 6 is implemented.
10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the resource extraction method according to any one of claims 1 to 6 is implemented.