Ken Wakasa
7d81f31871
am 7b1570e6
: Merge "Cleanup Makefiles of LatinIME" into jb-dev
...
* commit '7b1570e60c2e04fe7d132df758476b34685eb709':
Cleanup Makefiles of LatinIME
2012-05-23 20:22:04 -07:00
Ken Wakasa
dd58065733
Cleanup Makefiles of LatinIME
...
Change-Id: Id4c6700bc045825eb64fb2b7ae57f23a6211441d
2012-05-24 12:08:59 +09:00
satok
074e8c9206
am a0ac31fc
: Fix the issue on multiple words suggestion
...
* commit 'a0ac31fcaa01c21592a6e7af243c14dada65cf3e':
Fix the issue on multiple words suggestion
2012-05-23 05:06:08 -07:00
satok
a0ac31fcaa
Fix the issue on multiple words suggestion
...
Bug: 6509844
Change-Id: I823074a2b29befc3e60c63699ab4dc7719105c63
2012-05-23 20:40:59 +09:00
Jean Chalard
7557d3c6f3
am bc77adef
: Merge "Return the bigram frequency if available." into jb-dev
...
* commit 'bc77adefbb0305c5ec0e41ab01e3a085c47c21eb':
Return the bigram frequency if available.
2012-05-17 03:31:15 -07:00
Jean Chalard
bc77adefbb
Merge "Return the bigram frequency if available." into jb-dev
2012-05-17 03:15:40 -07:00
Jean-Baptiste Queru
cd7c41352f
Fix build
...
Change-Id: I799811aa3afb59bba2e4086a063f5da03669bba3
2012-05-16 16:56:11 -07:00
Ken Wakasa
3b088a2f36
Add missing includes.
...
Change-Id: Ic7199045d0cffb208871f52cc167194013351d32
2012-05-16 23:05:32 +09:00
Jean Chalard
9416c81403
Return the bigram frequency if available.
...
This concludes the work on bug#6313806.
Don't submit it before the dictionaries are suitably amended.
Bug: 6313806
Change-Id: Icfea45bd52bb9d8cc68ba2266f80640e3942bb7f
2012-05-16 21:14:06 +09:00
satok
0028ed3627
Use "float" instead of "double"
...
Change-Id: I93ed4d88ede4058f081dd8d634b00dfff4e96d07
2012-05-16 20:45:05 +09:00
satok
f837b57bf5
Merge "Reorder suggestions result according to auto correction threshold" into jb-dev
2012-05-16 04:13:08 -07:00
satok
db1939dbaa
Reorder suggestions result according to auto correction threshold
...
Bug: 5413904
Change-Id: I3aa3a8109ba45d2129b58d8242866fd3dd3473cb
2012-05-16 19:58:48 +09:00
satok
6804b8e0fd
Fix a bug of handling single quote in the correction algorithm
...
Bug: 6096247
Change-Id: I5490bbdee4ce1e3e0729ec1510a2baab85eeaf05
2012-05-15 15:12:55 +09:00
Tom Ouyang
4d289d39ae
Contacts dictionary rebuilds only when contact names have changed.
...
Bug: 6396600
Change-Id: Iad693ec4bab6351793d624e5c5b0a9f5c12a60e3
2012-05-11 18:43:53 -07:00
Jean Chalard
49ba135fde
Perform the actual bigram frequency lookup.
...
This still returns the unigram frequency, because the values stored
for bigrams in the dictionary are not ready to be returned in-place
instead of unigram values. Aside from this, the code is complete.
Bug: 6313806
Change-Id: If7bb7b644730782277f0f6663334c170b7fe13fb
2012-05-10 20:01:44 +09:00
Jean Chalard
8950ce6c44
Replace the bigram list position with the map and filter
...
Passing the position will not allow us a reasonable lookup
time. Replace this with a map and bloom filter for very fast
lookup.
Bug: 6313806
Change-Id: I3a61c0001cbc987c1c3c7b8df635d4590a370144
2012-05-07 17:15:21 +09:00
Jean Chalard
f1634c872c
Fill in the bloom filter for bigram lookup.
...
Bug: 6313806
Change-Id: Ib79e14f6f8b241f053da6069c15f19c71084317e
2012-05-07 15:38:43 +09:00
Jean Chalard
1ff8dc47be
Fill up a map of bigram addresses for lookup.
...
We don't want to do a linear search on each terminal when there
may be 100+ bigrams for a given word because that would be
disastrous for performance. Also, we need to resolve each bigram
address anyway.
This change resolves the addresses at first and puts them in a
balanced tree so that lookup will be O(log(n)).
Bug: 6313806
Change-Id: Ibf088035870b9acb41e948f0ab7af4726f2cee24
2012-05-02 17:50:44 +09:00
Jean Chalard
351864b38a
Fetch and pass the bigram position on suggestions.
...
This is a cherry-pick of change I2d81742f
Bug: 6313806
Change-Id: Ic1190b7980d032bc11b57841bca040d980889b6b
2012-04-26 15:24:42 +09:00
Jean Chalard
4d9b202c40
Pass the bigram list position from the top level
...
The position itself is still a const int = 0 until we have the previous
word passed to the function. This basically does the plumbing.
Bug: 6313806
Change-Id: Ib58995f334fe93e3ff5704d7c79f332017f101ac
2012-04-24 16:47:09 +09:00
Jean Chalard
171d1809ff
Add methods to inverse compute the probability.
...
For now the probability is just returned with the same
value it had, but this is some ground work that needs to be
done anyway.
Bug: 6313806
Change-Id: I9bb8b96b294109771208ade558c9ad56932d2f8e
2012-04-24 09:40:44 +09:00
Jean Chalard
522a04ea5b
Pass words as int[] to the native code.
...
We need to get the bigrams during the call to getSuggestions for
bug#6313806. We already give an int[] to getSuggestions and we
wanted to get rid of char[]'s anyway because it doesn't work with
surrogate pairs, so here we go.
Bug: 6313806
Change-Id: I56ce99f1db6b3302cdf42f0527343bded837091e
2012-04-23 16:05:36 +09:00
Tadashi G. Takaoka
a58ebc73ae
Fix typo of some methods' name
...
Also changes some methods' argument type from Locale to String.
Change-Id: Ib68b528a450dc68a01546483403230f76500bee4
2012-04-18 16:40:50 +09:00
Jean Chalard
bde232dcaa
Merge "Pass the previous word down to native code in getSuggestions"
2012-04-17 18:01:05 -07:00
Jean Chalard
80111f08e2
Pass the previous word down to native code in getSuggestions
...
Change-Id: I477b631d81ef58461e44954f3ae5fd895928bb97
2012-04-17 20:07:10 +09:00
Jean Chalard
fec6837ae1
Fix debug compilation + small cleanup
...
Change-Id: Ia89d84f62ba38dee05d25fbc94698e889cf27d2c
2012-04-17 17:33:25 +09:00
Jean Chalard
ee396df162
Fix a native crash
...
This was introduced by Ieb2e306a which failed to keep the return
behavior in case the word doesn't have a bigram.
Change-Id: I6d2f0b79d41c4335e94696690c8331e314961133
2012-04-17 16:57:42 +09:00
Jean Chalard
9c2a96aa6c
Preparatory refactoring
...
Split out getting the pointer to the bigrams to a separate
function. This is a preparative change to bug#6313806
Change-Id: Ieb2e306a1151cd95dc1a16793c8dc2f7fed8b654
2012-04-17 11:46:20 +09:00
Ken Wakasa
db87fe4d5c
Just cosmetic changes in jni code
...
Change-Id: I8628131b5a7ccdee4c158e891002c8b86623b0cd
2012-04-16 19:16:05 +09:00
Jean Chalard
3f675f7060
Fix a large native memory leak.
...
This leak was about 500k and would happen whenever a new binary
dictionary was opened/closed.
Bug: 6299535
Change-Id: I4fad5b4d9c556ca889f5ef62d9d083a2eff6346a
2012-04-16 16:48:53 +09:00
Jean Chalard
338d3ec725
Replace the flags in getSuggestions with a boolean.
...
Change-Id: I0ec44df1979cb1dc21017ea290d2151a2af0e7cd
Conflicts:
java/src/com/android/inputmethod/latin/Suggest.java
2012-04-06 19:34:48 +09:00
Jean Chalard
aa8df59914
Enable using the flags read from the binary file.
...
Change-Id: Ib420c3e174ccc1a80c4b6fd066de3b7a2b6fb290
2012-04-06 18:54:20 +09:00
Jean Chalard
cd274b1469
Save the flags in a member in the unigram dictionary.
...
Change-Id: Ic8fad9110db6b97f98ace27af0f347b4e69de8c8
2012-04-06 18:34:59 +09:00
Jean Chalard
e81ac8baa0
Add a method to get the flags from a binary dictionary.
...
This method is not used yet
Change-Id: Ic15d3d423aff2c83c712bc0aa56571d30755e663
2012-04-06 18:34:22 +09:00
Jean Chalard
5b0761e6a9
Remove write-only stuff
...
Change-Id: I5ac8ab64c77a298502b3d063ea70db9b4da41716
2012-04-06 17:52:18 +09:00
Jean Chalard
9a933a742d
Read shortcuts as strings in the dictionary.
...
This has no impact on performance.
Before:
(0) 9.61 (0.01%)
(1) 57514.58 (56.70%)
(2) 10.55 (0.01%)
(3) 10.79 (0.01%)
(4) 133.20 (0.13%)
(5) 43553.87 (42.94%)
(6) 10.03 (0.01%)
(20) 47.20 (0.05%)
Total 101431.47 (sum of others 101289.84)
After:
(0) 10.52 (0.01%)
(1) 56311.16 (56.66%)
(2) 13.40 (0.01%)
(3) 10.98 (0.01%)
(4) 136.72 (0.14%)
(5) 42707.92 (42.97%)
(6) 9.79 (0.01%)
(20) 51.35 (0.05%)
Total 99390.76 (sum of others 99251.84)
The difference is not significant with regard to measure imprecision
Change-Id: I2e4f1ef7a5e99082e67dd27f56cf4fc432bb48fa
2012-04-06 16:22:08 +09:00
Ken Wakasa
0c1a3ec629
Make LatinIME's native Makefile NDK-friendly
...
Change-Id: I55d430756b3a8251c9ff49dfabfcecb047d979a4
2012-03-31 05:07:32 +09:00
Ying Wang
32f0e24b33
Remove ".." in the native LOCAL_SRC_FILES.
...
The build system does not work well with ".." in the path of native
source code.
".." causes the object files to spill out of the module's intermediate
directory.
Change-Id: Ib4a473426be296a738e7facbaa091e56f0b7c5b8
2012-03-30 10:50:26 -07:00
Ken Wakasa
3ef3e24a12
Move the "src" directory as a preparation for Ib4a47342 and I66f6c5b9
...
Change-Id: I3ab65059f6e356530484bfd0bba26a634a4cba65
2012-03-30 09:53:51 +09:00
satok
6ba8de2a60
Good bye the proximity logic in Java code
...
Bug: 4343280
Change-Id: I82f7d08703647a3492ce6e2d3b741146df58927e
2012-03-28 18:42:30 +09:00
satok
0cb2097a45
Fix additional proximity in the native code
...
Bug: 4343280
Change-Id: I4164bb916b2dbdfb6bdc151b99d46a6171d9c355
2012-03-14 11:17:59 +09:00
satok
5eec574cf0
Use additional proximity chars in the native code
...
Bug: 4343280
Change-Id: Ida690fe246cea80a82fcdb3ad0c28e2907b882ac
2012-03-13 19:00:16 +09:00
satok
552c3c27f0
Implement additional proximity characters in the native code
...
Bug: 4343280
Change-Id: I9bbc5cab2fef1ee80c1fe32017df811ef8af10bc
2012-03-13 17:38:50 +09:00
satok
a70ee6e3b3
Add functions to calculate proximity characters in the native code
...
Bug: 4343280
Change-Id: I17f8f6295b01900948b98680d0267753f33a46cf
2012-03-08 12:55:15 +09:00
Jean-Baptiste Queru
26e315785d
resolved conflicts for merge of 3ad1145a
to master
...
Change-Id: I13159b95f90c5095373951bf9e91b7dbf8b14558
2012-02-14 13:09:49 -08:00
Jean-Baptiste Queru
11c41216f1
Merge 2577fca1
...
Change-Id: Ie2c9f6c2eafb59dff95db8954481ce49c87a6d44
2012-01-23 09:06:00 -08:00
satok
9fb6f47a6a
New LOG lib
...
Change-Id: I977e7e10fa58c0a64ca0c3c7b5cb2272446e3efe
2012-01-13 18:04:15 +09:00
satok
be0cf72253
Move auto correction thresthold to the native code
...
bug: 5858137
Change-Id: Ic4b6270c6e51ef4ed25a6a1d8ddd7fdfa70fd78d
2012-01-12 19:56:15 +09:00
Ken Wakasa
d5e35acffb
Reorganize LatinIME native build directory structure. Now it got NDK friendly.
...
Change-Id: I0f62ce8a6a4d2b6134db698f8b8d0576616e524d
2011-12-13 21:16:20 +09:00
Tadashi G. Takaoka
5fdcd7d5cd
Fix JNI as 64bit ready
...
Change-Id: I7a3ed2cee3b20744869aa5cf89ff9fd95f5ab8fe
2011-10-31 20:44:01 +09:00