用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/varunr89/claude-marketplace --skill flight-search命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
正在显示 SKILL.md
基于 SOC 职业分类
| name | flight-search |
| description | Search and score multi-leg flight itineraries using Duffel API with cost-duration-stop optimization |
Searches for multi-leg flight itineraries (e.g., Seattle -> Milan -> Hyderabad -> Seattle) using the Duffel API (with optional fast-flights Google Flights scraper fallback). Applies hard constraints and a weighted scoring model to rank results.
Use this skill when the user wants to search for flight options across multiple legs with constraint filtering and convenience-adjusted scoring.
DUFFEL_API_KEY=<your-key> python3 ${CLAUDE_PLUGIN_ROOT}/scripts/flight_optimizer.py
The script currently targets a specific trip (SEA -> MXP -> HYD -> SEA), but the functions are reusable for any multi-leg itinerary.
| Variable | Required | Description |
|---|---|---|
DUFFEL_API_KEY | Yes | Duffel API access token (live or test mode) |
The optimizer applies hard constraints to filter out unsuitable flights:
MAX_STOPS)MAX_LAYOVER_HOURS)Each flight leg is scored as:
leg_score = price + (duration_hours * $20) + (stops * $200)
Complete itineraries add a childcare penalty:
total_score = sum(leg_scores) + (weekdays_away * $200)
Scoring weights are configurable constants: COST_PER_HOUR, COST_PER_STOP, COST_PER_WEEKDAY.
The optimizer tries two strategies and ranks all results together:
flight_results_spring2026.json (top 30 itineraries)