laya

laya is a Python library that makes fast typed decisions such as choices, scores and yes/no answers over text in 100+ languages for developers building agents.

What it is good for

  • Sorting incoming messages to the right team automatically
  • Getting a yes/no or score decision from any text quickly
  • Routing requests to the right model based on language and length
  • Calibrating decision confidence using your own labeled examples

At a glance

Who it is for
Setup difficulty
Developer ยท Requires programming

Level 5 of 5. You need to write code to use it.

Cost
Free and open source
Type
Framework or SDK
Tasks
Works with
LangChain, LangGraph, LlamaIndex, CrewAI, Hugging Face, ONNX Runtime

How to get started with laya

  1. Install Python 3.10 or newer.
  2. Run python -m pip install laya in a terminal.
  3. Import laya in your Python code and create an agent with laya.Agent().
  4. Pass your text and a list of questions to the agent's predict call to get typed answers.

From the project's own documentation. If a step does not match what you see, the official pages have the latest instructions.

Before you try it

  • Requires Python 3.10 or newer and you need to write code to use it.
  • Optional features such as vision, audio, server and MCP need extra install packages.
  • Fitting on your own labels needs at least about 35 labeled rows for the example questions.
  • Calibration with very few rows gives wide, less certain prediction sets.

Momentum

Rank this week
#44 in builder tools
Best rank
#35 week 45, 2026
Stars gained last week
+322
GitHub stars
35,586

GitHub numbers as of Nov 16, 2026. Updated weekly.

34.8k 35.2k 35.6k Nov 2, 2026 Nov 16, 2026
GitHub stars for laya: 34,856 on Nov 2, 2026, 35,586 on Nov 16, 2026. Source: GitHub.

Ranking history

First ranked in week 45, 2026.

Questions

Is laya free?
Yes. It is free and open source (Apache-2.0 license).
Do I need to know how to code to use laya?
Yes. You need to write code to use it.
What does laya work with?
According to its own documentation, it works with LangChain, LangGraph, LlamaIndex, CrewAI, Hugging Face, and ONNX Runtime.
How do I get started with laya?
1. Install Python 3.10 or newer. 2. Run python -m pip install laya in a terminal. 3. Import laya in your Python code and create an agent with laya.Agent(). 4. Pass your text and a list of questions to the agent's predict call to get typed answers.
What should I know before trying laya?
Requires Python 3.10 or newer and you need to write code to use it. Optional features such as vision, audio, server and MCP need extra install packages. Fitting on your own labels needs at least about 35 labeled rows for the example questions. Calibration with very few rows gives wide, less certain prediction sets.
What is laya good for?
Sorting incoming messages to the right team automatically, getting a yes/no or score decision from any text quickly, routing requests to the right model based on language and length, and calibrating decision confidence using your own labeled examples.

Similar agents to laya

  • AnyJev

    Turns any open language model into a typed decision maker rather than using laya's own non-autoregressive checkpoints.

  • Gateway

    Routes requests across many language models through one API, while laya routes between its own decision models.

  • skills

    A skill that teaches coding agents to build integrations with a decision API, not a library for making decisions.

  • LangChain

    A broad framework for building agents and LLM apps, while laya focuses on fast typed decisions.

  • Haystack

    A general framework for production LLM apps and agent workflows, not a single-pass decision engine.

  • LangBot

    LangBot is a self-hosted platform that connects AI models and agent workflows to chat apps like Slack, Discord, Telegram, and WeChat for teams and businesses.

Last updated Nov 16, 2026. Tracked since Nov 2, 2026. Parts of this summary required judgment because the source material was brief. Spotted an error? Tell us.