typesafe-go
Dependency-free unofficial Go SDK for System One calls and model discovery, with retries and typed errors.
Overview
typesafe-go is an unofficial, MIT-licensed Go client for TypeSafe's v1 API, covering System One calls and model discovery with no third-party dependencies. It requires Go 1.23+. State can be any JSON-shaped value, and questions are built with Noul, Choice and Score helpers; answers are read with NoulAnswer, ChoiceAnswer and ScoreAnswer.
Configuration comes from TYPESAFE_API_KEY, TYPESAFE_BASE_URL and TYPESAFE_DEFAULT_MODEL or client options, which also control retries, HTTP transport and maximum response size. Transient failures are retried per policy, Retry-After is honored, canceled contexts are never retried, and typed HTTP errors include status, headers, request ID and a bounded body. Releases follow semantic versioning from conventional commits. Request options can override settings such as the model for a single call without changing the client, and every successful response exposes a request ID for tracing.
What the decision model decides
| Type | Question | Answers |
|---|---|---|
| Yes / no | Is the draft safe to send? | yes · no |
| Choice | Which audience should receive the draft? | engineering · customers |
| Score | How feasible is shipping the migration on Friday? | Not feasible · At risk · Feasible |
How it works
- Create a client with NewClient.
- Call SystemOne with state and questions.
- Read typed answers and the request ID.
- Handle typed errors and retries as configured.
Strengths
- No third-party dependencies.
- Respects Retry-After and context cancellation.
- Detailed typed errors for diagnostics.
Caveats
- Unofficial.
- Requires a TypeSafe key.
Getting started
go get github.com/zhirschtritt/typesafe-goAt a glance
- Type
- Library
- Status
- beta
- Language
- Go
- Runtime
- library
- Has code
- yes
- License
- MIT
Use cases and integrations
How curated lists describe it
An unofficial Go client without third-party dependencies for System One calls and model discovery.
logicrw/awesome-jev-projectsIdiomatic Go SDK for the TypeSafe AI API.
wh000wh000/awesome-jev-liveIdiomatic Go SDK for the TypeSafe API.
cobanov/awesome-jevIdiomatic Go SDK for the TypeSafe AI API.
hellogumbo/awesome-jev
Frequently asked questions
What Go version is needed?
Go 1.23 or later.
Does it have dependencies?
No third-party dependencies.
Can I override the model per request?
Yes, request options can override request-scoped settings such as the model.
Related projects
Hack Club's lightweight LLM proxy, listed for adding a Jev forwarding endpoint behind its auth, limits and usage logging.
MCP serverproductionTypeScriptAx, a DSPy-style multi-language LLM framework, listed with a native TypeSafe provider for Boolean, Choice, Score and raw Jev questions.
PluginproductionTypeScriptEffect TypeScript library whose @effect/ai-typesafe package maps classify, probability and rating operations to Jev questions.
ProjectproductionTypeScriptPHP monorepo whose Polyglot module adds a TypeSafe driver for typed Noul, Choice and Score decisions alongside LLM inference.
ProjectproductionPHPGo MCP server giving any client typed Jev decisions via OpenRouter or TypeSafe, with validated answers and no paid retries.
MCP serverproductionGoSimon Willison's LLM plugin that adds Jev as a model for yes/no, choice and score questions from the command line.
PluginproductionPython