AI Blocks › Build and ship software
Structured data extractor
Say what fields you need. Get code that pulls them from AI replies as checked data, retrying on errors.
Structured data extractor is a free AI skill for the job "Build and ship software". Give the instructions to an AI assistant that supports the required files and tools, then review its output.
Free · No account · MIT licence · Made by Orchestra Research
Made by Orchestra Research. See the original on GitHub; we copied it as it is, with its licence.
What it does
Code that turns an AI's free-text reply into clean, checked data your program can use. You say which fields you want, such as name, date and amount, and get a short Python setup with the Instructor library. You define the shape of the answer with Pydantic, and each reply is checked against it. If a field is missing or the wrong type, the error goes back to the AI and it tries again, up to a limit you set. It handles nested data, lists and optional fields, can stream partial results, and works with Claude, OpenAI and other providers. You need Python, a package install and an API key for your AI provider.
You give it
- The fields you want to extract
- Example text to read from
- Your AI provider and API key
- Rules for valid values (optional)
You get
- A data model for your fields
- Extraction code with automatic retries
- Validation rules
- Example runs on your text
- Optional streaming code
Use it when
- Your script breaks when the AI adds extra words around its JSON.
- You need to pull names, dates and amounts from many documents.
- You want wrong values caught automatically before they reach your database.
- You may change AI provider later and want the same code to work.
How to use it
- Add it to your AI once: download it and add the folder to Claude, ChatGPT or Codex as a skill.
- Ask for the job in your own words. Your AI opens the skill when it fits.
- It works best when your AI can run Python code and call an AI model.