Fortune Teller

  • 8 Replies
  • 6635 Views
*

MarkB

  • Roomba
  • *
  • 17
Fortune Teller
« on: November 03, 2010, 03:18:42 am »
Last week I was asked to make a chat-bot that could do fortune telling. For example, you'll ask something like "Will I win the lottery next week?" and it will answer "The odds are good that you will win the lottery next week." It rolls a dice and replaces the "The odds are good..." part with a phrase to indicate higher or lesser odds.

It sounded simple enough to give it a try. But since I hate to reinvent the wheel, I first posted something on a Pandora-bot mailing list if there maybe was already an existing solution for this particular case. But I got zero response.

So I decided to give it a go. I thought, how hard can it be? Well, it turned out to be trickier than I originally thought. I cut it up in two parts. First it has to recognize a yes-no question and turn it into a declarative statement. I soon found out that catching all the possible variations using straight pattern-matching a la AIML or CHAT-L is going to be a nightmare. So I needed something else. A bigger boat, so to speak.

So what I decided to do was incorporate grammar patterns into my CHAT-L parser. What it does is use Link Grammar to build the constituent tree and allow XPATH expressions on this tree to be incorporated into the chat-rule. That way I was able to turn yes-no questions into a declarative statement with just a few chat-rules.

The second part was to switch the person around. So it will answer a question asked in 1st person into a 2nd person statement. I'm not happy with that part yet, but it works somewhat.

I'd be interested to hear about experience others had with similar problems. Are there other chat-bots that do grammar juggling like this? In the meantime you can try my solution out in Wildwood in Blue Mars. (When in Wildwood, click on the bear to jump to Rosie the Fortune Teller.)

When I asked it "Tell me, will the silly Giants win the world series this year?" it answered "Absolutely, the silly Giants will win the world series this year."

So there, it works! :)

Mark
"More human than human is our motto."

*

Data

  • Trusty Member
  • ***********
  • Eve
  • *
  • 1279
  • Overclocked // Undervolted
    • Datahopa - Share your thoughts ideas and creations
Re: Fortune Teller
« Reply #1 on: November 03, 2010, 12:00:58 pm »
Hi Mark, this sounds interesting, as long as you don’t take it too seriously and as a bit of fun I think it’s a neat idea.

In the meantime you can try my solution out in Wildwood in Blue Mars. (When in Wildwood, click on the bear to jump to Rosie the Fortune Teller.)

What is Wildwood or Blue Mars? Never heard of them, could you post a link to the bot.

*

Freddy

  • Administrator
  • **********************
  • Colossus
  • *
  • 6859
  • Mostly Harmless
Re: Fortune Teller
« Reply #2 on: November 03, 2010, 01:55:57 pm »
Here's one example : http://www.somewhereincanada.com/playground/swami/

And also an iTunes app if you have that : http://itunes.apple.com/app/edwin-the-foreteller/id380422365

Might give you some ideas. :)

*

MarkB

  • Roomba
  • *
  • 17
Re: Fortune Teller
« Reply #3 on: November 03, 2010, 07:13:16 pm »
Here's one example : http://www.somewhereincanada.com/playground/swami/

And also an iTunes app if you have that : http://itunes.apple.com/app/edwin-the-foreteller/id380422365

Might give you some ideas. :)

Although those look interesting at first sight, both of these completely ignore what you're saying to them and just put out a random phrase. So that is definitely not what I'm interested in, even if there are many people that are.
« Last Edit: November 03, 2010, 07:30:59 pm by MarkB »
"More human than human is our motto."

*

MarkB

  • Roomba
  • *
  • 17
Re: Fortune Teller
« Reply #4 on: November 03, 2010, 07:20:58 pm »
What is Wildwood or Blue Mars? Never heard of them, could you post a link to the bot.

I did't want to spam the forum with links to the place I work for every time I post, but since you're asking...
Blue Mars is a platform for building social 3-D virtual worlds. Wildwood is one of those worlds.
http://www.bluemars.com

"More human than human is our motto."

*

Data

  • Trusty Member
  • ***********
  • Eve
  • *
  • 1279
  • Overclocked // Undervolted
    • Datahopa - Share your thoughts ideas and creations
Re: Fortune Teller
« Reply #5 on: November 03, 2010, 08:48:57 pm »
Thanks for the link and the concern about spamming. Its fine to post them here as long as its related in some way to Ai dreams and your topic, which yours is, that’s right isn’t it Freddy?

I didn’t know Blue Mars was a virtual world though, I must have missed some of your previous posts, don’t think I will be going in there, had enough trouble breaking my SL addiction  :(  :o  :)

Good luck with the Fortune Teller.

*

Art

  • At the end of the game, the King and Pawn go into the same box.
  • Trusty Member
  • **********************
  • Colossus
  • *
  • 5865
Re: Fortune Teller
« Reply #6 on: November 03, 2010, 09:02:42 pm »
Datahopa,

Bruce Wilcox's Suzette chatbot was written primarily as a bot / avatar on Blue Mars or at least that's what I got from his explanation a while back when we were discussing Suzette.

Sorry you missed it.

Personally, I'm not into the Virtual World scene like SL and all the others... I have enough difficulty navigating the real world for now! ::)
In the world of AI, it's the thought that counts!

*

Freddy

  • Administrator
  • **********************
  • Colossus
  • *
  • 6859
  • Mostly Harmless
Re: Fortune Teller
« Reply #7 on: November 03, 2010, 09:38:47 pm »
@Datahopa, Fine by me - links of interest are encouraged  ;D

*

MarkB

  • Roomba
  • *
  • 17
Re: Fortune Teller
« Reply #8 on: November 05, 2010, 02:49:29 am »
As chance would have it, direct linking to the different worlds has just been implemented. So now you can go here:
 
http://www.bluemars.com/#/Wildwood

but you still have to click the bear to meet the fortune teller.

Clicking "Go to city" will then bring you there straight. If you have the client installed and an account, obviously, but it's all free.

Suzette can be found here:

 http://www.bluemars.com/#/AR_WelcomeArea

she's on the stage.
"More human than human is our motto."

 


AI controlled F-16, for real!
by frankinstien (AI News )
June 15, 2024, 05:40:28 am
Open AI GPT-4o - audio, vision, text combined reasoning
by MikeB (AI News )
May 14, 2024, 05:46:48 am
OpenAI Speech-to-Speech Reasoning Demo
by MikeB (AI News )
March 31, 2024, 01:00:53 pm
Say good-bye to GPUs...
by MikeB (AI News )
March 23, 2024, 09:23:52 am
Google Bard report
by ivan.moony (AI News )
February 14, 2024, 04:42:23 pm
Elon Musk's xAI Grok Chatbot
by MikeB (AI News )
December 11, 2023, 06:26:33 am
Nvidia Hype
by 8pla.net (AI News )
December 06, 2023, 10:04:52 pm
How will the OpenAI CEO being Fired affect ChatGPT?
by 8pla.net (AI News )
December 06, 2023, 09:54:25 pm

Users Online

312 Guests, 0 Users

Most Online Today: 341. Most Online Ever: 2369 (November 21, 2020, 04:08:13 pm)

Articles