Skip to content

Commit

Permalink
fix model schema file type (#43)
Browse files Browse the repository at this point in the history
  • Loading branch information
kenho811 authored Oct 15, 2023
2 parents 7c21adf + 9489dd0 commit e6844e7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion scripts/dump_model_schemas.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@ def main(output_folder_path: Path):
models: List[BaseModel] = sum([entry.models for entry in ProcessorRegistry().registry], [])
for model in models:
print('============================')
file_path = output_folder_path.joinpath(model.model_name)
file_name = f"{model.model_name}.json"
file_path = output_folder_path.joinpath(file_name)
schema: Dict = model.model_json_schema()
with open(file_path, 'w') as schema_file:
schema_str: str = json.dumps(schema, indent=4)
Expand Down

0 comments on commit e6844e7

Please sign in to comment.