Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
34 changes: 17 additions & 17 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ jobs:
just check-lean-size

rust-check-wasm:
name: Check and Test GDK Agent Crates on wasm32
name: Check and Test oi-kit Agent Crates on wasm32
runs-on: ubuntu-latest
needs: changes
if: needs.changes.outputs.code == 'true' || github.event_name != 'pull_request'
Expand All @@ -150,19 +150,19 @@ jobs:
cargo install wasm-bindgen-cli --version "$version" --locked

- name: Check wasm32 build
run: cargo check --locked --target wasm32-unknown-unknown -p goose-agent -p goose-provider-types
run: cargo check --locked --target wasm32-unknown-unknown -p oi-kit-agent -p oi-kit-provider-types
env:
CARGO_INCREMENTAL: "0"
RUSTFLAGS: "-D warnings"

- name: Run agent loop on wasm32
run: cargo test --locked --target wasm32-unknown-unknown -p goose-agent --test wasm
run: cargo test --locked --target wasm32-unknown-unknown -p oi-kit-agent --test wasm
env:
CARGO_INCREMENTAL: "0"
RUSTFLAGS: "-D warnings"

goose-sdk-uniffi:
name: Check goose-sdk UniFFI
oi-kit-bindings-uniffi:
name: Check oi-kit-bindings UniFFI
runs-on: ubuntu-latest
needs: changes
if: needs.changes.outputs.code == 'true' || github.event_name != 'pull_request'
Expand All @@ -180,14 +180,14 @@ jobs:
- name: Check UniFFI feature
run: |
export CARGO_INCREMENTAL=0
cargo check -p goose-sdk --features uniffi --locked
cargo test -p goose-sdk --features uniffi --locked
cargo check -p oi-kit-bindings --features uniffi --locked
cargo test -p oi-kit-bindings --features uniffi --locked
env:
RUST_MIN_STACK: 8388608
GOOSE_DISABLE_KEYRING: 1

kotlin-gdk-smoke-test:
name: Test Kotlin GDK package
kotlin-oi-kit-smoke-test:
name: Test Kotlin oi-kit package
needs: changes
if: needs.changes.outputs.code == 'true' || github.event_name != 'pull_request'
permissions:
Expand Down Expand Up @@ -228,7 +228,7 @@ jobs:
run: |
export CARGO_INCREMENTAL=0
cargo test -p goose --no-default-features --features ${{ matrix.tls-feature }},code-mode,tree-sitter,live-voice,scheduler,platform-apps,chat-recall,acp-http
cargo test -p goose-providers --no-default-features --features ${{ matrix.tls-feature }},live-websocket
cargo test -p oi-kit-providers --no-default-features --features ${{ matrix.tls-feature }},live-websocket
cargo test -p goose-cli --no-default-features --features ${{ matrix.tls-feature }},code-mode,tree-sitter,live-voice,scheduler,platform-apps,chat-recall,acp-http
env:
RUST_MIN_STACK: 8388608
Expand Down Expand Up @@ -375,24 +375,24 @@ jobs:
cd ui/goose-acp-client
pnpm run lint

gdk-release-config-check:
name: Check GDK Release Configuration
oi-kit-release-config-check:
name: Check oi-kit Release Configuration
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1

- name: Check GDK crate membership and publication order
run: python3 crates/goose-sdk/scripts/gdk-release.py check-config
- name: Check oi-kit crate membership and publication order
run: python3 crates/oi-kit-bindings/scripts/oi-kit-release.py check-config

gdk-api-docs-check:
name: Check GDK API Reference is Up-to-Date
oi-kit-api-docs-check:
name: Check oi-kit API Reference is Up-to-Date
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1

- name: Check generated GDK API reference data
- name: Check generated oi-kit API reference data
run: python3 documentation/automation/gdk-api/generate.py --check

desktop-lint:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# Regenerates the GDK API reference data from the goose-sdk UniFFI surface and
# Regenerates oi-kit API reference data from the oi-kit-bindings UniFFI surface and
# opens a PR when it drifts from what is committed.
#
# The generator is deterministic and needs no build or API key, so this stays a
# plain script run rather than an AI-assisted job.

name: Update GDK API Reference
name: Update oi-kit API Reference

on:
workflow_dispatch:
Expand All @@ -15,8 +15,8 @@ permissions:
contents: read

jobs:
update-gdk-api-docs:
name: Update GDK API reference
update-oi-kit-api-docs:
name: Update oi-kit API reference
runs-on: ubuntu-latest
permissions:
contents: write
Expand All @@ -25,25 +25,25 @@ jobs:
- name: Checkout repository
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1

