# Lucid Schema Generation and Model Class Naming Updates

Canonical URL : https://adonisjs-signal.jrmc.dev/insights/2683de2d-0a62-4af9-9372-af2097a828c0
Source release or documentation date : 2026-11-19T07:05:56.000Z
Category : documentation | Developer impact : medium
Affected packages : @adonisjs/lucid

The Lucid ORM documentation has been updated to clarify the schema generation process and model class naming conventions\. Generated schema classes now use the singular PascalCase table name followed by 'Schema' \(e\.g\., 'PostSchema' for the 'posts' table\)\. Models extend these schema classes and do not inherit the static table property; instead, the model class name determines the table name unless explicitly overridden\. For tables in non\-default schemas, schema class names are prefixed with the schema name to avoid collisions \(e\.g\., 'AppOrderSchema'\)\. The documentation also includes examples of model definitions, hooks, relationships, and query scopes updated to reflect these naming conventions\.

## What this means for your code

Developers should update their model imports and class extensions to use the singular PascalCase schema class names instead of plural forms\. They should also be aware that the static table property is no longer inherited from schema classes and must be set explicitly on models when dealing with tables outside the default schema\. This change improves clarity and consistency in schema generation and model definitions but does not introduce breaking API changes if followed correctly\.

## Suggested actions

- Update model imports to use singular PascalCase schema class names \(e\.g\., import \{ PostSchema \} from '\#database/schema'\)\.
- Extend models from the singular schema classes \(e\.g\., class Post extends PostSchema \{\}\)\.
- Set static table property explicitly on models for tables outside the default schema \(e\.g\., static table = 'app\.orders'\)\.
- Review and update model hooks, relationships, and query scopes to use the new schema class names\.
- Regenerate schema files using 'node ace schema:generate' after updating rules or migrations\.

## Updated documentation

- [Configuration](https://lucid.adonisjs.com/docs/configuration)
- [Installation and usage](https://lucid.adonisjs.com/docs/installation)
- [Introduction](https://lucid.adonisjs.com/docs/introduction)
- [Schema generation](https://lucid.adonisjs.com/docs/schema-generation)
- [Hooks](https://lucid.adonisjs.com/docs/model-hooks)
- [Introduction](https://lucid.adonisjs.com/docs/models)
- [Query builder](https://lucid.adonisjs.com/docs/model-query-builder)
- [Query scopes](https://lucid.adonisjs.com/docs/model-query-scopes)
- [Schema classes](https://lucid.adonisjs.com/docs/schema-classes)
- [Serializing models](https://lucid.adonisjs.com/docs/serializing-models)
- [BelongsTo](https://lucid.adonisjs.com/docs/belongs-to)
- [HasMany](https://lucid.adonisjs.com/docs/has-many)
- [HasManyThrough](https://lucid.adonisjs.com/docs/has-many-through)
- [HasOne](https://lucid.adonisjs.com/docs/has-one)
- [Introduction](https://lucid.adonisjs.com/docs/relationships)
- [ManyToMany](https://lucid.adonisjs.com/docs/many-to-many)

## Original sources

- [lucid\.adonisjs\.com: 16 documentation file\(s\)](https://github.com/adonisjs/lucid.adonisjs.com/compare/663a9322a8d3db22c479681782f9f12e9c06bc78...c2734269085b174dacff52decbcad665bdbf37ae)

AI-generated analysis based on the linked sources. Check the original documentation before changing your application.
