pyomop

pyomop is a Python library/CLI for working with OHDSI OMOP CDM (v5.4/v6) databases using SQLAlchemy. It can create/init CDM tables, load OMOP vocabularies, run QueryLibrary queries, execute custom SQL and convert results to pandas DataFrames. It also includes FHIR Bulk Export (NDJSON/NDJSON) import utilities that map FHIR source values to OMOP concepts, and an optional MCP server exposing tools for database operations and query execution. There is also optional LLM-based natural-language query support via langchain extras.

Evaluated Apr 04, 2026 (16d ago)
Homepage ↗ Repo ↗ Ai Ml ai-ml clinical-trials health-informatics ohdsi omop cdm fhir text-to-sql llm mcp sqlalchemy etl
⚙ Agent Friendliness
58
/ 100
Can an agent use this?
🔒 Security
41
/ 100
Is it safe for agents?
⚡ Reliability
36
/ 100
Does it work consistently?

Score Breakdown

⚙ Agent Friendliness

MCP Quality
86
Documentation
70
Error Messages
0
Auth Simplicity
55
Rate Limits
0

🔒 Security

TLS Enforcement
55
Auth Strength
30
Scope Granularity
20
Dep. Hygiene
50
Secret Handling
55

Strengths/positives: TLS enforcement for database connections may depend on SQLAlchemy/DB settings; package uses standard drivers (asyncpg/SQLAlchemy) rather than custom network protocols. The MCP server supports stdio by default (less exposed). Environment variables for DB credentials are documented (reducing shell-history leakage). Concerns: no explicit authN/authZ for MCP tools (especially HTTP transport) is described; MCP includes tools that can execute SQL, increasing impact if exposed to untrusted users. No evidence of fine-grained tool-level scoping or audit logging. Dependency hygiene is not verifiable from provided content; presence of several external packages increases need for routine vulnerability scanning.

⚡ Reliability

Uptime/SLA
0
Version Stability
55
Breaking Changes
45
Error Recovery
45
AF Security Reliability

Best When

You control the database and runtime environment (local/managed instance), and you want a developer-friendly toolkit for OMOP CDM setup, querying, and some ETL (FHIR import), optionally with agent access via MCP.

Avoid When

You need strong, standardized API authentication/authorization, auditing, and strict operational guardrails for untrusted users—especially for an HTTP-exposed MCP server and for tools that can execute SQL.

Use Cases

  • Creating and initializing OMOP CDM schemas (SQLite/PostgreSQL/MySQL).
  • Loading OMOP vocabulary CSVs and reconciling vocabulary.
  • Running OHDSI QueryLibrary predefined queries and exporting results to pandas.
  • Executing custom SQL against OMOP CDM and converting results to DataFrames.
  • Importing FHIR Bulk Export data into OMOP CDM with vocabulary reconciliation using provided mapping configs.
  • Using an MCP client to programmatically create/load/run SQL against an OMOP CDM database.

Not For

  • Production-grade managed access control for multi-tenant environments (no evidence of robust authN/authZ).
  • Internet-facing services without additional deployment hardening (package appears primarily developer/CLI focused).
  • Environments where deterministic/repeatable query generation from LLMs is required (LLM support is optional and depends on external models/prompts).

Interface

REST API
No
GraphQL
No
gRPC
No
MCP Server
Yes
SDK
Yes
Webhooks
No

Authentication

Methods: Local usage / direct DB credentials via connection parameters or environment variables (PYOMOP_DB/HOST/PORT/USER/PW/SCHEMA). MCP server via stdio default; HTTP transport available (requires dependencies), but explicit auth mechanisms not described in provided README.
OAuth: No Scopes: No

Authentication/authorization for database access appears to be delegated to the target DB credentials supplied by the user. For the MCP server, transport options are described, but no explicit MCP authN/authZ, API keys, or scope enforcement are documented in the provided materials.

Pricing

Free tier: No
Requires CC: No

No hosted service pricing is indicated; this is a library/CLI. LLM extras may incur external model/provider costs depending on configuration.

Agent Metadata

Pagination
none
Idempotent
False
Retry Guidance
Not documented

Known Gotchas

  • SQL execution tools can modify databases; agents should use check_sql/validation and constrain scope before run_sql.
  • create_cdm/create_eunomia limited to local sqlite to avoid inadvertent data loss—agents should respect those constraints to prevent unexpected failures.
  • HTTP transport is available for MCP but no authentication guidance is provided; avoid exposing publicly without external safeguards.
  • LLM-based natural language query generation quality depends heavily on prompt/model configuration and may require validation via check_sql before executing.

Alternatives

Full Evaluation Report

Comprehensive deep-dive: security analysis, reliability audit, agent experience review, cost modeling, competitive positioning, and improvement roadmap for pyomop.

AI-powered analysis · PDF + markdown · Delivered within 30 minutes

$99

Package Brief

Quick verdict, integration guide, cost projections, gotchas with workarounds, and alternatives comparison.

Delivered within 10 minutes

$3

Score Monitoring

Get alerted when this package's AF, security, or reliability scores change significantly. Stay ahead of regressions.

Continuous monitoring

$3/mo

Scores are editorial opinions as of 2026-04-04.

8642
Packages Evaluated
17761
Need Evaluation
586
Need Re-evaluation
Community Powered