
直接从 Claude 查询 AACT(ClinicalTrials.gov)数据库。使用只读 SQL 探索 70+ 张临床试验数据表——研究、干预措施、结局、赞助商、机构......
概览
直接从 Claude 查询 AACT(ClinicalTrials.gov)数据库。使用带缓冲分页的只读 SQL 探索 70+ 张临床试验数据表——研究、干预措施、结局、赞助商、设施。 ClinicalTrials.gov API 每次试验返回一条 JSON 记录——方便快速查找,但分析时不便。想要 2020-2025 年间第二阶段 NSCLC 试验的平均持续时间吗?用 API 你可以过滤试验,从每个 JSON 记录中提取日期,然后在客户端计算持续时间。而 AACT 只需一个 SQL 查询。 结构化的PostgreSQL数据库能让你以任何需要的方式更容易获取临床试验数据。对于AI辅助分析,SQL是大型语言模型处理极佳的标准——错误更少,上下文管理更少,性能更好,成本也更低,相较于解析定制API响应。 这是一个独立的第三方集成。
概述(AI 翻译)
直接从 Claude 查询 AACT(ClinicalTrials.gov)数据库。使用带缓冲分页的只读 SQL 探索 70+ 张临床试验数据表——研究、干预措施、结局、赞助商、设施。
为什么选择AACT而不是 ClinicalTrials.gov API?
ClinicalTrials.gov API 每次试验返回一条 JSON 记录——方便快速查找,但分析时不便。想要 2020-2025 年间第二阶段 NSCLC 试验的平均持续时间吗?用 API 你可以过滤试验,从每个 JSON 记录中提取日期,然后在客户端计算持续时间。而 AACT 只需一个 SQL 查询。
结构化的PostgreSQL数据库让你以任何需要的方式汇总、合并和总结临床试验数据变得更加容易。对于AI辅助分析,SQL是大型语言模型处理极佳的标准——错误更少,上下文管理更少,性能更好,成本也更低,相较于解析定制API响应。
注: 这是一个独立的第三方集成。它与临床试验转型倡议(CTTI)或杜克大学没有关联或认可。
本页由 AI 翻译,技术细节请以原文为准。
README
以下为原文 README 节选,完整内容请查看原文。
AACT Clinical Trials MCP Server
Query the AACT (ClinicalTrials.gov) database directly from Claude. Explore 70+ tables of clinical trial data — studies, interventions, outcomes, sponsors, facilities — using read-only SQL with buffered pagination.
Why AACT over the ClinicalTrials.gov API?
The ClinicalTrials.gov API returns one JSON record per trial — useful for quick lookups, but awkward for analytics. Want the average duration of Phase 2 NSCLC trials from 2020-2025? With the API you’d filter trials, extract dates from each JSON record, then compute durations client-side. With AACT, that’s a single SQL query.
A structured PostgreSQL database makes it far easier to aggregate, combine, and summarize clinical trial data in any way you need. And for AI-assisted analysis, SQL is a standard that LLMs handle extremely well — fewer mistakes, less context to manage, better performance, and lower cost compared to parsing bespoke API responses.
Note: This is an independent, third-party integration. It is not affiliated with or endorsed by the Clinical Trials Transformation Initiative (CTTI) or Duke University. However, we released a case study with CTTI on integrating their database with Claude - see AACT case study.
Tools
| Tool | Description |
|---|---|
database_info |
Confirm database connection, server time, and data currency |
list_tables |
Discover all available tables with approximate row counts |
describe_table |
Inspect column names, types, distinct counts, and sample values |
get_column_values |
Get distinct values for a column with counts — essential before filtering |
search_columns |
Find columns by keyword across all tables (e.g. masking -> designs.masking) |
read_query |
Execute a SELECT, CTE, or EXPLAIN query with buffered results and preview |
fetch_rows |
Page through buffered query results without re-querying |
All tables join on nct_id.
Every read_query statement is parsed before it runs. Only one read-only SELECT, WITH, or EXPLAIN statement is accepted. It runs in a read-only database session and is cancelled after 2 minutes.
Setup
- Create a free account at https://aact.ctti-clinicaltrials.org/users/sign_up
- Install the plugin (see options below)
- Enter your AACT credentials when prompted
Installation
Option 1: Claude Desktop Plugin (recommended)
Download the latest .mcpb file from Releases and open it in Claude Desktop. You’ll be prompted for your AACT credentials.
Option 2: Published package
Add to your claude_desktop_config.json (~/Library/Application Support/Claude/claude_desktop_config.json on macOS, %APPDATA%\Claude\claude_desktop_config.json on Windows):
{
"mcpServers": {
"aact": {
"command": "uvx",
安装
uvx mcp-server-aact配置
{
"mcpServers": {
"aact": {
"command": "uvx",
"args": ["mcp-server-aact"],
"env": {
"DB_USER": "your_username",
"DB_PASSWORD": "your_password"
}
}
}
}