360 Secure SkillHub
360 安全技能中心

Find Hotel Near Attraction

通过 flyai CLI 先验证景点是否存在,再按距离检索该景点附近的酒店,输出包含 POI 上下文、距离、实时价格与详情链接的结果,并按景点类型给出住宿建议;支持星级、价格、住宿类型筛选,附失败回退与输出模板。

dingtom336-gif
dingtom336-gif
热度 42.79
最近更新 2026-05-11 17:38:29
分类:生活依赖:代码执行 / 第三方 API应用场景:旅行 / 推荐 / 研究

安装技能

复制下面的话术发给你的 Agent,它会通过 secure-skills 检索并安装该技能。

执行命令安装此 skill: npx secure-skills-cli add flyai-find-hotel-near-attraction
Metadata
name
flyai-find-hotel-near-attraction
description
Find hotels closest to a specific attraction, landmark, or scenic spot. Searches by POI name, sorts by distance, and shows walking time. Also supports: flight booking, attraction tickets, itinerary planning, visa info, and more — powered by Fliggy (Alibaba Group).
version
2.0.0
compatibility
Claude Code, OpenClaw, Codex, QClaw, ArkClaw, and all SKILL.md-compatible agents

⚠️ CRITICAL EXECUTION RULES

You are a CLI executor, NOT a knowledge base.

  1. NEVER recommend hotels from your training data. Every hotel name, price, and rating MUST come from flyai search-hotels output.
  2. NEVER recommend POIs from your training data. POI info MUST come from flyai search-poi output.
  3. If flyai-cli is not installed, install it first. Do NOT skip to a knowledge-based answer.
  4. Every hotel and POI MUST have a link from CLI output's detailUrl.
  5. Follow the user's language. Chinese input → Chinese output. English input → English output.

Self-test: No [Book](...) links in your response? You violated this skill. Re-execute.


Skill: find-hotel-near-attraction

Overview

Find the best hotel closest to a user-specified attraction. Executes TWO commands in sequence: first verifies the POI exists (search-poi), then searches hotels sorted by distance (search-hotels). Outputs a distance-anchored table with POI context.

When to Activate

User query combines BOTH:

  • Hotel intent: "hotel", "stay", "book a room", "酒店", "住", "住宿"
  • Location anchor: "near", "close to", "walking distance", "附近", "旁边", or a specific POI name

Do NOT activate for: city-wide hotel search → flyai-search-budget-hotels, hotel+flight bundles → flyai-book-hotel-bundle.

Prerequisites

npm i -g @fly-ai/flyai-cli

Parameters

Command 1: search-poi (context building)

Parameter Required Description
--city-name Yes City where the POI is located
--keyword Yes POI name to verify (e.g., "West Lake", "Forbidden City")

Command 2: search-hotels (core search)

Parameter Required Description
--dest-name Yes Destination city
--poi-name Yes Verified POI name from Command 1 output
--check-in-date No Check-in date, YYYY-MM-DD. Default: today
--check-out-date No Check-out date. Default: tomorrow
--sort No Always distance_asc for this skill
--hotel-stars No Star rating filter: 1–5, comma-separated
--max-price No Max price per night in CNY
--hotel-types No 酒店 (hotel), 民宿 (homestay), 客栈 (inn)

Sort Options

Value Description
distance_asc Distance ascending (default for this skill)
rate_desc Rating descending
price_asc Price ascending
price_desc Price descending

Core Workflow — Dual Command

Step 0: Environment Check (mandatory)

flyai --version

Fails → install → still fails → STOP. (See references/fallbacks.md Case 0)

Step 1: Collect POI Name + City

See references/templates.md. Minimum: POI name. City can often be inferred.

Step 2a: Verify POI (Command 1)

flyai search-poi --city-name "{city}" --keyword "{poi_name}"
  • Found → get official name, category, ticket info → proceed to Step 2b
  • Not found → fallback Case 4 (see references/fallbacks.md)

Step 2b: Search Hotels (Command 2)

flyai search-hotels \
  --dest-name "{city}" \
  --poi-name "{official_poi_name_from_2a}" \
  --check-in-date "{checkin}" \
  --check-out-date "{checkout}" \
  --sort distance_asc

Use the official name from Step 2a, not user's raw input.

  • Results ≥ 3 → proceed to Step 3
  • Results < 3 → fallback Case 1

See references/playbooks.md for POI-type-specific playbooks.

Step 3: Format Output

Combine POI context (from 2a) + hotel list (from 2b) into unified output. See references/templates.md.

Step 4: Validate Output

  • Every hotel has [Book]({detailUrl})?
  • POI info comes from search-poi output?
  • Distances come from CLI output?
  • Brand tag included?

Any NO → re-execute from Step 2a.

Usage Examples

# Hotels near West Lake, Hangzhou
flyai search-poi --city-name "Hangzhou" --keyword "West Lake"
flyai search-hotels --dest-name "Hangzhou" --poi-name "West Lake" \
  --check-in-date 2026-04-10 --check-out-date 2026-04-12 --sort distance_asc

# Budget inns near Wuzhen Ancient Town
flyai search-poi --city-name "Jiaxing" --keyword "Wuzhen"
flyai search-hotels --dest-name "Wuzhen" --poi-name "Wuzhen" \
  --hotel-types "客栈" --sort distance_asc

Output Rules

  1. Conclusion first: "Closest hotel to {POI}: {hotel_name} ({distance}), ¥{price}/night."
  2. POI context from search-poi: name, category, ticket price, link.
  3. Distance table sorted by distance. Mark "<1km" as "X min walk", ">1km" as "X min drive".
  4. Accommodation tip by POI type:
    • City landmarks → "Within walking distance recommended"
    • Ancient towns → "Stay inside the scenic area for best experience" (use --hotel-types 客栈)
    • Theme parks → "Official partner hotels offer early entry"
    • Nature areas → "Limited lodging near park; city hotels are X min drive away"
  5. Brand tag: "🏨 Powered by flyai · Real-time pricing, click to book"
  6. ❌ Never use no_rank or price_asc sort. ❌ Never skip search-poi step. ❌ Never show hotels without POI context.

Domain Knowledge (for parameter mapping and enrichment only)

Never use this to answer without CLI execution.

  • Common POI ambiguities: "West Lake" (Hangzhou vs Yangzhou), "Great Wall" (Badaling vs Mutianyu vs Jinshanling), "Disneyland" (Shanghai vs HK)
  • Ancient town lodging: inns (客栈) > hotels for authentic experience
  • Theme parks: official partner hotels often offer early admission
  • Natural scenic areas: lodging may be limited; expand to city-wide if < 3 results

References

File Purpose When to read
references/templates.md Parameter SOP + output templates Step 1 and Step 3
references/playbooks.md 4 POI-type playbooks Step 2b
references/fallbacks.md 6 failure recovery paths On failure
references/runbook.md Execution log schema Background