API stability channels
Genkit follows semantic versioning guidelines for version updates. Everything in github.com/firebase/genkit/go except the packages listed below is stable, and takes breaking changes only in a major release.
Versioning
Section titled “Versioning”Genkit Go is in the v1 series. The module path stays github.com/firebase/genkit/go for the whole series; a v2 would take a /v2 suffix, so a major bump can never break your build silently. The module requires Go 1.25 or later.
Running go get github.com/firebase/genkit/go records the dependency version in your go.mod. You can update to newer releases using go get -u. See the release notes for what changed between versions.
Preview APIs
Section titled “Preview APIs”A few features ship ahead of that guarantee so you can build on them and send feedback while their shape is still settling. Preview is the name for this channel throughout the docs, and a page that carries a :::caution[Preview] admonition is in it. In code, the channel shows up two ways: the package suffix exp (or x), and the genkit.WithExperimental() opt-in. Each preview API may experience breaking changes in minor releases while its shape is stabilizing.
Every preview package declares itself exp, so these docs import each one under an alias that keeps them apart:
| Alias | Package |
|---|---|
aix | github.com/firebase/genkit/go/ai/exp |
genkitx | github.com/firebase/genkit/go/genkit/exp |
middlewarex | github.com/firebase/genkit/go/plugins/middleware/exp |
a2uix | github.com/firebase/genkit/go/plugins/a2ui/exp |
firebasex | github.com/firebase/genkit/go/plugins/firebase/exp |
pgexp | github.com/firebase/genkit/go/plugins/postgresql/exp |
systemonex | github.com/firebase/genkit/go/plugins/systemone/exp |
The preview APIs, by feature:
- Agents (
github.com/firebase/genkit/go/ai/exp,.../ai/exp/localstore,.../ai/exp/sessionstoretest,.../genkit/exp): the agent constructors, remote agents, session stores and the conformance suite a custom store runs, and HTTP route builders. - Agent session stores in databases (
github.com/firebase/genkit/go/plugins/firebase/exp,.../plugins/postgresql/exp): the Firestore and PostgreSQL session stores. - Middleware (
github.com/firebase/genkit/go/plugins/middleware/exp): the multi-agent, background-delegation, and artifact middleware, plusBudget, which caps the usage of a run or a session, andContextCompression, which keeps a long conversation inside a context budget. See Middleware. - A2UI (
github.com/firebase/genkit/go/plugins/a2ui/exp): the generative UI middleware that streams A2UI surfaces from a model to a browser. - Durable streaming (
github.com/firebase/genkit/go/core/x/streaming,.../plugins/firebase/exp): theStreamManagerAPI that lets a client reconnect to a stream by ID. - System One (
github.com/firebase/genkit/go/plugins/systemone/exp): decision models that answer typed questions with calibrated probabilities.
Everything else is stable, including the tool runtime verbs in github.com/firebase/genkit/go/ai/tool (tool.Interrupt, tool.Fail, tool.AttachParts, and the rest) and the OpenTelemetry GenAI instrumentation in github.com/firebase/genkit/go/plugins/otelgenai.
The genkit/exp constructors require opting in. Pass genkit.WithExperimental() to genkit.Init, or they panic with a message pointing back to that option.
Samples whose directory name ends in -exp, such as basic-durable-streaming-exp, are written against these APIs.