---
name: science-anything
description: Polymorphic 5-source scientific evidence compiler across Literature (PubMed/EuropePMC/arXiv/Crossref), Compounds (PubChem PUG REST), Clinical Trials (ClinicalTrials.gov v2), OpenFDA (labels, recalls, FAERS), and Patents (USPTO/PatentsView/EuropePMC SRC:PAT/PubChem XRefs) via REST, native /mcp, or 0%-commission Treg Hub. Strictly bills $0 on empty hits, HTTP 422, or unverified IDs.
---

# Science-Anything — AI Agent Integration Skill

Use **Science-Anything** (`https://science.fastmesh.dev`, local dev `http://127.0.0.1:8809`) whenever an agent or R&D workflow needs verified scientific evidence tables, Lipinski druggability audits, clinical trial termination reasons, OpenFDA FAERS/recall safety matrices, patent claim white-space audits, or reproducible wet/dry-lab protocol checklists backed by official identifiers and SHA-256 receipts.

> **Research Compilation Notice**: Science-Anything compiles public scientific, regulatory, and patent records for research triage only. Outputs do not constitute medical diagnosis or clinical advice.

## Core Endpoints & Channels

- **Web 5-Second Try-Now Console**: `https://science.fastmesh.dev/`
- **Single Compile REST API**: `POST https://science.fastmesh.dev/compile` (alias: `/api/compile`)
- **Batch Matrix REST API**: `POST https://science.fastmesh.dev/batch` (alias: `/api/batch`)
- **Exporter API (JSON / CSV / Markdown)**: `POST` or `GET https://science.fastmesh.dev/export` (alias: `/api/export`)
- **Native Streamable MCP Server (JSON-RPC 2.0)**: `POST https://science.fastmesh.dev/mcp`
- **OpenAPI 3.1.0 Spec**: `GET https://science.fastmesh.dev/openapi.json`
- **Service Health & Readiness**: `GET https://science.fastmesh.dev/health`
- **Treg Hub QuickJS Package (`0%` commission)**: `science-anything` (`a09_science_anything_v1`)
- **Discovery Manifest**: `https://science.fastmesh.dev/llms.txt`

## Pricing & Non-Negotiable Invariants

| `source_mode` | Upstream Public Registries | Base Rate | `10%` Recheck Tier | Invalid (`422`) / Miss / Fake-200 |
| :--- | :--- | :---: | :---: | :---: |
| `compound` | PubChem PUG REST (MW, XLogP, HBD, HBA, TPSA, Lipinski, Bioassays) | `$0.03` (`30,000` micros) | `$0.003` (`3,000` micros) | `$0.00` (`0`) |
| `literature` | PubMed, EuropePMC, arXiv, Crossref | `$0.04` (`40,000` micros) | `$0.004` (`4,000` micros) | `$0.00` (`0`) |
| `trials` | ClinicalTrials.gov v2 API | `$0.05` (`50,000` micros) | `$0.005` (`5,000` micros) | `$0.00` (`0`) |
| `fda` | OpenFDA Labels, Drugs@FDA, Enforcement Recalls, FAERS | `$0.05` (`50,000` micros) | `$0.005` (`5,000` micros) | `$0.00` (`0`) |
| `patent` | USPTO / PatentsView / EuropePMC `SRC:PAT` / PubChem Patent XRefs | `$0.07` (`70,000` micros) | `$0.007` (`7,000` micros) | `$0.00` (`0`) |
| `auto` | Polymorphic router across all 5 sources | `$0.03–$0.07` (default `$0.05`) | `10%` of matched mode | `$0.00` (`0`) |

1. **Strict `$0` on Empty Hits, Misses & HTTP `422`**: Empty queries, sentinel values (`"N/A"`, `"null"`), forged IDs (`10.9999/fake`, `NCT00000000`), fake-200 HTML shells, and upstream `NOT_FOUND` responses strictly yield `billed_micros: 0`.
2. **Official ID Provenance Guarantee**: Every returned record must pass regex provenance validation (`DOI`, `PMID`, `PMCID`, `arXiv`, `PubChem CID`, `NCT`, `OpenFDA NDA/BLA/ANDA/Recall/FAERS`, or `Patent ID`) and includes a `64`-char hex `sha256_attestation`.
3. **Hard `$2.00` Per-Batch Spend Cap**: `/batch` enforces `max_budget_micros <= 2000000` (`$2.00`), isolating partial invalid rows at `$0` without failing valid rows.
4. **7d–30d Adaptive Archive Cache**: Cross-tenant hits cost `100%` with `$0` upstream latency/cost; same-tenant `recheck: true` calls cost `10%`.
5. **Zero Query or Trajectory Resale**: Queries, SMILES strings, and draft patent claims are never resold or used to train models.

