Repository navigation
Releases: guchengod/typesafe-sdk-go
Releases · guchengod/typesafe-sdk-go
Release list
v0.13.0
Full Changelog: v0.12.0...v0.13.0
v0.12.0
v0.11.0
v0.10.1
v0.10.0
v0.9.0
The typesafe command line
This release adds a CLI, built on the standard library only, for using the API without writing Go.
# Install into $(go env GOPATH)/bin
go install github.com/guchengod/typesafe-sdk-go/cmd/typesafe@v0.9.0
# Or download a binary belowexport TYPESAFE_API_KEY="ts_live_..."
typesafe models --format text
typesafe ask \
--state '{"body": "I was charged twice on invoice #4912."}' \
--noul 'billing=Is this about billing?' \
--choice 'queue=billing:Charges,technical:API issues,other' \
--score 'urgency=routine,elevated,critical' \
--format textmodel jev-1.13.0
usage Usage{input_tokens: 367, output_tokens: 69}
billing noul 0.9900
queue choice billing (confidence 1.00)
urgency score 0.53 of 2 (confidence 0.20)
The state and the questions each come from an inline value, an @file, or stdin, so the command
drops into a pipeline; --format json (the default) composes with jq. Exit codes separate a
usage error (1) from an API error status (2) and a failure to reach the API (3).
The library is unchanged: cmd/typesafe is a separate package that imports the SDK like any other
program, and the module has no new dependencies.
Downloads
| Platform | amd64 | arm64 |
|---|---|---|
| macOS | typesafe_0.9.0_darwin_amd64 |
typesafe_0.9.0_darwin_arm64 |
| Linux | typesafe_0.9.0_linux_amd64 |
typesafe_0.9.0_linux_arm64 |
| Windows | typesafe_0.9.0_windows_amd64.exe |
typesafe_0.9.0_windows_arm64.exe |
Verify with sha256sum -c checksums.txt.
Also in this release
.github/workflows/release.ymlbuilds these binaries on everyv*tag and publishes them, so
future releases are reproducible from the tag alone.- The SDK now reports version
0.9.0.