Fastest memory based search technique (was: Adding 1 to an array)
JimAultWins at yahoo.com
Sun Jun 24 12:04:01 CDT 2007
I would recommend that you try to institute a controlled word dictionary,
rather than let the user create key words since this will defeat the
description of 'instant'. Even with very fast databases, the "SQL join"
operation (which sounds like your method) can get slower and slower.
You might want to send a note directly to Eric Chatonet about this because I
believe he has done massive work and study on this topic (and multi-lingual
to boot!). The key word for searching this archive I believe would be
"stemmer", which is a way of defining which words are similar. This would
be overkill for your project, but the fast techniques he uses could be
applied in some form.
Certainly you are developing a specialized application, but it is a road
well-traveled by many.
Hope this helps. I have only done rudimentary indexing and on very small
data sets. The "filter var with .." and "filter var without .." are speed
champs with short line-length lists.
Don't forget the idea adding a comment line at the beginning of the handler
that contains the keywords used in a single location.
--tagg doThisForMe calcPixels repeat for each union using
then harvest them by...
filter handlersText with "--tagg*" =>
On 6/24/07 4:32 AM, "David Bovill" <david at openpartnership.net> wrote:
> Thanks Ken.
> On 24/06/07, Ken Ray <kray at sonsothunder.com> wrote:
>> on mouseUp
>> put 1 into tA
>> put 2 into tA
>> put 3 into tA
>> put tA + 1 into tA
>> put tA,tA,tA
>> end mouseUp
> On 24/06/07, Jim Ault <JimAultWins at yahoo.com> wrote:
>> Does the list of tags change or is it static?
> Its a general technique for keyword indexes I'm looking at, in this example
> it is for Rev handlers, each of which can have many keywords. It's the "find
> similar" algorithm I posted about earlier - so if a handler has say these 6
> keywords - which other handlers have similar keywords. Or another way of
> putting it if a user types in some keywords, how can we find related
> handlers in the library?
> These are the types of technique I'd like to compare:
> 1. My very old stack searched for keywords in a field, and i am
> looking for a better way
> 2. Use indexes and loop though them with repeat
> 3. Use arrays and use union and intersect (current experiment)
> 4. Use database
> I'm interested to see how the old style card index compares for speed with
> the rest.
> This is what i am thinking;
> 1. Users will type in (or select from a list) the most important
> keywords first
> 2. Keywords can be in any order
> 3. Cannot index all keyword combinations - so need fast dynamic lookup
> 4. indexes of keyword => handlerNames are useful so lets store them
> If from each keyword i can fetch an index of handler names from an array
> then I have several indexes - then i guess i just need the fastest way to
> calculate unions of indexes. I'm thinking that arrays and union will be
> faster than repeating through and index or array.
> use-revolution mailing list
> use-revolution at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription
More information about the use-livecode