nlweb-tools-framework

nlweb-tools-framework is a skill for Claude Code from OrcaQubits/agentic-commerce-skills-plugins. It costs 100 tokens per session (2,039 once invoked), scanned A, original, MIT.

A guide to building NLWeb tools, which are handlers that turn a user's question into a specific operation such as search, comparison, item details, or recipe substitution. It explains how tools are selected and configured for different content types.

In plain words
What is it for?
Use it to configure tools, route questions with the tool selector, reuse built-in handlers, and write custom handlers for new operations.
Why use it?
It provides a consistent way to add specialized question handling instead of putting every behavior into one general request handler.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter.

Part of the nlweb-protocol plugin — 13 skills, 1 agent shipped together

Good fit Use it to configure tools, route questions with the tool selector, reuse built-in handlers, and write custom handlers for new operations.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/orcaqubits/agentic-commerce-skills-plugins/nlweb-tools-framework
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add OrcaQubits/agentic-commerce-skills-plugins --skill nlweb-tools-framework
Clone the repo
git clone --depth 1 https://github.com/OrcaQubits/agentic-commerce-skills-plugins

Made for: Claude Code.

Or install nlweb-protocol, the plugin that ships this one along with the rest of its 13 skills, 1 agent.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for nlweb-tools-framework

README.md
[![agentmods](https://agentmods.dev/badge/skills/orcaqubits/agentic-commerce-skills-plugins/nlweb-tools-framework/github.svg)](https://agentmods.dev/skills/orcaqubits/agentic-commerce-skills-plugins/nlweb-tools-framework)
Your own site
<a href="https://agentmods.dev/skills/orcaqubits/agentic-commerce-skills-plugins/nlweb-tools-framework"><img src="https://agentmods.dev/badge/skills/orcaqubits/agentic-commerce-skills-plugins/nlweb-tools-framework/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for nlweb-tools-framework

Your own site · 80×15
<a href="https://agentmods.dev/skills/orcaqubits/agentic-commerce-skills-plugins/nlweb-tools-framework"><img src="https://agentmods.dev/badge/skills/orcaqubits/agentic-commerce-skills-plugins/nlweb-tools-framework.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 100 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,039 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00100 $0.02039
Opus 5 $0.00050 $0.01019
Sonnet 5 $0.00020 $0.00408
Haiku 4.5 $0.00010 $0.00204

Measured 2d ago against content hash ee9727545844, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-16, from the pricing page.

Security

Grade A, and why

nlweb-tools-framework scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

curl 'http://localhost:8000/ask?query=test&site=X&streaming=false&forced_tool=your_tool'
nlweb-protocol/skills/nlweb-tools-framework/SKILL.md · 181 lines

How it starts

The opening of the file, as written. The whole thing — 181 lines — stays where its author put it; the contents beside it link to each section on GitHub.

NLWeb Tools Framework

Config layout changed upstream. NLWeb replaced the single site_types.xml with two files in config/: sites.xml (site name → itemType list + description) and tools.xml (per-site / per-type tool definitions, prompts and examples, scoped by <Site id="…"> / <Item> blocks). Older guidance — including any site_type / extends inheritance syntax — describes the retired file. Fetch config/sites.xml and config/tools.xml from the live repo before editing anything.

Before writing code

Fetch live docs:

  1. Fetch https://github.com/nlweb-ai/NLWeb/blob/main/docs/tools.md for the canonical tools framework reference.
  2. Fetch https://github.com/nlweb-ai/NLWeb/blob/main/config/sites.xml for the per-type tool inheritance tree.
  3. Read AskAgent/python/core/router.py::ToolSelector for how routing actually picks a tool.
  4. Read existing handlers in AskAgent/python/methods/: generate_answer.py, item_details.py, compare_items.py, ensemble_tool.py, recipe_substitution.py, accompaniment.py.
  5. Fetch https://github.com/nlweb-ai/NLWeb/blob/main/docs/nlweb-prompts.md for the <returnStruc> JSON contract that handlers must satisfy.

Conceptual Architecture

What a "Tool" Is in NLWeb

Confusingly, "tool" means two different things in NLWeb depending on context:

  1. Internal tool / handler — a Python module in methods/ that the ToolSelector routes a query to (e.g., compare_items.py). This is the meaning used in this skill.
  2. MCP tool — the JSON-RPC tool exposed at /mcp (ask, list_sites, who). See the nlweb-mcp-server skill for that meaning.

When NLWeb's docs say "tools framework," they mean (1).

The Tool Routing Flow

For every /ask request:

  1. ToolSelector (core/router.py) inspects the decontextualized query + detected Schema.org type.
  2. It consults tools.xml / tools.xml for the candidate tools for that type.
  3. It makes an LLM call (with a strict <returnStruc> JSON output schema) asking "which tool fits?"
  4. The selected handler in methods/<tool>.py is invoked.
  5. The handler runs retrieval + ranking + any tool-specific logic, then emits results.

Read the full file on GitHub · 181 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 181 lines · 100 tokens per session scan A ee9727545844

Subscribe to this mod's changes

nlweb-tools-framework is a skill published in the GitHub repository OrcaQubits/agentic-commerce-skills-plugins (39 stars, last pushed 2d ago), licensed MIT. It adds 100 tokens to every session and 2,039 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-15.

Related

Other skills, from other repositories

archestra-dev-llm-providers

Use when adding an LLM provider, changing proxy adapters or provider routes, fixing streaming/tool-call translation bugs, editing model fetchers or model handling, or touching provider credentials/enums and model constants.

archestra-ai/archestra · 49 tokens

chaingpt

Build with the ChainGPT Web3 AI developer platform. Full API/SDK reference and project scaffolding for: Web3 AI Chatbot & LLM, AI NFT Generator, Smart Contract Generator, Smart Contract Auditor, AI Crypto News, AgenticOS Twitter agents, and Solidity LLM. Use when building blockchain apps, Web3 chatbots, NFT tools…

internet-court/internet-court-skill · 132 tokens

switchboard

Complete Switchboard Oracle Protocol SDK for Solana - the permissionless oracle solution for price feeds, on-demand data, VRF randomness, and real-time streaming via Surge. Covers TypeScript SDK, Rust integration, Oracle Quotes, and all Switchboard tools.

internet-court/internet-court-skill · 54 tokens

0g-compute

0G Compute Network guide for decentralized AI inference, fine-tuning, and GPU services. Covers chatbots, image generation, speech-to-text, SDK integration (0g-serving-broker), processResponse API, broker.inference methods, CLI commands (0g-compute-cli), and account management. Use this skill for any 0G compute, 0G AI…

internet-court/internet-court-skill · 85 tokens

near-ai-cloud

NEAR AI Cloud private inference and verification. Use when integrating NEAR AI Cloud API for verifiable private AI inference, verifying model or gateway TEE attestation (NVIDIA NRAS, Intel TDX), verifying chat message signatures, implementing end-to-end encrypted chat, or using the OpenAI-compatible API with NEAR AI…

internet-court/internet-court-skill · 71 tokens

omni-compression

Configure RTK (command output), Caveman (prose), and stacked compression modes. Manage language packs, custom rules, and test prompt compression reducing tokens by 60–90%.

diegosouzapw/OmniRoute · 42 tokens