Pokemon_G0

Vighnesh-M-S/Pokemon_G0

3.1

If you are the rightful owner of Pokemon_G0 and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to dayong@mcphub.com.

The Pokémon MCP Server is a Model Context Protocol server that provides AI models with access to Pokémon knowledge and battle simulations.

Pokémon MCP Server International_Pokémon_logo svg

This project implements a Model Context Protocol (MCP) server that provides AI models access to Pokémon knowledge and battle simulations.
It exposes two main components:

  1. Pokémon Data Resource – Exposes comprehensive Pokémon data (stats, types, moves, abilities, evolutions).
  2. Battle Simulation Tool – Simulates battles between any two Pokémon with core mechanics.

📜 System Flow Diagram

Screenshot 2025-09-11 at 8 08 20 AM


🚀 Setup Instructions

Prerequisites

  • Python 3.9+
  • pip install -r requirements.txt

Run the server

python3 main.py

MCP Integration

You can mount the MCP server into Copilot / mcpc using:

  • Make a folder .vscode/mcp.json
  • inside that paste your url
    {
      "servers": {
      	"pokemonG0": {
      		"url": "http://localhost:6274/mcp",
      		"type": "http"
      	},
      },
      "inputs": []
    }
    
  • mcp_connect

or via SSE:

  • Install any mcp-cli
  • Code used in this project
git clone https://github.com/JorianWoltjer/mcp-cli.git && cd mcp-cli
python3 -m pip install requests
sudo ln -s $(pwd)/mcpc.py /usr/local/bin/mcpc
mcpc localhost:6274
  • sse

📊 Part 1: Pokémon Data Resource

The server connects to the PokéAPI and exposes resources:

  • Pokémon Info (/api/pokemon/{name})
    Returns base stats, abilities, types, moves.

  • Move Info (/api/move/{name})
    Returns move power, type, accuracy, effect.

  • Ability Info (/api/ability/{name})
    Returns description of Pokémon abilities.

  • Evolution Chain (/api/evolution/{pokemon})
    Returns the full evolution chain.

✅ Example Queries

Using LLM:

give me pokemon pikachu
tell me about the move thunderbolt
give me evolution chain of bulbasaur
  • Screenshot 2025-09-11 at 8 52 44 AM

Using mcp-cli:

mcpc http://0.0.0.0:6274 pokemon_resource_api_pokemon__id_or_name__get '{"id_or_name": "pikachu"}'

⚔️ Part 2: Battle Simulation Tool

Simulates battles between two Pokémon with:

  • Type effectiveness multipliers (Fire > Grass, Water > Fire, etc).
  • Damage calculation using stats + move power.
  • Turn order based on Speed stat.
  • Status effects: Paralysis, Burn, Poison.
  • Battle logs for each turn.
  • Winner determination when a Pokémon faints.

✅ Example Usage

Using LLM:

simulate a battle between pikachu and bulbasaur
  • Screenshot 2025-09-11 at 9 53 38 AM

Using mcp-cli:

mcpc http://0.0.0.0:6274 battle_api_battle_post '{"pokemon1": "pikachu", "pokemon2": "bulbasaur"}'

Sample Output:

--- Turn 1 ---
Pikachu used Thunderbolt! It dealt 22 damage.
Charmander is paralyzed and may not move!
Charmander used Ember! It dealt 12 damage.

--- Turn 2 ---
Pikachu used Quick Attack! It dealt 14 damage.
Charmander fainted!

Winner: Pikachu

📹 Project Explanation

![Watch the demo]Screenshot 2025-09-11 at 9 47 19 AM

📂 Project Structure

- main.py   # Main FastAPI + MCP server
- resources
--- pokemon_resources.py     
- tools
--- battle_tool.py
- domian
--- battle_engine.py        # Battle mechanics and simulation
--- pokeapi.py              # Pokémon, Move, Ability, Evolution resources

- README.md        # Documentation
- requirements.txt