Class DefaultLoopAgentInstance
java.lang.Object
dev.langchain4j.agentic.workflow.impl.DefaultLoopAgentInstance
- All Implemented Interfaces:
AgentInstance, LoopAgentInstance
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface AgentInstance
activationCondition, agentId, arguments, as, async, description, leaf, name, optional, outputKey, outputType, parent, plannerType, subagents, topology, type
-
Constructor Details
-
DefaultLoopAgentInstance
-
-
Method Details
-
maxIterations
public int maxIterations()- Specified by:
maxIterationsin interfaceLoopAgentInstance
-
testExitAtLoopEnd
public boolean testExitAtLoopEnd()- Specified by:
testExitAtLoopEndin interfaceLoopAgentInstance
-
exitCondition
- Specified by:
exitConditionin interfaceLoopAgentInstance
-
type
- Specified by:
typein interfaceAgentInstance
-
plannerType
- Specified by:
plannerTypein interfaceAgentInstance
-
name
- Specified by:
namein interfaceAgentInstance
-
agentId
- Specified by:
agentIdin interfaceAgentInstance
-
description
- Specified by:
descriptionin interfaceAgentInstance
-
outputType
- Specified by:
outputTypein interfaceAgentInstance
-
outputKey
- Specified by:
outputKeyin interfaceAgentInstance
-
async
public boolean async()- Specified by:
asyncin interfaceAgentInstance
-
optional
public boolean optional()- Specified by:
optionalin interfaceAgentInstance
-
activationCondition
Description copied from interface:AgentInstanceThe condition under which this agent runs when it is invoked as a subagent, ornullwhen it always runs. When the condition is false, the agent is skipped: it is not invoked, it writes nothing to theAgenticScopeand its parent's planner is notified of the skip. The condition is ignored when the agent is invoked directly, as the root of an agentic system.The condition can be evaluated more than once for a single invocation, by the planner of the parent while selecting its next agents and again when the agent is invoked, so it must be cheap and free of side effects.
- Specified by:
activationConditionin interfaceAgentInstance
-
arguments
- Specified by:
argumentsin interfaceAgentInstance
-
parent
- Specified by:
parentin interfaceAgentInstance
-
subagents
- Specified by:
subagentsin interfaceAgentInstance
-
leaf
public boolean leaf()- Specified by:
leafin interfaceAgentInstance
-
topology
- Specified by:
topologyin interfaceAgentInstance
-
as
- Specified by:
asin interfaceAgentInstance
-