# sashabaranov/go-openai

OpenAI, GPT 5.6, GPT-Image-2, Whisper API clients for Go

Repository: https://github.com/sashabaranov/go-openai
Canonical: https://ross.abutalabs.com/products/go-openai
Language: Go
License: Apache-2.0
License Family: permissive
Topics: go, openai, golang, streaming-api, dall-e, chatgpt, chatgpt-api, openai-whisper, gpt-5-6, gpt-5-6-sol
Last push: 2026-08-19T20:04:20+00:00

## Health v2 (maintenance only)
Score: 98/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 98, release rhythm 96, longevity 100
- inputs: {"age_days": 2206, "days_push": 14, "days_rel": 31, "gap_med": 9.0, "n_releases_24m": 33}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 10748, forks 1711 (observed 2026-08-28T04:10:44.054156+00:00)

## What it is
An unofficial Go client library for the OpenAI API covering chat completions, the Responses API, embeddings, image generation, audio transcription (Whisper), moderation, files, fine-tuning, and more. It provides typed request/response structs, streaming support, and multi-turn conversation helpers for Go applications.

## Use cases
- call the OpenAI API from Go
- build a chatbot in Golang
- stream GPT responses in a Go server
- transcribe audio with Whisper from Go
- generate images with DALL-E in Go
- get embeddings for semantic search in Go
- fine-tune OpenAI models via Go

## When to choose
- you write Go and need typed, idiomatic access to OpenAI endpoints
- you need streaming, tool-calling, or multi-turn conversation support
- you want a mature community client with broad API surface coverage

## When to avoid
- you use another language like Python or TypeScript with official SDKs
- you need a provider-agnostic abstraction across multiple LLM vendors
- you require official support guarantees from OpenAI

## Facets
- artifact type: library
- maturity: active
- function: sdk, http-client, llm-inference, speech-recognition, image-processing
- domain: large-language-models, artificial-intelligence, developer-tools, apis
- platform: go, cross-platform
- tags: openai-api, chatgpt, gpt, whisper, dall-e, embeddings, streaming, unofficial-client

## Member repositories
- sashabaranov/go-openai (main) score 98

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:10:44.054156+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T17:17:54.953150+00:00, confidence not recorded.
  - readme: https://github.com/sashabaranov/go-openai (fetched 2026-08-28T04:10:44.054156+00:00, sha 054f78842e97)
- Data as of 2026-08-30T08:39:29.467469+00:00.
