惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

小众软件
小众软件
博客园 - Franky
罗磊的独立博客
G
Google Developers Blog
The GitHub Blog
The GitHub Blog
P
Proofpoint News Feed
Recent Announcements
Recent Announcements
V
V2EX
F
Fortinet All Blogs
阮一峰的网络日志
阮一峰的网络日志
Blog — PlanetScale
Blog — PlanetScale
月光博客
月光博客
U
Unit 42
GbyAI
GbyAI
A
About on SuperTechFans
WordPress大学
WordPress大学
Engineering at Meta
Engineering at Meta
雷峰网
雷峰网
Microsoft Azure Blog
Microsoft Azure Blog
Martin Fowler
Martin Fowler
D
DataBreaches.Net
The Cloudflare Blog
H
Hackread – Cybersecurity News, Data Breaches, AI and More
MongoDB | Blog
MongoDB | Blog

Hacker News - Newest: "AI"

AI can't read an investor deck AI as an attorney? Student uses ChatGPT, Gemini to sue UW over alleged racial discrimination Hacking MCP Servers in AI Systems – The Rug Pull: Tool Changes After Approval GitHub - MeepCastana/KubeezCut: Free Web based video editor Can AI judge journalism? A Thiel-backed startup says yes, even if it risks chilling whistleblowers Coming soon: 10 Things That Matter in AI Right Now DARPA built an AI to fact-check enemy weapons claims What explains heterogeneity in AI adoption? When AI Meets Muscle: Context-Aware Electrical Stimulation Promises a New Way to Guide Human Movements - Department of Computer Science AI Changed How We Build. It Did Not Change What Matters. Linux rules on using AI-generated code - Copilot is OK, but humans must take 'full responsibility for the… Meta spins up AI version of Mark Zuckerberg to engage with employees Code Mode: Let Your AI Write Programs, Not Just Call Tools | TanStack Blog GitHub - Delavalom/graft: Go framework for building AI agents. Type-safe tools, multi-provider (OpenAI, Anthropic, Gemini, Bedrock), zero vendor SDKs. India's TCS tops estimates, says new AI models did not dent services demand Gen Z's fading AI hype Strong feeling: we are in a folded AI reality GitHub - machinarii/total-recall-catalog: A reference catalog of latest knowledge retrieval, memory & RAG systems GitHub - mensfeld/code-on-incus: Give each AI agent its own isolated machine with root, Docker, and systemd. Active defense detects and stops threats automatically.. Quantization, LoRA, and the 8% Problem: Benchmarking Local LLMs for Production AI Iran war: We spoke to the man making Lego-style AI videos that experts say are powerful propaganda Powell, Bessent discussed Anthropic's Mythos AI cyber threat with major U.S. banks GitHub - immartian/bellamem: Persistent belief-graph memory for AI agents. Retrieves decisive context by importance — not recency, not RAG, not /compact. recursive-mode: The Repo-Native Operating System for AI Engineering After the attack on Sam Altman's home, will AI CEO's go on the offensive? The biggest advance in AI since the LLM Opus 4.6 vs GPT 5.4 One Prompt Unity World Generation Test “AI polls” are fake polls Client Challenge Can AI be a 'child of God'? Inside Anthropic's meeting with Christian leaders
GitHub - Neurall-build/implit: Validate imports and catch...
neurall-buil · 2026-04-27 · via Hacker News - Newest: "AI"

Implit Logo

Stop AI hallucinations before they break your code

npm version npm downloads License: MIT GitHub stars

"AI wrote code with fake packages. Implit caught them in 0.3 seconds."

Quick StartFeaturesWhy Implit?Examples


😱 The Problem

// AI generates this code...
import { awesomeAuth } from 'super-auth-lib';  // ❌ DOESN'T EXIST
import { fetchUser } from './api/users';       // ❌ NO export named fetchUser
import { login } from 'magic-auth';            // ❌ TYPO - should be 'magic-auth-lib'

// You run npm install... 💥 BROKEN BUILD

Every developer using AI has experienced this:

  • ❌ AI invents npm packages that don't exist
  • ❌ AI guesses wrong local import paths
  • ❌ Security risk: hackers can register fake packages
  • ❌ Hours wasted debugging phantom dependencies

✨ The Solution

Implit scans your AI-generated code and validates every import BEFORE you run it.

npx @neurall.build/implit check generated-code.ts
🔍 Checking generated-code.ts...

