Summary audio
No audio recap for this lesson.
Study notes
Project Overview
- Building a CLI-based chatbot to understand how MCP clients and servers work together
- Users can interact with a collection of in-memory documents (fake data)
- Project includes both a custom MCP client and custom MCP server in one codebase
MCP Server Implementation
- Two tools will be implemented:
- Read document contents
- Update document contents
- Documents are stored in memory only (not persisted to disk)
Important Context
- In real projects, developers typically build either a client OR a server, not both
- MCP servers are distributed to allow other developers to access services
- MCP clients connect to external servers built by other engineers
- This project builds both for educational purposes to demonstrate how they interact
Project Setup Steps
- Download the CLI_project. zip starter code file
- Open the project directory in a code editor
- Read the readme. md file for setup instructions
- Add API key to the . env file
- Install dependencies using UV or pip
- Run the project with uv run main. py (or python main. py without UV)
- A chat prompt should appear; test with a simple query like "what's one plus one"
Next Steps
- After setup is complete, begin adding new features to the application
Takeaways
- Building a CLI chatbot project that includes both a custom MCP client and server to learn how they work together
- MCP server will implement two tools: read document contents and update document contents (stored in memory only)
- Typically developers build either a client OR server, not both — this project does both for educational purposes
- Setup requires downloading starter code, adding API key to . env, installing dependencies with UV or pip, and running with uv run main. py
- After setup, you'll test the chatbot with a simple query before adding new features
Flashcards 10 cards
Question
click to reveal · ←/→
Answer
click to flip back
Knowledge check 6 questions