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
23ef92fa
Commit
23ef92fa
authored
Sep 11, 2020
by
Alexandre Delanoë
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[TextFlow] map list acceptable for tests (WIP)
parent
e16a2824
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
List.hs
src/Gargantext/Core/Text/List.hs
+6
-6
No files found.
src/Gargantext/Core/Text/List.hs
View file @
23ef92fa
...
...
@@ -99,17 +99,17 @@ buildNgramsTermsList :: Lang
->
MasterCorpusId
->
Cmd
err
(
Map
NgramsType
[
NgramsElement
])
buildNgramsTermsList
_l
_n
_m
s
uCid
mCid
=
do
candidates
<-
sortTficf
Down
<$>
getTficf
uCid
mCid
NgramsTerms
candidates
<-
sortTficf
Up
<$>
getTficf
uCid
mCid
NgramsTerms
printDebug
"head candidates"
(
List
.
take
10
$
candidates
)
printDebug
"tail candidates"
(
List
.
take
10
$
List
.
reverse
$
candidates
)
let
candidatesSize
=
400
candidatesHead
=
List
.
take
candidatesSize
candidates
candidatesTail
=
List
.
drop
candidatesSize
candidates
(
candidatesHead
,
candidatesTail0
)
=
List
.
splitAt
3
candidates
(
candidatesMap
,
candidatesTailFinal
)
=
List
.
splitAt
400
candidatesTail0
termList
=
(
map
(
toGargList
((
isStopTerm
s
)
.
fst
)
MapTerm
)
candidatesHead
)
<>
(
map
(
toGargList
((
isStopTerm
s
)
.
fst
)
CandidateTerm
)
candidatesTail
)
termList
=
(
map
(
toGargList
((
isStopTerm
s
)
.
fst
)
CandidateTerm
)
candidatesHead
)
<>
(
map
(
toGargList
((
isStopTerm
s
)
.
fst
)
MapTerm
)
candidatesMap
)
<>
(
map
(
toGargList
((
isStopTerm
s
)
.
fst
)
CandidateTerm
)
candidatesTailFinal
)
ngs
=
List
.
concat
$
map
toNgramsElement
...
...
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