1. Go to this page and download the library: Download rampart/quality-checker library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
bash
# Review the current state without failing
php artisan quality:check --format=all --fail-on=none
# Accept the current findings as a starting point
php artisan quality:check --baseline-generate
# From now on, fail only on new findings
php artisan quality:check --ci --baseline-file=baseline.json
bash
php -d memory_limit=1G bin/quality-check /path/to/project --only=custom --tier=security --fail-on=none --format=json --output=/tmp/out
php tools/sample-findings.php /tmp/out/quality-report.json --n=100 --seed=42 --out=sample.csv
# label sample.csv verdict column TP/FP, then per-rule precision = TP/(TP+FP) — target ≥0.85 for high rules
php tools/inter-rater.php reviewer1.csv reviewer2.csv # kappa ≥0.9 for 8/10
# holdout is automatic: AnalyzerMetricsTest::holdoutCorpus() crc32(id)%5==0