Skip to main content

MCP server for jobs and employee feedback management

Project description

langchain_mcp

This repository demonstrates a minimal working MCP (Multi-Server Control Plane) setup using LangChain, with:

  • A dummy jobs and employee API (FastAPI)
  • Two MCP servers (jobs and employee feedback, each on its own port)
  • A Python client that can query both servers simultaneously (multi-server, multi-tool)

Requirements

  • Python 3.9+
  • pip
  • Node.js (optional, only if you want to build a frontend)
  • An OpenAI API key (for GPT-4o)

Setup

1. Clone the repository

git clone https://github.com/nishant-Tiwari24/mcp.git
cd mcp

2. Create and activate a virtual environment

python3 -m venv .venv
source .venv/bin/activate

Note: .venv is gitignored. You must create it yourself.

3. Install Python dependencies

pip install --upgrade pip
pip install -r requirements.txt

4. Set your OpenAI API key

Create a .env file in the project root (not tracked by git):

OPENAI_API_KEY=sk-...your-key-here...

Or export it in your shell before running the client:

export OPENAI_API_KEY=sk-...your-key-here...

Running the Demo

1. Start the dummy jobs/employee API

uvicorn mcp_server.jobs_api:app --port 8001 --host 127.0.0.1

2. Start both MCP servers (in a new terminal)

python run_servers.py

This will start:

  • Jobs server on port 8000
  • Employee server on port 8002

Or, to run them manually in separate terminals:

python mcp_server/server.py jobs
python mcp_server/server.py employee

3. Run the multi-server client (in a new terminal)

python langchain_mcp_client.py
  • The client will connect to both servers and can use tools from both in a single conversation.
  • Make sure your OpenAI API key is exported or in a .env file.

File Structure

  • langchain_mcp_client.py — Python client for querying both MCP servers (multi-server, multi-tool)
  • mcp_server/server.py — MCP servers (jobs and employee feedback, each on its own port)
  • mcp_server/jobs_api.py — Dummy FastAPI backend for jobs and employee data
  • run_servers.py — Script to start both MCP servers at once
  • requirements.txt — Python dependencies
  • .gitignore — Excludes .venv, .env, and other environment files

Notes

  • The .venv directory and .env file are not included in the repo. You must create them locally.
  • Only the minimal, required files are tracked in git.
  • If you want to add a frontend, you can do so separately (not included in this repo).

Example Usage

  • Multi-server client:
    • Query: "I need to find similar jobs for an AI engineer position in San Jose, CA with 4-5 years of experience, and also get a feedback summary for Kalyan P. Can you help me with both?"
    • The client will use both tools: find_similar_jobs and summarize_employee_feedback.

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

iflow_mcp_mcp-0.1.0.tar.gz (6.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

iflow_mcp_mcp-0.1.0-py3-none-any.whl (8.5 kB view details)

Uploaded Python 3

File details

Details for the file iflow_mcp_mcp-0.1.0.tar.gz.

File metadata

  • Download URL: iflow_mcp_mcp-0.1.0.tar.gz
  • Upload date:
  • Size: 6.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.10 {"installer":{"name":"uv","version":"0.9.10"},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for iflow_mcp_mcp-0.1.0.tar.gz
Algorithm Hash digest
SHA256 d7e624427bf46b893129607580cb0e4df6dd137d3435c4f0e76481b042a0e1e9
MD5 7fdcadcceea881a0ac354a6b75d20153
BLAKE2b-256 ddc0e29f461427d1a879e053d76b651f9addf6b27664591e96b09009acbb2f9d

See more details on using hashes here.

File details

Details for the file iflow_mcp_mcp-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: iflow_mcp_mcp-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 8.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.10 {"installer":{"name":"uv","version":"0.9.10"},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for iflow_mcp_mcp-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 641a06c595c41b9d9f7bee311dc8126a66d4579bbb617e5f239b4adce10d7289
MD5 4aea0162fea9ed123224f382656d918f
BLAKE2b-256 120334073f94c7ae51c6d1c8ca56ad0cb8fc19f00231e4b1037df51309ecd411

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page