forked from phoenix-oss/llama-stack-mirror
feat: tool outputs metadata (#1155)
Summary: Allows tools to output metadata. This is useful for evaluating tool outputs, e.g. RAG tool will output document IDs, which can be used to score recall. Will need to make a similar change on the client side to support ClientTool outputting metadata. Test Plan: LLAMA_STACK_CONFIG=fireworks pytest -s -v tests/client-sdk/agents/test_agents.py
This commit is contained in:
parent
36162c8c82
commit
25fddccfd8
8 changed files with 141 additions and 28 deletions
|
@ -165,6 +165,7 @@ class ToolResponse(BaseModel):
|
|||
call_id: str
|
||||
tool_name: Union[BuiltinTool, str]
|
||||
content: InterleavedContent
|
||||
metadata: Optional[Dict[str, Any]] = None
|
||||
|
||||
@field_validator("tool_name", mode="before")
|
||||
@classmethod
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue