Kelbie/hunch on GitHub
- Stars
- 4
- Forks
- 2
- Language
- TypeScript
- License
- MIT
- Last push
- 23 Sep 2026
Read from GitHub on . Counts change daily.
How it uses Jev
| { type: "score"; score: number; probabilities?: Record<string, number> };
/** TypeSafe's own REST API: POST https://api.typesafe.ai/v1/systemone. */
export function typesafeClient(opts: { apiKey: string; baseUrl?: string; fetch?: typeof fetch }): JevClient {
const base = opts.baseUrl ?? "https://api.typesafe.ai/v1";
const doFetch = opts.fetch ?? fetch;
return {
async evaluate(req) {
const body = JSON.stringify({ model: req.model, state: req.state, questions: req.questions });
let lastErr: unknown;
const signal = req.signal ? AbortSignal.any([req.signal, AbortSignal.timeout(45_000)]) : AbortSignal.timeout(45_000);
for (let attempt = 0; attempt < 3; attempt++) {
const res = await doFetch(`${base}/systemone`, {
method: "POST",
signal,View in packages/core/src/jev.ts

