An open API service indexing awesome lists of open source software.

https://github.com/fumiama/deepinfra

Lightweight OpenAI/OLLaMA/GenAI compatible caller, originally designed for DeepInfra.
https://github.com/fumiama/deepinfra

gemini-api genai genai-api golang golang-cli golang-library golang-package golang-tools google-generative-ai ollama ollama-api ollama-client openai openai-api openaiapi

Last synced: 4 days ago
JSON representation

Lightweight OpenAI/OLLaMA/GenAI compatible caller, originally designed for DeepInfra.

Awesome Lists containing this project

README

          

# deepinfra
Lightweight OpenAI/OLLaMA/GenAI compatible caller, originally designed for DeepInfra.

## Quick Start
```go
api := NewAPI(OpenAIDeepInfra, "PUT YOUR API KEY HERE")
txt, err := api.Request(model.NewOpenAI(model.ModelDeepDeek, model.SeparatorThink, 0.7, 0.9, 1024).
System("Be a good assistant.").User("Hello"),
)
if err != nil {
panic(err)
}
fmt.Println(txt)
// Hello! How can I assist you today?
```