chore: apply pep8-naming rules for naming convention (#8261)

This commit is contained in:
Bowen Liang 2024-09-11 16:40:52 +08:00 • committed by GitHub
commit 292220c596
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
95 changed files with 287 additions and 258 deletions

View file

@ -26,6 +26,7 @@ class LangfuseConfig(BaseTracingConfig):
host: str = "https://api.langfuse.com"
@field_validator("host")
@classmethod
def set_value(cls, v, info: ValidationInfo):
if v is None or v == "":
v = "https://api.langfuse.com"
@ -45,6 +46,7 @@ class LangSmithConfig(BaseTracingConfig):
endpoint: str = "https://api.smith.langchain.com"
@field_validator("endpoint")
@classmethod
def set_value(cls, v, info: ValidationInfo):
if v is None or v == "":
v = "https://api.smith.langchain.com"

View file

@ -15,6 +15,7 @@ class BaseTraceInfo(BaseModel):
metadata: dict[str, Any]
@field_validator("inputs", "outputs")
@classmethod
def ensure_type(cls, v):
if v is None:
return None