Skip to main content
Glama

Tawadoo

smart_search

Read-onlyIdempotent

Searches Tawadoo marketplace listings. Use it when the user asks to find, browse, compare or get recommendations for listings in this category, with or without a budget or preferences. It returns the matching listings with title, price, location, date and link, and the total number of matches. The result is shown in a widget: every listing appears as a card with its photo, price and link, and a View all button opens the full search results page. Do not list the listings again and do not show or add images. Reply in a few sentences that compare or advise about those listings and ask a useful follow-up question. For more results, point the user to the View all button in the widget. Search Tawadoo in one call — automatic category resolution + product search.

Use this when the user gives a broad or ambiguous request and no static vertical tool clearly applies. The server resolves the matching category within a bounded search budget, uses cacheable taxonomy metadata, and returns ranked results ready to evaluate.

Relevant results include auto_display.items, so the widget can render directly from this search response. Call display_recommendations only when you need to curate, reorder, or combine final listings.

smart_search is generic. It does not contain language-specific synonym tables or category-specific business rules. You are responsible for interpreting the user's natural language before calling.

Do not use smart_search for a completely categoryless recommendation request such as "what do you recommend on the site?" when the user gives no product type, use case, budget, or preference. Ask one short clarifying question rather than choosing a category.

When to use

Situation

Use

Request clearly maps to a major vertical

Use the static vertical tool directly

Broad, ambiguous, or cross-category request

Use smart_search

Structured criteria + clear vertical

Use the vertical tool — do not start with smart_search

If a brand/model is paired with an implied product vertical, use the static vertical tool rather than smart_search. smart_search is for unresolved category discovery; it can legitimately surface cross-category matches when the query is only a brand/model with no product type.

If smart_search resolves the wrong category branch, correct silently with the appropriate vertical tool. Never tell the user that smart_search confused categories or resolved the wrong branch.

If the exact same request with the same locale and filters was already answered in this conversation, reuse that result rather than calling again. Re-call only when locale, budget, filters, or page changed.

Before calling — decompose the request

  • Hard criteria (brand, model, capacity, price, fuel type, rooms): keep these in query or pass as params; do not drop them silently

  • City / location: never put it in query, properties, or any other filter param — smart_search has no location filter, and a city name is matched as literal search text against listing titles/descriptions, which pollutes results with unrelated listings that merely mention that city. Handle location entirely after the call, by highlighting results whose returned location_label matches the user's city.

  • Soft criteria (condition words: new, like new, clean, no scratches): use a broad query for recall; explain the condition caveat in your answer

  • Broad recommendation wording ("good value", "rapport qualité prix", "pas cher mais bien"): search for the core object (query="smartphone"), not the recommendation words; compare returned listings by price, condition, and negotiability

query must be short and verbatim-safe. Before including any word, apply this test: "Would this word appear in a listing title or structured property field?" If no, omit it. Keep query to 1–4 terms.

  • User context (situation, usage, lifestyle) → interpret it, then drop it from query

  • Quality adjectives (fiable, économique, propre, bon état) → omit; they appear in some descriptions but not all, and their absence lowers the relevance score unfairly

  • Budget amounts → pass as the budget param, never in query

For broad category searches (user wants "a car", "a phone" with few hard constraints): use 1–2 core product nouns only. A long query inflates query_term_count and can push the match ratio below the relevance threshold even when matching listings exist.

If is_relevant=false, check whether query was too long or contained words unlikely to appear verbatim in listings. If so, retry once with a shorter, core-noun-only query.

For storage or unit wording, normalize before calling: 128go, 128 Go, 128GB, 128 GB, 128 جيغا are the same user intent.

What happens server-side

  1. Fetches cached root categories → picks likely branches for query

  2. Explores child categories and property-backed result variants

  3. Optionally tests deeper branches within the configured probe budget

  4. Runs compare with the resolved category ids and returns ranked results

Evaluate results

Check relevance_assessment first:

Result

Action

is_relevant=true

Proceed — use recommendations

is_relevant=false

Stop. Tell the user no relevant listing was found on Tawadoo for this request.

recommendations empty

