Ignore:
Timestamp:
2019-11-15T23:14:48+13:00 (4 years ago)
Author:
ak19
Message:

Links to more reading

File:
1 edited

Legend:

Unmodified
Added
Removed
  • other-projects/maori-lang-detection/src/org/greenstone/atea/TextLanguageDetector.java

    r33674 r33698  
    5353     */
    5454    public final double MINIMUM_CONFIDENCE;
    55 
    56     /** Number of language and confidence results to return for storing in MongoDB
    57      * MongoDB runs out of space if storing too many, as we store this info per sentence
    58      * and a long text document becomes a very large MongoDB document presumable*/
    59     public final int NUM_TOP_LANGUAGES = 5; // 103 max, in current version of opennlp lang model
    6055   
    6156    /** silentMode set to false means TextLanguageDetector won't print helpful messages while running. Set to true to run silently. */
     
    162157    }
    163158 
    164     public ArrayList<SentenceInfo> getAllSentencesInfo(String[] sentences) {
     159    public ArrayList<SentenceInfo> getAllSentencesInfo(String[] sentences, int NUM_TOP_LANGUAGES) {
    165160
    166161    if(sentences == null) {
     
    194189    }
    195190
    196     public ArrayList<SentenceInfo> getAllOverlappingSentencesInfo(String[] sentences) {
     191    public ArrayList<SentenceInfo> getAllOverlappingSentencesInfo(String[] sentences, int NUM_TOP_LANGUAGES) {
    197192   
    198193    if(sentences == null) {
Note: See TracChangeset for help on using the changeset viewer.