Skip to content

gut

Python library for one-line judgment calls (likely, classify, rate) returning YES, NO or UNSURE, built for Jev and other small models.

ModelbetaApache-2.0

Overview

gut (published as gutfeel) turns judgment calls into one line of Python: gut.likely(text, "is spam") for yes/no, gut.classify(text, Enum) for which one, and gut.rate(text, levels) for how much. There is no prompt, no parsing, no threshold and no model named at the call site. It is built around TypeSafe's Jev but runs on other backends, including local NLI zero-shot models, local transformers, Ollama, vLLM, OpenAI, OpenRouter and Ollaya.

Its distinguishing feature is that it knows when it does not know: with ask_human=True, likely returns YES, NO or UNSURE so ambiguous cases can be sent to a person instead of guessed. A browser demo runs a local model in the page with no key or server. It is pre-1.0 and Apache-2.0, and every code block in its documentation runs in the test suite. It is also listed as an MCP server.

What the decision model decides

TypeQuestionAnswers
Yes / noIs this comment spam?YES · NO · UNSURE
ChoiceWhich team owns this ticket (Enum)?—
ScoreHow urgent is it?can wait · this week · right now

How it works

  1. Configure a backend (Jev or local)
  2. Call likely, classify or rate
  3. Branch on YES/NO/UNSURE or typed results
  4. Send UNSURE cases to a human

Strengths

  • One-line API
  • Explicit UNSURE outcome
  • Many backends including fully local
  • Docs tested in CI

Caveats

  • Pre-1.0
  • Local backends are less accurate than Jev

Getting started

pip install "gutfeel[jev]", set TYPESAFE_API_KEY, then gut.likely(comment, "is spam").

At a glance

Type
Model
Status
beta
Language
Python
Runtime
library (+ browser demo, MCP)
Has code
yes
Has tests
yes
License
Apache-2.0

Use cases and integrations

How curated lists describe it

  • Judgment calls as one line of Python, built for TypeSafe AI.

    wh000wh000/awesome-jev-live
  • Judgment calls as one line of Python, built for TypeSafe AI's Jev and running on any small model: likely / classify / rate → YES, NO or UNSURE. Also local NLI, local LLMs, Ollama, vLLM, OpenAI.

    hellogumbo/awesome-jev

Frequently asked questions

What are the three calls?

likely (yes/no), classify (which one) and rate (how much).

Can it say it is unsure?

Yes, with ask_human=True it returns UNSURE.

Does it need Jev?

No, it supports local and other hosted backends too.

Related projects

  • C++20 library for typed routing, classification and scoring with compile-time enum schemas, local Laya and optional System One.

    LibrarybetaC++
  • 48-requirement spec and conformance suite for Jev-compatible servers, with a normalising proxy; shows confidence is not portable.

    CLIbetaPython
  • Rust CLI and library that asks Jev typed questions via OpenRouter and combines the probabilities with fuzzy-logic rules into decisions.

    CLIbetaRust
  • Go harness for System One models: hosted Jev, open Kev in-process via llama.cpp, and Cloudflare Clef, with typed helpers and a CLI.

    ServicebetaGo
  • TypeScript library for one-line local decisions with open models (kev-0.6b, kev-4b, open-jev), no API keys or cloud.

    ProjectbetaTypeScript
  • Unofficial standard-library Go client for Jev with generic typed Choice values and local confidence thresholds.

    ProjectbetaGo