AI Zone Admin Forum Add your forum

NEWS: Chatbots.org survey on 3000 US and UK consumers shows it is time for chatbot integration in customer service!read more..

Pre-chatbot, it’s my syllogism program
 
 
  [ # 16 ]

OK, I have edited the syllogisms so they now make more sense.

Type 1 to run the program
1


Enter a sentence
all lower case.
Rename X and Y with wordsthe new word must have both a letter and vowel in it.

Formats of sentences:

A.)X are Y
B
.)some X is Y
C
.)some X are not Y


some dog is here

__________________________________________

Type Celarent 
(EAE-1) or Celaront (EAE-1Syllogism pattern

No M is P
S are M


Celarent

some dog is here
.
bloodhound are dog.
some bloodhound is here

Celaront

some dog is here
.
bloodhound are dog.
Some bloodhound are not here

Felapton

some dog is here
.
bloodhound are dog.
Some dog are not here

__________________________________________


Was the syllogism logical
for yesfor no1
Close program
for yesfor no0



Enter a sentence
all lower case.
Rename X and Y with wordsthe new word must have both a letter and vowel in it.

Formats of sentences:

A.)X are Y
B
.)some X is Y
C
.)some X are not Y


some bad is here

__________________________________________

Type Celarent 
(EAE-1) or Celaront (EAE-1Syllogism pattern

No M is P
S are M


Celarent

some bad is here
.
backstabber are bad.
some backstabber is here

Celaront

some bad is here
.
backstabber are bad.
Some backstabber are not here

Felapton

some bad is here
.
backstabber are bad.
Some bad are not here

__________________________________________


Was the syllogism logical
for yesfor no1
Close program
for yesfor no1

Press any key to 
continue . . . 

I’ve re-uploaded the newest source too.

File Attachments
new.zip.txt  (File Size: 46KB - Downloads: 90)
 

 
  [ # 17 ]

I did simplify the syllogisms and see now that ruined it, so I will go and update my program so the syllogisms are verbatim to what the charts show at Wikipedia.
It’ll take a while though.

 

 
  [ # 18 ]

I am unsure why you would copy a chart that is incorrect?

 

 
  [ # 19 ]

Here is the exact formula from the Wikipedia charts:

Felapton (EAO-3)   

No Bloodhound is here
And all Bloodhound are Dog
And some Bloodhound exist
Thus some Dog are not here


Celarent 
(EAE-1)   

No Dog is here
And all Bloodhound are Dog
Thus no Bloodhound is here


Celaront 
(EAO-1)

No egg is here
And all chickens are egg
And some chickens exist
Thus some chickens are not here 

In my code I changed the celarent and felapton and disgarded the celaront. Here are my new results:

no dog is here

__________________________________________

Type Celarent 
(EAE-1) or Felapton (EAE-1Syllogism pattern

No M is P
(CelarentS are M
(FelaptonM are S)


Celarent

no dog is here
.
bloodhound are dog.
no bloodhound is here

Felapton

no bloodhound is here
.
bloodhound are dog.
Some dog are not here

__________________________________________


Was the syllogism logical
for yesfor no

Now it’s correct I think.

 

 
  [ # 20 ]

That’s more like it. smile

 

 
  [ # 21 ]

Here are the new results

Type 1 to run the program
1


Enter a sentence
all lower case.
Rename X and Y with wordsthe new word must have both a letter and vowel in it.

Formats of sentences:

A.)X are Y
B
.)no X is Y
C
.)some X are not Y


no dog is here

__________________________________________

Type Celarent 
(EAE-1) or Felapton (EAE-1Syllogism pattern

No M is P
(CelarentS are M
(FelaptonM are S


Celarent

no dog is here
.
bloodhound are dog.
no bloodhound is here

Felapton

no bloodhound is here
.
bloodhound are dog.
Some dog are not here

__________________________________________


Was the syllogism logical
for yesfor no1
Close program
for yesfor no0



Enter a sentence
all lower case.
Rename X and Y with wordsthe new word must have both a letter and vowel in it.

Formats of sentences:

A.)X are Y
B
.)no X is Y
C
.)some X are not Y


music are here

__________________________________________

Type Camestros 
(AEO-2Syllogism pattern

P are M
No S is M


music are here
.
No artistic is here.
Some artistic are not music

__________________________________________


Was the syllogism logical
for yesfor no1
Close program
for yesfor no0



Enter a sentence
all lower case.
Rename X and Y with wordsthe new word must have both a letter and vowel in it.

Formats of sentences:

A.)X are Y
B
.)no X is Y
C
.)some X are not Y


some music are not here

__________________________________________

Type Bocardo 
(OAO-3Syllogism pattern

Some M are not P
M are S


some music are not here
.
music are artistic.
some artistic are not here

__________________________________________


Was the syllogism logical
for yesfor no1
Close program
for yesfor no1

Press any key to 
continue . . . 

I’ll upload the newest source too.

File Attachments
new.zip.txt  (File Size: 46KB - Downloads: 93)
 

 
  [ # 22 ]

I notice some of your sentences are forced into odd constructions (ie, “music are artistic.”) Is this because the “X” and “Y” choices must be single words? (I haven’t looked at your source code.) Have you thought about generalizing the format requirements for the input strings?

 

 
  [ # 23 ]

I have to know the location of M to generate S. So the sentences need to point to the location of M in the first sentence.

I thought about this problem though. The solution I thought of was, there are sections in a sentence that can hold multiple words.

A section may be a noun and verb, then it is followed by a complement noun section, then a verb section, then a complement noun section.

What this would work like is I am operating with one word then I get to M and M is one word, then one word then P then I generate S.

But in this new scheme I would go to the first word, then the second word, then to M and there would be a M1 and M2 and I generate the word based on what M2 is, then I go to the third section and this has two words and the P section has two words.
Then the generated sentence, the minor premise would do the same thing, instead of going past the first word to S I would go through two words and so on.

This way I could plan how many words I want for my templates and maybe a hundred or so templates should hold most kinds of sentences.

But the problem is with so many templates how do I know which one is being used, and this means the templates need grammar and so the word list needs grammar and so the job balloons by ten fold to get the templates and word list to use grammar.
This is too much for me to do so I will leave it alone.
But thank you for your interest in my project. smile

Edit, this is what I wrote for Arthur Arturovich over at a-i.com forum:

“Hi, I have updated the first post.

Syllogisms are easy to program, I will tell you how I did it.
The user inputs a sentence.
The syllogism has two parts in the main and minor premise.

So the first sentence, the one the user input has a M and a P part.
The minor premise has a S and M part. (I know the letters are odd, but I got this from Wikipedia).

You take the M part from the main premise and put it in the m part in the minor premise, and you use your program to deduce what S should be.

Then you write the syllogism conclusion using the S M P parts and your done. Easy as that.

Edit, I think you may wonder how I deduced what S should be?

The word has two parts and four forms. I used these two pieces to draft up what S should be.

The two parts of the word are the vowel and the letter.
Each word has these in one of four forms.
These forms are:
Letter
Vowel
Letter vowel
Vowel letter

I used the vowel and letter and one of the four forms to deduce what the S should be. I think I used the vowel letter form, I’m not sure.

This means that the last letter in the word is the letter, not vowel, and somewhere in the word is the vowel.

Edit, no no, I used Both Vowel letter and letter vowel.
Meaning that if there was no letter in the last letter of the word, I went with the letter as the First letter of the word, and then the vowel was somewhere random in the word.”

The template looks like this:
“point\shoot\reload\autofire”
This translates into this if you use words and vowels:
“BAB\BA\AB\ABA”

The way the template would work with grammar added would be:
“BAB(Noun and verb)\BA(complement noun)\AB(verb)\ABA(complement noun)”
Which would literally look like this:
“BAB\AB\  BA\AB \BAB\BA \ABA\ABA”

 

 
  [ # 24 ]

Example:

Type 1 to run the program
1


Enter a sentence
all lower case.
Rename X and Y with wordsthe new word must have both a letter and vowel in it.

Formats of sentences:

no X is Y

no dog is here

__________________________________________

Type Celarent 
(EAE-1Syllogism pattern

No M is P
S are M
No S is P


Celarent

no dog is here
.
bloodhound are dog.
no bloodhound is here

__________________________________________


Was the syllogism logical
for yesfor no

The program uses two parts: a sentence generator and a syllogism conclusion maker.
The user inputs one sentence and the code creates the rest of the syllogism.
The S word in the minor premise is created by randomly choosing a word from a list of words. I use kelvins word list 12 dictionaries, “2 of 12.txt” from source-forge.

The way the word is chosen is if it is wrong for the syllogism you mark it zero and one if it is right.
I posted this before but I have slimmed the program down so only one syllogism is made and not every kind listed at Wikipedia. Now the code has everything it needs but only for one syllogism. Before it has around 30000 lines of code now less than 6000.

In the code there is four key words: point, shoot, reload, auto fire.
These translate into: point = letter as the first letter, and last letter of the word, shoot = letter as the first letter and vowel as the last letter of the word, reload = vowel as the first letter of the word and letter as the last letter of the word, auto fire = vowel as the first and last letter of the word.
These keywords translate language into four words. so all sentences are made up of these four words. This makes the program easy to design.

link

 

 

 
  [ # 25 ]

I am a bit confused by the logic that is being applied here. My inturpitation of the process is to qualify the intention of the user’s input by means of determination.

An example of what I am working on:

User: I just bought a new apple.

Kbase returns: apple~fruit_food/~company_technology_computer

Bot: Apple is a fruit associated with food and a company associated with technology.

User: I mean fruit.

Bot: You just bought fruit which is an apple.

Or alternatively;

User: I mean computer

Bot: You bought an apple computer

Of course this method of determination requires a word association algorithm in the parsing process, but it is a simple straight forward method of sentence inturpitation when more than one meaning is possible.

 

 
  [ # 26 ]

I have updated the code reducing the number of lines from ~30000 to ~3000
link

That method sounds pretty good. If I put this concept into my program I would have the multiple options of what a word means instead of a zero one answer and this would lead to the syllogism using that word.

My intention is to generate a word (S) that should match the input word (M) so the entire syllogism makes sense.

These are the results my program generates for the input sentence “no apple is here”:
apple armful

apple appal

apple appall

apple apparel

apple appeal

apple appraisal

apple approval

apple arboreal

apple archaeological

apple archangel

apple archetypal

apple archetypical

apple archiepiscopal

apple architectural

apple archival

apple areal

apple arithmetical

 

 
  [ # 27 ]
Jeremy Duncan - Dec 23, 2011:

These are the results my program generates for the input sentence “no apple is here”:
apple armful

apple appal

apple appall

apple apparel

apple appeal

apple appraisal

apple approval

apple arboreal

apple archaeological

apple archangel

apple archetypal

apple archetypical

apple archiepiscopal

apple architectural

apple archival

apple areal

apple arithmetical

Well I am still confused. What possible use would such output have for “no apple is here”? Surely a random word generator could do exactly the same thing.

 

 
  [ # 28 ]

It’s never a good thing when some of the smartest people I know have become confused all at once. downer

 

 
  [ # 29 ]

I updated my program again:
http://www.mediafire.com/?vl1h1970lb7b8wp

A lot less unused code, more easy to read.

My program isn’t finished, it’s an early design.
The results aren’t geared to the syllogism, they are geared to the M word from the main premise.
Let me ask you, if you eat an apple do you inspect it to see if it’s rotten? This is approval process.
But this result isn’t logical I guess since it’s not fitting “no apple is here”, but then it wasn’t designed to do so.

 

 
  [ # 30 ]
Jeremy Duncan - Dec 23, 2011:

But this result isn’t logical I guess since it’s not fitting “no apple is here”, but then it wasn’t designed to do so.

Care to post some results that are logical? I find it hard to believe that it took 3000 lines of code to create such output.

Edit, this is what I wrote for Arthur Arturovich over at a-i.com forum:

I wouldn’t pay too much attention to Arthur. Without even seeing the thread, I will guess that he has said very little about your program yet managed to spam his own? Am I right?

 

 < 1 2 3 4 >  Last ›
2 of 9
 
  login or register to react
‹‹ MALDIX      SMS ChatBot ››