[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M74MSB2PC8D3EF6WH302Q2JC":3,"skill-same:01M74MSB2PC8D3EF6WH302Q2JC":67},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":27,"repositoryHtmlUrl":28,"repositoryHomepageUrl":29,"ownerHtmlUrl":30,"ownerBlogUrl":6,"ownerDescription":31,"updatedAt":32,"install":33,"resources":46},"01M74MSB2PC8D3EF6WH302Q2JC","clinical-trials-database",null,"Query ClinicalTrials.gov via APIv2. Use when you want to search for trials by condition, drug, location, status, or phase; retrieve trial details by NCT ID; check eligibility\u002Finclusion criteria; count trials across conditions or time periods; identify a sponsor's trial portfolio; find recruiting trials for patient matching.","pengqianhan\u002FAI-Human-Research-OS","pengqianhan","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F4286531?v=4","01M74M3DT9HNZ6HPAK8TX69EX9","PengqianHan","01M74M3DTVSN2GXW0JH2W396FK",3,"MIT","https:\u002F\u002Fgithub.com\u002Fpengqianhan\u002FAI-Human-Research-OS\u002Fblob\u002Fmain\u002Fresearch-skills-hub\u002Fscience-skills\u002Fclinical_trials_database\u002FSKILL.md",[],[],"2026-11-11 15:11:14",false,"---\nname: clinical-trials-database\ndescription: >\n  Query ClinicalTrials.gov via APIv2. Use when you want to search for trials by\n  condition, drug, location, status, or phase; retrieve trial details by NCT ID;\n  check eligibility\u002Finclusion criteria; count trials across conditions or time\n  periods; identify a sponsor's trial portfolio; find recruiting trials for\n  patient matching.\n---\n\n# Clinical Trials Database\n\n## Prerequisites\n\n1.  **`uv`**: Read the `uv` skill and follow its Setup instructions to ensure\n    `uv` is installed and on PATH.\n2.  **User Notification**: If .licenses\u002Fclinical_trials_database_LICENSE.txt\n    does not already exist in the workspace root directory then (1) prominently\n    notify the user to check the terms at https:\u002F\u002Fclinicaltrials.gov\u002F, then (2)\n    create the file recording the notification text and timestamp.\n\n## Overview\n\nAccess worldwide clinical trial data from ClinicalTrials.gov via the REST API\nv2. The CLI script at `scripts\u002Fclinical_trials_api.py` wraps the API with\ndedicated flags for common filters (phase, age group, status, intervention,\nsponsor, etc.) so you rarely need to construct raw queries.\n\n## Core Rules\n\n-   **Use the Wrapper**: ALWAYS execute the provided helper scripts to query the\n    database rather than accessing the database directly. The scripts\n    automatically enforce the required rate limit gracefully.\n-   **Always use `--fields`** — trial JSON records can be very large; restrict\n    to the data points you need.\n-   **Use `--count-total` first** — check result volume before fetching all\n    records.\n-   **Paginate large result sets** — use `--limit` with `--page-token` to\n    iterate.\n-   **Trust Search Filters**: Do not manually re-filter results unless\n    explicitly asked to verify detailed eligibility.\n-   **Notification**: If this skill is used, ensure this is mentioned in the\n    output.\n\n## Context Efficiency Warning\n\nTrial JSON records can be very large. **Always** use the `--fields` parameter to\nrestrict the response to only the data points you need. After writing to file,\nread only the fields you need rather than the entire file.\n\n> [!TIP] Use `references\u002Fstudies_schema.md` to identify exact field paths for\n> `--fields`.\n\n## Response Layout Summary\n\nAPI responses contain a list of studies (usually in a `studies[]` array). Each\nstudy is split into `protocolSection` and optional `resultsSection`.\n\n> [!Tip] Use the **shorthand aliases** below with the `--fields` parameter to\n> request specific data and keep responses small.\n\n### Top-Level Fields\n\n-   `totalCount` — Total studies matching query (integer)\n-   `studies[]` — Array of study objects\n-   `nextPageToken` — cursor string for pagination\n\n### Common Study Fields (and shorthand alias)\n\n-   **Identification**\n    -   `protocolSection.identificationModule.nctId` (`NCTId`) — Unique trial ID\n    -   `protocolSection.identificationModule.briefTitle` (`BriefTitle`) — Short\n        title\n-   **Status**\n    -   `protocolSection.statusModule.overallStatus` (`OverallStatus`) —\n        Recruitment status\n-   **Description**\n    -   `protocolSection.descriptionModule.briefSummary` (`BriefSummary`) —\n        Short description\n-   **Arms & Interventions**\n    -   `protocolSection.armsInterventionsModule.interventions`\n        (`ArmsInterventionsModule`)\n-   **Eligibility**\n    -   `protocolSection.eligibilityModule.eligibilityCriteria`\n        (`EligibilityCriteria`) — Inclusion\u002FExclusion\n    -   `protocolSection.eligibilityModule.stdAges` (`StdAge`) — CHILD, ADULT,\n        etc.\n\nConsult `references\u002Fstudies_schema.md` for full paths (Locations, Outcomes,\nResults) and common `--fields` recipes.\n\n## Commands\n\n### Search for studies\n\nUse for: finding trials by disease, drug, phase, status, age group, or any\ncombination of these filters.\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --condition \"\u003Cdisease>\" \\\n  --intervention \"\u003Cdrug_or_treatment>\" \\\n  --status \"\u003Cstatus>\" \\\n  --phase \"\u003Cphase>\" \\\n  --age-group \"\u003Cage_group>\" \\\n  --study-type \"\u003Cstudy_type>\" \\\n  --sponsor \"\u003Csponsor_name>\" \\\n  --has-results \\\n  --sort \"\u003Cfield>:\u003Casc|desc>\" \\\n  --fields \"\u003Cfields>\" \\\n  --limit \u003CN> \\\n  --count-total \\\n  --page-token \"\u003Ctoken>\" \\\n  --output \u002Ftmp\u002Fsearch_results.json\n```\n\nAll flags are optional and combine via AND logic.\n\n**Flag reference:**\n\n-   `--condition` — Disease or condition to search for (e.g. `\"cystic\n    fibrosis\"`).\n-   `--intervention` — Drug, device, or treatment name (e.g. `\"pembrolizumab\"`).\n-   `--status` — Recruitment status filter. Values: RECRUITING, COMPLETED,\n    NOT_YET_RECRUITING, ACTIVE_NOT_RECRUITING, ENROLLING_BY_INVITATION,\n    TERMINATED, SUSPENDED, WITHDRAWN.\n-   `--phase` — Trial phase filter. Values: PHASE1, PHASE2, PHASE3, PHASE4,\n    EARLY_PHASE1, NA.\n-   `--age-group` — Patient age group filter. Values: CHILD (0–17), ADULT\n    (18–64), OLDER_ADULT (65+).\n-   `--study-type` — Type of study. Values: INTERVENTIONAL, OBSERVATIONAL,\n    EXPANDED_ACCESS.\n-   `--sponsor` — Lead sponsor or institution name (e.g. `\"National Cancer\n    Institute\"`).\n-   `--has-results` — Boolean flag (no value needed). When present, filters for\n    studies that have results available on ClinicalTrials.gov.\n-   `--sort` — Sort order as `FieldName:asc` or `FieldName:desc`. Common fields:\n    `LastUpdatePostDate`, `EnrollmentCount`, `StudyFirstPostDate`, `StartDate`.\n-   `--fields` — Comma-separated list of JSON field names to include in the\n    response. Use this to keep responses small (e.g.\n    `\"NCTId,BriefTitle,OverallStatus,Phase\"`). See\n    `references\u002Fstudies_schema.md` for available field paths.\n-   `--limit` — Maximum number of studies to return per request (1–1000, default\n    10).\n-   `--count-total` — Boolean flag (no value needed). When present, the response\n    includes a `totalCount` field showing the total number of matching studies\n    across all pages.\n-   `--page-token` — An opaque cursor string used to fetch the next page of\n    results. Obtain this value from the `nextPageToken` field in a previous\n    search response. Do not construct this string yourself; always copy it\n    verbatim from the API response. See the Pagination section below.\n-   `--advanced` — Raw Essie filter expression for structured queries beyond the\n    dedicated flags (e.g. `\"AREA[LocationCountry]United States\"`). Combined with\n    other flags via AND. See `references\u002Fclinical_trials_api.md` for syntax.\n-   `--output` — **(Required)** File path where the JSON response is written.\n\n**Example — actively recruiting Phase 3 pediatric cystic fibrosis trials:**\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --condition \"cystic fibrosis\" \\\n  --status RECRUITING \\\n  --phase PHASE3 \\\n  --age-group CHILD \\\n  --fields \"NCTId,BriefTitle,OverallStatus,Phase\" \\\n  --limit 10 \\\n  --output \u002Ftmp\u002Fcf_trials.json\n```\n\n**Example — recruiting atezolizumab trials for esophageal cancer:**\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --condition \"esophageal cancer\" \\\n  --intervention \"Atezolizumab\" \\\n  --status RECRUITING \\\n  --fields \"NCTId,BriefTitle,Phase\" \\\n  --limit 10 \\\n  --output \u002Ftmp\u002Fatezolizumab_trials.json\n```\n\n### Retrieve a study by NCT ID\n\nUse for: fetching full details of a specific trial when you already have the NCT\nidentifier.\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py get-study \\\n  \u003Cnct_id> [--fields \"\u003Cfields>\"] \\\n  --output \u002Ftmp\u002Fstudy.json\n```\n\nReturns a useful default set of fields if `--fields` is omitted:\n`NCTId,BriefTitle,OverallStatus,Phase,BriefSummary,`\n`ConditionsModule,ArmsInterventionsModule,EligibilityModule`\n\n**Structure of the default response:**\n\n```json\n{\n  \"protocolSection\": {\n    \"identificationModule\": {\n      \"nctId\": \"NCT00000000\",\n      \"briefTitle\": \"Study Title\"\n    },\n    \"statusModule\": {\n      \"overallStatus\": \"RECRUITING\"\n    },\n    \"descriptionModule\": {\n      \"briefSummary\": \"This study is about...\"\n    },\n    \"conditionsModule\": {\n      \"conditions\": [ \"Condition Name\" ]\n    },\n    \"armsInterventionsModule\": {\n      \"interventions\": [ { \"type\": \"DRUG\", \"name\": \"Drug Name\" } ]\n    },\n    \"eligibilityModule\": {\n      \"eligibilityCriteria\": \"Inclusion:\\n- ...\",\n      \"stdAges\": [ \"ADULT\" ]\n    }\n  }\n}\n```\n\n### Get eligibility \u002F inclusion criteria\n\nUse for: pulling inclusion\u002Fexclusion rules, age ranges, and sex requirements for\npatient-matching tasks.\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py \\\n  get-eligibility \u003Cnct_id> \\\n  --output \u002Ftmp\u002Feligibility.json\n```\n\nShortcut that returns title and the full eligibility module (inclusion\u002Fexclusion\ncriteria, age range, sex).\n\n**Example — inclusion criteria for NCT04886804:**\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py \\\n  get-eligibility NCT04886804 \\\n  --output \u002Ftmp\u002Feligibility_NCT04886804.json\n```\n\n### Count matching studies\n\nUse for: exploring the trial landscape — checking how many trials exist for a\ncondition, phase, or status before fetching full records.\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py count \\\n  --condition \"\u003Cdisease>\" \\\n  [--status \"\u003Cstatus>\"] [--phase \"\u003Cphase>\"] ... \\\n  --output \u002Ftmp\u002Fcount.json\n```\n\nReturns only the total count of clinical trials matching the search criteria\nwithout fetching study records. Accepts the same filter flags as `search`.\n\n### Search by location \u002F geography\n\nUse for: narrowing trials to a specific country, state, or city.\n\nUse `--advanced` with `AREA[LocationCountry]` or `AREA[LocationCity]` to\nrestrict results by geography:\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --condition \"cystic fibrosis\" \\\n  --status RECRUITING \\\n  --advanced \"AREA[LocationCity]New York\" \\\n  --fields \"NCTId,BriefTitle\" \\\n  --limit 20 \\\n  --output \u002Ftmp\u002Fnyc_cf_trials.json\n```\n\n### Search by sponsor \u002F organization\n\nUse for: identifying a sponsor's or institution's trial portfolio.\n\nUse `--sponsor` to find trials run by a specific institution or company:\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --sponsor \"National Cancer Institute\" \\\n  --fields \"NCTId,BriefTitle,LeadSponsorName\" \\\n  --limit 20 \\\n  --output \u002Ftmp\u002Fnci_trials.json\n```\n\n### Combined multi-criteria search\n\nUse for: complex queries that layer multiple filters (condition and drug and\nphase and geography and sponsor, etc.).\n\nAll flags combine via AND, so you can layer conditions, interventions, status,\nphase, geography, and sponsor in a single query:\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --condition \"pancreatic cancer\" \\\n  --intervention \"immunotherapy\" \\\n  --status RECRUITING \\\n  --phase PHASE3 \\\n  --advanced \"AREA[LocationCountry]United States\" \\\n  --fields \"NCTId,BriefTitle,Phase,LeadSponsorName\" \\\n  --limit 20 \\\n  --output \u002Ftmp\u002Fpanc_trials.json\n```\n\n### Raw API query (escape hatch)\n\nUse for: uncommon endpoints or parameter combinations not covered by the\ndedicated flags.\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py raw-query \\\n  --endpoint \u003Cpath> \\\n  --params '\u003Cjson_dict>' \\\n  --output \u002Ftmp\u002Fraw_result.json\n```\n\n## Pagination\n\nWhen results exceed `--limit`, the response includes a `nextPageToken`. Pass it\nwith `--page-token` to fetch the next page:\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --condition \"breast cancer\" \\\n  --status RECRUITING \\\n  --limit 50 --count-total \\\n  --output \u002Ftmp\u002Fbreast_cancer_p1.json\n\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --condition \"breast cancer\" \\\n  --status RECRUITING \\\n  --limit 50 --page-token \"CAo=\" \\\n  --output \u002Ftmp\u002Fbreast_cancer_p2.json\n```\n\n## Advanced Querying\n\nFor complex filtering beyond the dedicated flags, use `--advanced` with an Essie\nexpression.\n\n**What is an Essie Expression?** Essie is the search engine powering\nClinicalTrials.gov. An Essie expression is a structured query that targets\nspecific fields (e.g., country, phase) rather than doing general keyword\nsearches.\n\n-   **`AREA[Field]Value`**: Targets a specific field.\n    -   `AREA[LocationCountry]United States`\n    -   `AREA[Phase]PHASE3`\n-   **Boolean operators**: Combine with `AND`, `OR`, `NOT`.\n-   **`RANGE[min, max]`**: For numeric\u002Fdate fields (e.g. `RANGE[500, MAX]`).\n\nSee `references\u002Fclinical_trials_api.md` for syntax and available fields.\n\nIt is combined with other flags via AND:\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --condition \"diabetes\" \\\n  --advanced \"AREA[LocationCountry]United States \\\n    AND AREA[EnrollmentCount]RANGE[500, MAX]\" \\\n  --fields \"NCTId,BriefTitle,EnrollmentCount\" \\\n  --output \u002Ftmp\u002Fdiabetes_us_large.json\n```\n\n## References\n\n-   **API parameters, enum values, and Essie syntax:**\n    `references\u002Fclinical_trials_api.md`\n-   **JSON field paths and `--fields` recipes:** `references\u002Fstudies_schema.md`\n","# Clinical Trials Database\n\n## Prerequisites\n\n1.  **`uv`**: Read the `uv` skill and follow its Setup instructions to ensure\n    `uv` is installed and on PATH.\n2.  **User Notification**: If .licenses\u002Fclinical_trials_database_LICENSE.txt\n    does not already exist in the workspace root directory then (1) prominently\n    notify the user to check the terms at https:\u002F\u002Fclinicaltrials.gov\u002F, then (2)\n    create the file recording the notification text and timestamp.\n\n## Overview\n\nAccess worldwide clinical trial data from ClinicalTrials.gov via the REST API\nv2. The CLI script at `scripts\u002Fclinical_trials_api.py` wraps the API with\ndedicated flags for common filters (phase, age group, status, intervention,\nsponsor, etc.) so you rarely need to construct raw queries.\n\n## Core Rules\n\n-   **Use the Wrapper**: ALWAYS execute the provided helper scripts to query the\n    database rather than accessing the database directly. The scripts\n    automatically enforce the required rate limit gracefully.\n-   **Always use `--fields`** — trial JSON records can be very large; restrict\n    to the data points you need.\n-   **Use `--count-total` first** — check result volume before fetching all\n    records.\n-   **Paginate large result sets** — use `--limit` with `--page-token` to\n    iterate.\n-   **Trust Search Filters**: Do not manually re-filter results unless\n    explicitly asked to verify detailed eligibility.\n-   **Notification**: If this skill is used, ensure this is mentioned in the\n    output.\n\n## Context Efficiency Warning\n\nTrial JSON records can be very large. **Always** use the `--fields` parameter to\nrestrict the response to only the data points you need. After writing to file,\nread only the fields you need rather than the entire file.\n\n> [!TIP] Use `references\u002Fstudies_schema.md` to identify exact field paths for\n> `--fields`.\n\n## Response Layout Summary\n\nAPI responses contain a list of studies (usually in a `studies[]` array). Each\nstudy is split into `protocolSection` and optional `resultsSection`.\n\n> [!Tip] Use the **shorthand aliases** below with the `--fields` parameter to\n> request specific data and keep responses small.\n\n### Top-Level Fields\n\n-   `totalCount` — Total studies matching query (integer)\n-   `studies[]` — Array of study objects\n-   `nextPageToken` — cursor string for pagination\n\n### Common Study Fields (and shorthand alias)\n\n-   **Identification**\n    -   `protocolSection.identificationModule.nctId` (`NCTId`) — Unique trial ID\n    -   `protocolSection.identificationModule.briefTitle` (`BriefTitle`) — Short\n        title\n-   **Status**\n    -   `protocolSection.statusModule.overallStatus` (`OverallStatus`) —\n        Recruitment status\n-   **Description**\n    -   `protocolSection.descriptionModule.briefSummary` (`BriefSummary`) —\n        Short description\n-   **Arms & Interventions**\n    -   `protocolSection.armsInterventionsModule.interventions`\n        (`ArmsInterventionsModule`)\n-   **Eligibility**\n    -   `protocolSection.eligibilityModule.eligibilityCriteria`\n        (`EligibilityCriteria`) — Inclusion\u002FExclusion\n    -   `protocolSection.eligibilityModule.stdAges` (`StdAge`) — CHILD, ADULT,\n        etc.\n\nConsult `references\u002Fstudies_schema.md` for full paths (Locations, Outcomes,\nResults) and common `--fields` recipes.\n\n## Commands\n\n### Search for studies\n\nUse for: finding trials by disease, drug, phase, status, age group, or any\ncombination of these filters.\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --condition \"\u003Cdisease>\" \\\n  --intervention \"\u003Cdrug_or_treatment>\" \\\n  --status \"\u003Cstatus>\" \\\n  --phase \"\u003Cphase>\" \\\n  --age-group \"\u003Cage_group>\" \\\n  --study-type \"\u003Cstudy_type>\" \\\n  --sponsor \"\u003Csponsor_name>\" \\\n  --has-results \\\n  --sort \"\u003Cfield>:\u003Casc|desc>\" \\\n  --fields \"\u003Cfields>\" \\\n  --limit \u003CN> \\\n  --count-total \\\n  --page-token \"\u003Ctoken>\" \\\n  --output \u002Ftmp\u002Fsearch_results.json\n```\n\nAll flags are optional and combine via AND logic.\n\n**Flag reference:**\n\n-   `--condition` — Disease or condition to search for (e.g. `\"cystic\n    fibrosis\"`).\n-   `--intervention` — Drug, device, or treatment name (e.g. `\"pembrolizumab\"`).\n-   `--status` — Recruitment status filter. Values: RECRUITING, COMPLETED,\n    NOT_YET_RECRUITING, ACTIVE_NOT_RECRUITING, ENROLLING_BY_INVITATION,\n    TERMINATED, SUSPENDED, WITHDRAWN.\n-   `--phase` — Trial phase filter. Values: PHASE1, PHASE2, PHASE3, PHASE4,\n    EARLY_PHASE1, NA.\n-   `--age-group` — Patient age group filter. Values: CHILD (0–17), ADULT\n    (18–64), OLDER_ADULT (65+).\n-   `--study-type` — Type of study. Values: INTERVENTIONAL, OBSERVATIONAL,\n    EXPANDED_ACCESS.\n-   `--sponsor` — Lead sponsor or institution name (e.g. `\"National Cancer\n    Institute\"`).\n-   `--has-results` — Boolean flag (no value needed). When present, filters for\n    studies that have results available on ClinicalTrials.gov.\n-   `--sort` — Sort order as `FieldName:asc` or `FieldName:desc`. Common fields:\n    `LastUpdatePostDate`, `EnrollmentCount`, `StudyFirstPostDate`, `StartDate`.\n-   `--fields` — Comma-separated list of JSON field names to include in the\n    response. Use this to keep responses small (e.g.\n    `\"NCTId,BriefTitle,OverallStatus,Phase\"`). See\n    `references\u002Fstudies_schema.md` for available field paths.\n-   `--limit` — Maximum number of studies to return per request (1–1000, default\n    10).\n-   `--count-total` — Boolean flag (no value needed). When present, the response\n    includes a `totalCount` field showing the total number of matching studies\n    across all pages.\n-   `--page-token` — An opaque cursor string used to fetch the next page of\n    results. Obtain this value from the `nextPageToken` field in a previous\n    search response. Do not construct this string yourself; always copy it\n    verbatim from the API response. See the Pagination section below.\n-   `--advanced` — Raw Essie filter expression for structured queries beyond the\n    dedicated flags (e.g. `\"AREA[LocationCountry]United States\"`). Combined with\n    other flags via AND. See `references\u002Fclinical_trials_api.md` for syntax.\n-   `--output` — **(Required)** File path where the JSON response is written.\n\n**Example — actively recruiting Phase 3 pediatric cystic fibrosis trials:**\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --condition \"cystic fibrosis\" \\\n  --status RECRUITING \\\n  --phase PHASE3 \\\n  --age-group CHILD \\\n  --fields \"NCTId,BriefTitle,OverallStatus,Phase\" \\\n  --limit 10 \\\n  --output \u002Ftmp\u002Fcf_trials.json\n```\n\n**Example — recruiting atezolizumab trials for esophageal cancer:**\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --condition \"esophageal cancer\" \\\n  --intervention \"Atezolizumab\" \\\n  --status RECRUITING \\\n  --fields \"NCTId,BriefTitle,Phase\" \\\n  --limit 10 \\\n  --output \u002Ftmp\u002Fatezolizumab_trials.json\n```\n\n### Retrieve a study by NCT ID\n\nUse for: fetching full details of a specific trial when you already have the NCT\nidentifier.\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py get-study \\\n  \u003Cnct_id> [--fields \"\u003Cfields>\"] \\\n  --output \u002Ftmp\u002Fstudy.json\n```\n\nReturns a useful default set of fields if `--fields` is omitted:\n`NCTId,BriefTitle,OverallStatus,Phase,BriefSummary,`\n`ConditionsModule,ArmsInterventionsModule,EligibilityModule`\n\n**Structure of the default response:**\n\n```json\n{\n  \"protocolSection\": {\n    \"identificationModule\": {\n      \"nctId\": \"NCT00000000\",\n      \"briefTitle\": \"Study Title\"\n    },\n    \"statusModule\": {\n      \"overallStatus\": \"RECRUITING\"\n    },\n    \"descriptionModule\": {\n      \"briefSummary\": \"This study is about...\"\n    },\n    \"conditionsModule\": {\n      \"conditions\": [ \"Condition Name\" ]\n    },\n    \"armsInterventionsModule\": {\n      \"interventions\": [ { \"type\": \"DRUG\", \"name\": \"Drug Name\" } ]\n    },\n    \"eligibilityModule\": {\n      \"eligibilityCriteria\": \"Inclusion:\\n- ...\",\n      \"stdAges\": [ \"ADULT\" ]\n    }\n  }\n}\n```\n\n### Get eligibility \u002F inclusion criteria\n\nUse for: pulling inclusion\u002Fexclusion rules, age ranges, and sex requirements for\npatient-matching tasks.\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py \\\n  get-eligibility \u003Cnct_id> \\\n  --output \u002Ftmp\u002Feligibility.json\n```\n\nShortcut that returns title and the full eligibility module (inclusion\u002Fexclusion\ncriteria, age range, sex).\n\n**Example — inclusion criteria for NCT04886804:**\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py \\\n  get-eligibility NCT04886804 \\\n  --output \u002Ftmp\u002Feligibility_NCT04886804.json\n```\n\n### Count matching studies\n\nUse for: exploring the trial landscape — checking how many trials exist for a\ncondition, phase, or status before fetching full records.\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py count \\\n  --condition \"\u003Cdisease>\" \\\n  [--status \"\u003Cstatus>\"] [--phase \"\u003Cphase>\"] ... \\\n  --output \u002Ftmp\u002Fcount.json\n```\n\nReturns only the total count of clinical trials matching the search criteria\nwithout fetching study records. Accepts the same filter flags as `search`.\n\n### Search by location \u002F geography\n\nUse for: narrowing trials to a specific country, state, or city.\n\nUse `--advanced` with `AREA[LocationCountry]` or `AREA[LocationCity]` to\nrestrict results by geography:\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --condition \"cystic fibrosis\" \\\n  --status RECRUITING \\\n  --advanced \"AREA[LocationCity]New York\" \\\n  --fields \"NCTId,BriefTitle\" \\\n  --limit 20 \\\n  --output \u002Ftmp\u002Fnyc_cf_trials.json\n```\n\n### Search by sponsor \u002F organization\n\nUse for: identifying a sponsor's or institution's trial portfolio.\n\nUse `--sponsor` to find trials run by a specific institution or company:\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --sponsor \"National Cancer Institute\" \\\n  --fields \"NCTId,BriefTitle,LeadSponsorName\" \\\n  --limit 20 \\\n  --output \u002Ftmp\u002Fnci_trials.json\n```\n\n### Combined multi-criteria search\n\nUse for: complex queries that layer multiple filters (condition and drug and\nphase and geography and sponsor, etc.).\n\nAll flags combine via AND, so you can layer conditions, interventions, status,\nphase, geography, and sponsor in a single query:\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --condition \"pancreatic cancer\" \\\n  --intervention \"immunotherapy\" \\\n  --status RECRUITING \\\n  --phase PHASE3 \\\n  --advanced \"AREA[LocationCountry]United States\" \\\n  --fields \"NCTId,BriefTitle,Phase,LeadSponsorName\" \\\n  --limit 20 \\\n  --output \u002Ftmp\u002Fpanc_trials.json\n```\n\n### Raw API query (escape hatch)\n\nUse for: uncommon endpoints or parameter combinations not covered by the\ndedicated flags.\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py raw-query \\\n  --endpoint \u003Cpath> \\\n  --params '\u003Cjson_dict>' \\\n  --output \u002Ftmp\u002Fraw_result.json\n```\n\n## Pagination\n\nWhen results exceed `--limit`, the response includes a `nextPageToken`. Pass it\nwith `--page-token` to fetch the next page:\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --condition \"breast cancer\" \\\n  --status RECRUITING \\\n  --limit 50 --count-total \\\n  --output \u002Ftmp\u002Fbreast_cancer_p1.json\n\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --condition \"breast cancer\" \\\n  --status RECRUITING \\\n  --limit 50 --page-token \"CAo=\" \\\n  --output \u002Ftmp\u002Fbreast_cancer_p2.json\n```\n\n## Advanced Querying\n\nFor complex filtering beyond the dedicated flags, use `--advanced` with an Essie\nexpression.\n\n**What is an Essie Expression?** Essie is the search engine powering\nClinicalTrials.gov. An Essie expression is a structured query that targets\nspecific fields (e.g., country, phase) rather than doing general keyword\nsearches.\n\n-   **`AREA[Field]Value`**: Targets a specific field.\n    -   `AREA[LocationCountry]United States`\n    -   `AREA[Phase]PHASE3`\n-   **Boolean operators**: Combine with `AND`, `OR`, `NOT`.\n-   **`RANGE[min, max]`**: For numeric\u002Fdate fields (e.g. `RANGE[500, MAX]`).\n\nSee `references\u002Fclinical_trials_api.md` for syntax and available fields.\n\nIt is combined with other flags via AND:\n\n```bash\nuv run scripts\u002Fclinical_trials_api.py search \\\n  --condition \"diabetes\" \\\n  --advanced \"AREA[LocationCountry]United States \\\n    AND AREA[EnrollmentCount]RANGE[500, MAX]\" \\\n  --fields \"NCTId,BriefTitle,EnrollmentCount\" \\\n  --output \u002Ftmp\u002Fdiabetes_us_large.json\n```\n\n## References\n\n-   **API parameters, enum values, and Essie syntax:**\n    `references\u002Fclinical_trials_api.md`\n-   **JSON field paths and `--fields` recipes:** `references\u002Fstudies_schema.md`\n",{"name":5,"description":7},"main","e71245365df78e06cd166602744bf2491f79910e","research-skills-hub\u002Fscience-skills\u002Fclinical_trials_database",0,"https:\u002F\u002Fgithub.com\u002Fpengqianhan\u002FAI-Human-Research-OS","https:\u002F\u002Fpengqianhan.github.io\u002FAI-Human-Research-OS\u002F","https:\u002F\u002Fgithub.com\u002Fpengqianhan","Ph.D. candidate of The University of Auckland, New Zealand","2026-11-14 18:08:16",{"source":8,"skillName":5,"commands":34,"prompt":44,"zipAvailable":45},[35,38,41],{"tool":36,"command":37},"npx","npx skills add pengqianhan\u002FAI-Human-Research-OS --skill clinical-trials-database",{"tool":39,"command":40},"bunx","bunx skills add pengqianhan\u002FAI-Human-Research-OS --skill clinical-trials-database",{"tool":42,"command":43},"pnpm","pnpm dlx skills add pengqianhan\u002FAI-Human-Research-OS --skill clinical-trials-database","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fpengqianhan\u002FAI-Human-Research-OS\u002Fblob\u002Fmain\u002Fresearch-skills-hub\u002Fscience-skills\u002Fclinical_trials_database\u002FSKILL.md",true,[47,53,57,61],{"path":48,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":51,"sourceHtmlUrl":52},"references\u002Fcitation.bib","REFERENCE","参考文档",376,"https:\u002F\u002Fgithub.com\u002Fpengqianhan\u002FAI-Human-Research-OS\u002Fblob\u002Fmain\u002Fresearch-skills-hub\u002Fscience-skills\u002Fclinical_trials_database\u002Freferences\u002Fcitation.bib",{"path":54,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":55,"sourceHtmlUrl":56},"references\u002Fclinical_trials_api.md",6331,"https:\u002F\u002Fgithub.com\u002Fpengqianhan\u002FAI-Human-Research-OS\u002Fblob\u002Fmain\u002Fresearch-skills-hub\u002Fscience-skills\u002Fclinical_trials_database\u002Freferences\u002Fclinical_trials_api.md",{"path":58,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":59,"sourceHtmlUrl":60},"references\u002Fstudies_schema.md",5146,"https:\u002F\u002Fgithub.com\u002Fpengqianhan\u002FAI-Human-Research-OS\u002Fblob\u002Fmain\u002Fresearch-skills-hub\u002Fscience-skills\u002Fclinical_trials_database\u002Freferences\u002Fstudies_schema.md",{"path":62,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":65,"sourceHtmlUrl":66},"scripts\u002Fclinical_trials_api.py","SCRIPT","脚本",11639,"https:\u002F\u002Fgithub.com\u002Fpengqianhan\u002FAI-Human-Research-OS\u002Fblob\u002Fmain\u002Fresearch-skills-hub\u002Fscience-skills\u002Fclinical_trials_database\u002Fscripts\u002Fclinical_trials_api.py",[68,75,82,89,96,103],{"skillNo":69,"name":70,"nameZh":6,"description":71,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":72,"categories":73,"keywords":74,"publishedAt":19},"01M74MWYTHT498SVMN823896T7","workflow-skill-creator","Distills a completed user workflow or interaction into a reusable agent skill. Use when the user asks to turn their workflow, interaction, or multi-step process into a skill, or when they say \"make this a skill\", \"create a skill from what we just did\", \"package this workflow\" or similar. Do not use for creating skills from scratch without an existing workflow (use a generic skill-creator for that).","https:\u002F\u002Fgithub.com\u002Fpengqianhan\u002FAI-Human-Research-OS\u002Fblob\u002Fmain\u002Fresearch-skills-hub\u002Fscience-skills\u002Fworkflow_skill_creator\u002FSKILL.md",[],[],{"skillNo":76,"name":77,"nameZh":6,"description":78,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":79,"categories":80,"keywords":81,"publishedAt":19},"01M74MWWVCFZ8HQS8840F1V1FT","uv","Checks whether the uv Python package manager is installed and installs it if missing. Ensures uv is on PATH. Use when another skill requires uv as a prerequisite.","https:\u002F\u002Fgithub.com\u002Fpengqianhan\u002FAI-Human-Research-OS\u002Fblob\u002Fmain\u002Fresearch-skills-hub\u002Fscience-skills\u002Fuv\u002FSKILL.md",[],[],{"skillNo":83,"name":84,"nameZh":6,"description":85,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":86,"categories":87,"keywords":88,"publishedAt":19},"01M74MWRH5BTSWZ2C5PCTD5FV9","uniprot-database","Access protein metadata, function, taxonomy, and sequences across UniProtKB, UniParc, and UniRef. Use when searching for proteins, mapping identifiers, or retrieving functional annotations and publications. Don't use for sequence alignment, protein folding, or sequence similarity search (use specialized skills for those tasks).","https:\u002F\u002Fgithub.com\u002Fpengqianhan\u002FAI-Human-Research-OS\u002Fblob\u002Fmain\u002Fresearch-skills-hub\u002Fscience-skills\u002Funiprot_database\u002FSKILL.md",[],[],{"skillNo":90,"name":91,"nameZh":6,"description":92,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":93,"categories":94,"keywords":95,"publishedAt":19},"01M74MWN1D3ER9F1FZPWH8HQC1","unibind-database","Queries the UniBind database for experimentally validated transcription factor (TF) binding sites. Use when retrieving direct TF-DNA interaction datasets, downloading binding site coordinates (BED\u002FFASTA) for local analysis, or listing available datasets by species, cell line, or TF name. Don't use to query specific intervals, locations, genes, motif models or expression data.","https:\u002F\u002Fgithub.com\u002Fpengqianhan\u002FAI-Human-Research-OS\u002Fblob\u002Fmain\u002Fresearch-skills-hub\u002Fscience-skills\u002Funibind_database\u002FSKILL.md",[],[],{"skillNo":97,"name":98,"nameZh":6,"description":99,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":100,"categories":101,"keywords":102,"publishedAt":19},"01M74MWHHB5QZY3NR2FYA1EK4N","ucsc-conservation-and-tfbs","Fetch Evolutionary Conservation scores (phyloP, phastCons) and Transcription Factor Binding Sites (TFBS) from the UCSC Genome Browser. Use when analyzing whether genomic variants or regions are evolutionarily conserved, functionally important, or bounded by TF regulators across major projects (ENCODE, JASPAR, ReMap).","https:\u002F\u002Fgithub.com\u002Fpengqianhan\u002FAI-Human-Research-OS\u002Fblob\u002Fmain\u002Fresearch-skills-hub\u002Fscience-skills\u002Fucsc_conservation_and_tfbs\u002FSKILL.md",[],[],{"skillNo":104,"name":105,"nameZh":6,"description":106,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":107,"categories":108,"keywords":109,"publishedAt":19},"01M74MWERYHSY87P21FDMVE6BA","string-database","Query the STRING database for protein-protein interactions (PPIs), functional enrichment, and homology. Use when the user asks about interactions between specific proteins, interaction evidence, confidence scores, protein interaction partners, or pathway enrichments.","https:\u002F\u002Fgithub.com\u002Fpengqianhan\u002FAI-Human-Research-OS\u002Fblob\u002Fmain\u002Fresearch-skills-hub\u002Fscience-skills\u002Fstring_database\u002FSKILL.md",[],[]]