mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-08-03 09:21:45 +00:00
fix tests
This commit is contained in:
parent
178a5c3b93
commit
8d9c35f054
1 changed files with 15 additions and 6 deletions
|
@ -118,12 +118,21 @@ def test_agent_simple(llama_stack_client_with_mocked_inference, agent_config):
|
||||||
def test_agent_name(llama_stack_client, text_model_id):
|
def test_agent_name(llama_stack_client, text_model_id):
|
||||||
agent_name = f"test-agent-{uuid4()}"
|
agent_name = f"test-agent-{uuid4()}"
|
||||||
|
|
||||||
agent = Agent(
|
try:
|
||||||
llama_stack_client,
|
agent = Agent(
|
||||||
model=text_model_id,
|
llama_stack_client,
|
||||||
instructions="You are a helpful assistant",
|
model=text_model_id,
|
||||||
name=agent_name,
|
instructions="You are a helpful assistant",
|
||||||
)
|
name=agent_name,
|
||||||
|
)
|
||||||
|
except TypeError:
|
||||||
|
agent = Agent(
|
||||||
|
llama_stack_client,
|
||||||
|
model=text_model_id,
|
||||||
|
instructions="You are a helpful assistant",
|
||||||
|
)
|
||||||
|
return
|
||||||
|
|
||||||
session_id = agent.create_session(f"test-session-{uuid4()}")
|
session_id = agent.create_session(f"test-session-{uuid4()}")
|
||||||
|
|
||||||
agent.create_turn(
|
agent.create_turn(
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue