- Locate the concrete dependency version in the fixture lockfile.
- Compare the suggested method with documentation for that major version.
- Choose keep or upgrade with compatibility tests and a reversible lockfile change.
An assistant may remember a method from another library version or suggest a package that is unnecessary for the task. Treat dependency advice as a hypothesis. Inspect the project’s installed version and its official documentation before changing the dependency graph or following installation commands.
Identify the version actually in use
A package manifest may permit a version range while the lockfile records the concrete resolution used for a reproducible install. In the fictional parser project, the manifest range and lockfile version are different kinds of evidence. Record both without assuming that the newest online example matches the current runtime. Also note the supported Node.js version and whether the package is used on the server or in the browser, because those environments expose different APIs.
Verify the proposed API and its cost
Ask the assistant to point to the exact official API page for the installed major version. Check argument names, return types and whether the method is synchronous or asynchronous. Compare a standard-library solution before adding a new dependency for a small transformation. Dependency cost includes bundle size, maintenance, licensing and installation behavior, not just the convenience of one function call. Do not paste credentials into an installation diagnostic or a public issue.
Change one dependency boundary at a time
If an upgrade is genuinely needed, separate it from unrelated feature work and preserve the prior lockfile in version control. Run the project’s meaningful tests and inspect any migration notes that affect your use. A successful install is not evidence that every runtime path still works. Capture the commands, resolved version and observed failures in the review note, and state which provider-backed or platform-specific behavior could not be tested locally.
Fictional worked example — Version evidence
Supplied input
Manifest: ^2.1.0; lockfile:2.4.3; suggested API documented for3.x
Example result to inspect
API advice remains unverified for2.4.3
The mismatch is a reason to consult versioned documentation, not proof that an upgrade is required.
This is an authored teaching example, not a recorded live provider run or an independent performance test.
Make the idea concrete.
- Locate the concrete dependency version in the fixture lockfile.
- Compare the suggested method with documentation for that major version.
- Choose keep or upgrade with compatibility tests and a reversible lockfile change.
What a useful outcome looks like
A lockfile records resolved package versions; a manifest range alone may permit several resolutions.
Ask for reasoning you can verify.
Use fictional or permitted data. This is a copyable brief for a separate approved model; no model is called from this article.
Help me review this fictional coding with ai exercise: Ground AI coding advice in the project lockfile and official API documentation. I will supply the original input, my expected result and the actual transformation. Explain API compatibility, identify unsupported assumptions about unverified runtime paths, and propose one bounded negative control. Keep observations separate from hypotheses; do not invent output or act on external systems.
Turn reading into a reviewed checkpoint.
Complete the manual exercise, review each item, then answer the evidence question. This records self-study, not independent assessment of expertise.
Review the checklist and pass the question to save this lesson.
Primary references
References support further checking; cited organizations do not endorse AgentX. This guide is original AI-assisted educational content with illustrative examples. Read the editorial policy or report a correction.
Continue with a related task.
Read the contract before asking for code
Map callers, inputs and invariants before requesting a change.
Request a minimal diff with explicit exclusions
Keep an AI-assisted patch focused enough to review and revert.
Test the requirement rather than the generated implementation
Use independent examples to challenge an AI-written function.