- name: Regenerate GDK API reference data
- name: Regenerate oi-kit API reference data
run: python3 documentation/automation/gdk-api/generate.py

- name: Create pull request
uses: peter-evans/create-pull-request@3ffccacd46053766916f087ce41d627c0b8cf2d1 # v8.1.3
with:
branch: docs/auto-gdk-api-reference
branch: docs/auto-oi-kit-api-reference
delete-branch: true
add-paths: documentation/src/data/gdk-api.json
commit-message: "docs: update GDK API reference data"
title: "docs: update GDK API reference"
commit-message: "docs: update oi-kit API reference data"
title: "docs: update oi-kit API reference"
body: |
Regenerated `documentation/src/data/gdk-api.json` from
`crates/goose-sdk/src/bindings.rs`.
`crates/oi-kit-bindings/src/bindings.rs`.

- **Triggered by**: ${{ github.event_name }}
- **Release**: ${{ github.event.release.tag_name || 'n/a' }}

The GDK API reference renders from this file, so merging publishes the
The oi-kit API reference renders from this file, so merging publishes the
updated Rust, Python, and Kotlin reference docs.
labels: |
documentation
Expand Down
64 changes: 32 additions & 32 deletions .github/workflows/maven-sdk.yml
Original file line number Diff line number Diff line change
@@ -1,27 +1,27 @@
name: Maven GDK
name: Maven oi-kit

on:
workflow_call:
inputs:
publish:
description: "Publish gdk to Maven Central after building"
description: "Publish oi-kit to Maven Central after building"
required: false
default: false
type: boolean
smoke-test:
description: "Run the Kotlin GDK smoke test"
description: "Run the Kotlin oi-kit smoke test"
required: false
default: true
type: boolean
workflow_dispatch:
inputs:
publish:
description: "Publish gdk to Maven Central after building"
description: "Publish oi-kit to Maven Central after building"
required: true
default: false
type: boolean
smoke-test:
description: "Run the Kotlin GDK smoke test"
description: "Run the Kotlin oi-kit smoke test"
required: true
default: true
type: boolean
Expand Down Expand Up @@ -65,15 +65,15 @@ jobs:

- name: Build native library
shell: bash
run: cargo build -p goose-sdk --features uniffi --release
run: cargo build -p oi-kit-bindings --features uniffi --release

