New Search Engine?

Discussion in 'PHP' started by Catherine86, Mar 18, 2011.

  1. #1
    Hi,

    We have designing new search engine for that we want script that detect spell error and automated keywords suggestion for that spell error.

    Is there any free script code for that structure, please let me know.
     
    Catherine86, Mar 18, 2011 IP
  2. bartolay13

    bartolay13 Active Member

    Messages:
    735
    Likes Received:
    14
    Best Answers:
    1
    Trophy Points:
    98
    #2
    thats not simple task, if your going to do it from scratch, maybe you can divide your questions.
     
    bartolay13, Mar 18, 2011 IP
  3. awood969

    awood969 Member

    Messages:
    186
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    40
    #3
    Detecting search errors would all depend on what data your crawler is gathering, how you've formatted your database etc. I have developed a search engine myself (nothing ever published just to say "i can do it!") using a multitude of technologies. I found the hardest bit was the searching (using binary tree's etc) and that spell checks were really not too hard once you've got the rest sorted.

    As you can never predict new words, phrases slang etc etc the best way to approach this problem is to compare the search string against recently popular search strings and check for comparible words, if the "slang" is out then this will become apparent to the server and can offer the correct, more popular phrase.

    Andrew
     
    awood969, Mar 18, 2011 IP
  4. srisen2

    srisen2 Peon

    Messages:
    359
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    0
    #4
    you will have a lot of work on your hands to get this up and running but most of your results will come from the accepted solution your users choose from your list of suggested results to calculate which like results is the best solution
     
    srisen2, Mar 18, 2011 IP
  5. vediovis

    vediovis Peon

    Messages:
    35
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    I'm not sure this is a realistic project.
     
    vediovis, Mar 22, 2011 IP
  6. ROOFIS

    ROOFIS Well-Known Member

    Messages:
    1,234
    Likes Received:
    30
    Best Answers:
    5
    Trophy Points:
    120
    #6
    Hi there Catherine86 I've been coding a web 3.0 app (auto content generator like IBM's Watson - shameless promo :) )

    that's pretty much in your line of necessity,
    http://blog.afterthedeadline.com/2010/03/04/all-about-language-models/

    simple api call to his function(s) may do the trick. :)










    ROOFIS
    :cool:
     
    Last edited: Mar 23, 2011
    ROOFIS, Mar 23, 2011 IP
  7. ROOFIS

    ROOFIS Well-Known Member

    Messages:
    1,234
    Likes Received:
    30
    Best Answers:
    5
    Trophy Points:
    120
    #7
    Also forgot to mention, for the front end you'll need to run some sort of runtime auto complete script/lib something like
    YUI 2: AutoComplete for instance,

    developer.yahoo.com/yui/autocomplete

    developer.yahoo.com/yui/examples/autocomplete/ac_fn_multfields

    The YUI Library is issued under a BSD license (similar to the GNU free software license)

    Great example of it's usage: adult meta engine offers search-as-you-type. You could configure a suggest.php
    spelling lib page to append to the lib for spell errors - search suggestions etc. similar to the search engine mentioned above.




    ROOFIS
     
    ROOFIS, Mar 24, 2011 IP
  8. bledileka

    bledileka Peon

    Messages:
    35
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #8
    well i think there is no perfect tool for that, you can use some ready scipts but you have to do your own code for that. autocomplete scripts there are a lot, just google it, but the code, you have to do it yourself.If you use mysql, you need to use some queries with REGEXP or LIKE %% to get aproximate or possible matches for suggestions.
    You can try with google spell checker class for spelling.
     
    bledileka, Mar 24, 2011 IP
  9. G3n3s!s

    G3n3s!s Active Member

    Messages:
    325
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    80
    #9
    he wanted to obtain completed free code


    I saw function which compared text with similar mysql records but I do not remember name :/
     
    G3n3s!s, Mar 25, 2011 IP
  10. ROOFIS

    ROOFIS Well-Known Member

    Messages:
    1,234
    Likes Received:
    30
    Best Answers:
    5
    Trophy Points:
    120
    #10
    Probably, though OP could be looking for some direction too.

    PHP has some nifty functions like soundex and metaphones/double metaphones for spelling applications.

    Lawrence Philips offers a Open Source Spell Checker utilizing the metaphone algorithm and a PHP Implementation
    of the double metaphone algorithm is available too. This combined with all the other replies should be able to give
    Catherine86 a good head start at least. :cool:






    ROOFIS
     
    ROOFIS, Mar 26, 2011 IP
  11. CodeMaster1233

    CodeMaster1233 Well-Known Member

    Messages:
    28
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    106
    #11
    CodeMaster1233, Mar 30, 2011 IP