Thanks for your interest in making AI agents safer! 🏰
node bin/clawmoat.js testAll 37 tests must pass before submitting a PR.
- Create your scanner in
src/scanners/your-scanner.js - Export a
scan(input, options)function that returns{ blocked, threats, score } - Register it in
src/index.js - Add tests in
test/— aim for both detection and false-positive coverage - Update
README.mdwith the new feature
Scanner template:
function scan(input, options = {}) {
const threats = [];
// Detection logic here
return {
blocked: threats.length > 0,
threats,
score: threats.length > 0 ? 1.0 : 0.0,
};
}
module.exports = { scan };- Tests required — every PR must include tests and all existing tests must pass
- Zero dependencies — ClawMoat has zero runtime dependencies. Do not add any. Use Node.js built-ins only.
- One concern per PR — keep PRs focused and reviewable
- Describe what and why — include context in your PR description
- CommonJS (
require/module.exports) - No semicolons (match existing style — check the codebase)
- Descriptive variable names
- Keep functions small and focused
- No external linters or formatters required — just match what's there
Looking for a place to start? Check out issues labeled good first issue.
Open an issue — we're happy to help.