{"id":925,"date":"2008-07-26T12:36:45","date_gmt":"2008-07-26T19:36:45","guid":{"rendered":"http:\/\/islemaster.wordpress.com\/?p=9"},"modified":"2014-03-17T00:40:42","modified_gmt":"2014-03-17T07:40:42","slug":"self-training-categorizer","status":"publish","type":"post","link":"https:\/\/www.bradleycbuchanan.com\/b\/self-training-categorizer\/","title":{"rendered":"Self-Training Categorizer"},"content":{"rendered":"<p>I&#8217;m beginning a new project this month, to run through December.  I&#8217;m going to learn how to train a Support Vector Machine (SVM) to categorize text, and then write a program that will automatically train the SVM using web searches generate training material.  Once I&#8217;ve got a semblance of a working system, I&#8217;ll be building a &#8216;web game&#8217; to evaluate the machine&#8217;s performance accuracy against human feedback.  I hope that an automatically trained SVM will be able to catch references to current events in news and pop culture, and use those to assist in categorizing paragraphs of text.<\/p>\n<p>I&#8217;ll be using <a href=\"http:\/\/svmlight.joachims.org\/\">SVM<sup>light<\/sup><\/a> (or a related work from Thorsten Joachims of Cornell University) as the SVM backend.  I just finished Probability, so the mathematics involved here are far beyond me; however, there is an <a href=\"http:\/\/www.kernel-machines.org\/papers\/Burges98.ps.gz\">SVM tutorial<\/a> by Chris Burges out of Microsoft Research for those interested in the theory of SVMs.<\/p>\n<p>My first challenge of this project is learning how to represent a text document as a vector.  The most common representation (and the one used in the Inductive SVM example on Joachims&#8217; page) is a Bag-of-Words or BOW.  There&#8217;s a <a href=\"http:\/\/www.esi.uem.es\/~jmgomez\/tutorials\/eacl03\/index.html\">tutorial<\/a> covering variations on the BOW model by Jos\u00e9 Mar\u00eda G\u00f3mez Hidalgo of the Universidad Europea de Madrid.  Basically, you build a dictionary for the categorization domain and then assign a value to each word based on whether it is in the document or not: Zero if the word does not appear, and either a one or a weighted value if it does.  I think I will begin with a simple binary document representation while I work out the program flow, and tweak the representation later to see if it improves my results.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I&#8217;m beginning a new project this month, to run through December. I&#8217;m going to learn how to train a Support Vector Machine (SVM) to categorize text, and then write a program that will automatically train the SVM using web searches generate training material. Once I&#8217;ve got a semblance of a working system, I&#8217;ll be building&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8],"tags":[61,343,41,344],"class_list":["post-925","post","type-post","status-publish","format-standard","hentry","category-programmer","tag-bag-of-words","tag-support-vector-machine","tag-svm-trainer","tag-svmlight"],"_links":{"self":[{"href":"https:\/\/www.bradleycbuchanan.com\/b\/wp-json\/wp\/v2\/posts\/925","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.bradleycbuchanan.com\/b\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.bradleycbuchanan.com\/b\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.bradleycbuchanan.com\/b\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.bradleycbuchanan.com\/b\/wp-json\/wp\/v2\/comments?post=925"}],"version-history":[{"count":1,"href":"https:\/\/www.bradleycbuchanan.com\/b\/wp-json\/wp\/v2\/posts\/925\/revisions"}],"predecessor-version":[{"id":1217,"href":"https:\/\/www.bradleycbuchanan.com\/b\/wp-json\/wp\/v2\/posts\/925\/revisions\/1217"}],"wp:attachment":[{"href":"https:\/\/www.bradleycbuchanan.com\/b\/wp-json\/wp\/v2\/media?parent=925"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.bradleycbuchanan.com\/b\/wp-json\/wp\/v2\/categories?post=925"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.bradleycbuchanan.com\/b\/wp-json\/wp\/v2\/tags?post=925"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}