Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions cmd/lk/simulate.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,10 @@
Name: "scenarios",
Usage: "Path to a scenarios `FILE` (yaml). If omitted, scenarios are generated from the agent's source",
},
&cli.BoolFlag{
Name: "audio",
Usage: "Simulate over audio (TTS + the agent's full media pipeline) instead of text",

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Usage: "Simulate over audio (TTS + the agent's full media pipeline) instead of text",
Usage: "Simulate speech-to-speech interactions using the agent's full audio pipeline. By default, simulations run in text-only mode.",

},
&cli.BoolFlag{
Name: "yes",
Aliases: []string{"y"},
Expand Down Expand Up @@ -157,6 +161,7 @@
numSimulations int32
concurrency int32
mode simulateMode
simulationMode livekit.SimulationMode
agentName string
projectDir string
projectType agentfs.ProjectType
Expand Down Expand Up @@ -259,13 +264,19 @@

simClient := lksdk.NewAgentSimulationClient(serverURL, pc.APIKey, pc.APISecret)

simulationMode := livekit.SimulationMode_SIMULATION_MODE_TEXT
if cmd.Bool("audio") {
simulationMode = livekit.SimulationMode_SIMULATION_MODE_AUDIO
}

simCfg := &simulateConfig{
ctx: ctx,
client: simClient,
pc: pc,
numSimulations: numSimulations,
concurrency: concurrency,
mode: mode,
simulationMode: simulationMode,
agentName: agentName,
projectDir: projectDir,
projectType: projectType,
Expand Down Expand Up @@ -400,6 +411,7 @@
req := &livekit.SimulationRun_Create_Request{
AgentName: c.agentName,
NumSimulations: c.numSimulations,
Mode: c.simulationMode,

Check failure on line 414 in cmd/lk/simulate.go

View workflow job for this annotation

GitHub Actions / test (ubuntu-latest)

unknown field Mode in struct literal of type livekit.SimulationRun_Create_Request (typecheck)

Check failure on line 414 in cmd/lk/simulate.go

View workflow job for this annotation

GitHub Actions / Build darwin (native)

unknown field Mode in struct literal of type livekit.SimulationRun_Create_Request
}
if c.concurrency > 0 {
req.Concurrency = &c.concurrency
Expand Down
Loading