CoolFace
Apppublic

jstoppa/mcp_example

sourceHugging Facemitupdated 2y agoView on Hugging Face
0likes
App README

Model Context Protocol (MCP) Example Implementation

This repository demonstrates the implementation of the Model Context Protocol (MCP), a standardized approach for managing context in AI/ML models.

To get more details, look at the post How to create an MCP server and client with an LLM

Overview

MCP (Model Context Protocol) is a protocol designed to standardize how context is handled when working with AI/ML models. This example repository shows how to implement and use MCP in your projects.

Getting Started

Prerequisites

  • Python 3.8 or higher
  • pip (Python package installer)

Setup Virtual Environment

Windows

First, open Command Prompt and follow these steps:

  1. 1.Create and navigate to your project directory:
bash
cd mcp_example
  1. 1.Create a virtual environment:
bash
python -m venv app
  1. 1.Activate the virtual environment:
bash
venv\Scripts\activate
  1. 1.Your prompt should now show "(venv)" at the beginning, indicating the virtual environment is active.
  1. 1.Install required packages:
bash
pip install -r requirements.txt
macOS

Open Terminal and follow these steps:

  1. 1.Create and navigate to your project directory:
bash
mkdir mcp_example
cd mcp_example
  1. 1.Create a virtual environment:
bash
python3 -m venv venv
  1. 1.Activate the virtual environment:
bash
source venv/bin/activate
  1. 1.Your prompt should now show "(venv)" at the beginning, indicating the virtual environment is active.
  1. 1.Install required packages:
bash
pip install -r requirements.txt