Showing posts with label ai. Show all posts
Showing posts with label ai. Show all posts

2015-11-03

Named Entity Recognition using SpaCy in 5 minutes

Recently, I am looking it SpaCy, a startup and an NLP toolkit. It is fabulous on its speed. Today, I just gave it a try on NER. Just a few lines (as in iPython):

In [1]: import spacy.en
In [2]: parser = spacy.en.English()
In [12]: ParsedSentence = parser(u"alphabet is a new startup specializing in eating their own words on leaving china to fight for information freedom")

In [13]: print ParsedSentence.ents
()

In [14]: ParsedSentence = parser(u"Alphabet is a new startup specializing in eating their own words on leaving China to fight for information freedom")

In [15]: print ParsedSentence.ents
(Alphabet, China)

In [16]: for Entity in  ParsedSentence.ents:    
   ....:     print Entity.label, Entity.label_, ' '.join(t.orth_ for t in Entity)
   ....:     
349 ORG Alphabet
350 GPE China

I used only default settings. Apparently, the NER of SpaCy is very sensitive to case of words.

2014-01-12

Strange Impact Factor trend of the journal Computational Intelligence

Back in 2009, I was submitting a paper on artificial intelligence with  my PhD advisor. We found a journal called Computational Intelligence, whose then Impact Factor was above 5 (see Appendix: How high IF 5 is in AI?). According to Thomson Reuter's Journal Citation Report, this journal was the No.1 in the category "Computer Science, Artificial Intelligence." So we submitted to this journal and it was accepted and published. I was so happy and told my mom "I published a paper on a top AI journal."

The next year (2010), the Impact Factor of this journal drastically dropped to 0.704. I felt this was the end of the world. How can I use such a paper to find a faculty position?

For a random reason, I checked its Impact Factor today. Now it's exactly 1.000.

The figure below visualizes the Impact Factor trend of this journal over the past 5 years.


Sometimes I think that Impact Factor of a journal is a joke.

Appendix: How high IF 5 is in AI?
Here are the Impact Factors (2012) of the several well-known AI journals:
  • Artificial Intelligence (Elsevier, also known as AIJ): 2.194
  • IEEE Transactions on Knowledge and Data Engineering (TKDE): 1.892
  • Journal of Machine Learning Research: 3.420
  • IEEE Transactions on Systems, Man, and Cybernetics Part B: 3.236
  • IEEE Transactions on Pattern Analysis and Machine Intelligence (PAMI): 4.795
  • International Journal of Computer Vision (Springer): 3.623
  • Knowledge-based systems (Elsevier): 4.104
  • IEEE Transactions on Neural Networks and Learning Systems: 3.766
So, an Impact Factor of 5 is pretty high in the field of AI, or literally "Computer Science, Artificial Intelligence" category.

2008-02-10

Thinking in AI [0]: Why I don't need to know how to read EEG plots?

by Forrest Sheng Bao http://fsbao.net

Recently I wanna write a computer program that can diagnose a neural disease automatically from EEG data. Since I have no idea on diagnosis of this disease, those medical guys couldn't understand how I can "teach" a computer to some stuff without knowing how to it by myself.

So I gave them another example. I know nothing about botany, but Stephen Wu and I did build a program that can classify 32 plants. I explained to them that I just need to extract some features by signal processing techniques and "feed" them into a classifier, which is a mathematical transformation in essential. The the output of the transformation can tell me of which class the sample is.

They just couldn't understand the mechanism I explained to them. It looked like that I was discussing building a time machine.

Then I tried much easier way, I said we wanna find a mapping from the space spanned from feature vectors to a space of classes. Different classifiers (linear classifiers, ANN, SVM, integral transformation, etc.) are just different mappings. They varies on identity, speed, anti-noise ability, etc. You can just consider you have a lot of equations and you wanna find a solution. That's why I don't need to know any medical knowledge about diagnosis of this disease.

Well, it was still useless.

