World Monitor
Real-time global intelligence on conflict, markets, energy, trade, shipping and cyber. 100 tools.
Stops an agent's Trino or Pinot query before it runs if it costs too much or reads outside its grant
Lists are ordered by a usage score (out of 100) built from these parts
| Popularity | 4/80 | GitHub stars or weekly downloads: the larger counts 60, the smaller 20 |
|---|---|---|
| Freshness | 12/12 | Full marks for a release or code change within 30 days |
| Still answering | 0/8 | The cloud endpoint answered at the last check |
| Usage score | 16/100 |
Quality: Passed 3/3 basic checks (shown, not used for ordering) · Momentum: No data yet (Used only on the Trending tab)
Pick the AI app you use, then copy the settings.
Let your AI install it with one sentence
Please install Lagaam. Follow https://mcp.popnx.com/i/lagaam-ai-lagaam.md, show me the commands and wait for my OK before running them.Paste it into an AI that can work on your computer (such as Claude Code or Cursor). It reads our steps, shows you the commands and waits for your OK. No key, no sign-up. · See the full text your AI reads
Passed 3/3 checks · Runs on your computer · ✓ Commands checked Nov 14, 2026
First: which AI do you use?
Pick your app and the steps appear below.
Works with Claude, with some setup first
You need a Lagaam key (create it on the maker’s site) · 1 setting(s) to fill in (LAGAAM_ALLOWED_TABLES) · Install Python (uv) on your computer first (one time) · Only the Claude desktop app (Windows or Mac), not the web or phone
Copy this message into a Claude chat. The AI checks your computer, tells you which file it will change, and waits for your OK every time.
Please install the MCP server Lagaam for Claude on this computer, in this order: 1) Check uv with uv --version. If it is missing, tell me to install it from https://docs.astral.sh/uv/getting-started/installation/; do not install it yourself. 2) Use only this config (already checked by PopNx MCP): { "mcpServers": { "lagaam": { "command": "uvx", "args": [ "lagaam" ], "env": { "LAGAAM_ALLOWED_TABLES": "your-value", "TRINO_PASSWORD": "your-value", "TRINO_JWT": "your-value", "PINOT_PASSWORD": "your-value" } } } } 3) Tell me the full path of the file you will change, or the command you will run, and wait for my OK. 4) For TRINO_PASSWORD, TRINO_JWT, PINOT_PASSWORD, LAGAAM_ALLOWED_TABLES, leave "your-value" in place and tell me to paste the real value myself into the file or the app’s field. Never ask me to type a key in chat. 5) Do what we agreed, then check that the Lagaam tools really show up.This message has no key in it. If a key is needed, the AI will ask you to paste it yourself into the file or the app’s field.
Already installed? Check first · Open Terminal, type this command and press Enter
uv --versionMac: press ⌘ + Space, type Terminal, press Enter
Windows: open Start, type Windows PowerShell, then Open
Not installed: uv has no click-through installer. Copy the one-line command for your system (macOS or Windows) from uv’s official page into Terminal · no separate Python install needed; uv downloads it when required
When it’s done, close Terminal, open it again and run the same command. You should see a version number: uv --version
Install once; it works for everything that needs uv
Open the maker’s site, sign up and create an API key for the next step. Check the maker’s site for pricing and free plans.
These are program settings, not keys. No sign-up needed; fill them in as the maker describes.
LAGAAM_ALLOWED_TABLES Comma list of catalog.schema.table grants; the server will not start without itDescriptions are as written by the maker.
SettingsDeveloperEdit Config
{
"mcpServers": {
"lagaam": {
"command": "uvx",
"args": [
"lagaam"
],
"env": {
"LAGAAM_ALLOWED_TABLES": "your-value",
"TRINO_PASSWORD": "your-value",
"TRINO_JWT": "your-value",
"PINOT_PASSWORD": "your-value"
}
}
}
}Paste the key only into the app’s field, never into a chat or to anyone
Use Lagaam and tell me what you can do for me, then show me one thing✓ If Claude says it is using Lagaam or shows a Lagaam tool in the answer, you are connected
The command above works without these. Add them only if you want to change something, following the maker’s description.
LAGAAM_ALLOW_ALL_TABLES true to run with no grant at all: an explicit opt-out, off by defaultLAGAAM_ENGINE Which adapter to run · default trinoTRINO_HOST Trino coordinator host · default localhostTRINO_PORT Trino coordinator port · default 8080TRINO_USER Trino user · default lagaamTRINO_HTTP_SCHEME http or https; unset means https once a password or JWT is set, else httpTRINO_VERIFY TLS cert check: true, false, or the path of a CA bundle (PEM) · default truePINOT_CONTROLLER_URL Pinot controller URL · default http://localhost:9000PINOT_BROKER_URL Pinot broker URL · default http://localhost:8000PINOT_USER Pinot user; unset means no authLAGAAM_AGENT_NAME Identity stamped on the audit trail · default anonymousLAGAAM_MAX_SCAN_BYTES Scan-bytes budget per query, checked before it runs (default 50 GiB) · default 53687091200LAGAAM_MAX_ROWS Scanned-row estimate budget per query; unset means ungatedLAGAAM_MAX_INTERMEDIATE_ROWS Rows the engine would build at its widest step, not rows returned, so a LIMIT doesn't lower it · default 50000000LAGAAM_MAX_RETURNED_ROWS Rows returned to the agent per query, capped at 100000; a bigger LIMIT in the query is lowered to it · default 1000LAGAAM_QUERY_TIMEOUT Wall-clock seconds per query · default 300LAGAAM_METADATA_TTL Metadata cache TTL, seconds · default 300LAGAAM_AUDIT_LOG Audit JSONL file path; unset means stderrDescriptions are as written by the maker.
Menu names checked against Anthropic’s help page on Nov 11, 2026 · your screen may differ slightly by app version
ChatGPT cannot connect Lagaam yet
Lagaam runs on your computer, but ChatGPT can only connect servers that run on the web
A · Use an app that can connect Lagaam
B · Others in Other that work with ChatGPT
Picked from the most used in the same category, only ones that connect by address with no key
Works with Claude Code, with some setup first
You need a Lagaam key (create it on the maker’s site) · 1 setting(s) to fill in (LAGAAM_ALLOWED_TABLES) · Install Python (uv) on your computer first (one time)
Copy this message into a Claude Code chat. The AI checks your computer, tells you which file it will change, and waits for your OK every time.
Please install the MCP server Lagaam for Claude Code on this computer, in this order: 1) Check uv with uv --version. If it is missing, tell me to install it from https://docs.astral.sh/uv/getting-started/installation/; do not install it yourself. 2) Use only this config (already checked by PopNx MCP): claude mcp add --scope user lagaam --env LAGAAM_ALLOWED_TABLES=your-value --env TRINO_PASSWORD=your-value --env TRINO_JWT=your-value --env PINOT_PASSWORD=your-value -- uvx lagaam 3) Tell me the full path of the file you will change, or the command you will run, and wait for my OK. 4) For TRINO_PASSWORD, TRINO_JWT, PINOT_PASSWORD, LAGAAM_ALLOWED_TABLES, leave "your-value" in place and tell me to paste the real value myself into the file or the app’s field. Never ask me to type a key in chat. 5) Do what we agreed, then check that the Lagaam tools really show up.This message has no key in it. If a key is needed, the AI will ask you to paste it yourself into the file or the app’s field.
Already installed? Check first · Open Terminal, type this command and press Enter
uv --versionMac: press ⌘ + Space, type Terminal, press Enter
Windows: open Start, type Windows PowerShell, then Open
Not installed: uv has no click-through installer. Copy the one-line command for your system (macOS or Windows) from uv’s official page into Terminal · no separate Python install needed; uv downloads it when required
When it’s done, close Terminal, open it again and run the same command. You should see a version number: uv --version
Install once; it works for everything that needs uv
Open the maker’s site, sign up and create an API key for the next step. Check the maker’s site for pricing and free plans.
These are program settings, not keys. No sign-up needed; fill them in as the maker describes.
LAGAAM_ALLOWED_TABLES Comma list of catalog.schema.table grants; the server will not start without itDescriptions are as written by the maker.
Mac: press Command+Space and type Terminal · Windows: open PowerShell
claude mcp add --scope user lagaam --env LAGAAM_ALLOWED_TABLES=your-value --env TRINO_PASSWORD=your-value --env TRINO_JWT=your-value --env PINOT_PASSWORD=your-value -- uvx lagaamReplace “your-value” with your key before pressing Enter
Paste the key only into the app’s field, never into a chat or to anyone
You should see Lagaam listed as connected
Use Lagaam and tell me what you can do for me, then show me one thing✓ If Claude Code says it is using Lagaam or shows a Lagaam tool in the answer, you are connected
The command above works without these. Add them only if you want to change something, following the maker’s description.
LAGAAM_ALLOW_ALL_TABLES true to run with no grant at all: an explicit opt-out, off by defaultLAGAAM_ENGINE Which adapter to run · default trinoTRINO_HOST Trino coordinator host · default localhostTRINO_PORT Trino coordinator port · default 8080TRINO_USER Trino user · default lagaamTRINO_HTTP_SCHEME http or https; unset means https once a password or JWT is set, else httpTRINO_VERIFY TLS cert check: true, false, or the path of a CA bundle (PEM) · default truePINOT_CONTROLLER_URL Pinot controller URL · default http://localhost:9000PINOT_BROKER_URL Pinot broker URL · default http://localhost:8000PINOT_USER Pinot user; unset means no authLAGAAM_AGENT_NAME Identity stamped on the audit trail · default anonymousLAGAAM_MAX_SCAN_BYTES Scan-bytes budget per query, checked before it runs (default 50 GiB) · default 53687091200LAGAAM_MAX_ROWS Scanned-row estimate budget per query; unset means ungatedLAGAAM_MAX_INTERMEDIATE_ROWS Rows the engine would build at its widest step, not rows returned, so a LIMIT doesn't lower it · default 50000000LAGAAM_MAX_RETURNED_ROWS Rows returned to the agent per query, capped at 100000; a bigger LIMIT in the query is lowered to it · default 1000LAGAAM_QUERY_TIMEOUT Wall-clock seconds per query · default 300LAGAAM_METADATA_TTL Metadata cache TTL, seconds · default 300LAGAAM_AUDIT_LOG Audit JSONL file path; unset means stderrDescriptions are as written by the maker.
Menu names checked against Anthropic’s help page on Nov 11, 2026 · your screen may differ slightly by app version
Works with Cursor, with some setup first
You need a Lagaam key (create it on the maker’s site) · 1 setting(s) to fill in (LAGAAM_ALLOWED_TABLES) · Install Python (uv) on your computer first (one time)
Copy this message into a Cursor chat. The AI checks your computer, tells you which file it will change, and waits for your OK every time.
Please install the MCP server Lagaam for Cursor on this computer, in this order: 1) Check uv with uv --version. If it is missing, tell me to install it from https://docs.astral.sh/uv/getting-started/installation/; do not install it yourself. 2) Use only this config (already checked by PopNx MCP): { "mcpServers": { "lagaam": { "command": "uvx", "args": [ "lagaam" ], "env": { "LAGAAM_ALLOWED_TABLES": "your-value", "TRINO_PASSWORD": "your-value", "TRINO_JWT": "your-value", "PINOT_PASSWORD": "your-value" } } } } 3) Tell me the full path of the file you will change, or the command you will run, and wait for my OK. 4) For TRINO_PASSWORD, TRINO_JWT, PINOT_PASSWORD, LAGAAM_ALLOWED_TABLES, leave "your-value" in place and tell me to paste the real value myself into the file or the app’s field. Never ask me to type a key in chat. 5) Do what we agreed, then check that the Lagaam tools really show up.This message has no key in it. If a key is needed, the AI will ask you to paste it yourself into the file or the app’s field.
Already installed? Check first · Open Terminal, type this command and press Enter
uv --versionMac: press ⌘ + Space, type Terminal, press Enter
Windows: open Start, type Windows PowerShell, then Open
Not installed: uv has no click-through installer. Copy the one-line command for your system (macOS or Windows) from uv’s official page into Terminal · no separate Python install needed; uv downloads it when required
When it’s done, close Terminal, open it again and run the same command. You should see a version number: uv --version
Install once; it works for everything that needs uv
Open the maker’s site, sign up and create an API key for the next step. Check the maker’s site for pricing and free plans.
These are program settings, not keys. No sign-up needed; fill them in as the maker describes.
LAGAAM_ALLOWED_TABLES Comma list of catalog.schema.table grants; the server will not start without itDescriptions are as written by the maker.
In the Lagaam settings, TRINO_PASSWORD, TRINO_JWT, PINOT_PASSWORD, LAGAAM_ALLOWED_TABLES is empty; add your key and save
Paste the key only into the app’s field, never into a chat or to anyone
Use Lagaam and tell me what you can do for me, then show me one thing✓ If Cursor says it is using Lagaam or shows a Lagaam tool in the answer, you are connected
The command above works without these. Add them only if you want to change something, following the maker’s description.
LAGAAM_ALLOW_ALL_TABLES true to run with no grant at all: an explicit opt-out, off by defaultLAGAAM_ENGINE Which adapter to run · default trinoTRINO_HOST Trino coordinator host · default localhostTRINO_PORT Trino coordinator port · default 8080TRINO_USER Trino user · default lagaamTRINO_HTTP_SCHEME http or https; unset means https once a password or JWT is set, else httpTRINO_VERIFY TLS cert check: true, false, or the path of a CA bundle (PEM) · default truePINOT_CONTROLLER_URL Pinot controller URL · default http://localhost:9000PINOT_BROKER_URL Pinot broker URL · default http://localhost:8000PINOT_USER Pinot user; unset means no authLAGAAM_AGENT_NAME Identity stamped on the audit trail · default anonymousLAGAAM_MAX_SCAN_BYTES Scan-bytes budget per query, checked before it runs (default 50 GiB) · default 53687091200LAGAAM_MAX_ROWS Scanned-row estimate budget per query; unset means ungatedLAGAAM_MAX_INTERMEDIATE_ROWS Rows the engine would build at its widest step, not rows returned, so a LIMIT doesn't lower it · default 50000000LAGAAM_MAX_RETURNED_ROWS Rows returned to the agent per query, capped at 100000; a bigger LIMIT in the query is lowered to it · default 1000LAGAAM_QUERY_TIMEOUT Wall-clock seconds per query · default 300LAGAAM_METADATA_TTL Metadata cache TTL, seconds · default 300LAGAAM_AUDIT_LOG Audit JSONL file path; unset means stderrDescriptions are as written by the maker.
Menu names checked against Cursor’s help page on Nov 11, 2026 · your screen may differ slightly by app version
Works with VS Code, with some setup first
You need a Lagaam key (create it on the maker’s site) · 1 setting(s) to fill in (LAGAAM_ALLOWED_TABLES) · Install Python (uv) on your computer first (one time)
Copy this message into a VS Code chat. The AI checks your computer, tells you which file it will change, and waits for your OK every time.
Please install the MCP server Lagaam for VS Code on this computer, in this order: 1) Check uv with uv --version. If it is missing, tell me to install it from https://docs.astral.sh/uv/getting-started/installation/; do not install it yourself. 2) Use only this config (already checked by PopNx MCP): { "servers": { "lagaam": { "type": "stdio", "command": "uvx", "args": [ "lagaam" ], "env": { "LAGAAM_ALLOWED_TABLES": "your-value", "TRINO_PASSWORD": "your-value", "TRINO_JWT": "your-value", "PINOT_PASSWORD": "your-value" } } } } 3) Tell me the full path of the file you will change, or the command you will run, and wait for my OK. 4) For TRINO_PASSWORD, TRINO_JWT, PINOT_PASSWORD, LAGAAM_ALLOWED_TABLES, leave "your-value" in place and tell me to paste the real value myself into the file or the app’s field. Never ask me to type a key in chat. 5) Do what we agreed, then check that the Lagaam tools really show up.This message has no key in it. If a key is needed, the AI will ask you to paste it yourself into the file or the app’s field.
Already installed? Check first · Open Terminal, type this command and press Enter
uv --versionMac: press ⌘ + Space, type Terminal, press Enter
Windows: open Start, type Windows PowerShell, then Open
Not installed: uv has no click-through installer. Copy the one-line command for your system (macOS or Windows) from uv’s official page into Terminal · no separate Python install needed; uv downloads it when required
When it’s done, close Terminal, open it again and run the same command. You should see a version number: uv --version
Install once; it works for everything that needs uv
Open the maker’s site, sign up and create an API key for the next step. Check the maker’s site for pricing and free plans.
These are program settings, not keys. No sign-up needed; fill them in as the maker describes.
LAGAAM_ALLOWED_TABLES Comma list of catalog.schema.table grants; the server will not start without itDescriptions are as written by the maker.
In the Lagaam settings, TRINO_PASSWORD, TRINO_JWT, PINOT_PASSWORD, LAGAAM_ALLOWED_TABLES is empty; add your key and save
Paste the key only into the app’s field, never into a chat or to anyone
Use Lagaam and tell me what you can do for me, then show me one thing✓ If VS Code says it is using Lagaam or shows a Lagaam tool in the answer, you are connected
The command above works without these. Add them only if you want to change something, following the maker’s description.
LAGAAM_ALLOW_ALL_TABLES true to run with no grant at all: an explicit opt-out, off by defaultLAGAAM_ENGINE Which adapter to run · default trinoTRINO_HOST Trino coordinator host · default localhostTRINO_PORT Trino coordinator port · default 8080TRINO_USER Trino user · default lagaamTRINO_HTTP_SCHEME http or https; unset means https once a password or JWT is set, else httpTRINO_VERIFY TLS cert check: true, false, or the path of a CA bundle (PEM) · default truePINOT_CONTROLLER_URL Pinot controller URL · default http://localhost:9000PINOT_BROKER_URL Pinot broker URL · default http://localhost:8000PINOT_USER Pinot user; unset means no authLAGAAM_AGENT_NAME Identity stamped on the audit trail · default anonymousLAGAAM_MAX_SCAN_BYTES Scan-bytes budget per query, checked before it runs (default 50 GiB) · default 53687091200LAGAAM_MAX_ROWS Scanned-row estimate budget per query; unset means ungatedLAGAAM_MAX_INTERMEDIATE_ROWS Rows the engine would build at its widest step, not rows returned, so a LIMIT doesn't lower it · default 50000000LAGAAM_MAX_RETURNED_ROWS Rows returned to the agent per query, capped at 100000; a bigger LIMIT in the query is lowered to it · default 1000LAGAAM_QUERY_TIMEOUT Wall-clock seconds per query · default 300LAGAAM_METADATA_TTL Metadata cache TTL, seconds · default 300LAGAAM_AUDIT_LOG Audit JSONL file path; unset means stderrDescriptions are as written by the maker.
Menu names checked against VS Code’s help page on Nov 11, 2026 · your screen may differ slightly by app version
Claude Code
claude mcp add --scope user lagaam --env LAGAAM_ALLOWED_TABLES=your-value --env TRINO_PASSWORD=your-value --env TRINO_JWT=your-value --env PINOT_PASSWORD=your-value -- uvx lagaamClaude Desktop (claude_desktop_config.json)
{
"mcpServers": {
"lagaam": {
"command": "uvx",
"args": [
"lagaam"
],
"env": {
"LAGAAM_ALLOWED_TABLES": "your-value",
"TRINO_PASSWORD": "your-value",
"TRINO_JWT": "your-value",
"PINOT_PASSWORD": "your-value"
}
}
}
}Cursor (~/.cursor/mcp.json)
{
"mcpServers": {
"lagaam": {
"command": "uvx",
"args": [
"lagaam"
],
"env": {
"LAGAAM_ALLOWED_TABLES": "your-value",
"TRINO_PASSWORD": "your-value",
"TRINO_JWT": "your-value",
"PINOT_PASSWORD": "your-value"
}
}
}
}VS Code (mcp.json)
{
"servers": {
"lagaam": {
"type": "stdio",
"command": "uvx",
"args": [
"lagaam"
],
"env": {
"LAGAAM_ALLOWED_TABLES": "your-value",
"TRINO_PASSWORD": "your-value",
"TRINO_JWT": "your-value",
"PINOT_PASSWORD": "your-value"
}
}
}
}LAGAAM_ALLOWED_TABLES required envLAGAAM_ALLOW_ALL_TABLES envLAGAAM_ENGINE envTRINO_HOST envTRINO_PORT envTRINO_USER envTRINO_PASSWORD secret required envTRINO_JWT secret required envTRINO_HTTP_SCHEME envTRINO_VERIFY envPINOT_CONTROLLER_URL envPINOT_BROKER_URL envPINOT_USER envPINOT_PASSWORD secret required envLAGAAM_AGENT_NAME envLAGAAM_MAX_SCAN_BYTES envLAGAAM_MAX_ROWS envLAGAAM_MAX_INTERMEDIATE_ROWS envLAGAAM_MAX_RETURNED_ROWS envLAGAAM_QUERY_TIMEOUT envLAGAAM_METADATA_TTL envLAGAAM_AUDIT_LOG envDescriptions are as written by the maker.
These settings are generated from the maker’s registry entry. If the README says otherwise, follow the README.
pypi: lagaamBased on how this server connects and on each app’s own docs, checked Nov 10, 2026.
Run on your computer in
ClaudeGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatRaycast
Runs on your computer; the tool list appears in your AI app after you install it.
We check information anyone can see; we have not read the code. Checks that do not apply are left out of the count. · Checked Nov 19, 2026
The registry name was verified with the GitHub account lagaam-ai, which owns the repo
Code last changed 13 days ago
Uses Apache-2.0
This one runs on your computer; there is no internet endpoint
Runs on your computer and uses local settings instead
Runs on your computer; we can only read tool lists from internet endpoints
No entries on OSV.dev for lagaam@1.0.0
Checks only this package version, not every dependency · checked Nov 15, 2026
If you made this, paste this code into your README. The badge links back to this page.
[](https://mcp.popnx.com/en/servers/lagaam-ai-lagaam)Ask, share a tip or report that it does not work. Sorted by what people marked helpful.
No posts yet. Be the first to ask or share.
Posts here are written by users, not the PopNx team.
No reviews yet
Compared with every active server in this category in the registry. Stars count only when the publisher owns the repo.
It passed 3 of 3 applicable basic checks. We have not read the code. Before adding a key or token, see what access the server asks for and use a key with only the permissions you need.
You need to fill in: TRINO_PASSWORD, TRINO_JWT, PINOT_PASSWORD
It runs on your computer. Your AI app starts it when needed, and data does not pass through the maker’s servers (unless it calls an online service itself).
The GitHub repo last changed 13 days ago, and the latest version (1.0.0) reached the registry 13 days ago.
Apps that support MCP, such as Claude Desktop, Claude Code, Cursor and VS Code. You also need Python (uv) on your computer.
In the same category: World Monitor, openstatus, Oh My Posh Validator, Strata, Jitsu
Same category, other makers, commands already checked. Official ones first, then by stars.
Reading a card:↓ Downloads per weeki★ GitHub starsiThree pillars: reviews · checks · usageiUpdated = latest version published to the registryi
Real-time global intelligence on conflict, markets, energy, trade, shipping and cyber. 100 tools.
Manage monitors, status pages, incidents and maintenances in your openstatus workspace.
Validate oh-my-posh configurations and segment snippets against the official schema.
MCP server for progressive tool usage at any scale (see https://klavis.ai)
Manage Jitsu data pipelines: destinations, streams, connections, functions, live events.
| This one Lagaam | World Monitor | openstatus | Oh My Posh Validator | Strata | Jitsu | |
|---|---|---|---|---|---|---|
| Runs where | Installs on your computer | Runs in the cloud, nothing to install | Runs in the cloud, nothing to install | Runs in the cloud, nothing to install | Runs in the cloud, nothing to install | Runs in the cloud, nothing to install |
| Needs a key | Yes | No | No | No | No | No |
| Add with + in Claude | No | No | No | No | No | No |
| Basic checks | 3/3 | 4/4 | 4/4 | 4/4 | 1/4 | 4/4 |
| License | Apache-2.0 | AGPL-3.0 | AGPL-3.0 | MIT | Apache-2.0 | MIT |
| Price | No cost listed in the registry | No cost listed in the registry | No cost listed in the registry | No cost listed in the registry | No cost listed in the registry | No cost listed in the registry |
Copied from the maker’s repo as written. PopNx MCP has not reviewed or endorsed it. HTML, images and scripts are removed. Links lead off this site.
One agent query shouldn't stall everyone's Trino. On a shared cluster, a missing partition filter or an accidental cross join doesn't cost you a bill — it costs everyone else their queries. Lagaam is an MCP server that sits between your AI agents and your lakehouse (Trino and Apache Pinot): every query is schema-grounded, priced from the engine's own plan *before* it runs, checked against a budget, and audited — and the bad one is refused before it runs, with a fix the agent can act on.
*Real session, real Trino, nothing mocked — reproduce it with uv run --project server python examples/demo.py.*
*Real session, real Pinot 1.5.1 realtime table, nothing mocked — reproduce it with uv run --project server python examples/demo_pinot.py.*
Agents write syntactically-valid, catastrophic SQL, and on a shared cluster the damage isn't theirs alone. A missing partition filter turns into a full scan that ties up every worker; an accidental cross join fills worker memory while everyone else's queries wait behind it; a retry loop runs it again. A SELECT * drags 40 columns into a context window that needed 2. The usual fix is to not give agents database access at all.
Lagaam gives them access with reins on:
EXPLAIN (TYPE IO) for the bytes it would scan, EXPLAIN (TYPE LOGICAL) for the widest row count any operator would build (the number a cross join blows and a LIMIT cannot hide). Over budget → blocked, with the number and the fix.SELECT only. No DDL/DML, no multi-statement injection, no SELECT *, no table-function passthrough, and a LIMIT is injected when missing. Validated SQL is re-rendered, so what runs is exactly what was checked.list_catalogs and describe_table return exact names, types, and row estimates — scoped to the agent's table grant, so the agent never learns names it isn't allowed to touch.It limits a query once it is running. Lagaam refuses it before it starts. Keep both.
| Acts | What the agent sees | Catches a cross join that reads little | |
|---|---|---|---|
query.max-scan-physical-bytes | during execution: terminated once the bytes are scanned | a query failure | no — it counts bytes read, not rows built |
query.max-execution-time | during execution: terminated after the time is spent | a query failure | only after it has held the cluster that long |
Resource groups (hardPhysicalDataScanLimit, softMemoryLimit, …) | on the *next* query: new queries queue once the group is over its share | its later queries wait | no — the running query continues |
| Lagaam | before execution, from EXPLAIN | a refusal with the number and the fix | yes — it prices the rows the widest step would build |
Measured on Trino 476: SELECT o.orderkey, l.partkey FROM tpch.tiny.orders o CROSS JOIN tpch.tiny.lineitem l LIMIT 10 reads 676,575 bytes by Trino's own plan — any scan cap above 0.7 MB lets it run — and would build 902,625,000 rows. Lagaam refuses it before it runs: *"This query would build 902,625,000 rows at its widest step, over your budget of 50,000,000 … a LIMIT will not help — join on a column with more distinct values, or filter each side before the join."*
Resource groups stay your backstop for everything that does reach the cluster; Lagaam is the gate in front of it for agent traffic.
They're good servers that do a different job: keep the agent read-only and bound what comes back. Lagaam does that too, and also prices the query first.
| Read-only | Row cap | Timeout | Checks the plan before running | |
|---|---|---|---|---|
| tuannvm/mcp-trino | on by default | results truncated while fetching (TRINO_MAX_ROWS) | during execution (TRINO_QUERY_TIMEOUT) | no — explain_query shows the agent a plan; it doesn't gate execute_query |
| startreedata/mcp-pinot | always on, parsed before execution | LIMIT rewritten before execution, paged results | during execution (PINOT_QUERY_TIMEOUT, 60 s) | no |
| bytebase/dbhub | opt-in (readonly): keyword check plus the database's own read-only transaction | opt-in (max_rows), injected as LIMIT/TOP | opt-in (query_timeout), during execution | no — opt-in explain_sql shows a plan; it doesn't gate execute_sql |
| Lagaam | always on, parsed before execution | 1,000 by default; a bigger LIMIT is lowered before it runs | during execution (LAGAAM_QUERY_TIMEOUT, 300 s) | yes — scan bytes and widest-step rows from EXPLAIN; over budget is refused |
11 queries an LLM agent plausibly writes — full scans, SELECT *, DDL, injection attempts, oversized joins, out-of-grant reads. A raw MCP wrapper submits all of them to the engine. Lagaam stops 11/11 before execution while the well-scoped control query runs untouched. Reproduce: benchmarks/catch_rate.py → results.
Against the Trino you already have (TRINO_PORT / TRINO_USER if yours aren't 8080 / lagaam):
TRINO_HOST=trino.internal LAGAAM_ALLOWED_TABLES=hive.sales.orders uvx lagaam # MCP server on stdio
Or try it on a demo warehouse:
git clone https://github.com/lagaam-ai/lagaam && cd lagaam
docker compose -f examples/docker-compose.yml --profile trino up -d # demo warehouse cd server && uv sync LAGAAM_ALLOWED_TABLES=tpch.tiny.orders,tpch.tiny.lineitem \ uv run python -m lagaam # MCP server on stdio
For Pinot, --profile pinot brings up the batch quickstart and --profile pinot-realtime up -d brings up a Kafka-fed streaming one — run examples/pinot-realtime/bootstrap.sh after it to create the topics, tables and feed. Then start the server with LAGAAM_ENGINE=pinot.
Wire it into any MCP client (Claude Code, Claude Desktop, or your own agent):
{
"mcpServers": { "lagaam": { "command": "uvx", "args": ["lagaam"], "env": { "TRINO_HOST": "localhost", "LAGAAM_MAX_SCAN_BYTES": "5368709120", "LAGAAM_ALLOWED_TABLES": "hive.sales.orders,hive.sales.customers" } } } }
In Claude Code, install it as a plugin instead:
/plugin marketplace add lagaam-ai/lagaam
/plugin install lagaam@lagaam
It asks for the tables to allow (LAGAAM_ALLOWED_TABLES) and your Trino host, port and user (localhost / 8080 / lagaam if you leave them). From a shell, pass them as flags:
claude plugin marketplace add lagaam-ai/lagaam
claude plugin install lagaam@lagaam \ --config allowed_tables=hive.sales.orders --config trino_host=trino.internal
On Pinot, pick engine=pinot and set the controller and broker URLs (http://localhost:9000 / http://localhost:8000 if you leave them):
claude plugin install lagaam@lagaam --config engine=pinot \
--config allowed_tables=pinot.default.baseballStats \ --config pinot_controller_url=http://pinot.internal:9000 \ --config pinot_broker_url=http://pinot.internal:8099
Other LAGAAM_* settings, the Trino login (TRINO_PASSWORD or TRINO_JWT, plus TRINO_VERIFY for a private CA), and PINOT_USER / PINOT_PASSWORD for a Pinot with auth, are read from the environment you start claude in, so a password never sits in the plugin's config.
The agent gets three tools — list_catalogs, describe_table, query_data — and cannot reach the engine any other way.
| Env var | Meaning | Default |
|---|---|---|
LAGAAM_ALLOWED_TABLES | Comma list of catalog.schema.table grants | required |
LAGAAM_ALLOW_ALL_TABLES | true to run with no grant at all | off |
LAGAAM_AGENT_NAME | Identity stamped on the audit trail | anonymous |
LAGAAM_MAX_SCAN_BYTES | Scan-bytes budget per query, pre-execution | 50 GiB |
LAGAAM_MAX_ROWS | Scanned-row estimate budget per query | ungated |
LAGAAM_MAX_INTERMEDIATE_ROWS | Rows the engine would *build* at its widest step — not rows returned, so a LIMIT doesn't lower it | 50,000,000 |
LAGAAM_MAX_RETURNED_ROWS | Rows returned to the agent per query — unset, the server applies its own 1000-row cap, and a bigger LIMIT in the query is lowered to it before it runs | 1000 (max 100000) |
LAGAAM_QUERY_TIMEOUT | Wall-clock seconds per query | 300 |
LAGAAM_METADATA_TTL | Metadata cache TTL, seconds | 300 |
LAGAAM_AUDIT_LOG | Audit JSONL file path | stderr |
LAGAAM_ENGINE | pinot to run the native Pinot adapter | trino |
PINOT_CONTROLLER_URL / PINOT_BROKER_URL | Pinot controller and broker | http://localhost:9000 / http://localhost:8000 |
PINOT_USER / PINOT_PASSWORD | Basic-auth login for Pinot | unset (no login) |
TRINO_HOST / TRINO_PORT / TRINO_USER | Trino coordinator | localhost / 8080 / lagaam |
TRINO_PASSWORD | Password for TRINO_USER, for a cluster that wants a login | unset (no login) |
TRINO_JWT | JWT to log in with instead of a password — set one or the other, not both | unset |
TRINO_HTTP_SCHEME | http or https | https once a password or JWT is set, else http |
TRINO_VERIFY | Check the cluster's TLS cert: true, false, or the path of your CA bundle (PEM) for a private CA | true |
A shared Trino with a login works the same way. Set TRINO_PASSWORD (or TRINO_JWT) and lagaam talks https, since Trino won't take a password over plain http; set TRINO_PORT to the cluster's https port too (often 443 or 8443). A login the cluster refuses tells the agent so, without the password, and a password and a JWT both set stop the server at startup rather than guessing which one you meant. Try it locally against a Trino that wants both: examples/trino-auth/setup.sh, then docker compose -f examples/docker-compose.yml --profile trino-auth up -d.
The server will not start without `LAGAAM_ALLOWED_TABLES`. An agent that can reach every table in every catalog is the thing this exists to prevent, so that has to be asked for — set LAGAAM_ALLOW_ALL_TABLES=true if you mean it.
The budget dimensions above apply whether or not you set them. Leaving LAGAAM_MAX_SCAN_BYTES and LAGAAM_MAX_INTERMEDIATE_ROWS unset gives you their defaults, not an open gate — an unconfigured server refuses what it cannot afford rather than waving it through. If queries are being denied and you expected no limits, that is why; raise the dimension you mean to raise.
Cost quotes come from the engine's own plan estimates, and those need tab