Skip to main content

Clinical entity extraction schema for MESA

Project description

Entityschema

Schema package for clinical entity extraction from NHS medical documents.

Structure

📁 entityschema
├── examples/            # Training examples showing document input and structured output
├── schema.py            # Pydantic model for specifying expected output structure
├── prompt_builder.py    # Prompt builder for data generation and inference
├── prompt_datagen.txt   # Prompt template with example (for training data generation)
├── prompt_main.txt      # Prompt template without example (for inference/deployment)
└── py.typed             # Type checking marker

Usage

from entityschema.prompt_builder import PromptBuilder

# Initialize builder
builder = PromptBuilder()

# Build data generation prompt (with example)
datagen_prompt = builder.build_datagen_prompt()

# Build main/inference prompt (without example)
main_prompt = builder.build_main_prompt()

License

This project uses a proprietary license issued by Guy's and St Thomas' NHS Foundation Trust (see LICENSE.md).

The contents of this repository are designed for NHS organisations to use on private data.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

londonaicentre_entityschema-1.0.0.tar.gz (36.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

londonaicentre_entityschema-1.0.0-py3-none-any.whl (37.6 kB view details)

Uploaded Python 3

File details

Details for the file londonaicentre_entityschema-1.0.0.tar.gz.

File metadata

  • Download URL: londonaicentre_entityschema-1.0.0.tar.gz
  • Upload date:
  • Size: 36.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.17 {"installer":{"name":"uv","version":"0.11.17","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Amazon Linux","version":"2023","id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for londonaicentre_entityschema-1.0.0.tar.gz
Algorithm Hash digest
SHA256 ba4bd32bf4083728e1b59b861354648b322a20c5cd384fc1965a243813f8e046
MD5 ca6dc15745fd0517a7cfa1e69bdc199f
BLAKE2b-256 2b37829f326ad417e86273679f8a263d1909fabe98526edb66a989ed5fa4068b

See more details on using hashes here.

File details

Details for the file londonaicentre_entityschema-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: londonaicentre_entityschema-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 37.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.17 {"installer":{"name":"uv","version":"0.11.17","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Amazon Linux","version":"2023","id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for londonaicentre_entityschema-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 1cf9e3ec1c83f8fb29badb02be20a7add7e47d407abb9b8bb31cb103777e7844
MD5 ce0875b1fa1305f96c3c6eab7d0bcd1e
BLAKE2b-256 572702d886770ec94d81c90bbd5e050f3ce7c75b2a12578906b4ebd5857f824e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page