✓ react - Package exists on npm
✓ lodash - Package exists on npm
✗ super-auth-lib - Package NOT FOUND on npm registry
✗ ./api/users - No export named 'fetchUser' (available: getUser, deleteUser)
✗ magic-auth - Package NOT FOUND (did you mean: magic-auth-lib?)

❌ Found 3 hallucinated imports!

🚀 Quick Start

Zero Config (Recommended)

# Check any file instantly - no installation needed
npx @neurall.build/implit check your-file.ts

Global Install

# Install globally for frequent use
npm install -g @neurall.build/implit

# Then run anywhere
implit check your-file.ts

Generate Fix Prompt for AI

# Get a ready-to-paste prompt to feed back to your AI
npx @neurall.build/implit check your-file.ts --fix

Output:

📋 Fix prompt (ready to paste):

Your generated code has invalid imports:

1. "super-auth-lib" does not exist on npm.
2. "./api/users" does not export "fetchUser". Available exports: getUser, deleteUser.
3. "magic-auth" does not exist. Did you mean "magic-auth-lib"?

Please fix these imports and regenerate the code.

🎯 Features

✓ npm Package Verification

  • Checks every external import against registry.npmjs.org
  • Detects typos with fuzzy matching ("Did you mean...")
  • Prevents supply chain attacks from fake packages

✓ Local Import Validation

  • Scans your local files for actual exports
  • Detects missing files
  • Reports available exports for wrong imports

✓ Node.js Built-in Detection

  • Automatically recognizes Node.js built-ins (fs, path, http, etc.)
  • No false positives on standard modules

✓ Smart Caching

  • Caches npm lookups for 24 hours
  • Blazing fast on repeated runs
  • Minimal network overhead

✓ Zero Config

  • Works out of the box
  • No setup required
  • Just npx and go

✓ AI-Friendly Output

  • --fix flag generates clipboard-ready prompts
  • Feed directly back to Claude, GPT, or Gemini
  • One-command workflow for AI-assisted coding

💡 Why Implit?

Feature Implit Manual Review IDE Linter
Catches fake npm packages Maybe
Validates local exports Maybe
Zero setup required
Works on any file
Generates AI fix prompts
Speed 0.3s Minutes Realtime*

*IDE linters only catch already-installed packages, not hallucinated ones


📦 Examples

Basic Check

npx @neurall.build/implit check src/components/App.tsx

Check Multiple Files

npx @neurall.build/implit check src/**/*.ts

CI/CD Integration

# .github/workflows/check.yml
name: Validate Imports

on: [pull_request]

jobs:
  check:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: actions/setup-node@v4
      - run: npx @neurall.build/implit check src/index.ts

JSON Output

npx @neurall.build/implit check your-file.ts --json
[
  {
    "module": "react",
    "valid": true,
    "type": "external",
    "message": "Package exists on npm"
  },
  {
    "module": "super-auth-lib",
    "valid": false,
    "type": "external",
    "message": "Package NOT FOUND on npm registry"
  }
]

🔧 Commands

Command Description
implit check <file> Check a file for hallucinated imports
implit check <file> --security Also run security checks for typosquatting
implit check <file> --fix Generate fix prompt for AI
implit check <file> --json Output results as JSON
implit check <file> --no-cache Skip cache, always query npm
implit audit Run npm audit for vulnerabilities
implit install-hook Install git pre-commit hook
implit clear-cache Clear the dependency cache

🔒 Security Features

✓ Typosquatting Detection

  • Warns when packages are similar to popular ones (e.g., "lodas" vs "lodash")
  • Helps prevent supply chain attacks
  • High severity warnings for suspicious packages

✓ Git Pre-commit Hook

  • Automatically validates imports before every commit
  • Catches hallucinations before they enter your codebase
  • Easy installation: implit install-hook

✓ npm Audit Integration

  • Run implit audit to check for known vulnerabilities
  • Combines import validation with security scanning

🔮 Coming Soon

Phase 3: Multi-

Star the repo to get notified when these land!


🏆 Who Uses Implit?

  • AI Vibe Coders — Validate ChatGPT/Claude code before running
  • DevOps Teams — Catch issues before they hit CI/CD
  • Security Teams — Prevent dependency hijacking attacks
  • Open Source Maintainers — Validate PRs with AI-generated code

🤝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

📄 License

MIT License - feel free to use in personal and commercial projects.


🙏 Credits

Built by Neurall — making AI-assisted development safer.


⬆ Back to Top

Found this useful? Give us a ⭐ on GitHub!

GitHub Repo NPM Package