This repository contains code samples for the Genkit Go framework. All samples use the GA version of Genkit Go. The samples work with free tiers of Gemini, Mistral, etc. For Azure OpenAI, you can get a subscription for free here.
Some of the samples require the use of the Genkit CLI.
Genkit supports macOS, Windows, and Linux. These samples have been built and tested on macOS 26 Tahoe.
aoai-azsql: This sample shows how to use the Azure OpenAI sample plugin for embedding creation and vector search using Azure SQL's native vector type and functions.
aoai-pgvector: This sample shows how to use the Azure OpenAI sample plugin for embedding creation and vector search using PostgreSQL and the pgvector extension.
azure: This sample demonstrates building a custom Azure OpenAI plugin based on Genkit Go's OpenAI plugin.
code-agent: A basic CLI coding agent using Genkit Go flows and tools.
dotprompt: This sample demonstrates externalizing prompt templates using Genkit Go's Dotprompt support.
mcp-server: This sample demonstrates building a simple MPC server with Genkit Go and integrating it with Claude Desktop.
mistral: This sample demonstrates using the genkit-mistral plugin.
rag: A RAG (retrieval augmented generation) sample that demonstrates using Genkit Go's Dev Local Vector Store based on Genkit Go's RAG documentation.
rag-server: This sample is an updated version of the demo application published by the Go team for Genkit Go's alpha version.
tools: This sample demonstrates Genkit Go's tool calling capabilities based on a fictitious home automation scenario.
summarize-video: A Go version of the JavaScript tutorial published by the Genkit team.
I've also published a Go SDK for Microsoft's Foundry Local. An example for using Genkit Go with Foundry Local is in that repo's example folder.