Besides this, I was always asked what Answer Set Programming is. It seems this time I am talking about building time machine again. Since I don't know how to solve Sudoku or many other puzzles, again, they couldn't understand why I can "teach" computer to do something without knowing how to it myself. I told them that I just need to tell the computer rules to generate solutions and criteria to eliminate wrong solutions, then the computer can figure out possible solutions by logical reasoning.

So now I am tried and I just wanna tell everyone can't understand my answers "Yes, I am building a time machine". It is as difficult as telling Indians in 1800s what space shuttle is. But I am a graduate student rather than a magician.

Since I am working on a project using pattern recognition and machine learning stuffs, I wanna make my professors know what I am doing - I am not playing video games at the lab. I plan to write down the techniques I know in this fields so I can check them when need to review them.

Ok, so I will discuss some basic ideas of linear classifiers next time.

2008-01-23

Strong AI stalls?

by Forrest Sheng Bao http://fsbao.net

(I am very foolish and naive. So there will be tons of errors in this article. Welcome to figure them out to me.)

Last Xmas(2007), my sister Christina Zhang came from Canada to see me (coz Texas is warmer). She asked me what Artificial Intelligence is. It's fairly hard to explain AI to a high school student. But I think at least I don't understand AI well enough to explain to a kid instantly.

Today I got my textbook "Elements of the theory of computation" whose cover is a famous (I prefer to use the word I created, ZB) guy, Alan Turing. So I went to Wikipedia again and read his introduction which has been read by me many times. I surfed from one link to another and found a paper.

In 1980, a guy in UC Berkeley, John Searle, published a paper titled:
"Minds, Brains and Programs" on the journal "Behavioral and Brain Sciences"
http://www.bbsonline.org/Preprints/OldArchive/bbs.searle2.html

He defined two terms, "strong AI" and "weak/cautious AI".

To "weak AI", he said: "According to weak AI, the principal value of the computer in the study of the mind is that it gives us a very powerful tool. For example, it enables us to formulate and test hypotheses in a more rigorous and precise fashion."

To "strong AI", he said: "But according to strong AI, the computer is not merely a tool in the study of the mind; rather, the appropriately programmed computer really is a mind, in the sense that computers given the right programs can be literally said to understand and have other cognitive states."

In my words, automated reasoning and problem solving are among the fields of "strong AI". Looks like the works of John McCarthy decades ago on puzzle solving. "weak AI" considers that it is not possible to build a precise human mind but an optimized/approximated one. It is more popular now and rapidly developing, such as pattern recognition, computer vision, etc.

I saw a review, stating that strong AI stalls now (or develops very slowly) while weak AI has many widely credited applicable results. Yeah, it's true. Lots of laptops nowadays are equipped by a finger print recognition system.

I was shocked. This matches my feeling when I first joined KRLab(Knowledge Representation Lab). But the problem is, the requirements to planning and scheduling from industries are growing, such as airports or NASA. So it is funny. The world needs faster reasoning agents while we can't build them. For instance, it takes 30 years for John McCarthy to figure out the idea of "default." (According to Dr. Gelfond's slides of "Intelligent System"). It also took many years for us to distinguish the concepts default negation and true negation (Gelfond & Lifschitz).

You know LISP? You know Prolog? A long time ago... Of course, 50 years are not long to the history, but long enough to Computer Science.

Why? Do we need a new theory of computation? Do we need the next Alan Turing?

Now the basis of strong AI is from logic, precisely, the non-monotonic logic. The famous language Prolog stands for "Programming in Logic." That's why someone considered that the foundation of AI was formed when Aristotle concluded how human beings think on mountains of Greece. What I wonder is, whether this idea is correct.

Besides, strong AI costs much time on knowledge representation. But this is a tough work. It's hard to represent a container, a closed container, a container with a lip.

Can someone give me an answer, why strong AI stalls? What is the crack to the next revolution?

I need to figure this out before choosing the title of my Ph.D. dissertation.