adilfaisal01

multi-hop

"Multi-hop reasoning — questions that require chaining facts across multiple sources (A implies B, B implies C). Uses pipeline mode so each worker builds on the previous one's findings."

adilfaisal01 10 Updated 3mo ago
GitHub

Install

npx skillscat add adilfaisal01/llm-multiagent-swarm/multi-hop

Install via the SkillsCat registry.

SKILL.md

Multi-Hop Reasoning

When to Use

Questions that cannot be answered in one search — they require chaining facts across multiple sources. Example: "Who is the CEO of the company that acquired the startup founded by the person who wrote X?" Each hop is a separate search that feeds the next.

Workflow

The swarm runs in PIPELINE mode. Each worker depends on the previous worker's output:

  1. Worker 0 — identifies the FIRST hop: the most concrete, searchable fact in the question. Searches and extracts it.
  2. Worker 1 (depends_on: 0) — takes Worker 0's finding, identifies the SECOND hop, searches and extracts it.
  3. Worker 2 (depends_on: 1) — takes Worker 1's finding, identifies the THIRD hop, searches and extracts it.
  4. Worker 3 (depends_on: 2) — continues the chain.
  5. Worker 4 (depends_on: 3) — completes the chain and assembles the final answer.

Each worker MUST use the previous worker's output as the starting point for its own search. Log every hop's finding and source URL with scratchpad_add. The orchestrator synthesizes the chained answer with citations.

Running under swarm

python3 -m swarm --skill multi-hop --goal "Who is the CEO of the company that acquired the startup founded by the creator of Linux?"

Running under Hermes

Delegate a chain of sequential tasks, passing each task's output as the input to the next. Start with the most concrete searchable fact and work backward through the chain.

Categories