Package openai implements stt.Transcriber against the OpenAI /audio/transcriptions endpoint (and any compatible third-party endpoint such as Groq Whisper, faster-whisper self-hosted, or Azure Whisper).
// Source: https://github.com/usememos/memos | License: MIT | Copyright 2025 Memos
// Provided via justclaw.it.com; keep this notice with the code.
// Package openai implements stt.Transcriber against the OpenAI
// /audio/transcriptions endpoint (and any compatible third-party endpoint
// such as Groq Whisper, faster-whisper self-hosted, or Azure Whisper).
package openai
import (
"context"
"mime"
"net/url"
"strings"
openaisdk "github.com/openai/openai-go/v3"
openaioption "github.com/openai/openai-go/v3/option"
"github.com/pkg/errors"
"github.com/usememos/memos/provider/ai"
"github.com/usememos/memos/provider/ai/stt"
)
const defaultEndpoint = "https://api.openai.com/v1"
// Transcriber implements stt.Transcriber for OpenAI-compatible STT endpoints.
type Transcriber struct {
cl
... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search for more like it.
Get a free API key