VALUE_OUT_OF_RANGE error with "ai" collection after recent updates

Hi there,

I’m facing a critical issue with a collection I’ve been using for a long time.

The Issue: I have a collection named “ai”. It has been working perfectly until recently. However, now I’m getting a VALUE_OUT_OF_RANGE error whenever I try to manage fields or set up relationships (like M2O) with this collection.

Error Message:

JSON

{
  "errors": [
    {
      "message": "Numeric value \"ai\" for field \"collection\" in collection \"directus_fields\" is out of range.",
      "extensions": {
        "collection": "directus_fields",
        "field": "collection",
        "value": "ai",
        "code": "VALUE_OUT_OF_RANGE"
      }
    }
  ]
}

My Assumption: I suspect this is happening because Directus recently introduced its own native AI features. It seems like the internal system is now trying to treat the string "ai" as a numeric value or a reserved system ID, causing a collision with my existing collection name.

Questions:

  1. Is “ai” now a reserved keyword or restricted name in recent versions?

  2. Why is the collection field in directus_fields trying to parse my collection name as a numeric value?

  3. Is there any way to fix this without renaming my entire collection (which would break my current API integrations)?

Any help or workaround would be greatly appreciated. Thanks!

Directus does not use “ai” as a reserved or restricted name in any current or recent versions. Recommend checking the following:

  • clear and confirm cache refreshed
  • confirm the “directus_fields.collection” field column is a varchar string type - it should not be a numeric type
  • did anything go wrong with migrations during an upgrade (may need to rerun migrations)

If you have any other information about your set up let us know. I tested by creating a new collection “ai” with fields and added some data with no issues in one of my projects.