---

## Option 1: Calling via Native MCP (`POST https://science.fastmesh.dev/mcp`)

Three flat tools are exposed over JSON-RPC 2.0 (`tools/list`, `tools/call`):

| MCP Tool | Purpose | Key Arguments |
| :--- | :--- | :--- |
| `science_compile` | Compile single target across any of the 5 sources (`auto` supported) | `query`, `source_mode`, `export_format`, `recheck`, `verify` |
| `science_batch` | Concurrent heterogeneous batch matrix with hard budget ceiling | `items` (or `csv_text`), `source_mode`, `max_budget_micros` |
| `science_export` | Export compiled matrix & checklist in `json`, `csv`, or `markdown` | `format`, `receipt_id` (or `query` + `source_mode`) |

```bash
curl -fsSL -X POST "https://science.fastmesh.dev/mcp" \
  -H "Content-Type: application/json" \
  -H "X-Tenant-Id: research-agent-01" \
  -d '{
    "jsonrpc": "2.0",
    "id": 1,
    "method": "tools/call",
    "params": {
      "name": "science_compile",
      "arguments": {
        "query": "aspirin",
        "source_mode": "compound",
        "verify": true
      }
    }
  }'
```

---

## Option 2: Calling via REST API (`POST /compile`, `/batch`, `/export`)

### 1. Compound Property & Lipinski Audit (`compound`, `$0.03`)

```bash
curl -fsSL -X POST "https://science.fastmesh.dev/compile" \
  -H "Content-Type: application/json" \
  -d '{"query":"CID 2244","source_mode":"compound","verify":true}'
```

### 2. Literature Methods & Reproducible Checklist (`literature`, `$0.04`)

```bash
curl -fsSL -X POST "https://science.fastmesh.dev/compile" \
  -H "Content-Type: application/json" \
  -d '{"query":"33462507","source_mode":"literature","verify":true}'
```

### 3. ClinicalTrials.gov v2 Pipeline & Termination Audit (`trials`, `$0.05`)

```bash
curl -fsSL -X POST "https://science.fastmesh.dev/compile" \
  -H "Content-Type: application/json" \
  -d '{"query":"NCT04280705","source_mode":"trials","verify":true}'
```

### 4. OpenFDA FAERS Signal & Enforcement Recall Audit (`fda`, `$0.05`)

```bash
curl -fsSL -X POST "https://science.fastmesh.dev/compile" \
  -H "Content-Type: application/json" \
  -d '{"query":"semaglutide","source_mode":"fda","verify":true}'
```

### 5. Patent Claim Decomposition & White-Space Audit (`patent`, `$0.07`)

```bash
curl -fsSL -X POST "https://science.fastmesh.dev/compile" \
  -H "Content-Type: application/json" \
  -d '{"query":"US10000000B2","source_mode":"patent","verify":true}'
```

### 6. Concurrent Heterogeneous Batch Matrix (`POST /batch`, `$2.00` cap)

```bash
curl -fsSL -X POST "https://science.fastmesh.dev/batch" \
  -H "Content-Type: application/json" \
  -d '{
    "max_budget_micros": 500000,
    "items": [
      {"query": "aspirin", "source_mode": "compound"},
      {"query": "NCT04280705", "source_mode": "trials"},
      {"query": "metformin", "source_mode": "fda"},
      {"query": "10.1038/s41586-021-03819-2", "source_mode": "literature"}
    ]
  }'
```

---

## Option 3: Calling via Treg Hub (0% Commission QuickJS)

```bash
treg call science-anything --data '{
  "query": "NCT04280705",
  "source_mode": "trials",
  "export_format": "json",
  "max_cost_micros": 100000
}'
```

## Standardized Response Contract & Agent Error Recovery

Every response returns: `ok`, `status_code`, `receipt_id`, `source_mode`, `query`, `verdict`, `comparison_table` (`{columns, rows}`), `records`, `protocol_checklist`, `provenance_ids`, `sha256_attestation`, `billed_micros`, `cache_hit`, `cache_tier`, and `zero_bill_reason`.

- **On HTTP `422` (`billed_micros: 0`)**: Input failed local validation (empty, sentinel, or malformed identifier). Normalize the query before retrying.
- **On `ok: false` / `INCONCLUSIVE` / `EMPTY` (`billed_micros: 0`)**: Upstream returned zero verified hits or failed provenance validation; no credits were deducted.
- **On Repeat Checks**: Pass `"recheck": true` with the same `X-Tenant-Id` to re-verify cached targets at `10%` of the base price.
