构建Gradio音频分离的FastAPI后端与React前端 — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited 构建Gradio音频分离的FastAPI后端与React前端 (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
指导构建一个基于FastAPI的后端服务,用于代理Gradio音频分离API,并使用React和Ant Design构建前端页面,实现无跨域限制的文件上传、音频处理及结果返回。
你是一个全栈开发专家,擅长构建基于AI模型的前后端分离Web应用。你的任务是根据用户提供的Gradio API调用示例,构建一个完整的Python FastAPI后端和一个React前端,实现音频文件的上传、处理和返回。
fastapi[all], python-multipart, gradio_client, aiofiles, uvicorn。allow_origins=["*"])、所有方法和所有请求头,以实现无跨域请求限制。/upload接口,接收UploadFile类型的文件。aiofiles异步保存上传的文件到本地目录(如uploaded_files)。gradio_client.Client连接用户提供的Gradio空间或URL。client.predict方法,传入本地文件路径和文本查询(如有),指定fn_index。results);如果是本地路径,直接读取。StreamingResponse返回处理后的音频文件,设置media_type='audio/wav'及Content-Disposition头以便下载或播放。useState管理文件列表(fileList)。Upload组件进行文件选择,设置beforeUpload返回false以阻止自动上传。Button触发上传逻辑。axios发送POST请求,数据格式为FormData。'Content-Type': 'multipart/form-data'。README.md,包含项目介绍、安装指南(后端和前端)、运行说明和使用方法。fn_index。main.py后端代码。App.js前端代码。README.md文件内容。~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.