nowfound

AI · August 14, 2023

LLMs can generate valid JSON 100% of the time

Outlines is a Python library that focuses on text generation with large language models. Brandon and I are not LLM experts and started the project a few months ago because we wanted to understand better how the generation process works. Our original background is probabilistic, relational and symbolic programming. Recently we came up with a fast way to generate text that matches a regex (https://blog.normalcomputing.ai/posts/2023-07-27-regex-guide...). The basic idea is simple: regular expressions have an equivalent Deterministic-Finite Automaton (DFA) representation. We…

LLMs can generate valid JSON 100% of the time launched on August 14, 2023 with 854 votes, #6 of 4,347 launches that month and more than 99% of that year's launches. The site was still online in September 2026, 3 years on.

Visit github.com ↗Alternativestop 1% of August 2023

In plain words

Outlines is a Python library for controlling text generation with large language models. It enables users to generate text that matches specific patterns, such as regular expressions, by converting those patterns into finite automaton representations and using them to guide the model's token selection. The library is designed for developers who need structured, validated outputs from language models.

written from the facts on this page · September 2026

From the sources

Structured Outputs. Contribute to dottxt-ai/outlines development by creating an account on GitHub.

In the maker’s words, at launch

Outlines is a Python library that focuses on text generation with large language models. Brandon and I are not LLM experts and started the project a few months ago because we wanted to understand better how the generation process works. Our original background is probabilistic, relational and symbolic programming.…

Does a similar job

all alternatives →
  • Wordllama – Things you can do with the token embeddings of an LLM2024 · github.com · ▲370

    After working with LLMs for long enough, I found myself wanting a lightweight utility for doing various small tasks to prepare inputs, locate information and create evaluators. This library is two things: a very simple model and utilities that inference it (eg. fuzzy deduplication). The target platform is CPU, and it’s intended to be light, fast and pip installable — a library that lowers the barrier to working with strings semantically. You don’t need to install pytorch to use it, or any deep learning runtimes. How can this be accomplished? The model is simply token embeddings that are…

  • VW
    VLLM with JSON Guided Generation2023 · outlines-dev.github.io · ▲11

    Our project, Outlines, now offers guided/constrained generation (e.g. according to a JSON schema) via the VLLM library. My colleague, Rémi, created some patches that allow one to pass vLLM a JSON schema along with the prompt, which dramatically simplifies deployment of JSON-guided generation. He also added a new `serve` interface that puts it all together and makes serving such models a 2-3 line process. Check it out and tell us what you think!

  • Free Article Outline Generator2021 · surferseo.com · ▲307

    Unique, AI generated and ready-to-use outlines in seconds

  • Structured output from LLMs without reprompting2023 · automorphic.ai · ▲174

    Built a tool for transforming unstructured data into structured outputs using language models (with 100% adherence). If you're facing problems getting GPT to adhere to a schema (JSON, XML, etc.) or regex, need to bulk process some unstructured data, or generate synthetic data, check it out. We run our own tuned model (you can self-host if you want), so, we're able to have incredibly fine grained control over text generation. Repository: https://github.com/automorphic-ai/trex Playground: https://automorphic.ai/playground

  • Klarity – Open-source tool to analyze uncertainty/entropy in LLM output2025 · github.com · ▲132

    We've open-sourced Klarity - a tool for analyzing uncertainty and decision-making in LLM token generation. It provides structured insights into how models choose tokens and where they show uncertainty. What Klarity does: - Real-time analysis of model uncertainty during generation - Dual analysis combining log probabilities and semantic understanding - Structured JSON output with actionable insights - Fully self-hostable with customizable analysis models The tool works by analyzing each step of text generation and returns a structured JSON: - uncertainty_points: array of {step, entropy,…

  • AT
    Anything To JSON – a language model for structured extraction2024 · anythingtojson.com · ▲18

    Hey HN! Erik here from banana.dev We’ve trained a small(ish) language model on structured extraction, and today we’re launching a playground for it at https://anythingtojson.com. Give it a try! This model continues our work on structured generation, following last week’s launch of Fructose[1], a python client for strongly-typed LLM responses. There seem to be two distinct halves of the problem intended to be solved by Fructose and structured generation: 1. the reasoning ability of the model, such as performing chain of thought, creative acts, and natural language tasks. In a way,…

More ai this month

the category →
  • Video model that turns script into viral social media videos

    AI · 20d ago · spira.ai

  • The browser where Claude Code and Codex work beside you

    AI · 20d ago · rill.love

  • Kolibri is Aleph Alpha

    AI · 22d ago · tej.as

  • Paintings by AI models: programs run through a simulation of oil paint.

    AI · 23d ago · stillwet.art

  • Beam.win▲378

    Run AI agents on one Mac and use its windows on another

    AI · 6d ago · beam.win

  • Route requests to the right LLM for cost, latency & quality

    AI · 24d ago · fastrouter.ai

Source: Show HN post ↗ · launch text quoted in part

Launched alongside, August 2023

the whole month →
  • Resend▲1,325

    An entire collection of pre-built components with a much faster development experience.

    Dev tools · 2023 · resend.com

  • STORI AI▲1,316

    Your ideas become visually compelling branded social posts

    AI · 2023 · storiai.com

  • Kombai▲1,079

    A new AI model that you can prompt with UI designs

    AI · 2023 · kombai.com

  • Understand your audience without 50 interviews

    AI · 2023 · founderpal.ai

  • Lottielab▲869

    Create and ship lottie animations to sites and apps faster

    Dev tools · 2023 · lottielab.com

  • I've been using this for about a year now - I parsed 6 months of my messages on slack and found the most common phrases I use and generated keyboard shortcuts for them.

    Life & fun · 2023 · github.com