Re: [Tracker] MinWordLength of tracker-search-tool



On 28/10/10 10:00, Chen, Zhenqiang wrote:

Hi all,

Hi,

The default minimal word length of input string is 3 in tracker-fts.cfg.

It maybe reasonable for most English words.
But the length of lots lots of Chinese words is 2.

(1) Can we set different default values for different languages?
e.g.
By default, when my inputs are all in English, the default is 3.
When my inputs are all in Chinese, the default is 2.
When they are mixed, select the minimal one.

Ideally, we shouldn't have a minimum word length at all. We can set it per language since GKeyFiles allow that and you're right it does change per language. This should be quite trivial to patch actually. It might already work even if you set the keyfile now, since the API should return the value for the locale. See:


http://library.gnome.org/devel/glib/stable/glib-Key-value-file-parser.html#g-key-file-get-locale-string

and also the _get_string() variant. It is unclear to me from the documentation if the _get_string() variant will return the string for the current locale or not. Either way, it isn't much work to get this going.

(2) Or set it from UI?

Users set the value when searching.

It is not really useful for user I think.

(3) others?

From my viewpoint, do not expect common users know how to
change the default values from cmd line.
Even from UI, some users might not know the exact meanings of MinWordLength.

Note, some properties in Tracker don't use the MinWordLength setting. You can see whic properties using:

  tracker-sparql -q "select ?p where { ?p tracker:fulltextNoLimit true }"

--
Regards,
Martyn



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]