views:

70

answers:

1

The Problem:

I need a good free library or algorithm to determine whether a text is related to a search pattern or not. The search pattern can be an ordered or unordered list of words. For some searches the order is relevant, for some it is not. Additionally I need the ability to define aliases for searched words (e.g. "(C#|C sharp) code").

I doubt that there is a free cheap c# library meeting all my requests.

Which libraries/algorithms would you use to implement that functionality? I´m grateful for any tip.

EDIT: I need this to filter search results from multiple specialized search services. The resulting program must be VERY strict, so false negatives are no problem.False positives should be avoided(as far as possible).

+1  A: 

For free, start here with the builtin Regex namespace/class:

http://msdn.microsoft.com/en-us/library/system.text.regularexpressions.regex.aspx

More sophisticated search is unlikely to come for free (cf. Google Search Appliance or similar).

Steve Townsend
Lucene.Net ( http://lucene.apache.org/lucene.net/ ) is pretty sophisticated and is free, though I really don't think it is what the OP needs.
Brian
Regex is certainly a part of the solution but not the solution itself. I can not believe that there is not even one open source library that offering complex search options.
Oliver