Logo di Python Packaging Git Audit

Python Packaging Git Audit

Organizzazione
opendatahub-io
python-packaging-git-audit

Inspect recent git history of a Python package repository for suspicious commits touching supply-chain-sensitive files, then triage findings with AI reasoning to produce a structured risk report section.

Panoramica

Autoreopendatahub-io
Repositoryai-helpers
Nome della skillpython-packaging-git-audit
Stelle
39
Fork
76
File inclusi
Solo istruzioni
LicenzaApache-2.0
Link
  • Istruzioni in Markdown

    Un file SKILL.md che il modello carica quando serve, consumando token solo quando una richiesta è effettivamente pertinente.

  • Funziona con qualsiasi LLM

    Le skill IA sono in semplice Markdown, non in codice specifico di un fornitore, quindi funzionano con GPT, Claude, Gemini, Grok o un modello locale.

  • Tutto nelle istruzioni

    Tutto ciò che serve al modello è nelle istruzioni: nessun file aggiuntivo da sincronizzare.

  • Open source

    Pubblicata da opendatahub-io su GitHub. Leggi i sorgenti prima di installarla.

Installazione

Installa la skill IA Python Packaging Git Audit in TypingMind per usarla con qualsiasi LLM, oppure copiala in un altro agente in grado di leggere SKILL.md.

1

Installa in TypingMind

TypingMind installa una skill direttamente dalla sua cartella GitHub: legge SKILL.md, raccoglie i file delle risorse e salva il risultato in locale.

  1. Apri l'app e vai su Plugin → Skill.
  2. Scegli "Installa da GitHub".
  3. Incolla l'URL della cartella della skill riportato qui sotto e conferma.
    https://github.com/opendatahub-io/ai-helpers/tree/main/plugins/odh-python-packaging/skills/python-packaging-git-audit
  4. Attiva la skill in ogni chat in cui vuoi averla a disposizione.
Plugin → Skill → Nuova skill → Da URL GitHub, poi incolla l'URL della cartella e premi Continua.
2

Installa in un altro agente

Qualsiasi agente che legge il formato Agent Skills può usare questa skill: copia la cartella nella cartella delle skill di quell'agente.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/opendatahub-io/ai-helpers.git /tmp/ai-helpers
mkdir -p .claude/skills
cp -r /tmp/ai-helpers/plugins/odh-python-packaging/skills/python-packaging-git-audit .claude/skills/python-packaging-git-audit
Dopo la copia, riavvia Claude Code per caricare la nuova skill.

Usala in TypingMind

Attiva Python Packaging Git Audit in qualsiasi chat di TypingMind e al resto pensa il modello. Il nome e la descrizione della skill sono nel prompt di sistema e, non appena arriva una richiesta pertinente, il modello carica da solo le istruzioni complete: non devi mai richiamarla manualmente e non consuma token finché non viene effettivamente usata.

Il modello carica automaticamente Python Packaging Git Audit non appena riceve una richiesta pertinente.

Funziona con qualsiasi modello IA

Le skill IA sono semplici istruzioni in Markdown, non codice specifico di un fornitore, quindi Python Packaging Git Audit non è vincolata al modello per cui è stata scritta. Installala una sola volta in TypingMind e usala con GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama o un modello locale che esegui tu, sempre con le tue chiavi API.

  • Caricata solo quando serve

    Il prompt di sistema contiene solo il nome e la descrizione. Le istruzioni vengono recuperate alla prima richiesta pertinente, quindi una skill inutilizzata non costa nulla.

  • Cambia modello durante la chat

    Poiché la skill è composta da istruzioni e non da codice, continua a funzionare anche se cambi modello: il nuovo modello legge lo stesso file SKILL.md.

Istruzioni della skill

Questo è il contenuto di SKILL.md che il modello carica. Leggilo prima dell'installazione: una skill è un insieme di istruzioni che il tuo modello seguirà.

Python Packaging Git Audit

Inspects the recent git history of a Python package repository for commits that modify supply-chain-sensitive files (setup.py, CI configs, .pth files, etc.) and contain suspicious patterns. Produces a self-contained "Git History Analysis" report section with triaged findings and a risk assessment.

Inputs

  • repo_path (required): Local filesystem path to a git repository
  • output_file (optional): Write the report section to this file path instead of returning it inline. The first line of the file must be RISK_RATING:<value> so the orchestrator can parse it without reading the full report.

Step 1: Enumerate Commits

Determine the number of commits available and scan up to the last 50:

bash
git -C <repo-path> log -50 --format='%H'

Step 2: Filter Sensitive Files

From those commits, identify ones that modify supply-chain-sensitive files:

  • setup.py, setup.cfg, pyproject.toml, MANIFEST.in
  • .github/workflows/*.yml, .gitlab-ci.yml
  • Any .pth files
  • __init__.py files at package root
bash
git -C <repo-path> log -50 --diff-filter=ACMR --name-only --format='COMMIT:%H|%aI|%ae' -- \
  setup.py setup.cfg pyproject.toml MANIFEST.in \
  '.github/workflows/*.yml' .gitlab-ci.yml \
  '*.pth' '*/__init__.py'

Step 3: Search for Suspicious Patterns

