# ai\_code\_commit\_file\_sessions

Links commit files to tool/session ID pairs, including before sessions arrive. Links are unique per file, session ID, and logical tool, so one file can link the same ID under several tools. Tenants not yet migrated collapse a multi-tool ID to one \_\_unqualified\_\_ link.

Group: ai

[All tables](/schema.md)

[View HTML reference](https://docs.getdx.com/schema/ai_code_commit_file_sessions/)

| Column | Type | Description | References |
| --- | --- | --- | --- |
| id | number | Unique identifier for the row. |  |
| ai\_code\_commit\_file\_id | number | ID of the associated AI code commit file. | [ai\_code\_commit\_files](/schema/ai_code_commit_files.md) |
| session\_external\_id | string | External session identifier supplied by the tool. Match using ai\_tool as well. Unknown tools (NULL, whitespace-only, or \_\_unqualified\_\_) match only when exactly one tool has that external ID. Matching without the tool can count a link toward several sessions. | [ai\_sessions](/schema/ai_sessions.md) |
| ai\_tool | string | Explicit tool, or tool inferred from one usable stored session for legacy input. NULL, PostgreSQL whitespace-only strings and \_\_unqualified\_\_ share one logical unknown identity in the pair index and reconciliation, using the column's collation as the existing backfill does. New unknown writes use \_\_unqualified\_\_; equivalent older values can remain untouched on replay. Real tool labels remain verbatim. |  |
| row\_created\_at (DX internal) | date | When DX created this database row. |  |
| row\_updated\_at (DX internal) | date | When DX last updated this database row. |  |
