mcpField
P
Poké-Battle

Poké-Battle

Local
github.com/shreyahhhAI & Agents1Updated 72w ago

About Poké-Battle

Poké-Battle is a FastAPI and Python Pokémon game with turn-based battles and Anthropic Claude-generated commentary, move suggestions, and Pokémon personalities. It is for players seeking AI-generated elements alongside catching and battling.

Key features

  1. 01Catch random Pokémon
  2. 02Fight turn-based battles
  3. 03Generate AI battle commentary
  4. 04Get AI move recommendations
  5. 05Create Pokémon personalities
  6. 06Update game state with WebSocket

Use cases

  1. 01Build a team by catching Pokémon
  2. 02Battle a randomly selected opponent
  3. 03Get move suggestions during battles
  4. 04View generated stories for caught Pokémon

Configuration

Local server config is the same for every client. Copy it into your client’s MCP config file.

No install method listed yet

We haven’t collected a package or remote endpoint for this server. Follow the instructions in the project README.

Repository

Tools

No tool list yet

Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.

Details

From the project README

Poké-Battle

This is a Pokemon game built with FastAPI and Python, leveraging Anthropic's Claude AI for creative battle descriptions, attack recommendations, and generating unique personalities for caught Pokemon.

Catch Pokemon Battle Field

Tech Stack

  • Backend: FastAPI, Uvicorn (ASGI server)
  • AI Integration: Anthropic's Claude API, custom AI server (ai_server.py) and client (ai_client.py)
  • External API: PokeAPI
  • Frontend: HTML, CSS, JavaScript (served by FastAPI)
  • Dependencies: python-dotenv, httpx, websockets, Jinja2

Setup Instructions

  1. Clone the repository:

    git clone <repository_url>
    cd <repository_directory>
    
  2. Create a virtual environment:

    python -m venv .venv
    
  3. Activate the virtual environment:

    • On Windows:
      .venv\Scripts\activate
      
    • On macOS and Linux:
      source .venv/bin/activate
      
  4. Install dependencies:

    pip install -r requirements.txt
    
  5. Set up your Anthropic API Key:

    • Create a file named .env in the root directory.
    • Add your Anthropic API key in the following format:
      ANTHROPIC_API_KEY=your_api_key_here
      

    Note: For security, it's recommended to manage API keys using environment variables provided by your hosting environment rather than storing them in a .env file, especially in production.

  6. Run the AI Server: Open your terminal in the project root and run:

    uvicorn ai_server:app --reload --port 8000
    
  7. Run the Main Game Server: Open a new terminal in the project root (and activate the virtual environment if necessary) and run:

    uvicorn server:app --reload --port 8080
    
  8. Open the game in your browser: Go to http://localhost:8080

Project Structure

  • server.py: Main FastAPI application handling game logic and serving the frontend.
  • ai_server.py: FastAPI application handling communication with the Anthropic API.
  • ai_client.py: Python client library used by server.py to communicate with ai_server.py.
  • index.html: The main frontend HTML file.
  • static/: Directory for static assets (CSS, JavaScript, images - although currently only the directory is present).
  • requirements.txt: Lists the Python dependencies.
  • api.env: Environment file to load the API key (should be added to .gitignore).
  • .gitignore: Specifies intentionally untracked files that Git should ignore.

Features

  • Pokemon Catching: Catch random Pokemon to build your team.
  • Pokemon Battles: Turn-based battles against a random opponent Pokemon.
  • AI Battle Descriptions: Creative commentary for battle actions generated by Anthropic's Claude.
  • AI Attack Recommendations: Get AI suggestions for the best move to use in battle.
  • AI Pokemon Personalities: Each caught Pokemon gets a unique, AI-generated personality trait or backstory.
  • Real-time Updates: Game state and messages updated via WebSocket.
  • Responsive UI: Basic UI adjustments for better display of caught Pokemon.

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.