视频保存
This commit is contained in:
@@ -154,7 +154,7 @@ func (c *OpenAICompatibleClient) Transcribe(ctx context.Context, cfg *dao.STTCon
|
||||
// downloadAudio 从给定 URL 拉取音频内容,返回字节流 + 推断的文件名
|
||||
//
|
||||
// 文件名仅作为 multipart 的 filename 参数,主要决定 Content-Type 推断;
|
||||
// 取 URL path 末段,无后缀则默认 recording.mp4。
|
||||
// 取 URL path 末段,无后缀则默认 recording.webm(与 media-server 实际产物一致)。
|
||||
func (c *OpenAICompatibleClient) downloadAudio(ctx context.Context, fileURL string) ([]byte, string, error) {
|
||||
req, err := http.NewRequestWithContext(ctx, http.MethodGet, fileURL, nil)
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user