For each flagged commit, extract the diff and search for suspicious patterns:

  • Code execution: eval(, exec(, compile(
  • Process spawning: subprocess, os.system, os.popen
  • Encoding/serialization: base64, marshal, pickle
  • Network access: socket, urllib, requests.get, httpx
  • Native code: ctypes, cffi
  • Embedded URLs: http://, https://
bash
git -C "<repo-path>" show --format= -m --first-parent "<commit>" -- "<file>" | \
  grep -nE 'eval\(|exec\(|compile\(|subprocess|os\.system|os\.popen|base64|marshal|pickle|socket|urllib|requests\.get|httpx|ctypes|cffi|https?://'

Collect per finding: commit hash, author, date, file modified, and matching patterns.

Step 4: Triage

Review git history findings with AI reasoning. There are no deterministic rules for this phase — each finding requires contextual judgment.

For each flagged commit, consider:

  • Is this a normal dependency version bump or configuration change?
  • Does the pattern match the package's stated purpose?
  • Is the author a known maintainer with a history of contributions?
  • Does the change introduce new capabilities that seem out of scope?

Flag commits that introduced suspicious patterns into sensitive files. Assign a verdict to each:

  • Likely legitimate — change is a normal maintenance or dependency update
  • Suspicious — change introduces unexpected capabilities or patterns
  • Critical — change strongly indicates malicious intent (e.g., encoded payload in install hook)

Output Format

Produce the following markdown section:

markdown
## Git History Analysis (Last 50 Commits)

**Commits touching sensitive files:** {N}

| Commit | Date | Author | File | Patterns Found |
|--------|------|--------|------|----------------|
| abc1234 | 2026-03-15 | user@example.com | setup.py | subprocess, os.system |

**AI Assessment:** {Brief narrative on whether the git history changes look normal or concerning, with reasoning}

The risk_rating for this phase is one of:

  • no_issues — No sensitive files modified in recent history
  • low_risk — All findings classified as "likely legitimate"
  • needs_review — One or more findings classified as "suspicious"
  • critical — One or more findings classified as "critical"

If output_file is provided, write the file with the first line as RISK_RATING:<value> followed by a blank line and then the markdown section above. If output_file is not provided, return the report section inline.

Error Handling

ScenarioBehavior
Path is not a git repositoryReport "not a git repository", risk_rating = needs_review
Fewer than 50 commits availableScan all available commits, note count in report
No sensitive files modified in historyReport "no sensitive files found", risk_rating = no_issues

Domande frequenti

Cosa fa la skill IA Python Packaging Git Audit?

Inspect recent git history of a Python package repository for suspicious commits touching supply-chain-sensitive files, then triage findings with AI reasoning to produce a structured risk report section.

Perché usare Python Packaging Git Audit su TypingMind?

Perché la installi una volta e la usi con qualsiasi modello. Python Packaging Git Audit è scritta in semplice Markdown anziché in codice specifico di un fornitore, quindi la stessa skill funziona con GPT-5, Claude, Gemini, Grok o un modello locale, e puoi cambiare modello durante la chat senza che smetta di funzionare. TypingMind usa le tue chiavi API, quindi paghi direttamente i fornitori anziché un abbonamento per posto utente, e le tue skill e chat restano nel tuo spazio di archiviazione.

Come installo Python Packaging Git Audit in TypingMind?

Apri Plugin → Skill → Installa da GitHub in TypingMind e incolla https://github.com/opendatahub-io/ai-helpers/tree/main/plugins/odh-python-packaging/skills/python-packaging-git-audit. TypingMind legge il file SKILL.md e installa la skill, che puoi abilitare per ogni singola chat.

Quali modelli IA possono usare Python Packaging Git Audit?

Qualsiasi modello che colleghi in TypingMind. Le skill IA sono semplici istruzioni in Markdown anziché codice specifico di un fornitore, quindi GPT, Claude, Gemini, Grok e i modelli locali possono tutti caricare questa skill quando una richiesta corrisponde al suo scopo.

Quanti modelli IA posso usare con Python Packaging Git Audit?

Quanti ne vuoi. Se un modello supporta le skill, puoi usarlo con Python Packaging Git Audit: GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama e molti altri, tutti su TypingMind con le tue chiavi API.

La skill IA Python Packaging Git Audit è gratuita?

Sì. È pubblicata su GitHub da opendatahub-io con licenza Apache-2.0. Paghi solo il tuo fornitore IA per i token che usi.

Cosa sono le skill IA?

Una skill IA è un pacchetto di istruzioni riutilizzabili che insegna a un modello IA come svolgere un'attività specifica. Segue il formato aperto Agent Skills: un file SKILL.md con un nome e una descrizione, più eventuali script, modelli o file di riferimento di cui il modello potrebbe aver bisogno. Il modello legge le istruzioni solo quando la tua richiesta corrisponde alla skill, quindi una skill installata non comporta costi finché non viene usata.

In cosa si differenziano le skill IA dai plugin o dai server MCP?

Un plugin o un server MCP fornisce a un modello nuovi strumenti da richiamare: codice che viene eseguito da qualche parte e restituisce un risultato. Una skill IA, invece, fornisce al modello conoscenze e procedure: come affrontare un'attività, quali passaggi seguire e quali caratteristiche deve avere un buon output. Le skill sono semplici istruzioni in Markdown, quindi non richiedono server, chiavi API né ambienti di esecuzione e funzionano con qualsiasi modello.

Vedi tutti

Crea subito la tua area di lavoro IA

Iscriviti alla nostra newsletter per ricevere aggiornamenti sulle nuove funzionalità e sulle prossime iniziative a premi 👇