Route Optimization logo

Route Optimization

Community
dotanminh
route-optimization

Use when direct flights are expensive and traveler is open to layovers. Triggers on cheaper route, alternative routing, transit hub, is a layover worth it, save money with connection.

Overview

Publisherdotanminh
Repositorytravel-optimization-engine
Skill nameroute-optimization
Stars
40
Forks
29
Bundled files
2
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 2 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by dotanminh on GitHub. Read the source before you install it.

Installation

Install the Route Optimization AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/dotanminh/travel-optimization-engine/tree/master/skills/route-optimization
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/dotanminh/travel-optimization-engine.git /tmp/travel-optimization-engine
mkdir -p .claude/skills
cp -r /tmp/travel-optimization-engine/skills/route-optimization .claude/skills/route-optimization
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Route Optimization in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Route Optimization on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Route Optimization is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Route Optimization - Tối Ưu Lộ Trình Qua Điểm Trung Chuyển

Purpose

Most travelers search for direct flights by default. They don't know that routing through a strategic hub can save $200-500 with only 2-3 extra hours. This skill quantifies that trade-off precisely: "Is $350 savings worth 2.5 extra hours?"

Input Required

  • origin, destination (IATA codes)
  • baseline_price and baseline_duration from flight-search (direct/fastest option)
  • travel_purpose from profile (business travelers value time more)
  • risk_tolerance from profile

Execution Steps

Step 1: Establish Baseline

The baseline is the direct or fastest route found by flight-search:

BASELINE: HAN → SFO
  Price: $1,100 | Duration: 13.5h (direct, VN Airlines)
  This is the benchmark everything else is compared against.

Step 2: Identify Strategic Hubs

Based on the origin-destination pair, select top hub candidates:

Decision logic for hub selection:

O&D RegionTop Hubs to CheckWhy
Vietnam → US WestICN, NRT, TPE, HKGShort detour, competitive pricing
Vietnam → US EastDOH, IST, ICNMiddle East hubs or Pacific routing
Vietnam → EuropeIST, DOH, DXB, BKKTurkish=cheapest, Gulf=quality
Vietnam → OceaniaSIN, KUL, BKKLCC connections available
Vietnam → JapanTPE, HKGShort detour for cheaper fares
Intra-VietnamNo hubs neededDirect always optimal

Step 3: Calculate Each Alternative Route

For each hub route, compute:

savings_usd     = baseline_price - hub_route_price
extra_hours     = hub_route_duration - baseline_duration
savings_per_hour = savings_usd / extra_hours

Value rating system:

$/hour savedRatingRecommendation
> $100/hr⭐⭐⭐ ExcellentAlways worth it
$50-100/hr⭐⭐ GoodWorth it for most travelers
$25-50/hr⭐ AcceptableWorth it if flexible
< $25/hr❌ PoorOnly for extreme budget

Step 4: Flag Special Considerations

For each alternative route, check:

  1. Transit visa required?

    • China (PEK/PVG): YES - Transit visa needed for most nationalities
    • Japan (NRT/HND): NO - Transit without visa up to 72h
    • Korea (ICN): NO - Transit without visa, KTAV required
    • Singapore (SIN): NO - Transit up to 96h
    • Turkey (IST): NO - Most nationalities okay
  2. Ground transportation needed?

    • Some "hub" routes require train/bus between airports
    • Flag with cost estimate (e.g., "Train FRA→city center €4, taxi €35")
  3. Minimum connection time?

    • International-International: min 2h (recommended 3h)
    • Different terminal: add 1h buffer
    • Immigration required at hub: add 1.5h
  4. Layover quality?

    • IST: Excellent (lounges, transit hotel, long opening hours)
    • SIN: Excellent (Jewel, free city tour)
    • ICN: Excellent (transit hotel, culture center)
    • DOH: Very good (Al Maha lounge, transit hotel)
    • BKK: Good but terminal change can be tiring

Step 5: Present Results

ROUTE ALTERNATIVES vs BASELINE: HAN → SFO ($1,100, 13.5h)

#  Via Hub    Price   Saved   Extra Time  $/Hour   Rating
1  ICN       $750    $350    +3.0h       $117/hr  ⭐⭐⭐ Excellent
2  NRT       $820    $280    +2.5h       $112/hr  ⭐⭐⭐ Excellent
3  TPE       $790    $310    +4.0h       $78/hr   ⭐⭐ Good
4  IST       $680    $420    +8.0h       $53/hr   ⭐⭐ Good
5  BKK+NRT   $620    $480    +12.0h      $40/hr   ⭐ Acceptable

RECOMMENDATION (moderate risk tolerance):
  Route via ICN: Best value at $117/hr saved.
  You save $350 and only add 3 hours (1 layover at Incheon, one of Asia's
  best airports with transit hotel and free showers).

NOTE: Route 5 involves ground+air combination. See details below.

Step 6: Ground Transport Flag

If any route involves non-flight segments:

⚠️ GROUND TRANSPORT REQUIRED:
  Route 5 (BKK+NRT): Requires separate VietJet HAN→BKK, then
  overnight in Bangkok, then BKK→NRT→SFO next day.
  Additional costs: Hotel $30-50, airport transfer $10-15
  Net savings after ground costs: $415-445

Traveler Type Adjustments

ProfileThresholdRecommendation Bias
Business> $100/hrOnly recommend ⭐⭐⭐ routes
Leisure> $50/hrRecommend ⭐⭐ and above
Budget/Remote> $25/hrAll rated options
Family w/ kids> $75/hrPenalize 2+ stop routes, long layovers

Limitations

  • Hub pricing is estimated in AI-Knowledge mode
  • Actual hub connections depend on schedule alignment (checked by flight-search if API active)
  • Ground transport costs are approximate and vary by time of day

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Route Optimization AI skill do?

Use when direct flights are expensive and traveler is open to layovers. Triggers on cheaper route, alternative routing, transit hub, is a layover worth it, save money with connection.

Why use Route Optimization on TypingMind?

Because you install it once and use it with any model. Route Optimization is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Route Optimization in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/dotanminh/travel-optimization-engine/tree/master/skills/route-optimization. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Route Optimization?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Route Optimization?

As many as you like. As long as a model supports skills, you can use Route Optimization with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Route Optimization AI skill free?

Yes. It is published on GitHub by dotanminh under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