aboutsummaryrefslogtreecommitdiffstats
path: root/native/jni/src/suggest/core (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Rename to Kelar Keyboard (org.kelar.inputmethod.latin)Amin Bandali2025-01-111-1/+1
|
* Remove unused variablesJing Mike2023-03-193-6/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Since some variables with module LatinIME are defined but not used, when compiled with build combination "sdk_pc_x86_64-userdebug" and build command "mmm packages/inputmethods/LatinIME", the following code lines will be reported that "variable 'XXX' set but not used". (should be similar for all the other build combinations) Repeated 10 times for each: terminal_position_lookup_table.cpp:74:9 removedEntryCount terminal_position_lookup_table.cpp:85:9 removedEntryCount proximity_info_state_utils.cpp:493:9 tempTime trie_map.cpp:56:9 unusedRegionSize suggestion_results.cpp:100:9 index Repeated 80+ times: proximity_info_utils.h:75:25 proximityChar With this patch we are removing some of the unused variables and putting the C++ 17 attribute [[maybe_unused]] to the others which are used for logging. Then all the related build warnings have been eliminated. Test: mmm packages/inputmethods/LatinIME, presubmit check. Change-Id: Ia66766322d6ae8a010b1cb55cc22993fbc6d012c Signed-off-by: Jing Mike <jingyangliu@eswincomputing.com>
* Move dictionary code to top level dictionary dir.Keisuke Kuroyanagi2014-12-1727-1308/+19
| | | | | Bug: 18725954 Change-Id: Ia442ba4b5d84311057d83edf6e7aeb151d6a820b
* Remove dependency on jni.h from WordProperty.Keisuke Kuroyanagi2014-12-152-116/+0
| | | | | Bug: 18725954 Change-Id: Ic97d3a56b036ff042322c9f794504064046fd7d7
* Quit auto-correct explicit accented letters to base letters.Keisuke Kuroyanagi2014-12-094-8/+20
| | | | | Bug: 7677193 Change-Id: I66eddbf27a9db8682c0347a1be19922792a3bea7
* Merge "Use reference instead of pointer for WordProperty()."Keisuke Kuroyanagi2014-11-101-8/+13
|\
| * Use reference instead of pointer for WordProperty().Keisuke Kuroyanagi2014-11-101-8/+13
| | | | | | | | Change-Id: Idf03e97661d64186c752e35964d641a5528be5b1
* | Make profiler use getTimeInMicroSec().Keisuke Kuroyanagi2014-11-111-8/+8
|/ | | | | Bug: 17797064 Change-Id: Ie992c9454edfc3bf93d5ea367c3a4427b513a205
* Merge "Change v403 historical info format."Keisuke Kuroyanagi2014-10-311-0/+1
|\
| * Change v403 historical info format.Keisuke Kuroyanagi2014-10-311-0/+1
| | | | | | | | | | | | count -> 2B, level -> 0B. Change-Id: I3b241126f56eb33cdf09cb1ebfed04f534e4ec48
* | Further fixes to treat 0-frequency wordsAdrian Velicu2014-10-314-2/+8
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, when both legitimate 0-frequency words (such as distracters) and offensive words were encoded in the same way, distracters would never show up when the user blocked offensive words (the default setting, as well as the setting for regression tests). When b/11031090 was fixed and a separate encoding was used for offensive words, 0-frequency words would no longer be blocked when they were an "exact match" (where case mismatches and accent mismatches would be considered an "exact match"). The exact match boosting functionality meant that, for example, when the user typed "mt" they would be suggested the word "Mt", although they most probably meant to type "my". For this reason, we introduced this change, which does the following: * Defines the "perfect match" as a really exact match, with no room for case or accent mismatches * When the target word has probability zero (as "Mt" does, because it is a distracter), ONLY boost its score if it is a perfect match. By doing this, when the user types "mt", the word "Mt" will NOT be boosted, and they will get "my". However, if the user makes an explicit effort to type "Mt", we do boost the word "Mt" so that the user's input is not autocorrected to "My". Bug: 11031090 Change-Id: I92ee1b4e742645d52e2f7f8c4390920481e8fff0
* Block offensive words in multi-word suggestionsAdrian Velicu2014-10-313-13/+65
| | | | | | | | | If the user has chosen to block offensive words and types "aaaxbb", where "aaa" is an offensive word and "bb" is not, we should not suggest "aaa bb". Bug: 11031090 Change-Id: Ie23b8dd5d347bc26b1c046c3f5e8dfbc259bf528
* Enable count based dynamic ngram language model for v403.Keisuke Kuroyanagi2014-10-302-0/+5
| | | | | | Bug: 14425059 Change-Id: Icc15e14cfd77d37cd75f75318fd0fa36f9ca7a5b
* Improve space substitution error correction.Keisuke Kuroyanagi2014-10-283-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Bug: 17432052 [Category diff] +1 262 -1 93 +2 2 -2 18 +3 18 -3 2 +4 111 -4 148 +5 295 -5 217 +6 51 -6 276 +7 139 -7 124 [Weighted category diff] +1 276 -1 100 +2 4 -2 20 +3 20 -3 4 +4 118 -4 160 +5 309 -5 225 +6 52 -6 298 +7 163 -7 135 show diff for ./en_user_log_phones_2011_08.csv +1 173 -1 28 +2 2 -2 17 +3 17 -3 2 +4 63 -4 82 +5 120 -5 51 +6 24 -6 220 +7 88 -7 87 Change-Id: I9d673acb0ff632828ae2e0ead56e76e3a20411c6
* Fix: Personalized dicts suggest invalid words with v403.Keisuke Kuroyanagi2014-10-231-2/+3
| | | | | Bug: 14425059 Change-Id: I45ae00069dd3b7c461dd9a1f3558b96af0a1c975
* Support dumping ngram entries.Keisuke Kuroyanagi2014-10-222-14/+40
| | | | | Bug: 14425059 Change-Id: Ib03a0c3d166ed6f1e60c67127b28006d55143b6b
* Merge changes I210acb81,Ie9508788Keisuke Kuroyanagi2014-10-217-121/+154
|\ | | | | | | | | | | * changes: Make NgramProperty have NgramContext. Create .cpp file for NgramContext.
| * Make NgramProperty have NgramContext.Keisuke Kuroyanagi2014-10-215-15/+16
| | | | | | | | | | Bug: 14425059 Change-Id: I210acb816b122857dbbe1ee4dd6a35c5335bf2bf
| * Create .cpp file for NgramContext.Keisuke Kuroyanagi2014-10-212-106/+138
| | | | | | | | | | | | Bug: 14425059 Change-Id: Ie950878817b9c80cc9c970e1a84880c9b9ab228a
* | Renaming "blacklist" flag to "possibly offensive"Adrian Velicu2014-10-213-14/+45
|/ | | | | | | | | No behaviour changes. Unified the overloaded FusionDictionary::add method to always take an isPossiblyOffensive argument. Bug: 11031090 Change-Id: I5741a023ca1ce842d2cf10d4f6c926b0efabaa78
* Quit using weightChildNode for ADDITIONAL_PROXIMITY and SUBSTITUTION.Keisuke Kuroyanagi2014-10-142-7/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [Category diff] +1 0 -1 1 +2 0 -2 0 +3 0 -3 0 +4 1 -4 1 +5 8 -5 7 +6 0 -6 1 +7 1 -7 0 [Weighted category diff] +1 0 -1 1 +2 0 -2 0 +3 0 -3 0 +4 1 -4 1 +5 8 -5 7 +6 0 -6 1 +7 1 -7 0 Bug: 13756409 Change-Id: I6ac3567545676bbefbee3e87dda54bc083c15fb6
* [ML23] Introduce a different accuracy/performance tradeoffJean Chalard2014-10-103-3/+12
| | | | | Bug: 11230254 Change-Id: Ic09518c818ae7b68942b1c63160dd462e5922cb5
* Make members of classes that are used with std::vector constKeisuke Kuroyanagi2014-10-093-21/+19
| | | | Change-Id: Id93fb87f5630230fc3f9cd339e12f3b0e2006ea9
* Rename prev_words_info.h to ngram_context.hKeisuke Kuroyanagi2014-10-094-3/+3
| | | | | Bug: 14425059 Change-Id: I0e906631ecad2361a8198b3f9e3394bb22c5bf83
* Rename PrevWordsInfo to NgramContext.Keisuke Kuroyanagi2014-10-097-54/+54
| | | | | Bug: 14425059 Change-Id: I30703fc80e9450d4e2dbfec965e7f9f4468f6a11
* Rename updateCounter to updateEntriesForWordWithNgramContext.Keisuke Kuroyanagi2014-10-094-5/+6
| | | | | Bug: 14425059 Change-Id: Id9b0dd7e32c711ed4292981517c3febd5fe9e897
* Show prediction results in debug build.Keisuke Kuroyanagi2014-10-061-3/+0
| | | | | Bug: 16547409 Change-Id: If85418583998cd639c794bf5d5cfbbb972c34f72
* [ML13] Fix the locale passing in ProximityInfoJean Chalard2014-10-038-42/+48
| | | | | | | | | | | | | | | | | | | The locale is used to determine additional proximity characters. This is dependent on the dictionary language, but was passed as a function of the layout, which is wrong and would have given bad suggestions in multi-lingual mode. Ideally, additional proximity characters should be inserted in the dictionary header, but for now it's a rather simple change to get it from the dictionary's locale instead of the proximity info locale. Also, that allows us to remove completely the locale parameter from proximity info, which is a much needed change. This change has zero effect on unit tests and on regression tests. Bug: 11230254 Change-Id: If95157155db7dccd1f00b8ba55ccb3600283f9e4
* Implement updateCounter() by using existing entry adding methods.Keisuke Kuroyanagi2014-10-016-6/+42
| | | | | Bug: 14425059 Change-Id: I0b6cb80e1fb8f738e9c7d9e80fbc0c479546b879
* Move HistoricalInfo to property and use it in *Property.Keisuke Kuroyanagi2014-10-014-39/+79
| | | | | Bug: 14425059 Change-Id: Icccccabad98fb543c6a6be2844cfc0086d80b739
* Rename BigramProperty to NgramProperty.Keisuke Kuroyanagi2014-09-296-24/+24
| | | | | | | | Remaining work is changing bigram to ngram for supporting ngram entry counting, dumping, and migration. Bug: 14425059 Change-Id: Ifba288a1166996d62a5e57698f63537ea0a2a8ee
* Use std::move for dictionary properties.Keisuke Kuroyanagi2014-09-253-8/+8
| | | | Change-Id: I15056b36b7493f4bac1dbcbb46a0b44343ede153
* Use CodePointArrayView in WordProperty.Keisuke Kuroyanagi2014-09-241-3/+4
| | | | Change-Id: I45a9755c413003831788d190beb499fee8ce63aa
* Refactoring method to get code points and code point count.Keisuke Kuroyanagi2014-09-242-7/+4
| | | | | Bug: 14425059 Change-Id: I4731bd6076d34556e46e6714180fed324fb6aba3
* Move word flags to language model dict content.Keisuke Kuroyanagi2014-09-241-0/+5
| | | | | Bug: 14425059 Change-Id: I64712e5c83d0bc241e6f0f16117ab47b5d75bd4b
* [ML8] Add a language weightJean Chalard2014-09-1912-38/+53
| | | | | | | ...and rename an improperly named normalization value Bug: 11230254 Change-Id: I0f5633148a9f66dbfd7d28540b8a8985131c4549
* Use CodePointArrayView in DictionaryUtils.Keisuke Kuroyanagi2014-09-173-7/+8
| | | | Change-Id: I9ae308e60124ea5acb4ee09847c4fdd58ff168e2
* Use CodePointArrayView in Dictionary.Keisuke Kuroyanagi2014-09-172-29/+24
| | | | Change-Id: I63fa0a8348f6de6ec7a424a8033e936b4af72beb
* Have mPrevWordCount in DicNodeProperties.Keisuke Kuroyanagi2014-09-161-6/+11
| | | | | Bug: 14425059 Change-Id: I5ce22bace4ec08d0da4e5c167288a742c4426c33
* Use passed previous word count in PrevWordsInfo.Keisuke Kuroyanagi2014-09-145-36/+45
| | | | | | Bug: 14425059 Change-Id: I04007bdacf0176a05be7a27ef1c20c5b851d8bed
* Use WordIdArrayView for prevWordIds.Keisuke Kuroyanagi2014-09-1111-55/+57
| | | | | Bug: 14425059 Change-Id: Ia84fb997d89564e60111b46ca83bbfa3b187f316
* Remove unigram probability from dicNode.Keisuke Kuroyanagi2014-09-103-29/+8
| | | | | Bug: 14425059 Change-Id: Ie848e8568bb4dbb1d8358e823a881d9157a1aad3
* Quit using dicNode.getUnigramProbability().Keisuke Kuroyanagi2014-09-103-5/+14
| | | | | Bug: 14425059 Change-Id: I192070cc11e5d46c8413ebc19982d6a8c93577fc
* Use CodePointArrayView to create children DicNodes.Keisuke Kuroyanagi2014-09-102-8/+10
| | | | Change-Id: Ie940b6595f3f3f804fbb8dd03c710ea062b75af3
* Use WordAttributes for checking flags.Keisuke Kuroyanagi2014-09-105-33/+20
| | | | | Bug: 14425059 Change-Id: Idee84478a482a0e7b5cc53e5dbd4e2484584ba79
* Introduce WordAttributes to get word probability and flags.Keisuke Kuroyanagi2014-09-104-7/+69
| | | | | | Bug: 14425059 Change-Id: Iee11d038e0893d7ddd6c52447907f8c55fecb6a5
* Use getProbabilityOfWordInContext for prediction.Keisuke Kuroyanagi2014-09-102-8/+12
| | | | | Bug: 14425059 Change-Id: I9d5c905a0adda3503c593bfbf0bb9af8d1686f5d
* Use MultiBigramMap in structure policy.Keisuke Kuroyanagi2014-09-093-20/+7
| | | | | Bug: 14425059 Change-Id: I4d78da4839ef177e0223e6e5bcf0ebd7315c3099
* Rename probability to unigramProbability.Keisuke Kuroyanagi2014-09-096-20/+23
| | | | | Bug: 14425059 Change-Id: I6a204c3b8fb257d037ad95a1a455ae6fb89068fd
* Remove mHasChildrenPtNodes from DicNodeProperties.Keisuke Kuroyanagi2014-09-093-20/+11
| | | | | Bug: 14425059 Change-Id: I3a9511e7f7c3a722f9942f525530f04def5965da