Laguna XS 2.1 API

Laguna XS 2.1 on AIMLAPI.

Modalities
Image, TextText
In / Out price
$0.0635/$0.127per 1M
Context window
256K tokens
Released
Jul 2, 2026

Laguna XS 2.1 overview

Laguna XS 2.1 specs

Model ID
poolside/laguna-xs-2.1
Developer
Poolside
Context window
262,144 tokens
Max output
32,768 tokens
Input
Image, Text
Output
Text
API
OpenAI-compatible, base URL https://api.aimlapi.com/v1

Coding and code review
Generate, debug, and review code across languages, reading whole files or repos in a single prompt.

Agentic and multi-step workflows
Reliable tool-calling and instruction-following suit agent loops that plan, call tools, and iterate.

Complex reasoning
Extended reasoning improves reliability on multi-step math, logic, and technical analysis.

Long-document analysis
Summarize and extract from contracts, papers, and reports without aggressive chunking.

Use cases

Agentic coding is a documented use case for Laguna XS 2.1, including software engineering work and rapid agentic iteration in Poolside’s coding agent.

Long-horizon coding work is another documented use case, with the model described as suited to long-horizon work on local machines and long-horizon coding work.

Terminal-style tasks are explicitly listed as a use case, including tool-use workflows and shell-driven multi-step tasks.

Local text generation is also documented as an intended use case for the model.

Capabilities

  • Function calling
  • Reasoning
  • Streaming
  • Structured outputs
  • Web search

Laguna XS 2.1 API pricing

Laguna XS 2.1 pricing in US dollars
UsagePriceUnit
Input$0.06351M tokens
Output$0.1271M tokens
Cached input$0.03171M tokens

Prices from the AI/ML API price list, checked on Nov 4, 2026.

Laguna XS 2.1 vs other models: token prices

AI/ML API input and output rates for 5 models, per million tokens.

AI/ML API model prices in USD per million tokens
ModelInputOutput
Laguna XS 2.1$0.0635$0.127
Gemma 3 (4B)$0.0529$0.1058
Reka Edge$0.1058$0.1058
Nova Micro 1.0$0.037$0.1481
Laguna S 2.1$0.0952$0.1904

How to use the Laguna XS 2.1 API

View docs

Build with your agent

Give your agent the model details, code and documentation.

1Get your API key

Create API key
export AIMLAPI_KEY="8f2b4c7d9a1e6b3f…"

2Make your first request

curl 'https://api.aimlapi.com/v1/chat/completions' \
  -H "Authorization: Bearer $AIMLAPI_KEY" \
  -H 'Content-Type: application/json' \
  -d '{
  "model": "poolside/laguna-xs-2.1",
  "messages": [
    {
      "role": "user",
      "content": "Write a haiku about the ocean."
    }
  ]
}'

Related articles

All posts

Laguna XS 2.1 FAQ

What is the context window of Laguna XS 2.1?

Laguna XS 2.1 has a 262,144 tokens context window and can return up to 32,768 tokens.

What inputs and outputs does Laguna XS 2.1 support?

Laguna XS 2.1 takes image, text as input and returns text.

What is the model ID for Laguna XS 2.1?

Use poolside/laguna-xs-2.1 as the model id. Requests go to https://api.aimlapi.com/v1/chat/completions.

How much does Laguna XS 2.1 cost?

Laguna XS 2.1 costs $0.0635 input and $0.127 output per 1M tokens on AI/ML API, billed as you go with no subscription.

Does Laguna XS 2.1 support streaming?

Yes, Laguna XS 2.1 can stream responses as they are generated.

Can Laguna XS 2.1 read images?

Yes, Laguna XS 2.1 accepts image input alongside text.

Does Laguna XS 2.1 support tool calling?

Yes, it supports function calling, parallel tool calls, and structured output.

Start building with Laguna XS 2.1

Laguna XS 2.1 API

poolside/laguna-xs-2.1

Build with your agent

Give your agent the model details, code and documentation.

1Get your API key

Create API key
export AIMLAPI_KEY="8f2b4c7d9a1e6b3f…"

2Make your first request

curl 'https://api.aimlapi.com/v1/chat/completions' \
  -H "Authorization: Bearer $AIMLAPI_KEY" \
  -H 'Content-Type: application/json' \
  -d '{
  "model": "poolside/laguna-xs-2.1",
  "messages": [
    {
      "role": "user",
      "content": "Write a haiku about the ocean."
    }
  ]
}'