mcp-server-pp
MCP server for PharmaPendium data extraction — converts extraction results to XLSX, expands drug/concomitant rows, and uploads to Azure Blob Storage.
Tools
save_extraction
Converts a JSON array of extraction results into an XLSX file, uploads it to Azure Blob Storage, and returns a download URL (valid 7 days).
If the user provided corrections or new rules during the extraction session, pass them in notes — they are saved as a separate Notes sheet inside the XLSX for traceability.
Parameters:
json_data(required): JSON array string — extraction results, one object per rowfile_name(optional): Output filename (with or without.xlsx). Defaults toextraction_results.xlsxnotes(optional): User corrections, comments, or new rules applied in this sessionschema(optional): Output layout —auto(default),ae, ornone
AE delivery layout. The LLM's JSON key order drifts between runs, so the column layout is
fixed server-side. With schema: auto (the default) an AE frame is detected by its columns and
rewritten to the PharmaPendium AE delivery headers, in this exact order:
FDAName, Subject, Sex, Age, Route, Dose, Dosage type, Adverse effect, Severity, File name, Page, Duration, Toxicity Parameter, Parameter Comment, Dose Comment, Metabolite name, Metabolite type, Comments, DataFormat
Extraction-schema names are renamed (Drug Name → FDAName, Species → Subject,
Developmental Stage → Age, Dose/Concentration → Dose, Treatment Duration → Duration,
Adverse Effect Comment → Parameter Comment, Substance Inducing AE → Metabolite name,
Substance Inducing AE (Type) → Metabolite type); Comments and DataFormat are emitted empty.
Already-normalized input passes through unchanged, unrecognized columns are appended after the
schema columns (never dropped), and non-AE types (PK/EFF/CT/MET) are left alone. Pass
schema: "none" to write the columns exactly as given.
expand_concomitants
Takes a JSON array of rows (from the built-in Excel tool) with Drug Name and Concomitants columns and rotates each drug into the title slot. The Concomitants cell is parsed as CT-style free text: drugs separated by ;, each entry shaped as Name (aliases), route, dose, dose_comment, duration. For each input row, emits N+1 rows — the promoted drug's parsed metadata populates Drug Name, Route, Dose/Concentration, Dose Comment, and Treatment Duration; the displaced drugs are re-serialized back into Concomitants. All other columns are copied unchanged. Semicolons inside (...) and semicolons followed by non-drug continuations (digits, or/and, bare units) are preserved within a single drug's metadata; bare-name segments at the start of a chunk are merged as combination-drug components (e.g. Elexacaftor; Tezacaftor; Ivacaftor (ELX; TEZ; IVA), orally, ... stays one entry).
Parameters:
json_data(required): JSON array string of row objects — read via the built-in Excel toolfile_name(optional): Output filename (with or without.xlsx). Defaults toexpanded_results.xlsx
Example — one source row becomes three:
| Drug Name | Route | Dose/Concentration | Concomitants |
|---|---|---|---|
| DrugA | oral | 10 mg | DrugB, i.v., 5 mg, daily; DrugC, oral, 20 mg, twice daily |
→
| Drug Name | Route | Dose/Concentration | Concomitants |
|---|---|---|---|
| DrugA | oral | 10 mg | DrugB, i.v., 5 mg, daily; DrugC, oral, 20 mg, twice daily |
| DrugB | i.v. | 5 mg | DrugA, oral, 10 mg; DrugC, oral, 20 mg, twice daily |
| DrugC | oral | 20 mg | DrugA, oral, 10 mg; DrugB, i.v., 5 mg, daily |
Required environment variable: AZURE_STORAGE_CONNECTION_STRING
Usage
With uvx (no installation needed)
uvx mcp-server-pp@1.3.0
MCP client config (e.g. Codemie, Claude Desktop)
{
"mcpServers": {
"pp-tools": {
"command": "uvx",
"args": ["mcp-server-pp@1.3.0"],
"env": {
"AZURE_STORAGE_CONNECTION_STRING": "${AZURE_STORAGE_CONNECTION_STRING}"
}
}
}
}
Metadata
Release files for mcp-server-pp 1.3.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| mcp_server_pp-1.3.0.tar.gz | 74.3 kB | Without provenance | Details for mcp_server_pp-1.3.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| mcp_server_pp-1.3.0-py3-none-any.whl | Python 3 | none | any | Details for mcp_server_pp-1.3.0-py3-none-any.whl |
Total release size: 86.9 kB
Release files / mcp_server_pp-1.3.0.tar.gz
| Download URL | mcp_server_pp-1.3.0.tar.gz |
|---|---|
| Size | 74.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a5bd84d7ec7e69b67b88eac9335c925a80a6f538589ec8731733e57e79161831
|
|
BLAKE2b-256 checksum How to use checksums |
7c4c832fde6a8d6987e3a66d1109cde598951e835b2bf75f0da360d0bc953ff2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.27 {"installer":{"name":"uv","version":"0.11.27","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / mcp_server_pp-1.3.0-py3-none-any.whl
| Download URL | mcp_server_pp-1.3.0-py3-none-any.whl |
|---|---|
| Size | 12.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
714966a51b57f8b63b8111a81d8b306cac68b476dd0149ac1d355cda77224641
|
|
BLAKE2b-256 checksum How to use checksums |
cd7f9682e83de985c607fdf4d4cfd6b3cd5b2e86cef99711b3ee365c46c75d94
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.27 {"installer":{"name":"uv","version":"0.11.27","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Security for mcp-server-pp 1.3.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.