Udemy
    •  
    •  
    •  
    •  
    •  
    •  
    •  
    •  
Turn what you know into an opportunity and reach millions around the world.
Learn More
Your cart is empty.
Keep shopping
GPT5 Prompt Engineering for structured outputs
3 students

GPT5 Prompt Engineering for structured outputs

Using Pydantic and OpenRouter for a biomedical dataset
Last updated 9/2025
English

What you'll learn

  • How to use OpenRouter to extract structured data using any LLM
  • How to use Pydantic to specify complex schemas for extracting structured outputs
  • A workflow for engineering your prompts to get the best results
  • A system which helps you estimate the accuracy of an LLM for single valued fields

Course content

4 sections22 lectures1h 29m total length
  • Easily separate AI hype from actual progress2:16
  • Learn about real capabilities of LLMs1:42
  • Keep on top of developments in LLM reasoning2:12
  • Agentic AI1:16

Requirements

  • Fairly proficient in Python
  • You should already know how to use Jupyter
  • Preferable: basic knowledge of the spaCy NLP library

Description

"I’ve suspected for a while that the single most commercially valuable application of LLMs is turning unstructured content into structured data. That’s the trick where you feed an LLM an article, or a PDF, or a screenshot and use it to turn that into JSON or CSV or some other structured format."


Simon Willison, prolific LLM blogger and creator of Django, 28 Feb 2025


There are three forces converging in LLMs right now


1 LLMs are becoming much cheaper. For example, OpenAI's o1 pro cost $600 per million output tokens. Now OpenAI's flagship model GPT5 costs $10 per million output tokens, a factor of 60x


2 LLMs are becoming very good at extracting structured data which conforms to a JSON schema, even if it requires a little bit of reasoning ability


3 Open source LLMs are also becoming extremely competitive in terms of output quality


As a result, it has become much easier to extract structured data from text over the last year using LLMs, and there are also a lot more LLMs to choose from for this task.


You can get the most out of this investment by engineering your prompts.


This course teaches you a systematic approach for prompt engineering so as to make the most out of your LLM investment. 


Who should take this course?


Everyone who is interested in extracting structured information using LLMs can benefit from taking this course.


Biomedical NLP


Note: I do NOT have a background in biomedicine, but I have now spent over two years on a volunteer project which requires the use of practical NLP tools to extract information from a popular biomedical dataset and have done so quite successfully.


As a student, you do not need to have a background in biomedicine either to complete this course, but it does help if you have an interest in the subject.

Who this course is for:

  • Intermediate Python developers who want to learn how to use GPT5 and other LLMs to extract structured information from any dataset