aqc-mcp 2.1.0 → 2.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -6,7 +6,7 @@ A Model Context Protocol (MCP) server for astroquery-cli, providing HTTP and SSE
6
6
 
7
7
  ## Overview ✨
8
8
 
9
- The astroquery-mcp server exposes astroquery CLI functionality as MCP tools, allowing AI applications and other services to query astronomical databases through standardized MCP protocols. Supports both HTTP and SSE transports.
9
+ The aqc-mcp server provides direct HTTP/TAP API access to 17+ astronomical databases as MCP tools, allowing AI applications and other services to query astronomical data through standardized MCP protocols. Supports both HTTP and SSE transports.
10
10
 
11
11
  ---
12
12
 
@@ -17,24 +17,54 @@ The astroquery-mcp server exposes astroquery CLI functionality as MCP tools, all
17
17
  - HTTP (default)
18
18
  - SSE (Server-Sent Events)
19
19
  - Stdio (for Claude Desktop)
20
- - 🔌 **Extensible**: Easy to add new tools and modules
21
- - 🌍 **Language Support**: Multi-language output (English, Chinese, Japanese)
20
+ - 🔌 **17 Databases**: Direct TAP/REST API access to major astronomical archives
21
+ - 🌍 **Language Support**: Multi-language output (English, Chinese)
22
22
  - 📊 **Rich Output**: Formatted tables and structured results
23
23
  - 🔑 **ADS API Token Support**: Environment variable injection for authenticated queries
24
+ - ⚡ **No Python Required**: Pure Node.js/TypeScript implementation
24
25
 
25
26
  ---
26
27
 
27
28
  ## Supported Modules 🧩
28
29
 
29
- Currently implemented tools:
30
+ Currently implemented tools (17 astronomical databases):
30
31
 
32
+ ### General Astronomy
31
33
  - **SIMBAD**: Query SIMBAD astronomical database
32
34
  - **VizieR**: Query VizieR catalog database
33
- - **ALMA**: Query ALMA observations archive
35
+ - **NED**: NASA/IPAC Extragalactic Database
34
36
  - **ADS**: NASA Astrophysics Data System queries (requires API token)
35
- - **Gaia**: Gaia archive cone search
36
37
 
37
- > ⚠️ More modules (ESASky, IRSA, Heasarc, JPL, MAST, NED, NIST, Exoplanet, SDSS, ESO, Splatalogue) coming soon!
38
+ ### Radio & Millimeter
39
+ - **ALMA**: Query ALMA observations archive
40
+ - **ESO**: European Southern Observatory science archive
41
+
42
+ ### High Energy & X-ray
43
+ - **Fermi LAT**: Fermi Large Area Telescope gamma-ray source catalog
44
+ - **HEASARC**: High Energy Astrophysics Science Archive (multiple missions)
45
+
46
+ ### Infrared & Submillimeter
47
+ - **IRSA**: NASA/IPAC Infrared Science Archive
48
+
49
+ ### Space Observatories
50
+ - **MAST**: Barbara A. Mikulski Archive for Space Telescopes
51
+ - **ESASky**: Multi-mission all-sky archive
52
+
53
+ ### Solar System
54
+ - **JPL Horizons**: Solar system body ephemerides and state vectors
55
+ - **JPL SBDB**: Small-Body Database for asteroids and comets
56
+
57
+ ### Exoplanets & Stars
58
+ - **Exoplanet**: NASA Exoplanet Archive
59
+ - **AAVSO**: Variable Star Index (VSX catalog)
60
+ - **NIST**: Atomic Spectra Database for spectral lines
61
+
62
+ ### Optical Surveys
63
+ - **Gaia**: Gaia DR3 catalog cone search and ADQL queries
64
+ - **SDSS**: Sloan Digital Sky Survey (DR18)
65
+ - **Splatalogue**: Spectral line database
66
+
67
+ ### Total: 17 databases, 30+ tools
38
68
 
39
69
  ---
40
70
 
@@ -43,13 +73,9 @@ Currently implemented tools:
43
73
  ### Quick Start
44
74
 
45
75
  **Prerequisites:**
46
- - Python ≥ 3.11
47
76
  - Node.js ≥ 18.0.0
48
77
 
49
- **Install Python CLI:**
50
- ```bash
51
- pip install astroquery-cli
52
- ```
78
+ **No Python dependency required** - aqc-mcp uses direct HTTP/TAP APIs to astronomical services.
53
79
 
54
80
  ### MCP Server Configuration
55
81
 
@@ -355,18 +381,31 @@ npm run watch
355
381
  ### Project Structure
356
382
 
