Advice for Natural Language Processing etc.

  • 8 Replies
  • 3604 Views
*

Melodix

  • Roomba
  • *
  • 1
Advice for Natural Language Processing etc.
« on: March 23, 2018, 06:34:17 pm »
Hi, I'm pretty new here, so I hope this is the right forum.
I recently took an Introduction course to AI and got interested.
I want to write a program which takes a question as input and give an answer depending on a "Facts-Database".
For example, if the user asks "How tall are you?" the program looks into the database for height and answers the question.
So kinda like a Chatbot but with a fixed set of knowledge.
My problem is just that I have no idea where to start, so I would be glad if someone could link me any papers, projects etc. which could help me.

Thanks in advance
Melodix

*

Freddy

  • Administrator
  • **********************
  • Colossus
  • *
  • 6860
  • Mostly Harmless
Re: Advice for Natural Language Processing etc.
« Reply #1 on: March 23, 2018, 07:04:08 pm »
Welcome to the site :)

Since the input/output is fixed then a scripting language like AIML would work for that.

You would be doing things like this :

Code
<category>
      <pattern>HOW TALL ARE YOU</pattern>   
      <template>Oh about 8 feet !</template>
</category>

Here's something to read on AIML : Learn AIML

And a more general article we have here : How To Create Your Own Customised Chatbot For Beginners - Chatbots 101

Part two of the latter (A Web-Based Chatbot - Pandorabots) you might want to read first as that deals with a service that will run AIML bots.
« Last Edit: March 23, 2018, 07:38:16 pm by Freddy »

*

Art

  • At the end of the game, the King and Pawn go into the same box.
  • Trusty Member
  • **********************
  • Colossus
  • *
  • 5865
Re: Advice for Natural Language Processing etc.
« Reply #2 on: March 24, 2018, 01:13:52 pm »
Hello Melodix! Good to have you aboard! O0
In the world of AI, it's the thought that counts!

*

keghn

  • Trusty Member
  • *********
  • Terminator
  • *
  • 824
Re: Advice for Natural Language Processing etc.
« Reply #3 on: March 24, 2018, 05:40:15 pm »
Here is a more advanced model that dose not rely on a return button and really speaks. You will like. It no of the long gone
age of text bot,

https://www.youtube.com/watch?time_continue=1&v=rcdhUMBN8P0

*

LOCKSUIT

  • Emerged from nothing
  • Trusty Member
  • *******************
  • Prometheus
  • *
  • 4659
  • First it wiggles, then it is rewarded.
    • Main Project Thread
Re: Advice for Natural Language Processing etc.
« Reply #4 on: March 24, 2018, 05:48:52 pm »
Advice - use a LSTM

DNC is a type of ANN-computer storing invention that recently came out by Deep Mind team. It can answer questions and explain the underground map of London or somethin like that.
Emergent          https://openai.com/blog/

*

Don Patrick

  • Trusty Member
  • ********
  • Replicant
  • *
  • 633
    • AI / robot merchandise
Re: Advice for Natural Language Processing etc.
« Reply #5 on: March 25, 2018, 08:29:52 am »
I should mention that ChatScript, a chatbot scripting language, supports using a fact database. I've often enough seen the topic pass on its support site. I've seen people hook it up to WordNet, which can make do as a knowledge database, although it's not supposed to be one. Of course Chatscript allows building one's own database of facts, and in my opinion it is well suited for programmers.

In NLP, I have yet to come across papers that address both chatbottery and fact databases aka ontologies. We have had a helpful topic on the latter recently that names some:
http://aidreams.co.uk/forum/index.php?topic=12946.0
CO2 retains heat. More CO2 in the air = hotter climate.

*

spydaz

  • Trusty Member
  • *******
  • Starship Trooper
  • *
  • 325
  • Developing Conversational AI (Natural Language/ML)
    • Spydaz_Web
Re: Advice for Natural Language Processing etc.
« Reply #6 on: April 12, 2018, 04:42:36 pm »


NLP is Not so hard to understand;
Tokenizing - Turning stings into tokens?
Categorising - Extracting categorical data
Counting freqs - Self explanatory...... If a word is highly frequent it may be assumed that the String is about that topic......or even a group of words can also be attributed to a particular writing style denoting the Writer of the text etc......
Sentence meaning---- Attempts to understand the sentences .... John is Paul's father, I am happy
Sentiment analysis - i am happy .... User sentiment / object sentiment etc.....

All can be achieved with collected lists (dictionaries), (Word polarities) etc.... Utilising these lists with functions which check the sentence for elements which have information pertaining to the technique being applied.

