AS AgentScopeAPI 手册 / API Reference

RewardCalculator

public interface RewardCalculator
源码Source io/agentscope/core/training/reward/RewardCalculator.java:26–35

定义 Reward Calculator契约的接口。位于 io.agentscope.core.training.reward 包。核心成员包括 calculate。

Reward Calculator Interface

Calculate reward value based on shadow Agent's execution results

方法摘要Method Summary

方法Method说明Description
public double calculate(Agent agent)
设置该参数。
Calculate reward value based on execution results

方法详情Method Detail

calculate

public double calculate(Agent agent)

设置该参数。

Calculate reward value based on execution results

参数Parameters
名称Name类型Type说明Description
agentAgent智能体(类型 `Agent`)。Shadow Agent
返回Returns double
返回数值结果。Reward value (typically between -1 and 1)
源码Source io/agentscope/core/training/reward/RewardCalculator.java:34
基于官方固定版本源码静态生成Generated from pinned official sources · Python 2.0.11 · Java 2.0.4
签名与文档为静态抽取;如有疑问请以源码为准。Signatures and docs are extracted statically; verify against the source when in doubt.