GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  AI::CATEGORIZER::LEARNER::BOOLEAN (3)

.ds Aq ’

NAME

AI::Categorizer::Learner::Boolean - Abstract class for boolean categorizers

CONTENTS

SYNOPSIS



 package AI::Categorizer::Learner::SomethingNew;
 use AI::Categorizer::Learner::Boolean;
 @ISA = qw(AI::Categorizer::Learner::Boolean);

 sub create_boolean_model {
   my ($self, $positives, $negatives, $category) = @_;
   ...
   return $something_helpful;
 }

 sub get_boolean_score {
   my ($self, $document, $something_helpful) = @_;
   ...
   return $score;
 }



DESCRIPTION

This is an abstract class which turns boolean categorizers (categorizers based on algorithms that can just provide yes/no categorization decisions for a single document and single category) into multi-valued categorizers. For instance, the decision tree categorizer AI::Categorizer::Learner::DecisionTree maintains a decision tree for each category, then uses it to decide whether a certain document belongs to the given category.

Any class that inherits from this class should implement the following methods:

create_boolean_model()

Used during training to create a category-specific model. The type of model you create is up to you - it should be returned as a scalar. Whatever you return will be available to you in the get_boolean_score() method, so put any information you’ll need during categorization in this scalar.

In addition to $self, this method will be passed three arguments. The first argument is a reference to an array of <B>positiveB> examples, i.e. documents that belong to the given category. The next argument is a reference to an array of <B>negativeB> examples, i.e. documents that do not belong to the given category. The final argument is the Category object for the given category.

get_boolean_score()

Used during categorization to assign a score for a single document relative to a single category. The score should be between 0 and 1, with a score greater than 0.5 indicating membership in the category.

In addition to $self, this method will be passed two arguments. The first argument is the document to be categorized. The second argument is the value returned by create_boolean_model() for this category.

AUTHOR

Ken Williams, <ken@mathforum.org>

SEE ALSO

AI::Categorizer
Search for    or go to Top of page |  Section 3 |  Main Index


perl v5.20.3 AI::CATEGORIZER::LEARNER::BOOLEAN (3) 2016-04-03

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.