ai-engram

v0.3.0 suspicious
4.0
Medium Risk

Surgical unlearning of classes, concepts, and facts in any PyTorch model

🤖 AI Analysis

Final verdict: SUSPICIOUS

The package has minimal risks in terms of network and shell activities but exhibits signs of low activity and lacks clear maintainer information, raising concerns about its legitimacy and long-term support.

  • Low metadata quality
  • Potential lack of active maintenance
Per-check LLM notes
  • Network: No network calls detected, which is normal unless the package's functionality requires it.
  • Shell: No shell execution patterns detected, indicating no immediate signs of malicious shell command execution.
  • Metadata: The package shows signs of potential low activity and lack of maintainer information, raising concerns about its legitimacy and maintenance.

📦 Package Quality Overall: Medium (6.2/10)

✦ High Test Suite 9.0

Test suite present — 2 test file(s) found

  • Test runner config found: pyproject.toml
  • 2 test file(s) detected (e.g. test_basic.py)
◈ Medium Documentation 7.0

Some documentation present

  • Documentation URL: "Documentation" -> https://jeakwon.github.io/ai-engram/
  • Detailed PyPI description (2255 chars)
○ Low Contributing Guide 4.0

No contributing guide or governance files found

  • Development Status classifier >= Beta
◈ Medium Type Annotations 5.0

Partial type annotation coverage

  • 30 type-annotated function signatures detected in source
◈ Medium Multiple Contributors 6.0

Limited contributor diversity

  • 2 unique contributor(s) across 23 commits in jeakwon/ai-engram
  • Two distinct contributors found

🔬 Heuristic Checks

Outbound Network Calls

No suspicious network call patterns found

Code Obfuscation score 2.0

Found 1 obfuscation pattern(s)

  • et_layers) self.model.eval() with collector, torch.inference_mode():
Shell / Subprocess Execution

No shell execution patterns detected

Credential Harvesting

No credential harvesting patterns detected

Typosquatting

No typosquatting candidates detected

Registered Email Domain

Email domain looks legitimate: gmail.com>

Suspicious Page Links

All external links appear legitimate

Git Repository History score 2.5

Git history flags: Repository has zero stars and zero forks

  • Repository has zero stars and zero forks
Maintainer History score 4.0

2 maintainer concern(s) found

  • Author name is missing or very short
  • Author "" appears to have only 1 package on PyPI (new or inactive account)
Known CVE Vulnerabilities

No known vulnerabilities found in OSV database.

💡 AI App Starter Prompt

Use this prompt to build a project with ai-engram
Create a Python-based mini-application that demonstrates the surgical unlearning capabilities of the 'ai-engram' package on a PyTorch model. This application will serve as a proof-of-concept for understanding how specific classes or concepts can be selectively removed from a pre-trained model without affecting its overall performance on other tasks. Here are the steps and features to include:

1. **Project Setup**: Initialize a new Python project, install necessary packages including PyTorch and ai-engram, and set up a virtual environment.
2. **Model Selection**: Choose a pre-trained PyTorch model (e.g., ResNet for image classification) and load it into your application.
3. **Data Preparation**: Prepare a dataset containing images related to a specific class (e.g., cats) that you wish to remove from the model's knowledge base.
4. **Unlearning Process**: Implement the unlearning process using ai-engram. This involves identifying the specific neurons or layers associated with the target class and modifying them to forget the information about this class.
5. **Evaluation**: Before and after the unlearning process, evaluate the model's performance on a test set to demonstrate the reduction in accuracy for the targeted class while maintaining performance on other classes.
6. **Visualization**: Include a feature to visualize changes in the model's behavior before and after unlearning, such as plotting confusion matrices or comparing prediction probabilities.
7. **Documentation**: Write clear documentation explaining each step of the process, the theory behind ai-engram, and how to run the application.
8. **User Interface**: Develop a simple command-line interface that allows users to specify which class they want to remove from the model and see the results of the unlearning process.

This project aims to showcase the unique capability of ai-engram to surgically remove learned information from a neural network, providing insights into the potential applications of this technology in areas like privacy preservation and bias mitigation.