Class CanaryFilter
java.lang.Object
io.agentscope.harness.agent.skill.curator.AbstractAgentCreatedFilter
io.agentscope.harness.agent.skill.curator.CanaryFilter
- All Implemented Interfaces:
SkillVisibilityFilter
Percentage-based rollout for agent-authored skills. Hashes
userId × skillName, and
admits the skill iff hash mod 100 < percent.
Only applies to agent-authored skills (via AbstractAgentCreatedFilter). Hand-
authored / hub-installed skills always pass through.
The rampUpDays parameter is currently a placeholder — accepted on construction
but the current implementation does not yet ramp; it always uses the configured static
percentage. A future version will interpolate using SkillUsageRecord.promotedAt.
-
Field Summary
Fields inherited from class io.agentscope.harness.agent.skill.curator.AbstractAgentCreatedFilter
usageStore -
Constructor Summary
ConstructorsConstructorDescriptionCanaryFilter(int percent, int rampUpDays, SkillUsageStore usageStore) CanaryFilter(int percent, SkillUsageStore usageStore) -
Method Summary
Modifier and TypeMethodDescriptionintprotected booleanshouldPassForAgentCreated(io.agentscope.core.skill.AgentSkill skill, SkillUsageRecord rec, io.agentscope.core.agent.RuntimeContext ctx) Returntrueto keep an agent-authored skill visible for this context,falseto filter it out.Methods inherited from class io.agentscope.harness.agent.skill.curator.AbstractAgentCreatedFilter
filter
-
Constructor Details
-
CanaryFilter
-
CanaryFilter
-
-
Method Details
-
shouldPassForAgentCreated
protected boolean shouldPassForAgentCreated(io.agentscope.core.skill.AgentSkill skill, SkillUsageRecord rec, io.agentscope.core.agent.RuntimeContext ctx) Description copied from class:AbstractAgentCreatedFilterReturntrueto keep an agent-authored skill visible for this context,falseto filter it out.recis guaranteed non-null withcreatedBy == "agent".- Specified by:
shouldPassForAgentCreatedin classAbstractAgentCreatedFilter
-
getRampUpDays
public int getRampUpDays()
-