Commit 70f9b505 authored by Alexandre Delanoë's avatar Alexandre Delanoë

[HAL] adapting crawler for one language (english by default).

parent b94aefad
...@@ -29,17 +29,18 @@ class HalCrawler(Crawler): ...@@ -29,17 +29,18 @@ class HalCrawler(Crawler):
'''formating the query''' '''formating the query'''
#search_field="title_t" #search_field="title_t"
search_field="abstract_t" #search_field="abstract_t"
#return (search_field + ":" + "(" + query + ")") #return (search_field + ":" + "(" + query + ")")
return query # (search_field + ":" + "(" + query + ")") return "(" + query + ")"
def _get(self, query, fromPage=1, count=10, lang=None): def _get(self, query, fromPage=1, count=10, lang=None):
# Parameters # Parameters
fl = """ title_s fl = """ en_title_s
, abstract_s , en_title_s
, en_abstract_s
, submittedDate_s , submittedDate_s
, journalDate_s , journalDate_s
, authFullName_s , authFullName_s
......
...@@ -16,8 +16,8 @@ class HalParser(Parser): ...@@ -16,8 +16,8 @@ class HalParser(Parser):
hyperdata_list = [] hyperdata_list = []
hyperdata_path = { "id" : "isbn_s" hyperdata_path = { "id" : "isbn_s"
, "title" : "title_s" , "title" : "en_title_s"
, "abstract" : "abstract_s" , "abstract" : "en_abstract_s"
, "source" : "journalTitle_s" , "source" : "journalTitle_s"
, "url" : "uri_s" , "url" : "uri_s"
, "authors" : "authFullName_s" , "authors" : "authFullName_s"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment