# hyperonym/basaran

Basaran is an open-source alternative to the OpenAI text completion API. It provides a compatible streaming API for your Hugging Face Transformers-based text generation models.

Repository: https://github.com/hyperonym/basaran
Canonical: https://ross.abutalabs.com/products/basaran
Language: Python
License: MIT
License Family: permissive
Topics: gpt, huggingface, language-model, natural-language-processing, openai-api, text-generation, llm, python, transformers, llama, generative, model, nlp
Archived: true
Last push: 2024-01-24T05:50:55+00:00

## Health v2 (maintenance only)
Score: 10/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 0, release rhythm 8, longevity 92
- inputs: {"age_days": 1293, "days_push": 952, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: archived
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1282, forks 77 (observed 2026-08-28T04:04:14.059581+00:00)

## What it is
Basaran is an open-source alternative to the OpenAI text completion API that serves Hugging Face Transformers-based text generation models behind a compatible streaming API. It ships as a Docker image with multi-GPU support, quantization, server-sent events, and a web-based playground.

## Use cases
- self-host an OpenAI-compatible API for local LLMs
- serve hugging face transformer models with streaming completions
- replace OpenAI API with open-source model without changing client code
- deploy llama models behind a REST completion endpoint
- run text generation inference with multi-GPU and quantization
- expose server-sent events streaming for LLM generation

## When to choose
- you already use OpenAI client libraries and want to swap in an open-source model
- you need a drop-in streaming completions API for Hugging Face models
- you want a simple Docker-based LLM serving solution with GPU support

## When to avoid
- you need OpenAI chat endpoints or embeddings rather than text completions
- you need high-throughput production serving with continuous batching like vLLM
- you don't use Python or Hugging Face Transformers models

## Facets
- artifact type: service
- maturity: active
- function: llm-inference, http-server, api-framework, streaming
- domain: large-language-models, apis, self-hosted
- platform: python, self-hosted
- tags: openai-api-compatible, huggingface-transformers, text-generation, server-sent-events, llm-serving, natural-language-processing, docker, gpu, linux

## Member repositories
- hyperonym/basaran (main) score 10

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:04:14.059581+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-30T04:57:42.483960+00:00, confidence not recorded.
  - readme: https://github.com/hyperonym/basaran (fetched 2026-08-28T04:04:14.059581+00:00, sha 184036d3db50)
- Data as of 2026-08-30T08:39:29.467469+00:00.
