Frequently asked questions
Quick Links
- NLWeb vs MCP vs A2A?
- What's the difference between 'ask' and 'await'?
- How does NLWeb handle context across multiple queries?
- What response types can an NLWeb agent return?
- What's the deal with this site design?
Q: NLWeb vs MCP vs A2A?
The major difference is that NLWeb is designed for text-in, text-out natural language interactions. You don't need to understand how to call specific tools, define parameters, or handle complex tool schemas. Just ask in natural language and get structured responses back. In contrast, MCP and A2A are protocols where you need to understand available tools, their schemas, and how to invoke them correctly. NLWeb abstracts away this complexity by providing a unified 'ask' interface. NLWeb is also transport-protocol agnostic and can work over HTTP, WebSockets, JSON-RPC, or within agentic protocols like MCP and A2A, making it complementary to these protocols rather than competing with them.
Q: What's the difference between 'ask' and 'await'?
'ask' is the primary API for querying an NLWeb agent with a natural language request. It can return immediate answers, elicitations (requests for more information), promises (for long-running tasks), or failures. 'await' is a helper API used to check the status of or cancel a long-running task that returned a promise. You use 'ask' to make your initial request, and if you receive a promise token back, you use 'await' with that token to check on the task's progress or get the final result.
Q: How does NLWeb handle context across multiple queries?
NLWeb treats context as a first-class object in both requests and responses. The request can include a 'context' section with conversation history (prev queries), free-form contextual text, and persistent user preferences or memory. The response includes a 'session_context' in the meta section that should be included in subsequent requests, similar to HTTP cookies. This enables agents to maintain conversational state, understand references to previous queries, and personalize responses based on accumulated user information.
Q: What response types can an NLWeb agent return?
An NLWeb agent can return four types of responses:
- Answer - provides the requested information or confirms task completion with structured results
- Elicitation - requests additional information from the user when the query is ambiguous or incomplete
- Promise - returns a token for long-running operations that can be checked later using the 'await' API
- Failure - indicates an error occurred with an error code and message
The response type is specified in the '_meta.response_type' field.
Q: What's the deal with this site design?
This CSS has a lineage. It was originally created for the Sitemaps protocol site, then adopted by Schema.org, and now lives on at NLWeb.ai. Three generations of web standards, one stylesheet. Thanks Shiva Shivakumar.