🧀 BigCheese.ai

Social

Extracting financial disclosure and police reports with OpenAI Structured Output

🧀

This gist provides examples of how to use OpenAI's Structured Output feature for extracting data from financial disclosures and police blotters. The gist offers Python scripts and results using the pydantic library to define schemas for parsing documents with minimal to no data preparation.

  • OpenAI introduced a Structured Outputs feature in its API.
  • Data can be extracted as JSON based on user-defined schemas.
  • The model can infer JSON outputs even without explicit schemas.
  • Examples include parsing PDFs and irregular information.
  • Python SDK and pydantic are used in the demo scripts.