mirror of
https://github.com/Mintplex-Labs/langchain-python.git
synced 2026-08-27 09:21:30 -04:00
af8f5c1a49
- Added self-critique constitutional chain based on this [paper](https://www.anthropic.com/constitutional.pdf).
11 lines
265 B
Python
11 lines
265 B
Python
"""Models for the Constitutional AI chain."""
|
|
from pydantic import BaseModel
|
|
|
|
|
|
class ConstitutionalPrinciple(BaseModel):
|
|
"""Class for a constitutional principle."""
|
|
|
|
critique_request: str
|
|
revision_request: str
|
|
name: str = "Constitutional Principle"
|