docs(gdk): distinguish native Rust APIs from shared bindings (#13026)

This commit is contained in:
Jack Amadeo
2026-10-21 16:06:14 +00:00
committed by GitHub
parent 78f2ba90ea
commit 44039f46ea
3 changed files with 61 additions and 15 deletions
+9 -2
View File
@@ -11,7 +11,14 @@ build agentic applications, including agent orchestration, model access, context
management, tools, memory, remote execution, automations, and routing. There are
two ways to use it:
- [SDK](/docs/gdk/sdk) — use goose's provider layer as an in-process
library from Rust, Python, or Kotlin.
- [SDK](/docs/gdk/sdk) — use goose's native Rust crates or the shared
provider bindings for Python and Kotlin as in-process libraries.
- [ACP](/docs/gdk/acp) — connect to goose as a separate agent process over
stdio, HTTP, or WebSocket.
For Rust, start with the crate documentation on docs.rs:
[`goose-agent`](https://docs.rs/goose-agent/latest/goose_agent/),
[`goose-providers`](https://docs.rs/goose-providers/latest/goose_providers/), and
[`goose-context-management`](https://docs.rs/goose-context-management/latest/goose_context_management/).
See the [Rust API reference](/docs/gdk/sdk/api-reference#rust-api-reference) for
the full list of GDK crates.
+29 -3
View File
@@ -2,15 +2,41 @@
sidebar_position: 2
title: SDK Reference
sidebar_label: API Reference
description: Complete SDK reference for Rust, Python, and Kotlin.
description: Rust GDK crate documentation on docs.rs and the shared Python and Kotlin bindings reference.
---
import GdkApiReference from '@site/src/components/GdkApiReference';
# SDK Reference
The complete SDK surface. Use the toggles to switch language and SDK
version — names and types are shown using each language's own conventions.
## Rust API reference
For Rust, use the native GDK crate documentation on **docs.rs** as the primary
API reference. These crates expose the full Rust APIs, beyond the shared
`goose-sdk` bindings shown below.
| Crate | API |
| --- | --- |
| [`goose-agent`](https://docs.rs/goose-agent/latest/goose_agent/) | Agent state machine, operations, inference, and tools |
| [`goose-providers`](https://docs.rs/goose-providers/latest/goose_providers/) | Model provider implementations and declarative providers |
| [`goose-provider-types`](https://docs.rs/goose-provider-types/latest/goose_provider_types/) | Provider traits, messages, model configuration, and shared types |
| [`goose-context-management`](https://docs.rs/goose-context-management/latest/goose_context_management/) | Conversation compaction and summarization |
| [`goose-local-inference`](https://docs.rs/goose-local-inference/latest/goose_local_inference/) | On-device model inference and model management |
| [`goose-download-manager`](https://docs.rs/goose-download-manager/latest/goose_download_manager/) | Model downloads and download progress |
| [`goose-sdk-types`](https://docs.rs/goose-sdk-types/latest/goose_sdk_types/) | Shared goose ACP wire types |
| [`goose-sdk`](https://docs.rs/goose-sdk/latest/goose_sdk/) | Shared wire type re-exports and optional UniFFI bindings |
The links open the latest published crate documentation. Use the docs.rs version
selector to match the version in your project.
## Shared bindings reference
The generated reference below covers the `goose-sdk` UniFFI API used by Python
and Kotlin, with Rust signatures also available for that bindings layer. It is
not the full native Rust GDK API.
Use the toggles to switch language and bindings version — names and types are
shown using each language's own conventions.
New to the SDK? Start with the [SDK overview](/docs/gdk/sdk) for
installation and runnable examples.
+23 -10
View File
@@ -2,25 +2,34 @@
sidebar_position: 1
title: SDK
sidebar_label: Overview
description: Build with goose providers in Rust, Python, and Kotlin.
description: Build with the native Rust GDK crates or shared provider bindings for Python and Kotlin.
---
# SDK
The SDK exposes its provider layer as an in-process library so you can
call models, stream completions, and compact conversations from your own
application.
The SDK provides native Rust crates for agent orchestration, model providers,
and context management. Python and Kotlin access the provider layer through
shared bindings, so you can call models, stream completions, and compact
conversations from your own application.
One Rust crate, `goose-sdk`, is the source of every language binding. Python and
Kotlin are generated from it with [UniFFI](https://github.com/mozilla/uniffi-rs),
so all three languages share the same types, behavior, and version number.
For Rust, the primary API reference is the crate documentation on docs.rs:
See the [API Reference](/docs/gdk/sdk/api-reference) for the complete
surface in your language of choice.
- [`goose-agent`](https://docs.rs/goose-agent/latest/goose_agent/) — agent state machine and tools
- [`goose-providers`](https://docs.rs/goose-providers/latest/goose_providers/) — model providers
- [`goose-context-management`](https://docs.rs/goose-context-management/latest/goose_context_management/) — conversation compaction
- [All GDK crates](/docs/gdk/sdk/api-reference#rust-api-reference)
The `goose-sdk` crate is the source of the Python and Kotlin bindings, generated
with [UniFFI](https://github.com/mozilla/uniffi-rs). The
[shared bindings reference](/docs/gdk/sdk/api-reference#shared-bindings-reference)
documents that API in Python, Kotlin, and Rust; it does not cover the full native
Rust GDK API. The installation and examples below focus on this shared bindings
layer.
:::info Alpha
The SDK is in alpha. The surface may change between `0.x` releases. Pin an
exact version and check the API reference version selector when upgrading.
exact version and select the matching version on docs.rs or in the shared
bindings reference when upgrading.
:::
## What you can do
@@ -39,6 +48,10 @@ exact version and check the API reference version selector when upgrading.
### Rust
For native Rust, depend directly on the
[GDK crates](/docs/gdk/sdk/api-reference#rust-api-reference) your application needs
and follow their docs.rs documentation. To use the shared bindings API from Rust:
```bash
cargo add goose-sdk --features uniffi
```