Crawl » History » Version 3
Vassilis Papavassiliou, 2016-05-18 01:16 PM
1 | 1 | Prokopis Prokopidis | # Crawl |
---|---|---|---|
2 | 1 | Prokopis Prokopidis | |
3 | 1 | Prokopis Prokopidis | In general, the crawler initializes its frontier (i.e. the list of pages to be visited) from a seed URL list, fetches the web pages, extracts links from fetched web pages, adds the links to the list of pages to be visited and so on. During this process, modules for page fetching, content normalization, boilerplate removal, metadata extraction, text classification, and link extraction and prioritization are used. Users can configure several settings that determine the fetching process or the strictness of the text classifier by modifying the default configuration file [[FBC_config.xml]]. |
4 | 1 | Prokopis Prokopidis | |
5 | 1 | Prokopis Prokopidis | The required input from the user consists of a list of seed URLs to initiate the crawler's frontier, and a list of terms that describe a targeted topic. If the user does not provide a list of terms, the software can be used as a general crawler. |
6 | 1 | Prokopis Prokopidis | |
7 | 2 | Vassilis Papavassiliou | The following example starts a new crawl for acquiring multilingual data. In the defined destination (argument of option -dest), a directory (the crawl directory) is created (its name is based on the argument of option -a and date). |
8 | 2 | Vassilis Papavassiliou | In this crawl directory a child directory (auto-generated directory) denoted the crawl id. Next in this auto-generated directory, the data acquired in each crawl cycle is stored in run directories. |
9 | 2 | Vassilis Papavassiliou | |
10 | 2 | Vassilis Papavassiliou | ``` |
11 | 2 | Vassilis Papavassiliou | java -Dlog4j.configuration=file:/opt/ilsp-fc/log4j.xml -jar /opt/ilsp-fc/ilsp-fc-2.2.3-SNAPSHOT-jar-with-dependencies.jar -crawl -f -k -a test -type p \ |
12 | 2 | Vassilis Papavassiliou | -lang "L1;L2;L3;L4" -n 2 -t 20 -len 0 -mtlen 100 -dest (fullpath of the destination to store crawl results) -u (fullpath of the text file containing the seed URLs) \ |
13 | 2 | Vassilis Papavassiliou | -filter (regex to control URLs to be visited) -tc (full path of topic file) -dom (title of targeted topic) -oxslt &>"log_crawl" |
14 | 2 | Vassilis Papavassiliou | ``` |
15 | 2 | Vassilis Papavassiliou | |
16 | 1 | Prokopis Prokopidis | |
17 | 3 | Vassilis Papavassiliou | <!-- This is an example of running a crawl: |
18 | 1 | Prokopis Prokopidis | |
19 | 1 | Prokopis Prokopidis | ``` |
20 | 1 | Prokopis Prokopidis | java -Dlog4j.configuration=file:/opt/ilsp-fc/log4j.xml -jar /opt/ilsp-fc/ilsp-fc-2.2.2-jar-with-dependencies.jar \ |
21 | 1 | Prokopis Prokopidis | -crawl -f -type p -lang "eng;ita" -a www_esteri_it \ |
22 | 1 | Prokopis Prokopidis | -u "/home/user/seeds/eng-ita-seeds" -filter ".*www\.esteri\.it\/.*" \ |
23 | 1 | Prokopis Prokopidis | -n 100 -t 20 -len 0 -mtlen 100 -k \ |
24 | 1 | Prokopis Prokopidis | -dest "/var/www/html/tests/eng-ita/" \ |
25 | 3 | Vassilis Papavassiliou | &> "/var/www/html/tests/eng-ita/log-crawl_www_esteri_it_eng-ita" --> |
26 | 1 | Prokopis Prokopidis | ``` |
27 | 1 | Prokopis Prokopidis | |
28 | 1 | Prokopis Prokopidis | -crawl : For applying crawling process. |
29 | 1 | Prokopis Prokopidis | |
30 | 1 | Prokopis Prokopidis | -f : Forces the crawler to start a new job. |
31 | 1 | Prokopis Prokopidis | |
32 | 1 | Prokopis Prokopidis | -type : The type of crawling. Crawling for monolingual (m) or parallel (p). |
33 | 1 | Prokopis Prokopidis | |
34 | 1 | Prokopis Prokopidis | -lang : The language iso codes of the targeted languages separated by ";". |
35 | 1 | Prokopis Prokopidis | |
36 | 1 | Prokopis Prokopidis | -cfg : The full path to a configuration file that can be used to override default parameters. |
37 | 1 | Prokopis Prokopidis | |
38 | 1 | Prokopis Prokopidis | -a : User agent name. It is proposed to use a name similar to the targeted site. |
39 | 1 | Prokopis Prokopidis | |
40 | 1 | Prokopis Prokopidis | -u : fullpath of text file that contains the seed URLs that will initialize the crawler. In case of bilingual crawling the list should contain the URL of the main page of the targeted website, or (of course) other URLs of this website. |
41 | 1 | Prokopis Prokopidis | |
42 | 1 | Prokopis Prokopidis | -filter : A regular expression to filter out URLs which do NOT match this regex. |
43 | 1 | Prokopis Prokopidis | The use of this filter forces the crawler to either focus on a specific web domain (i.e. ".*ec.europa.eu.*"), or on a part of a web domain (e.g.".*/legislation_summaries/environment.*") or in different web sites (i.e. in cases the translations are in two web sites e.g. http://www.nrcan.gc.ca and http://www.rncan.gc.ca). Note that if this filter is used, only the seed URLs that match this regex will be fetched. |
44 | 1 | Prokopis Prokopidis | |
45 | 1 | Prokopis Prokopidis | -n : The crawl duration in cycles. Since the crawler runs in cycles (during which links stored at the top of the crawler’s frontier are extracted and new links are examined) it is proposed to use this parameter either for testing purposes or selecting a large number (i.e. 100) to "verify" that the crawler will visit the entire website. |
46 | 1 | Prokopis Prokopidis | |
47 | 1 | Prokopis Prokopidis | -dest : The directory where the results (i.e. the crawled data) will be stored. The tool will create the file structure dest/agent/crawl-id (where dest and agent stand for the arguments of parameters dest and agent respectively and crawl-id is generated automatically). In this directory, the tool will create the "run" directories (i.e. directories containing all resources fetched/extracted/used/required for each cycle of this crawl. In addition a pdf directory for storing acquired pdf files will be created. |
48 | 1 | Prokopis Prokopidis | |
49 | 1 | Prokopis Prokopidis | -t : The number of threads that will be used to fetch web pages in parallel. |
50 | 1 | Prokopis Prokopidis | |
51 | 1 | Prokopis Prokopidis | -k : Forces the crawler to annotate boilerplate content in parsed text. |
52 | 1 | Prokopis Prokopidis | |
53 | 1 | Prokopis Prokopidis | -len : Minimum number of tokens per paragraph. If the length (in terms of tokens) of a paragraph is |
54 | 1 | Prokopis Prokopidis | less than this value the paragraph will be annotated as "out of interest" and will not be included into the clean text of the web page. |
55 | 1 | Prokopis Prokopidis | |
56 | 1 | Prokopis Prokopidis | -mtlen : Minimum number of tokens in cleaned document. If the length (in terms of tokens) of the cleaned text is less than this value, the document will not be stored. |
57 | 1 | Prokopis Prokopidis | |
58 | 1 | Prokopis Prokopidis | -tc : fullpath of topic file (a text file that contains a list of term triplets that describe the targeted topic). An example domain definition of "Environment" for the English-Spanish pair can be found at http://nlp.ilsp.gr/redmine/projects/ilsp-fc/wiki/ENV_EN_ES_topic. If omitted, the crawl will be a "general" one (i.e. module for text-to-domain classification will not be used). |
59 | 1 | Prokopis Prokopidis | |
60 | 1 | Prokopis Prokopidis | -dom : Title of the targeted domain (required when domain definition, i.e. tc parameter, is used). |
61 | 1 | Prokopis Prokopidis | |
62 | 1 | Prokopis Prokopidis | -storefilter : A regular expression to discard (i.e. visit/fetch/process but do not store) webpages with URLs which do NOT match this regex. |