boolRule brScore

Standard Ticket Classification

Scénario de test & Cas d'usage

Business Context

A telecom company receives thousands of support tickets daily. They want to automatically tag tickets related to 'Billing Disputes' and 'Technical Outages' to route them to the correct department efficiently. The rules have already been extracted from a training set.
About the Set : boolRule

Extraction of Boolean rules for classification.

Discover all actions of boolRule
Data Preparation

Creation of a document-term matrix representing support tickets and a rule definition table.

Copied!
1 
2DATA casuser.ticket_terms;
3INPUT ticket_id term_id;
4DATALINES;
5101 1 101 2 102 3 103 1 103 4 ;
6 
7RUN;
8 
9DATA casuser.defined_rules;
10INPUT ruleid termid;
11DATALINES;
121 1 1 2 2 3 ;
13 
14RUN;
15 

Étapes de réalisation

1
Execution of the brScore action to classify the tickets against the defined rules.
Copied!
1 
2PROC CAS;
3boolRule.brScore TABLE={name='ticket_terms', caslib='casuser'} ruleTerms={name='defined_rules', caslib='casuser'} docId='ticket_id' termId='term_id' casOut={name='scored_tickets', caslib='casuser', replace=true};
4 
5QUIT;
6 

Expected Result


The 'scored_tickets' table is created. Ticket 101 should match Rule 1 (terms 1 and 2 present). Ticket 102 should match Rule 2 (term 3 present). Ticket 103 has term 1 but missing term 2, so it should not match Rule 1.