systemone

package
v0.2.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 23, 2026 License: MIT Imports: 12 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package systemone answers OpenAI Decisions requests with TypeSafe's System One API, which asks the same three kinds of question under other names: a predicate is a noul, and choice and score keep their names. It serves every provider whose upstream speaks System One: jev (hosted Jev and self-hosted Kev servers) and OpenRouter, which serves Jev and Kev natively.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AnswerDecisions

func AnswerDecisions(ctx context.Context, req *core.PassthroughRequest, send Sender, opts Options) (*core.PassthroughResponse, error)

AnswerDecisions answers an OpenAI Decisions request with System One. The request is translated to a System One request, sent to /v1/systemone through send, and the answer translated back, so the caller sees OpenAI's shapes. Members System One has no place for (prompt caching, safety_identifier) are dropped. Images become System One image assets, which TypeSafe serves only with the TypeSafe-Danger-Zone-Images header; the gateway does not fetch images, so they must arrive inline as base64 data URLs.

Types

type Options

type Options struct {
	// ProviderType names the provider in errors.
	ProviderType string
	// ImagesRefusal, when set, refuses a request with images with this
	// message: the upstream reads text only.
	ImagesRefusal string
}

Options describe the provider a Decisions request is answered for.

type Sender

Sender sends one System One request upstream: a provider's Passthrough.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL