Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
H
haskell-gargantext
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Przemyslaw Kaminski
haskell-gargantext
Commits
a8fa4d43
Commit
a8fa4d43
authored
Jan 20, 2022
by
Przemyslaw Kaminski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[pubmed] use new Taggy parser in pubmed
This fixes an issue when article title contained XML (like <b> etc).
parent
df905a78
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
16 deletions
+15
-16
Pubmed.hs
src/Gargantext/Core/Text/Corpus/API/Pubmed.hs
+14
-15
stack.yaml
stack.yaml
+1
-1
No files found.
src/Gargantext/Core/Text/Corpus/API/Pubmed.hs
View file @
a8fa4d43
...
...
@@ -58,22 +58,21 @@ toDoc l (PubMedDoc.PubMed (PubMedDoc.PubMedArticle t j as aus)
,
_hd_publication_second
=
Nothing
,
_hd_language_iso2
=
Just
$
(
Text
.
pack
.
show
)
l
}
where
authors
::
Maybe
[
PubMedDoc
.
Author
]
->
Maybe
Text
authors
aus'
=
case
aus'
of
Nothing
->
Nothing
Just
au
->
Just
$
(
Text
.
intercalate
", "
)
authors
::
[
PubMedDoc
.
Author
]
->
Maybe
Text
authors
[]
=
Nothing
authors
au
=
Just
$
(
Text
.
intercalate
", "
)
$
catMaybes
$
map
(
\
n
->
PubMedDoc
.
foreName
n
<>
Just
" "
<>
PubMedDoc
.
lastName
n
)
au
institutes
::
Maybe
[
PubMedDoc
.
Author
]
->
Maybe
Text
institutes
aus'
=
case
aus'
of
Nothing
->
Nothing
Just
au
->
Just
$
(
Text
.
intercalate
", "
)
institutes
::
[
PubMedDoc
.
Author
]
->
Maybe
Text
institutes
[]
=
Nothing
institutes
au
=
Just
$
(
Text
.
intercalate
", "
)
$
(
map
(
Text
.
replace
", "
" - "
))
$
catMaybes
$
map
PubMedDoc
.
affiliation
au
abstract
::
Maybe
[
Text
]
->
Maybe
Text
abstract
as'
=
fmap
(
Text
.
intercalate
", "
)
as'
abstract
::
[
Text
]
->
Maybe
Text
abstract
[]
=
Nothing
abstract
as'
=
Just
$
Text
.
intercalate
", "
as'
stack.yaml
View file @
a8fa4d43
...
...
@@ -69,7 +69,7 @@ extra-deps:
# External Data API connectors
-
git
:
https://gitlab.iscpif.fr/gargantext/crawlers/pubmed.git
commit
:
a9d8e08a7ef82f90e29dfaced4071704a316339
4
commit
:
9cdba6423decad5acfacb0f274212fd8723ce73
4
-
git
:
https://gitlab.iscpif.fr/gargantext/crawlers/istex.git
commit
:
daeae80365250c4bd539f0a65e271f9aa37f731f
-
git
:
https://gitlab.iscpif.fr/gargantext/crawlers/hal.git
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment