Skip to main content
Drupal is a registered trademark of Dries Buytaert
Release: OpenID Connect / OAuth client 3.0.0-alpha9 New alpha version released for module openid_connect (3.0.0-alpha9). Release: Opensolr Search 4.5.0 Minor update available for module opensolr_search (4.5.0). Release: Timelinr 1.0.1 Minor update available for module timelinr (1.0.1). Usage Milestone: Simplify Module simplify crossed 10,000 active installs. Usage Milestone: Views Reference Filter Module entityreference_filter crossed 10,000 active installs. Usage Milestone: Dropdown Language Module dropdown_language crossed 10,000 active installs. Usage Milestone: Paragraphs Browser Module paragraphs_browser crossed 10,000 active installs. Usage Milestone: OpenAPI Module openapi crossed 10,000 active installs. Usage Milestone: Decoupled Router Module decoupled_router crossed 10,000 active installs. Module Revived: Entityqueue Buttons 1.1.2 Module entityqueue_buttons updated after 8 months of inactivity (1.1.2).

This module allows developers to capture and store prompts sent to and outputs received from LLMs as entities. This enables review and debugging of AI interactions. It is recommended to configure storage limits to manage the large amount of data generated.

The recommended route now is to use the AI core module's sub-module "AI Observability".

The AI logging module allows developers to capture prompts sent to and outputs received from LLMs by other modules and store them as entities to allow for review and debugging. Whilst this module is safe to use on a production environment, it stores a large amount of data into the database and so is recommended to keep the maximum quantity and time limits enabled for the amount of logs to store.

Installation

The module should be enabled as normal, which will add the bundleable AI Log entity to the site.

However, due to the large amount of data logging produces, no logging will begin until the module is configured:

  1. Visit /admin/config/ai/logging/settings
  2. Check the "Log requests" checkbox to enable logging of requests.
  3. If you also wish to log the response from the LLM, check the "Log response" checkbox.
  4. All requests sent to an LLM are tagged with the operation type being used: if you only wish to log the request and/or response from specific operations, enter their names in the "Request Tags" box. Multiple tags should be added as a comma-separated list. To find out more about the Operation Types, please refer to the Making AI Base Calls section of the documentation.
  5. Enter the maximum number of log entities to retain: once the number of log entries exceeds this limit, the earliest logs will be deleted.
  6. Enter the number of days to keep log messages for. Once any log message exceeds this age, it will be deleted regardless of the maximum retained number of logs.
  7. Save the configuration, and logging will begin with the next request sent to an LLM. Logs can be viewed at /admin/config/ai/logging/collection.

Drush commands

E.g. drush ai:logs; see the Drush Commands file for full options.

When to use

This module is maintained and compatible with the AI Logging module when it was part of AI Core. It is heavier than AI Observability because it uses a fieldable entity system to store each log as an AI Log.

Consider using the "AI Observability" sub-module of AI Core instead. There is no migration path between the two.

Depends on

Dependencies of the latest stable release

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
7
Tracked since
Dec 2025
Latest release
1 week ago
Releases (12 mo)
7 ▲ from 0
Maintenance
Active

Release Timeline

Releases

Version Type Core Release date
1.3.1 Stable 10–11 Aug 19, 2026
1.3.0 Stable 10–11 Aug 19, 2026
2.0.0-alpha2 Pre-release 10–11 Jul 2, 2026
1.3.0-alpha1 Pre-release 10–11 Jul 2, 2026
1.3.x-dev Dev 10–11 Jul 2, 2026
2.0.0-alpha1 Pre-release 10–11 Dec 18, 2025
2.0.x-dev Dev 10–11 Dec 18, 2025