Pydantic AI 1.107
Last reviewed Oct 12, 2026
Prompt Details
Prompt Composition
3prompts
- Python 3155 lines · 3.8K tokens
- Pydantic 2.1356 lines · 1.3K tokens
- Pydantic AI 1.107176 lines · 7.9K tokens
Total387 lines · 13K tokens
CWE Coverage
- 20
- 23
- 36
- 59
- 78
- 89
- 95
- 117
- 201
- 208
- 209
- 214
- 250
- 295
- 306
- 319
- 328
- 338
- 346
- 347
- 352
- 367
- 379
- 407
- 409
- 416
- 426
- 427
- 459
- 470
- 488
- 502
- 522
- 532
- 611
- 639
- 674
- 732
- 770
- 772
- 776
- 807
- 829
- 862
- 915
- 916
- 918
- 942
- 1104
- 1284
- 1287
- 1333
- 1395
- 1426
- 1427
Prompt Preview
Apply the Pydantic 2.13 and Python 3 prompts first, then these rules for agents built on pydantic-ai 1.107. V1 is a security-maintenance line: it carries both the original Agent(...) keyword surface and the newer capabilities= surface, and several defaults differ from V2, so verify a rule against the V1 API before applying it here.
Version scope and support window
- Run the newest V1 release of
pydantic-ai(orpydantic-ai-slim) and lock it in the lock file. Pydantic AI ships V1 security fixes only as new V1 patch releases, and its advisories don't always reach the databasespip-auditand OSV-Scanner read, so take each one when it ships rather than holding the release these rules were checked against or waiting for a scanner to flag it. - Treat V1 as security-maintenance work. The published policy promises security fixes for at least six months from the 2026-06-23 V2 stable release, so the window closes no earlier than 2026-12-23; schedule the V2 migration rather than adding new surface here.
- Read V1 behavior from the repository tag of the V1 release you run. The documentation site now describes V2, whose defaults differ.
- Resolve every deprecation before migrating: most of what V2 removes is already deprecated in V1 as of 1.100.0, and each
PydanticAIDeprecationWarningnames its replacement. Do not silence those warnings globally, or you lose the migration checklist. - Choose a security-supported CPython minor compatible with every deployed integration. Within this line's advertised Python 3.10 through 3.14 range, use 3.11 through 3.14: 3.10 is end of