Commit Graph
23 Commits
Author SHA1 Message Date
Timothy Kassis 3956e5408b feat: enhance skill security scan for forked PRs
- Added handling for missing SKILL_SCANNER_LLM_API_KEY in forked pull requests.
- Implemented a sticky comment to inform users when the scan is skipped due to the absence of the API key.
- Updated workflow documentation to clarify the behavior of the scanner in forked contexts.
2026-08-10 16:14:49 -07:00
Timothy Kassis 4fb7e0bc29 Test every script-bearing skill, and enforce that it stays that way
AGENTS.md has always said that a skill shipping scripts/ puts its tests in
tests/<name>/, but nothing checked it: 54 of the 100 such skills had no suite
at all, including docx, pptx, xlsx, pdf and scanpy. All 100 now do.

tests/_meta is the guard. It runs the shared structural contract across every
skill in a single process -- safe because it parses scripts with ast and never
imports them -- and fails when a skill ships scripts/ without a suite or
without a [skills.<name>] entry in skill-requirements.toml. It needs no
scientific packages and finishes in seconds, so skill-tests.yml blocks every
pull request on it, plus the packages=[] suites.

tests/_contract holds what the per-skill suites were each reimplementing:
frontmatter conformance, the 500-line limit, no tests or bytecode under
skills/, local links resolving, scripts parsing, no eval/exec/os.system, no
standard-library shadowing, no hardcoded local paths, valid shell scripts. Also
the --help contract, which skips when a skill's packages are absent and runs
for real under --isolated, and shared behaviour for the files docx/pptx/xlsx
and five schematic-shipping skills carry byte-identical copies of, with drift
detection so they cannot diverge silently.

67 new suites, 3325 test functions. The existing suites were retrofitted: 18
no longer pin an exact skill version, so a version bump no longer breaks a
test; 11 duplicated structural methods removed; 19 wired to the --help
contract; and 5 that failed collection without their packages now skip
cleanly. run_all.py in the bare project environment goes from 6 failures to 0.

Writing the tests surfaced 19 defects in the skills, fixed here with version
bumps. The ones that changed scientific output:

  - openpiv reported vorticity 0 for a rotating flow, from a sign error in
    openpiv's y-up coordinate relabelling; solid-body rotation now gives 2w
    exactly, on grids of either orientation
  - deepchem returned solubility predictions in z-scored space while labelling
    them log(mol/L), because it transformed a y-less dataset instead of
    untransforming the output
  - neuropixels-analysis had the Allen and IBL ISI thresholds swapped,
    contradicting its own references/QUALITY_METRICS.md and inverting the two
    standards' relative strictness
  - scanpy's summarize() raised TypeError on every AnnData under anndata 0.13,
    which reports an unnamed None key on .layers; scanpy convert was broken
  - experimental-design's Latin hypercube was never reproducible: pyDOE3 draws
    from its own default_rng and ignores numpy's global seed
  - primekg shipped a hardcoded path naming a person, which is why
    no_personal_paths is now a contract rule

The remainder is upstream API drift, each verified against the installed
package: retired symbols in bioservices 1.16, gget helpers that returned lists
where a string was written, ArviZ 1.x kwargs in pymc, a positional-only
factory in pymoo, ReduceLROnPlateau(verbose=) in torch 2.13, a removed scvelo
parameter, and PyPDF2 in scientific-slides.

Two manifest environments could not build and are pinned: gget, where an
unpinned scanpy walked back to 1.9.8 and pulled llvmlite 0.36 which does not
compile on 3.13, and pymatgen, pinned to the snapshot its own _common.py
enforces rather than loosening that check. deepchem gains torch, without which
no model class exists.

python tests/run_all.py --isolated: 101 passed, 0 failed.
2026-07-28 10:20:12 -07:00
Timothy Kassis b085e116c5 Update skill metadata formatting and improve .gitignore entries
- Revised the metadata format in multiple SKILL.md files to use block mapping instead of single-line JSON, enhancing YAML compatibility.
- Added a new entry for local agent tooling in .gitignore to exclude the .claude directory, improving project cleanliness.
- Removed outdated entries for AGENTS.md and CLAUDE.md from .gitignore, streamlining ignored files.
2026-07-26 09:29:16 -07:00
Timothy Kassis 489de4ce4c Update security documentation and scanning process
- Clarified the security scan report generation process in README.md, emphasizing the publication of results.
- Revised `scan_skills.py` documentation to reflect changes in report generation and the removal of the validate_report.py script.
- Updated SECURITY.md to specify the scope of vulnerabilities and improved clarity on the report's purpose and limitations.
- Adjusted the security scan workflow to remove the validation step, streamlining the process while ensuring accurate reporting.
2026-07-26 08:16:14 -07:00
Timothy Kassis 665663cac1 perf(security-scan): scan concurrently and reuse unchanged results
Scans were sequential at ~29s per skill: 72 minutes for 150 skills against a
120-minute workflow timeout. Each scan is blocked on LLM network I/O rather
than local CPU, so the work parallelizes.