357
383
  ```
358
- astroquery-mcp/
384
+ aqc-mcp/
359
385
  ├── src/
360
386
  │ ├── index.ts # Main server entry
361
- │ ├── tools/ # MCP tool definitions
387
+ │ ├── tools/ # MCP tool definitions (17 databases)
362
388
  │ │ ├── index.ts # Tool registration
363
- │ │ ├── simbad.ts
364
- │ │ ├── vizier.ts
365
- │ │ ├── alma.ts
366
- │ │ ├── ads.ts
367
- │ │ └── gaia.ts
389
+ │ │ ├── simbad.ts # SIMBAD queries
390
+ │ │ ├── vizier.ts # VizieR catalog queries
391
+ │ │ ├── alma.ts # ALMA archive queries
392
+ │ │ ├── ads.ts # ADS bibliographic queries
393
+ │ │ ├── gaia.ts # Gaia DR3 queries
394
+ │ │ ├── aavso.ts # AAVSO VSX variable stars
395
+ │ │ ├── fermi.ts # Fermi LAT gamma-ray sources
396
+ │ │ ├── heasarc.ts # HEASARC queries
397
+ │ │ ├── esasky.ts # ESASky multi-mission archive
398
+ │ │ ├── eso.ts # ESO science archive
399
+ │ │ ├── exoplanet.ts # NASA Exoplanet Archive
400
+ │ │ ├── irsa.ts # IRSA infrared archive
401
+ │ │ ├── jpl.ts # JPL Horizons & SBDB
402
+ │ │ ├── mast.ts # MAST space telescopes
403
+ │ │ ├── ned.ts # NED extragalactic DB
404
+ │ │ ├── nist.ts # NIST atomic spectra
405
+ │ │ ├── sdss.ts # SDSS optical survey
406
+ │ │ └── splatalogue.ts # Spectral line database
368
407
  │ └── utils/
369
- │ └── executor.ts # CLI command executor
408
+ │ └── http.ts # HTTP/TAP client utilities
370
409
  ├── dist/ # Compiled JavaScript
371
410
  ├── package.json
372
411
  └── tsconfig.json
@@ -386,10 +425,6 @@ astroquery-mcp/
386
425
 
387
426
  ## Troubleshooting 🔍
388
427
 
389
- ### "aqc: command not found"
390
-
391
- Make sure you're running the MCP server from within the `astroquery-mcp` directory, and that the parent `astroquery-cli` project has been installed via poetry.
392
-
393
428
  ### ADS queries fail
394
429
 
395
430
  Set the `ADS_API_KEY` environment variable:
@@ -407,6 +442,10 @@ Change the port:
407
442
  PORT=8080 npm start
408
443
  ```
409
444
 
445
+ ### Query timeouts
446
+
447
+ Some astronomical databases (e.g., Fermi LAT, HEASARC) may take longer to respond. The server uses reasonable timeout values, but you can adjust them if needed by modifying the `timeout` parameter in the HTTP client.
448
+
410
449
  ---
411
450
 
412
451
  ## License 📄
@@ -423,6 +462,6 @@ Contributions welcome! Please open an issue or PR.
423
462
 
424
463
  ## Links 🔗
425
464
 
426
- - [astroquery-cli](../README.md)
465
+ - [GitHub Repository](https://github.com/inoribea/aqc-mcp)
427
466
  - [MCP Specification](https://modelcontextprotocol.io/)
428
467
  - [NASA ADS API](https://ui.adsabs.harvard.edu/)
package/dist/index.js CHANGED
@@ -3,7 +3,9 @@ import { startSseAndStreamableHttpMcpServer } from 'mcp-http-server';
3
3
  import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
4
4
  import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';
5
5
  import { registerAllTools } from './tools/index.js';
6
- const VERSION = '2.0.0';
6
+ import { createRequire } from 'module';
7
+ const require = createRequire(import.meta.url);
8
+ const VERSION = require('../package.json').version;
7
9
  function createMcpServer() {
8
10
  const server = new McpServer({ name: 'astroquery-mcp', version: VERSION }, { capabilities: { tools: {} } });
9
11
  registerAllTools(server);
@@ -3,7 +3,7 @@ const AAVSO_VSX_BASE = 'https://www.aavso.org/vsx/index.php';
3
3
  function parseVOTable(xmlText) {
4
4
  const columns = [];
5
5
  const rows = [];
6
- const fieldRegex = /<FIELD\s+name="([^"]+)"/g;
6
+ const fieldRegex = /<FIELD\s+[^>]*name="([^"]+)"/g;
7
7
  let match;
8
8
  while ((match = fieldRegex.exec(xmlText)) !== null) {
9
9
  columns.push(match[1]);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "aqc-mcp",
3
- "version": "2.1.0",
3
+ "version": "2.1.2",
4
4
  "description": "MCP server for astronomical database queries via direct HTTP/TAP APIs",
5
5
  "keywords": [
6
6
  "mcp",
@@ -31,12 +31,6 @@
31
31
  },
32
32
  "main": "dist/index.js",
33
33
  "type": "module",
34
- "scripts": {
35
- "build": "tsc",
36
- "start": "node dist/index.js",
37
- "dev": "tsc && node dist/index.js",
38
- "watch": "tsc --watch"
39
- },
40
34
  "dependencies": {
41
35
  "@modelcontextprotocol/sdk": "^1.27.1",
42
36
  "cors": "^2.8.5",
@@ -52,5 +46,11 @@
52
46
  },
53
47
  "engines": {
54
48
  "node": ">=18.0.0"
49
+ },
50
+ "scripts": {
51
+ "build": "tsc",
52
+ "start": "node dist/index.js",
53
+ "dev": "tsc && node dist/index.js",
54
+ "watch": "tsc --watch"
55
55
  }
56
- }
56
+ }