blacklist->findInPressRelease($pressRelease); if ($word !== null) { return new ClassificationResult( classification: PressReleaseClassification::Red, reasons: [sprintf('Unzulässiges Wort gefunden: "%s".', $word)], provider: 'deterministic', model: null, rawResponse: ['matched_word' => $word], ); } return new ClassificationResult( classification: PressReleaseClassification::Green, reasons: [], provider: 'deterministic', model: null, rawResponse: ['matched_word' => null], ); } }