Example: Analytics on Medical Documents
In this example, we will walkthrough how you can use our APIs to extract key features from thousands of medical documents in seconds.
✅ Goal
We will be analyzing a dataset of dummy pathology reports. We’ll upload the reports to Trellis, and use Trellis’s extraction and classification operations to process these reports.
🏁 Alright, let’s get started!
1. Get your API key
First, go to https://dashboard.runtrellis.com/sign-up and create your account. Then, click settings
on the lower right or visit the setting page and copy your API key.
2. Set your API key
3. Create a Project to put your data
Each project has a unique ID. You can use this ID to refer to the project in the data upload process.
4. Define the transformation you want
A transformation is a set of operations that define a custom data extraction pipeline for your assets. In this example, we want to extract the following key information:
-
subject
: Who is the subject of the report? -
gender
: What is the gender of the subject? -
diagnosis
: What is the ultimate diagnosis? -
original_company
: The healthcare company issuing the report. -
comments
: A list of extra comments, if they exist.
Define your first Transformation!
To learn all about what Trellis Transformations have to offer, read our guide here!
5. Create event triggers to automatically run the extraction and transformation
6. Upload the data to the project
Since we created the event triggers in the earlier step, the extraction and transformation will automatically run on the data we upload.
Note: If you set up the project and transformation in the dashboard, the event triggers should already be set up for you.
Now, it’s time to upload the medical reports to our transformation. For illustrative purposes, we will only upload 3 documents.
Tip: If you have files locally instead of presigned URLs, you can use create presigned URLs endpoint to generate the presigned URLs to upload to Trellis.