Inspiration

Every developer has been there — you ask an AI to help set up Prisma or Next.js, follow the steps carefully, and then spend the next hour debugging because the commands were outdated. AI tools are trained on static data, and package ecosystems move fast. We got frustrated enough to fix it.

What it does

PackSense is a VS Code extension that acts as a real-time verification layer between you and AI-generated setup instructions. You type a request like "Can you do the latest prisma setup " — and instead of guessing, PackSense fetches the actual latest version from npm, pulls breaking change notes from GitHub Releases, builds a verified context, and only then sends it to the AI. The result is a confirmed, accurate setup — with a popup showing exactly what commands will run before anything touches your project.

How we built it

We built PackSense as a TypeScript VS Code extension using the VS Code Extension API for the UI layer. The backend logic hits the npm Registry API for real-time package versions and the GitHub REST API for release notes and breaking changes. We built a contextBuilder module that structures all this verified data into a clean prompt before passing it to Claude or GPT. Terminal commands are executed via VS Code's Terminal API, and config files like .env and schema.prisma are created using the Workspace FS API — all gated behind a confirmation popup.

Challenges we ran into

  • Registry inconsistencies — Different ecosystems (PyPI, npm, Crates.io, pub.dev) return data in wildly different formats, so normalizing them into a unified context structure took significant effort.
  • Fuzzy matching — Making typos like langchin correctly resolve to langchain without false positives required careful tuning.
  • AI prompt reliability — Getting the AI to strictly use only the verified context and not hallucinate older versions required prompt engineering and strict system instructions.
  • VS Code Webview security — Working within VS Code's CSP restrictions for the chat panel was trickier than expected.

Accomplishments that we're proud of

  • Built a fully working VS Code extension with a real-time multi-registry lookup pipeline
  • The confirmation popup system — we never touch a user's files or terminal without explicit permission
  • Fuzzy package search that works across 6+ ecosystems simultaneously
  • Successfully eliminated AI hallucination on package versions by making the AI a reasoning engine, not a knowledge source

What we learned

  • AI is most powerful when used for what it's good at — reasoning and explanation — not as a database. Separating verification from generation was our biggest architectural insight.
  • VS Code Extension development has a steep learning curve but an incredibly powerful API surface.
  • Real-time API chaining (registry → GitHub → AI) needs robust fallback handling because any one source can be slow or unavailable.

What's next for PackSense

  • PyPI & private registry support for Python and enterprise teams
  • package.json auto-update on user confirmation
  • Multi-package bulk setup — set up an entire stack in one command
  • VS Code Marketplace launch for public availability
  • Team sync features — share verified package configs across a dev team

Built With

  • claude-api
  • github-rest-api
  • node.js
  • npm-registry-api
  • openai-gpt-api
  • typescript
  • vs-code-extension-api
  • vs-code-terminal-api
  • vs-code-webview-api
  • workspace
Share this project:

Updates