TypeSafe AI Provider connects TypeSafe AI to Drupal's AI module. Use it to classify and moderate content, route requests, score submissions, and build workflows that act on structured AI results.
TypeSafe's Jev models evaluate text or structured data using three question types:
- Choice: Select an option from a defined set, with probabilities for each option.
- Score: Rate input against ordered levels you define, such as customer frustration or issue severity.
- Noul: Return the probability that a condition holds, such as whether a message requests a refund.
Combine independent questions in one request, then use the results in your Drupal application. See the TypeSafe API reference for the question and response formats.
Building with a coding agent? The official TypeSafe skill helps your agent design questions, batch evaluations, and use current documentation. Installation instructions are included below.
Features
- Standard Drupal AI text classification with probabilities for every supplied label.
- Standard Drupal AI moderation against policy categories you define, with a configurable flag threshold and a probability for every category. Use it to screen other providers' requests through Drupal AI's external moderation.
- A
system_oneoperation for mixed Choice, Score, and Noul questions. - Integration with Drupal AI request, response, and exception events.
- API key management through the Key module.
- Model discovery, response validation, and token usage metadata.
This provider supports structured evaluations. It does not provide chat generation, embeddings, or image generation. Integrations using system_one must explicitly support that operation.
Requirements
Quickstart
Enable and configure the provider
- Install the module:
composer require 'drupal/ai_provider_typesafe, then enable it the usual way. - Create an authentication key at
/admin/config/system/keys/add. Use a file or environment key provider to keep the secret out of exported configuration. - Open
/admin/config/ai/providers/typesafe, select your key, and save. The form checks access to TypeSafe's model list. The same page holds the moderation categories and threshold. - Select TypeSafe in a compatible Drupal AI integration, or call the provider from your own code. To moderate another provider's requests, add
typesafe__jev-latestat/admin/config/ai/ai-external-moderation.
Develop with the TypeSafe skill
The skill is optional for development and is not a dependency. Choose one installation method from your project directory.
Claude Code:
claude plugin marketplace add typesafe-ai/skills claude plugin install typesafe@typesafe-ai
Other supported agents:
npx skills add typesafe-ai/skills --skill typesafe-aiSelect your agent when prompted. You can also read the skill directly or give your agent the raw Markdown. Then ask it to use the TypeSafe skill when working on this project.
See the TypeSafe skill installation guide and TypeSafe documentation for more examples.
Project information
- Project categories: Artificial Intelligence (AI)
- Ecosystem: AI (Artificial Intelligence)
- Created by doxigo on , updated
Stable releases for this project are covered by the security advisory policy.
There are currently no supported stable releases.
Releases
Development version: 1.0.x-dev updated 28 Sep 2026 at 10:29 UTC


