target
BaseTarget
Bases: ABC
The BaseTarget
abstract base class defines the common interface for target
classes.
Source code in src/agenteval/targets/base_target.py
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 |
|
invoke(prompt)
abstractmethod
Invoke the target with a prompt and return a response as a string.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
prompt |
str
|
The prompt string to pass to the target. |
required |
Returns:
Type | Description |
---|---|
TargetResponse
|
A TargetResponse object containing the target's response string and |
TargetResponse
|
any trace data (if applicable). |
Source code in src/agenteval/targets/base_target.py
16 17 18 19 20 21 22 23 24 25 26 27 |
|