uv-pip-install
uv-pip-install
Install and manage Python packages in the uv-managed virtual environment.
Quick start
# Install a package
uv pip install requests
# Install multiple packages
uv pip install pandas numpy matplotlib
# Install with extras
uv pip install httpx[http2]
# Check if a package is installed
uv pip show python-docx
# List all installed packages
uv pip list
# Upgrade a package
uv pip install --upgrade requests
When to use
- Python import fails with
ModuleNotFoundError - User asks to install a Python package
- A script requires dependencies that are not installed
Common module-to-package mappings
| Import name | Package name |
|---|---|
| cv2 | opencv-python |
| PIL | pillow |
| sklearn | scikit-learn |
| yaml | pyyaml |
| docx | python-docx |
| pptx | python-pptx |
| bs4 | beautifulsoup4 |
| dotenv | python-dotenv |
| attr | attrs |
| dateutil | python-dateutil |
| gi | pygobject |
| magic | python-magic |
| serial | pyserial |
| usb | pyusb |
| Crypto | pycryptodome |
| jwt | pyjwt |
| jose | python-jose |
| lxml | lxml |
| wx | wxPython |
| gi | PyGObject |
| skimage | scikit-image |
| fitz | PyMuPDF |
| cv | opencv-python |
| telegram | python-telegram-bot |
| discord | discord.py |
| flask_cors | flask-cors |
| sqlalchemy | SQLAlchemy |
| alembic | alembic |
| pymongo | pymongo |
| redis | redis |
| celery | celery |
| fastapi | fastapi |
| uvicorn | uvicorn |
| httpx | httpx |
| aiohttp | aiohttp |
| websockets | websockets |
| jinja2 | Jinja2 |
| markdownify | markdownify |
Workflow
- If an import error occurs, extract the module name.
- Map module name to package name if different (see table above).
- Check if already installed:
uv pip show <package> - If not installed:
uv pip install <package>
Troubleshooting
Common issues
| Problem | Solution |
|---|---|
uv: command not found |
Install uv: curl -LsSf https://astral.sh/uv/install.sh | sh |
| Package installs but import still fails | Check you're in the correct venv: which python |
| Version conflict | Pin version: uv pip install package==1.2.3 |
| Build fails (C extension) | Install system deps: brew install pkg-config (macOS) |
| SSL certificate error | uv pip install --trusted-host pypi.org package |
Notes
- Always run from the project directory so the correct
.venvis used. - Use
uv pip(not plainpip) to ensure packages go into the uv-managed environment. - For packages with C extensions, ensure build tools are installed (
xcode-select --installon macOS).
More from memento-teams/memento-skills
filesystem
Direct filesystem operations (read, write, edit, list, search files). Use for any file manipulation tasks.
12docx
Use this skill whenever the user wants to create, read, edit, or manipulate Word documents (.docx files). Triggers include: any mention of \"Word doc\", \"word document\", \".docx\", or requests to produce professional documents with formatting like tables of contents, headings, page numbers, or letterheads. Also use when extracting or reorganizing content from .docx files, inserting or replacing images in documents, performing find-and-replace in Word files, working with tracked changes or comments, or converting content into a polished Word document. If the user asks for a \"report\", \"memo\", \"letter\", \"template\", or similar deliverable as a Word or .docx file, use this skill. Do NOT use for PDFs, spreadsheets, Google Docs, or general coding tasks unrelated to document generation.
9web-search
Web search and content fetching. Use when the user needs to search the web for information or fetch content from URLs.
9skill-creator
Create new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, update or optimize an existing skill, run evals to test a skill, benchmark skill performance with variance analysis, or optimize a skill's description for better triggering accuracy.
9pptx
Use this skill any time a .pptx file is involved in any way — as input, output, or both. This includes: creating slide decks, pitch decks, or presentations; reading, parsing, or extracting text from any .pptx file (even if the extracted content will be used elsewhere, like in an email or summary); editing, modifying, or updating existing presentations; combining or splitting slide files; working with templates, layouts, speaker notes, or comments. Trigger whenever the user mentions \"deck,\" \"slides,\" \"presentation,\" or references a .pptx filename, regardless of what they plan to do with the content afterward. If a .pptx file needs to be opened, created, or touched, use this skill.
8pdf
Use this skill whenever the user wants to do anything with PDF files. This includes reading or extracting text/tables from PDFs, combining or merging multiple PDFs into one, splitting PDFs apart, rotating pages, adding watermarks, creating new PDFs, filling PDF forms, encrypting/decrypting PDFs, extracting images, and OCR on scanned PDFs to make them searchable. If the user mentions a .pdf file or asks to produce one, use this skill.
8