- Run skills through a thread pool (SKILL_SCAN_WORKERS, default 8), building
  one scanner per worker thread rather than sharing one, since the analyzers
  carry mutable per-scan state. Rate-limit retry with backoff already exists
  inside cisco-ai-skill-scanner, so concurrency is bounded, not retried here.
- Reuse findings for skills whose package contents are unchanged, keyed on a
  SHA-256 over file paths and bytes. Invalidate on scanner version change,
  model change, --full, or a 30-day backstop from the last full scan.
- Record per-skill content_hash and last_scanned in the JSON report, and
  disclose carried-forward findings in the markdown header, so a reused
  finding always shows when it was actually produced.
- Sort report entries by skill name so worker completion order does not churn
  the committed JSON.
- Lower the workflow timeout to 60 minutes; add a full_scan dispatch input.

Also fixes skills/genomic-intelligence/SKILL.md, whose unquoted description
contained a colon-space that made its YAML frontmatter invalid. The loader had
been rejecting it silently, so every scan covered 149 of 150 skills.
2026-07-25 15:11:47 -07:00
Timothy Kassis d77f819637 Update security scanning process and documentation
- Enhanced the README to clarify the publication of security scan results to a dedicated markdown file.
- Modified `scan_skills.py` to generate both a human-readable report and a machine-readable JSON report, ensuring consistency checks before CI publishing.
- Updated the GitHub Actions workflow to validate the scan report and commit the new reports, replacing the previous SECURITY.md approach with separate report files.

This change improves the clarity and accessibility of security information for users and contributors.
2026-07-25 14:55:40 -07:00
Timothy Kassis edefe50783 Update default LLM model in security scan workflow to "claude-sonnet-5" 2026-07-25 13:46:10 -07:00
Timothy Kassis 878519452f Update directory for compatibility 2026-05-27 15:54:01 -07:00
Timothy Kassis aaf95ee57b chore: update version of scientific-agent-skills to 2.37.1 2026-04-17 16:34:45 -07:00
Timothy Kassis 747e003b9e chore: improve security scan workflow by adding git stash commands to handle untracked files 2026-04-11 10:53:44 -07:00
Timothy Kassis 968bf2a2e3 chore: update security scan workflow to use latest action versions
- Upgraded actions/checkout from v4 to v6 for improved performance and features.
- Updated astral-sh/setup-uv from v5 to v8.0.0 to leverage new capabilities and optimizations.
- Removed unnecessary environment variable setting for JavaScript actions.
2026-04-11 08:23:11 -07:00
Timothy Kassis 2550d1a89a chore: enhance security scan workflow by adding git pull --rebase before push 2026-04-11 05:12:01 -07:00
Timothy Kassis 398fc377c6 Update project metadata in pyproject.toml and remove marketplace.json
- Updated version to 2.34.2 and enhanced project description in pyproject.toml.
- Removed obsolete marketplace.json file as its functionality is now integrated into the project structure.
- Adjusted GitHub Actions workflow to reference pyproject.toml instead of marketplace.json for version extraction.
2026-04-10 13:46:41 -07:00
Timothy Kassis e0b68aa2f3 Update Python version in security scan workflow to 3.13 and adjust dependency installation command 2026-04-10 13:38:11 -07:00
Timothy Kassis 8b4e35c50b Update .gitignore and enhance security scan workflow
Removed unnecessary entries from .gitignore and added environment variable to the security scan workflow for improved compatibility with Node.js 24.
2026-04-10 13:36:45 -07:00
Timothy Kassis 0303a33f1e Enhance security scan configuration for improved vulnerability detection 2026-04-10 13:30:52 -07:00
Timothy Kassis 1346c01d9d Bump version 2026-03-18 12:22:31 -07:00
Timothy Kassis 4b7c910bb5 Add Skill scanner 2026-03-03 08:29:54 -08:00
Timothy Kassis d452499891 Merge pull request #68 from salmanmkc/upgrade-github-actions-node24
Upgrade GitHub Actions for Node 24 compatibility
2026-03-03 07:55:04 -08:00
Salman Muin Kayser Chishti e62b0eb98b Upgrade GitHub Actions to latest versions
Signed-off-by: Salman Muin Kayser Chishti <13schishti@gmail.com>
2026-03-02 09:20:16 +00:00
Salman Muin Kayser Chishti 5e62d71168 Upgrade GitHub Actions for Node 24 compatibility
Signed-off-by: Salman Muin Kayser Chishti <13schishti@gmail.com>
2026-03-02 09:20:08 +00:00
Timothy Kassis 9584469988 Refactor release notes generation in workflow to remove version header and streamline output 2025-10-22 08:21:43 -07:00
Timothy Kassis 685da0082c Add automatic releases 2025-10-22 08:17:56 -07:00