Yes After these elements and functions created , data collected.... It can be used in Some form of (probability learning mechanism) such as neural networks... based on patterns which element would here ..... The cat sat on the .... but we can all guess the answer... the neural network could predict the answer but ...... so could normal programming code and frequencies... some basic maths (not calculus) .....

the simplest answer is generally the best option.... to have a neural network performing a single task in your AI, and multiple neural networks performing other tasks is a very high overhead, being a part of these Royal societies and institutes in the u.k .....Statistics / Mathematics/computer the is not a massive crossover of skills.  mathematicians and statisticians approach things from a different perspective than programmers. Computer programs produce results which often cannot be recreated mathematically. Becoming a data scientist - made me realise this factor . O lot of NLP product are Mathematical..... such as a neural network.... but the same functionality can be recreated without a neural network......a simple program can often do the trick. A car can be programmed to park itself.... no problem but for every possible parking space there is an issue.... but if enough data is collected any problem can be scaled up or down. but they also have used neural networks to learn how to park .... this does not mean that they needed to.... DARPA was working on this in 2000... and solved the self parking car/AUTO PILOT!
Neural networks can be applied to any problem if re-framed mathematically ....

outputs can be framed to give YES / NO Answers!

So maybe LSTM can select the right answer from the database for you.... but SQL can do that too!

« Last Edit: April 12, 2018, 05:58:50 pm by spydaz »

*

spydaz

  • Trusty Member
  • *******
  • Starship Trooper
  • *
  • 325
  • Developing Conversational AI (Natural Language/ML)
    • Spydaz_Web
Re: Advice for Natural Language Processing etc.
« Reply #7 on: April 12, 2018, 04:52:24 pm »
To start  -
Think about your storage for your database;
the SQL to retrieve the answer from the database should be relatively simple.
Build your basic interface (Input / Output)
Make sure your QUESTIONS are all in a SINGLE CASE; when retrieving the user sentence; Make sure its in the SAME CASE;
If answer is not in DB then Ask the User for Answer to be stored for Future reference.

This is your basic loop! begin here!

Then you can develop new methods and functions and mechanisms - to understand more or respond in a different way!

Recently i was informed that you should always begin with your "basic game loop" ... its correct! then you can build upon your idea as your knowledge grows.

When starting in AI begin simple.... Add what you know.....
Soon the Program itself will evolve;  there are always API's in the world which can deliver functionality to your AI; There are always library's to experiment with .... with all these functions etc you will soon have a rich Chat-bot ....

DoNOT Swamp your self with lots of Mad knowledge.... have some goals in mind...Achieve them.

Good luck!
 

*

Art

  • At the end of the game, the King and Pawn go into the same box.
  • Trusty Member
  • **********************
  • Colossus
  • *
  • 5865
Re: Advice for Natural Language Processing etc.
« Reply #8 on: April 13, 2018, 02:51:35 am »
No one has asked nor did you mention whether or not you have prior programming experience or not. If so in which arena?
You did mention in your title that you wanted advice for NLP which in and of itself is no trivial task to accomplish.

For a Chatbot with a Fixed set of knowledge, I would follow those other recommendations for learning AIML, ElfScript or RiveScript.

ChatScript, while a very powerful programming platform is not very beginner-friendly and has a somewhat steep learning curve.

ElfScript or RiveScript are much more friendly and every bit as powerful (debatable) than even AIML and can do most of those things you asked with ease.

Just my take. Happy Trails! O0
In the world of AI, it's the thought that counts!

 


Will LLMs ever learn what is ... is?
by HS (Future of AI)
November 10, 2024, 06:28:10 pm
Who's the AI?
by frankinstien (Future of AI)
November 04, 2024, 05:45:05 am
Project Acuitas
by WriterOfMinds (General Project Discussion)
October 27, 2024, 09:17:10 pm
Ai improving AI
by infurl (AI Programming)
October 19, 2024, 03:43:29 am
Atronach's Eye
by WriterOfMinds (Home Made Robots)
October 13, 2024, 09:52:42 pm
Running local AI models
by spydaz (AI Programming)
October 07, 2024, 09:00:53 am
Hi IM BAA---AAACK!!
by MagnusWootton (Home Made Robots)
September 16, 2024, 09:49:10 pm
Attempting Hydraulics
by MagnusWootton (Home Made Robots)
August 19, 2024, 04:03:23 am
LLaMA2 Meta's chatbot released
by spydaz (AI News )
August 24, 2024, 02:58:36 pm
ollama and llama3
by spydaz (AI News )
August 24, 2024, 02:55:13 pm
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

Users Online

422 Guests, 0 Users

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

Articles