6 ms·
While spell-checking is slow, it is not necessarily as slow as 200ms per word. But it is necessary to have one or else people will struggle with your chatbot.
by olavgg 10y ago
While spell-checking is slow, it is not necessarily as slow as 200ms per word. But it is necessary to have one or else people will struggle with your chatbot.
We have created a chatbot that handles mispellings and dialects just fine for the banking and insurance industry in scandinavia. You can try him here: https://james-demo-test.boost.ai https://james-demo-test.boost.ai (You need google translate as it only understands norwegian, with some support for danish and swedish synonyms. Support for english and other languages are under development)
For fast spell checking, I recommend reading this http://theyougen.blogspot.no/2010/02/faster-spelling-corrector.html http://theyougen.blogspot.no/2010/02/faster-spelling-correct... which uses a bloom filter.
We use https://en.wikipedia.org/wiki/Damerau%E2%80%93Levenshtein_distance https://en.wikipedia.org/wiki/Damerau%E2%80%93Levenshtein_di... and we use a slightly modified slow python implementation https://www.guyrutenberg.com/2008/12/15/damerau-levenshtein-distance-in-python/ https://www.guyrutenberg.com/2008/12/15/damerau-levenshtein-...
Performance is not a high priority for us, we can easily scale by adding cpu cores. A good precise answer is a lot more important and its where we spend most of our time improving our chatbot.
- semi-extrinsic 10y agoNative Norwegian speaker here. I've tried about ten different questions off the top of my head, and it's very much "God dag mann - økseskaft." E.g. I asked "What is the interest rate on mortgages?" and it gave me basically what I asked for, with an example of total cost over 25 years. Then I asked "How much would that be every month?" and it gave me a link to applying for "avdragsfrihet", but with a text recommending against doing so. Apparently dividing by 300 is beyond its faculties. Or I asked "How do I invest in index funds?" and it replied "I don't understand, try calling us". Basically, I couldn't get an answer to any of my questions that I hadn't gotten if I'd just googled the exact same phrase. And it doesn't appear to understand follow-up questions at all. I'm curious, do you have a question I can try that will give me something google won't answer given the same query?
- olavgg 10y agoThank you for feedbank. 1. We are currently working on supporting queries with amounts, the first kind will be a "loan-calculator" that tell you how much you can loan for a new house or a new car. We did try syntaxnet for this earlier, but it failed big time with dialects, so we are creating our own variant. 2. We have nothing on index funds yet, our customers so far does neither have that kind of a thing, though it should at least have been a synonym for funds. This will be corrected. This bot is a customer service kind of chat bot. It's not something to have a conversation with, but more like a bot that can understand questions and help you. The business value here is not to be better than human, but be as close as possible for the most common support queries. Trying to pass the Turing test is unrealistic... We are trying to automate support issues for the most common questions like, I have lost my credit card, I need a new card and I cannot login. Compared to a regular search engine, ours will have a much better understanding of what your intention is. Google also tries to predict your intention when you search. However Google is not a replacement for customer support for most banks, telecoms, logistics, energy and insurance companies.
- olavgg 10y agoI would also like to add comparisons: Swedbank uses Nuance's Nina, its available at swedbank.se under customer service. SEB uses IPSoft's Amelia, which is available here: http://seb.se/kundservice/kundservice-privat/chatta-med-oss http://seb.se/kundservice/kundservice-privat/chatta-med-oss Those are Swedish though. Nuance also have an english version Nina for Coca Cola, but that one have very few answers... http://www.coca-colacompany.com/contact-us http://www.coca-colacompany.com/contact-us
- greglindahl 10y agoI did some advising for a company selling customer support software -- state of the art for ISP helpdesks was to have the person answering the phone try to google the answer. Terrible? Yes. But google worked better than most custom search engines :-/
- semi-extrinsic 10y ago> Trying to pass the Turing test is unrealistic I agree. But beating an equivalent Google query should be the goal IMO. Otherwise what's the point? Unfortunately, I don't think business specific chatbots are able to; Google just gets many orders of magnitude more users (even when narrowed down to Norwegian Bank X), so their "dumber" algorithms work just as well. So I reiterate my question: can you give me one example query where this chatbot outperforms Google search? The same goes for site-specific search engines, especially MSFTs Bing (neé Fast) that universities etc. seem to love spending money on; I've always found it to be worse than plain Google search with a "site:univ.edu" suffix. So you can definitely sell this tech to non-tech-savvy companies/institutions and make money, but users won't like it.
- dr_zoidberg 10y agoI toyed around with that python DL-distance in cython and without much effort got it to work 3.5~4x faster. Have you looked into cython to optimize it? It certainly seems cheaper than adding CPU cores, even more so considering I'm quite new to cython myself (I just took the code and added types and a few fixes here and there to get it to work faster).
- dr_zoidberg 10y agoScratch that, with a bit more of tinkering got a ~80x speedup. Still get the feeling there's some more performance to get, but that'd require some assembly-fu or a different algorithm.
- dr_zoidberg 10y agoAnother slight change got me 100x. Now yes, I'd need assembly or an equivalent (but more efficient) algorithm.
- eriknstr 10y agoInteresting bot. I found it a bit confusing that the page says to "ask James" but the bot presents itself as "Banki". Off-Topic: You've been on HN for 1337 days. You should celebrate that with a cake.