Package
also: packages
A bundle of ready-made code that someone published so other projects can install and use it. Once you add one to your project, it becomes a dependency.
A versioned, distributable unit of code published to a registry such as npm (JavaScript) or PyPI (Python). A package manager downloads packages along with their own dependencies and records which versions your project uses.
A package is like a flat-pack furniture kit. Someone else designed and boxed it. You order it by name and model number, and it arrives ready to fit into your home.
Agents often solve problems by installing packages. Knowing what that means helps you ask whether a package is trustworthy, maintained, and actually needed.
I installed the stripe package, version 14.2, and added it to package.json. I'll use it to create checkout sessions.
Before installing a package for this, check that it's well maintained and widely used. Tell me its name and what it does.
Thinking package, library and dependency mean exactly the same thing. A package is the published bundle. A library is the kind of code often inside it. A dependency is anything your project relies on.