skill-invocation-env / test_schema.py
mpnikhil's picture
Upload folder using huggingface_hub
33bb385 verified
raw
history blame contribute delete
250 Bytes
from pydantic import BaseModel, Field
from typing import Optional
import json
class A(BaseModel):
answer: Optional[str] = Field(None, json_schema_extra={"type": "string", "maxLength": 100000})
print(json.dumps(A.model_json_schema(), indent=2))