Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 15 additions & 1 deletion docs/docs/how-to/configure-llm-providers.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,20 @@ llm, err := openai.New(
)
```

### OpenAI-compatible gateways

You can also point the OpenAI client at a governed OpenAI-compatible endpoint such as [Tuning Engines](https://www.tuningengines.com/). LangChainGo keeps the application logic while the gateway centralizes model routing, policy controls, audit logs, traces, approvals, and cost visibility.

```go
import "os"

llm, err := openai.New(
openai.WithToken(os.Getenv("TUNING_ENGINES_API_KEY")),
openai.WithModel("gpt-4o-mini"),
openai.WithBaseURL("https://api.tuningengines.com/v1"),
)
```

### Azure OpenAI

```go
Expand Down Expand Up @@ -279,4 +293,4 @@ if err != nil {
| Google AI | Free tier, fast | Experimentation, mobile apps |
| Vertex AI | Enterprise features | Production, compliance |
| Ollama | Privacy, offline | Local development, sensitive data |
| Hugging Face | Open models, variety | Research, experimentation |
| Hugging Face | Open models, variety | Research, experimentation |
Loading