- name: Stage native library
shell: bash
run: |
case "${{ runner.os }}" in
Linux) lib="target/release/libgoose_sdk.so" ;;
macOS) lib="target/release/libgoose_sdk.dylib" ;;
Windows) lib="target/release/goose_sdk.dll" ;;
Linux) lib="target/release/liboi_kit_bindings.so" ;;
macOS) lib="target/release/liboi_kit_bindings.dylib" ;;
Windows) lib="target/release/oi_kit_bindings.dll" ;;
*) echo "unsupported runner OS: ${{ runner.os }}" >&2; exit 1 ;;
esac
mkdir -p "maven-native/${{ matrix.resource-prefix }}"
Expand All @@ -82,7 +82,7 @@ jobs:
- name: Upload native library artifact
uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7
with:
name: goose-sdk-native-${{ matrix.name }}
name: oi-kit-native-${{ matrix.name }}
path: maven-native/**
if-no-files-found: error

Expand Down Expand Up @@ -111,31 +111,31 @@ jobs:
- name: Download native library artifacts
uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8
with:
pattern: goose-sdk-native-*
pattern: oi-kit-native-*
path: native-artifacts
merge-multiple: true

- name: Generate Kotlin bindings
shell: bash
run: |
cargo build -p goose-sdk --features uniffi --release
crates/goose-sdk/scripts/prepare-maven-package.sh \
target/release/libgoose_sdk.so \
cargo build -p oi-kit-bindings --features uniffi --release
crates/oi-kit-bindings/scripts/prepare-maven-package.sh \
target/release/liboi_kit_bindings.so \
linux-x86-64

- name: Restore downloaded native libraries
shell: bash
run: cp -R native-artifacts/* crates/goose-sdk/maven/src/main/resources/
run: cp -R native-artifacts/* crates/oi-kit-bindings/maven/src/main/resources/

- name: Build Maven publication
working-directory: crates/goose-sdk/maven
working-directory: crates/oi-kit-bindings/maven
run: gradle --no-daemon publishToMavenLocal

- name: Resolve Maven version
id: version
shell: bash
run: |
version=$(grep -m1 '^version =' crates/goose-sdk/Cargo.toml | sed -E 's/version = "([^"]+)"/\1/')
version=$(grep -m1 '^version =' crates/oi-kit-bindings/Cargo.toml | sed -E 's/version = "([^"]+)"/\1/')
echo "value=$version" >> "$GITHUB_OUTPUT"

- name: Stage Maven local artifacts
Expand All @@ -144,17 +144,17 @@ jobs:
VERSION: ${{ steps.version.outputs.value }}
run: |
mkdir -p maven-artifacts
cp -R "$HOME/.m2/repository/io/github/aaif-goose/gdk/$VERSION" maven-artifacts/
cp -R "$HOME/.m2/repository/org/oi-kit/oi-kit/$VERSION" maven-artifacts/

- name: Upload Maven artifact bundle
uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7
with:
name: goose-sdk-maven
name: oi-kit-maven
path: maven-artifacts/**
if-no-files-found: error

smoke-test-linux-aarch64:
name: Smoke test Kotlin GDK (linux-aarch64)
name: Smoke test Kotlin oi-kit (linux-aarch64)
needs: package
if: inputs.smoke-test
runs-on: ubuntu-22.04-arm
Expand All @@ -174,26 +174,26 @@ jobs:
- name: Download Maven artifact bundle
uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8
with:
name: goose-sdk-maven
name: oi-kit-maven
path: maven-artifacts

- name: Install Maven artifact bundle into local repository
shell: bash
run: |
version=$(grep -m1 '^version =' crates/goose-sdk/Cargo.toml | sed -E 's/version = "([^"]+)"/\1/')
target="$HOME/.m2/repository/io/github/aaif-goose/gdk/$version"
version=$(grep -m1 '^version =' crates/oi-kit-bindings/Cargo.toml | sed -E 's/version = "([^"]+)"/\1/')
target="$HOME/.m2/repository/org/oi-kit/oi-kit/$version"
mkdir -p "$target"
find maven-artifacts -type f -exec cp -t "$target" {} +

- name: Load native library in an ARM64 JVM
shell: bash
working-directory: crates/goose-sdk/examples/uniffi/kotlin
working-directory: crates/oi-kit-bindings/examples/uniffi/kotlin
run: |
gradle --no-daemon installDist
cat > "$RUNNER_TEMP/LoadNativeLibrary.java" <<'JAVA'
public class LoadNativeLibrary {
public static void main(String[] args) {
System.out.println(io.github.aaif_goose.GooseKt.openaiDefaultModel());
System.out.println(org.oi_kit.Oi_kitKt.openaiDefaultModel());
}
}
JAVA
Expand All @@ -206,7 +206,7 @@ jobs:
if: inputs.publish && !cancelled() && needs.package.result == 'success' && (!inputs.smoke-test || needs.smoke-test-linux-aarch64.result == 'success')
environment: maven-central
concurrency:
group: gdk-maven-release-${{ needs.package.outputs.version }}
group: oi-kit-maven-release-${{ needs.package.outputs.version }}
cancel-in-progress: false
steps:
- name: Checkout code
Expand All @@ -227,24 +227,24 @@ jobs:
- name: Download native library artifacts
uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8
with:
pattern: goose-sdk-native-*
pattern: oi-kit-native-*
path: native-artifacts
merge-multiple: true

- name: Generate Kotlin bindings
shell: bash
run: |
cargo build -p goose-sdk --features uniffi --release
crates/goose-sdk/scripts/prepare-maven-package.sh \
target/release/libgoose_sdk.so \
cargo build -p oi-kit-bindings --features uniffi --release
crates/oi-kit-bindings/scripts/prepare-maven-package.sh \
target/release/liboi_kit_bindings.so \
linux-x86-64

- name: Restore downloaded native libraries
shell: bash
run: cp -R native-artifacts/* crates/goose-sdk/maven/src/main/resources/
run: cp -R native-artifacts/* crates/oi-kit-bindings/maven/src/main/resources/

- name: Publish to Maven Central
working-directory: crates/goose-sdk/maven
working-directory: crates/oi-kit-bindings/maven
env:
ORG_GRADLE_PROJECT_mavenCentralUsername: ${{ secrets.MAVEN_CENTRAL_TOKEN_USERNAME }}
ORG_GRADLE_PROJECT_mavenCentralPassword: ${{ secrets.MAVEN_CENTRAL_TOKEN_PASSWORD }}
Expand Down
Loading
Loading