feat: Simulation upgrades - #120
Conversation
|
| Filename | Overview |
|---|---|
| app/api/v1/routes/personas.py | Adds ambient library and persona-audio APIs, but both upload paths read oversized files fully before enforcing the configured limit. |
| app/services/audio/ambient_catalog.py | Adds platform and custom ambient resolution with validated API write paths; no reachable tenant or traversal failure was established. |
| app/services/audio/ambient_mixer.py | Adds decoding, resampling, looping, and volume-controlled ambient mixing used by simulation runtimes. |
| app/services/evaluators/evaluator_suite_service.py | Expands suite materialization and rotation around persona/scenario combinations. |
| app/services/testing/test_agent_template.py | Introduces normalized structured test-agent templates and deterministic prompt assembly. |
| app/services/webrtc_bridge/production_turn_gate.py | Adds production-agent turn buffering and gating behavior with focused test coverage. |
| app/services/voice_agent/audio_recorder.py | Extends recording and timing behavior for upgraded simulation and telephony audio flows. |
| app/workers/config.py | Routes evaluator cron dispatch through the usage worker topology with corresponding deployment and scheduling changes. |
| frontend/src/pages/personas/PersonaAmbientPanel.tsx | Adds persona ambient-source selection, upload, preview, and volume controls. |
| frontend/src/pages/agents/components/TestAgentTemplateEditor.tsx | Adds structured editing for test-agent prompt sections and opening-message modes. |
Reviews (1): Last reviewed commit: "feat: updating recording issues" | Re-trigger Greptile
| file_bytes = await file.read() | ||
| try: | ||
| extension = validate_ambient_upload_bytes(file_bytes, filename=filename) |
There was a problem hiding this comment.
When an authenticated Enterprise user submits an oversized ambient-audio file, await file.read() loads the complete file before the 10 MiB validation runs, causing excessive API-worker memory consumption or process termination. The same issue occurs in upload_persona_ambient_audio at lines 1255–1258.
How this was verified: Both upload handlers perform an unbounded read before checking the configured maximum, and the repository defines no earlier request-body limit.
|
Too many files changed for review (140 files, 100 file limit). Bypass the limit by tagging |
What Changed?
Briefly describe what this PR changes.
Why?
Explain the problem this solves and why this approach was chosen.
How to Test?
List clear steps for reviewers to verify the change.
Release Label
Select one semantic version bump intent for this PR:
major- breaking change, next release bumps major versionminor- backward-compatible feature, next release bumps minor versionfix- backward-compatible bug fix, next release bumps patch versionIf you do not have permission to apply labels, mention the intended release label here and a maintainer will set it.
Checklist
CONTRIBUTING.mdguide.