From c2c7bcf650199492da4ca4e3da64cb4502dd7462 Mon Sep 17 00:00:00 2001 From: James Ketrenos Date: Sat, 30 Aug 2025 12:23:59 -0700 Subject: [PATCH] Initial AI agent scaffolding --- .dockerignore | 4 + Dockerfile.server | 2 +- clean-venvs | 9 + client/src/MediaControl.tsx | 98 +++++- docker-compose.yml | 25 +- server/.python-version | 2 +- server/entrypoint.sh | 6 +- server/pyproject.toml | 7 +- server/requirements.txt | 3 + server/uv.lock | 213 +------------ voicebot/README.md | 0 voicebot/entrypoint.sh | 22 ++ voicebot/main.py | 616 ++++++++++++++++++++++++++++++++++++ voicebot/requirements.txt | 12 + 14 files changed, 789 insertions(+), 230 deletions(-) create mode 100755 clean-venvs create mode 100644 voicebot/README.md create mode 100644 voicebot/entrypoint.sh create mode 100644 voicebot/main.py create mode 100644 voicebot/requirements.txt diff --git a/.dockerignore b/.dockerignore index 1308843..95b324c 100644 --- a/.dockerignore +++ b/.dockerignore @@ -1,3 +1,7 @@ +* +!voicebot +!server +!client node_modules build dist diff --git a/Dockerfile.server b/Dockerfile.server index ae0838c..b385aef 100644 --- a/Dockerfile.server +++ b/Dockerfile.server @@ -1,4 +1,4 @@ -FROM ubuntu:oracular +FROM ubuntu:plucky # Install some utilities frequently used RUN apt-get update \ diff --git a/clean-venvs b/clean-venvs new file mode 100755 index 0000000..2b1a3ac --- /dev/null +++ b/clean-venvs @@ -0,0 +1,9 @@ +#!/bin/bash +find . -name .venv | while read path; do + echo "Removing ${path}" + sudo rm -rf "${path}" +done +find . -name .python-version | while read path; do + echo "Removing ${path}" + sudo rm "${path}" +done diff --git a/client/src/MediaControl.tsx b/client/src/MediaControl.tsx index 104812c..11d5ad4 100644 --- a/client/src/MediaControl.tsx +++ b/client/src/MediaControl.tsx @@ -164,6 +164,8 @@ interface VideoProps extends React.VideoHTMLAttributes { const Video: React.FC = ({ srcObject, local, ...props }) => { const refVideo = useRef(null); + const clickHandlerRef = useRef<(() => void) | null>(null); + const hasUserInteractedRef = useRef(false); useEffect(() => { if (!refVideo.current || !srcObject) return; @@ -171,6 +173,15 @@ const Video: React.FC = ({ srcObject, local, ...props }) => { const ref = refVideo.current; console.log("media-agent -