Categorygithub.com/cheahjs/gemini-to-openai-proxy
modulepackage
0.0.0-20241218174519-caa0f0987f4c
Repository: https://github.com/cheahjs/gemini-to-openai-proxy.git
Documentation: pkg.go.dev

# README

gemini-to-openai-proxy

[!IMPORTANT]

This has now been superceded by Gemini's built in OpenAI compatibility: https://ai.google.dev/gemini-api/docs/openai#embeddings

Call Gemini (https://ai.google.dev) embedding models with OpenAI-compatible endpoints

Deployment

Using docker run

To deploy using docker run, you can use the following command:

docker run -d -p 8080:8080 -e GEMINI_API_KEY=<your-gemini-api-key> ghcr.io/cheahjs/gemini-to-openai-proxy:latest

Replace <your-gemini-api-key> with your actual Gemini API key.

Using docker compose

To deploy using docker compose, you can use the provided docker-compose.yaml file. First, create a .env file with the following content:

GEMINI_API_KEY=<your-gemini-api-key>
LISTEN_ADDR=:8080

Then, run the following command:

docker-compose up -d

Using go install

To deploy using go install, you need to have Go installed on your machine. Run the following commands:

go install github.com/cheahjs/gemini-to-openai-proxy@latest
GEMINI_API_KEY=<your-gemini-api-key> LISTEN_ADDR=:8080 gemini-to-openai-proxy

Replace <your-gemini-api-key> with your actual Gemini API key.

# Packages

No description provided by the author

# Variables

No description provided by the author
No description provided by the author
No description provided by the author