Treat as no results unless the user explicitly asked for similar listings

When there are no results: do not mention rejected categories, technical mismatches, partial results, or close listings. Do not give generic market advice. Offer at most 1–3 short broadening directions — without naming any product, brand, or model:

  • "I can search with a looser condition"

  • "I can widen to nearby cities"

  • "I can look at a related category on Tawadoo"

If the user accepts a broadening direction, run a new tool call for that broader intent.

After this tool returns relevant results, do not call another search tool just to improve or verify the answer. Pick from recommendations/normalized_items, rely on auto_display when it matches your final picks, and call display_recommendations only to curate, reorder, or combine final selected product_url values. Do not call display_recommendations for no-results, weak, diagnostic, or exploratory results.

Responding with listings

Every product you mention must be a Markdown link: [Title](<product_url>). Angle brackets around the URL are required — URLs can end with _ or - and renderers may strip trailing characters without them.

Format for each listing:

Title — Price | location_label | Date: freshness_label | Negotiable / Not negotiable Why this is a good fit: [personalized explanation]

Always show location_label. If the field is empty, write "Location not specified". Never mention a listing without its location_label.

Always show the listing date. Use freshness_label if present, otherwise published_at. If neither is available, write "Date not specified".

If this tool fails or returns weak results, say so plainly and offer to refine the search.

Args

  • query: product-type terms only — what the product IS. Interpret the user's context first, then pass only the resulting product attributes.

  • minp / maxp: optional price range. Pass maxp=budget only when the user insists on strict filtering.

  • budget: user's exact target budget. Enables within_budget and negotiation_opportunity per item. The server automatically sets maxp to 120% to surface negotiable over-budget listings.

  • is_negotiable: filter to negotiable listings only

  • locale: "fr", "en", or "ar". Use "en" for unsupported languages. Detect from the user's sentence context — not from isolated tokens like GB, Go, iPhone, or BMW.

  • page: page number starting at 1. Use page=2 when the user asks for more results.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "query": "<query>"
    },
    "name": "smart_search"
  }
}

Input Schema

NameRequiredDescriptionDefault
maxpNo
minpNo
pageNo
queryYes
budgetNo
localeNofr
is_negotiableNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.3/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=true, idempotentHint=true and closed-world, so safety is covered; the description still adds substantial undisclosed behavior: server-side taxonomy probing within a budget, cache reuse of prior identical calls, and the is_relevant/relevance_assessment gate that should stop the conversation. However, much of the length is spent on response formatting and widget choreography rather than on how the tool itself behaves, and the retry/correction rules drift into agent-protocol territory.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness2/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Purpose is front-loaded, but the definition is roughly five times the length needed, with a long 'Responding with listings' formatting template, repeated instructions not to re-list or re-display results, and duplicated guidance about display_recommendations appearing in at least three places. The signal is good but heavily diluted, forcing the agent to parse response-authoring rules before it can call the tool.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Despite an output schema existing, the definition supplies the interpretive layer the schema cannot: the relevance gate, no-results handling, broadening directions, and the widget/display split. For a tool whose correctness depends on judging result quality, nothing an agent needs in order to call and act on it is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, so the description carries the full burden and does: query is limited to 1–4 verbatim-likely product nouns and explicitly must exclude city, budget and quality adjectives; budget triggers within_budget/negotiation_opportunity and auto-sets maxp to 120%; minp/maxp are the strict-filter alternative; locale accepts fr/en/ar with a detect-from-context rule; page starts at 1. Every one of the 7 params is given meaning beyond its type.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Opens with a specific verb+resource ('Searches Tawadoo marketplace listings') and immediately frames its role relative to the static vertical siblings: it is the generic, ambiguous-query path while a clear vertical should use the dedicated tool. An agent can pick between smart_search and search_vehicles/search_high_tech without opening any schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Contains an explicit routing table (clear vertical → vertical tool; broad/ambiguous → smart_search; structured criteria → vertical tool), a when-not rule for categoryless requests ('ask one short clarifying question'), a caching/re-call rule, and a single retry rule after is_relevant=false. Alternatives and exclusions are both named.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.