Skip to content

Go GenAI submodules: require published agenttel-go, make them installable - #30

Merged
rrohitramsen merged 2 commits into
mainfrom
go-genai-submodules
Oct 20, 2026
Merged

rrohitramsen merged 2 commits into
mainfrom
go-genai-submodules

Conversation

@rrohitramsen

Copy link
Copy Markdown
Collaborator

Makes the Go GenAI submodules installable so they can be released as v0.4.0-alpha.

Problem: go.agenttel.dev/agenttel-go/genai/openai and .../genai/anthropic required agenttel-go v0.1.0, which was never published, and worked only through replace ../../. Go ignores replace in dependencies, so nobody could go get them.

Changes

  • Both go.mod files now require the published go.agenttel.dev/agenttel-go v0.4.0-alpha, and the replace is removed.
  • New agenttel-go/go.work links the submodules to this checkout for local development and CI.
  • New CI step that builds and tests both submodules with GOWORK=off, exactly as consumers get them.
  • Added ExampleWrap for both packages. They're compile-checked, so they can't drift, and pkg.go.dev shows them.
  • Quick-start: added install commands, and corrected the Go GenAI snippet. EndSpanSuccess takes a genai.ChatResult, not three values.
  • One CHANGELOG line.

Tested (Docker, Go 1.24)

  • With GOWORK=off, each submodule resolves agenttel-go v0.4.0-alpha from the Go proxy, and vet and tests pass.
  • In workspace mode, the root module and both submodules pass.
  • actionlint passes on ci.yml.

After merge (not done in this PR)

Tag the merge commit and push the tags:

  • agenttel-go/genai/openai/v0.4.0-alpha
  • agenttel-go/genai/anthropic/v0.4.0-alpha

genai/openai and genai/anthropic pinned agenttel-go v0.1.0 (never
published) and relied on a replace directive, which consumers ignore, so
neither module could be installed.

- require go.agenttel.dev/agenttel-go v0.4.0-alpha, drop the replace
- agenttel-go/go.work links them to the checkout for local development
- CI also builds and tests them with GOWORK=off, as consumers do
- compile-checked ExampleWrap for both (shown on pkg.go.dev)
- quick-start: install commands and correct GenAI usage (EndSpanSuccess
  takes a ChatResult)

Signed-off-by: Rohit Kumar <rrohit.ramsen@gmail.com>
Signed-off-by: Rohit Kumar <rrohit.ramsen@gmail.com>
@rrohitramsen
rrohitramsen merged commit 8af35f6 into main Oct 20, 2026
9 checks passed
@rrohitramsen
rrohitramsen deleted the go-genai-submodules branch October 20, 2026 13:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant