Package org.iam.intent
Class MergeIntent
java.lang.Object
org.iam.intent.MergeIntent
MergeIntent is used to merge and manipulate sets of domain values for intent mining.
Supports merging compatible intents, checking mergeability, and converting to MCPIntent.
- Since:
- 2025-02-28
- Author:
-
Constructor Summary
ConstructorsConstructorDescriptionMergeIntent(MCPIntent finding) Constructs a MergeIntent from an MCPIntent.MergeIntent(MergeIntent intent) Copy constructor. -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns the domain values for this intent.Converts this MergeIntent to an MCPIntent.getFinding(String domain) Converts this MergeIntent to an MCPIntent for a specific domain.inthashCode()isMerged(MergeIntent intent) Checks if this intent can be merged with another (differs in exactly one domain).merge(MergeIntent intent) Merges this intent with another, combining values in the differing domain.voidsetDomainValues(String domain, Set<String> values) Sets the values for a specific domain.toString()
-
Constructor Details
-
MergeIntent
Copy constructor.- Parameters:
intent- the MergeIntent to copy
-
MergeIntent
Constructs a MergeIntent from an MCPIntent.- Parameters:
finding- the MCPIntent to convert
-
-
Method Details
-
getDomainValues
Returns the domain values for this intent.- Returns:
- the domain values map
-
setDomainValues
Sets the values for a specific domain.- Parameters:
domain- the domain namevalues- the set of values to set
-
isMerged
Checks if this intent can be merged with another (differs in exactly one domain).- Parameters:
intent- the other MergeIntent- Returns:
- true if mergeable, false otherwise
-
merge
Merges this intent with another, combining values in the differing domain.- Parameters:
intent- the other MergeIntent- Returns:
- the merged MergeIntent
-
getFinding
Converts this MergeIntent to an MCPIntent.- Returns:
- the corresponding MCPIntent
-
getFinding
Converts this MergeIntent to an MCPIntent for a specific domain.- Parameters:
domain- the domain name- Returns:
- the corresponding MCPIntent
-
hashCode
public int hashCode() -
equals
-
toString
-