%iKnow.Classification.Methods.VectorSpace
Class %iKnow.Classification.Methods.VectorSpace Extends Base [ Abstract, Deprecated, System = 4 ]
This Builder Method implementation generates category term weights as a vector per category that exists in the same vector space as the document term vector. The similarity between the document vector and each of the category vectors can then be calculated using euclidean distance or cosine similarity (angle). Alternatively, these weights can be used for a linear regression formula, calculating a score rather than a similarity/distance.
A combination of global term weights (across the corpus), local term weights (within each category) and normalization (per category) is used to calculate these category vectors.
Properties
CustomTermWeights
Property CustomTermWeights [ MultiDimensional ];
CategoryLocalTermWeights
Property CategoryLocalTermWeights As %String(VALUELIST = ",binary,linear,logarithmic") [ InitialExpression = "linear" ];
The per-category term weight factor
CategoryLocalTermMetric
Property CategoryLocalTermMetric As %String(VALUELIST = ",frequency,spread") [ InitialExpression = "spread" ];
The metric to use for calculating the local term weights
CategoryGlobalTermWeights
Property CategoryGlobalTermWeights As %String(VALUELIST = ",none,IDF") [ InitialExpression = "IDF" ];
The corpus-wide relevancy factor to take into account when calculating term weights
CategoryNormalization
Property CategoryNormalization As %String(VALUELIST = ",none,cosine") [ InitialExpression = "none" ];
Whether and how to normalize the category vectors
Methods
%SetCustomWeight
Method %SetCustomWeight(pIndex As %Integer, pCategory As %String, pCustomWeight As %Double) As %Status
Sets a custom weight factor for the term at pIndex in pCategory.
%SetCustomWeights
Method %SetCustomWeights(pIndex As %Integer, ByRef pCustomWeights) As %Status
%OnRemoveTerm
Method %OnRemoveTerm(pIndex As %Integer) As %Status
Callback invoked whenever an entire term at an index has been removed
%BuildClassificationMethod
Method %BuildClassificationMethod(ByRef pClassifier As %iKnow.Classification.Definition.Classifier, pVerbose As %Boolean = 1, pIncludeBuilderParams As %Boolean = 1) As %Status
%LoadFromModel
Method %LoadFromModel(pDefinition As %iKnow.Classification.Definition.Classifier) As %Status
%LoadMethodBuilderProperties
Method %LoadMethodBuilderProperties(pMethodBuilder As Base) As %Status [ Internal ]