🚀 Socket Launch Week Day 5:Introducing Repository Access Permissions and Custom Roles.Learn more
Sign In

@euconform/core

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@euconform/core

Core engine for EU AI Act compliance, risk classification, and fairness metrics.

latest
Source
npmnpm
Version
1.5.0
Version published
Maintainers
1
Created
Source

@euconform/core

Core engine for EU AI Act compliance, risk classification, and fairness metrics.

npm version License: MIT License: EUPL-1.2

Installation

npm install @euconform/core
# or
pnpm add @euconform/core

Features

  • 🎯 Risk Classification – Implements EU AI Act Article 5 (prohibited), Article 6 + Annex III (high-risk)
  • 📊 Bias DetectionCrowS-Pairs methodology (CC BY-SA 4.0) with log-probability analysis
  • 📄 Report Generation – Annex IV-compliant technical documentation
  • 🔒 Privacy-First – All processing happens client-side

Usage

Risk Classification

import { RiskEngine, type RiskClassification } from "@euconform/core";

const engine = new RiskEngine();

const result: RiskClassification = engine.classify({
  useCase: "hiring-automation",
  dataTypes: ["biometric", "personal"],
  autonomyLevel: "high",
});

console.log(result.riskLevel); // "high-risk" | "limited-risk" | "minimal-risk" | "prohibited"
console.log(result.articles);  // ["Article 6", "Annex III.4"]

Bias Testing (CrowS-Pairs)

import { calculateCrowsPairsBias } from "@euconform/core";

const result = await calculateCrowsPairsBias({
  dataset: crowsPairsData,
  engine: inferenceEngine,
  onProgress: (progress) => console.log(`${progress}% complete`),
});

console.log(result.overallBias);      // 0.0 - 1.0 (0 = no bias)
console.log(result.categoryResults);  // Bias breakdown by category

Annex IV Report Generation

import { generateAnnexIVReport } from "@euconform/core";

const report = generateAnnexIVReport({
  systemName: "My AI System",
  provider: "My Company",
  riskClassification: riskResult,
  biasResults: biasResult,
  version: "1.0.0",
});

API Reference

Risk Engine

MethodDescription
classify(input)Classify AI system risk level
getApplicableArticles(input)Get relevant EU AI Act articles
generateCompliance(input)Generate compliance checklist

Fairness Metrics

FunctionDescription
calculateCrowsPairsBias()CrowS-Pairs bias calculation
calculateLogProbBias()Log-probability bias measurement
validateCrowsPairsDataset()Validate dataset format

Report Generation

FunctionDescription
generateAnnexIVReport()Generate Annex IV documentation

⚠️ Important: This package provides technical guidance only. It does not constitute legal advice and does not replace legally binding conformity assessments. Always consult qualified legal professionals for compliance decisions.

License

Dual-licensed under MIT and EUPL-1.2.

Keywords

eu-ai-act

FAQs

Package last updated on 27 Apr 2026

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts