openalex-research-mcp 0.1.0

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/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2025 OpenAlex MCP Server
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/QUICKSTART.md ADDED
@@ -0,0 +1,133 @@
1
+ # Quick Start Guide
2
+
3
+ Get your OpenAlex MCP server running in under 5 minutes!
4
+
5
+ ## Step 1: Install Dependencies
6
+
7
+ ```bash
8
+ npm install
9
+ ```
10
+
11
+ ## Step 2: Build the Project
12
+
13
+ ```bash
14
+ npm run build
15
+ ```
16
+
17
+ ## Step 3: Configure Claude Desktop
18
+
19
+ 1. Open your Claude Desktop config file:
20
+ - **MacOS**: `~/Library/Application Support/Claude/claude_desktop_config.json`
21
+ - **Windows**: `%APPDATA%/Claude/claude_desktop_config.json`
22
+
23
+ 2. Add the OpenAlex server configuration (replace with your actual path):
24
+
25
+ ```json
26
+ {
27
+ "mcpServers": {
28
+ "openalex": {
29
+ "command": "node",
30
+ "args": ["/Users/yourusername/path/to/openalex-research-mcp/build/index.js"],
31
+ "env": {
32
+ "OPENALEX_EMAIL": "your.email@example.com"
33
+ }
34
+ }
35
+ }
36
+ }
37
+ ```
38
+
39
+ 3. Restart Claude Desktop
40
+
41
+ ## Step 4: Test It Out!
42
+
43
+ Try these prompts in Claude Desktop:
44
+
45
+ ### Find influential papers
46
+ ```
47
+ Find the top 10 most cited papers on quantum computing from the last 5 years
48
+ ```
49
+
50
+ ### Analyze research trends
51
+ ```
52
+ Show me how AI safety research has evolved from 2020 to 2024
53
+ ```
54
+
55
+ ### Citation network analysis
56
+ ```
57
+ Get the citation network for the paper with DOI: 10.48550/arXiv.1706.03762
58
+ ```
59
+
60
+ ### Author collaboration analysis
61
+ ```
62
+ Who are the main collaborators of Yann LeCun?
63
+ ```
64
+
65
+ ### Geographic research mapping
66
+ ```
67
+ Which countries are leading research in renewable energy?
68
+ ```
69
+
70
+ ## Available Tools
71
+
72
+ The server provides 18 specialized tools:
73
+
74
+ **Literature Search:**
75
+ - `search_works` - Advanced search for papers
76
+ - `get_work` - Get detailed paper information
77
+ - `get_related_works` - Find similar papers
78
+ - `search_by_topic` - Explore specific research domains
79
+ - `autocomplete_search` - Fast typeahead search
80
+
81
+ **Citation Analysis:**
82
+ - `get_work_citations` - Who cites this paper
83
+ - `get_work_references` - What this paper cites
84
+ - `get_citation_network` - Complete citation graph
85
+ - `get_top_cited_works` - Most influential papers
86
+
87
+ **Author & Institutions:**
88
+ - `search_authors` - Find researchers
89
+ - `get_author_works` - Author's publications
90
+ - `get_author_collaborators` - Co-authorship networks
91
+ - `search_institutions` - Find universities/organizations
92
+
93
+ **Research Trends:**
94
+ - `analyze_topic_trends` - Track research evolution
95
+ - `compare_research_areas` - Compare different fields
96
+ - `get_trending_topics` - Discover emerging areas
97
+ - `analyze_geographic_distribution` - Global research mapping
98
+
99
+ **Entity Lookup:**
100
+ - `get_entity` - Get any OpenAlex entity
101
+ - `search_sources` - Find journals/venues
102
+
103
+ ## Tips
104
+
105
+ - **Add your email** to get better rate limits (100K requests/day)
106
+ - Use **Boolean operators** in searches: `"AI" AND (safety OR ethics)`
107
+ - Filter by **year ranges** to focus on recent research
108
+ - Sort by **citation count** to find influential work
109
+ - Use **per_page** parameter to get more results (max 200)
110
+
111
+ ## Troubleshooting
112
+
113
+ **Server not showing up in Claude Desktop?**
114
+ - Check that the path in your config is absolute, not relative
115
+ - Verify the build was successful: `ls build/index.js`
116
+ - Restart Claude Desktop completely
117
+
118
+ **Rate limit errors?**
119
+ - Make sure `OPENALEX_EMAIL` is set in your config
120
+ - Slow down your requests if hitting 10 requests/second
121
+
122
+ **No results found?**
123
+ - Try broader search terms
124
+ - Check spelling and use Boolean operators
125
+ - Try searching by DOI or OpenAlex ID directly
126
+
127
+ ## Next Steps
128
+
129
+ - Read the full [README.md](./README.md) for detailed documentation
130
+ - Check out [OpenAlex API docs](https://docs.openalex.org) for more filtering options
131
+ - Join the polite pool by adding your email for better performance
132
+
133
+ Happy researching! 🔬📚
package/README.md ADDED
@@ -0,0 +1,253 @@
1
+ # OpenAlex MCP Server
2
+
3
+ A Model Context Protocol (MCP) server that provides access to OpenAlex, a comprehensive open catalog of scholarly papers, authors, institutions, and more. This server is specifically designed to empower AI assistants to conduct literature reviews, analyze research trends, and map the scholarly landscape.
4
+
5
+ ## Features
6
+
7
+ Access 240+ million scholarly works through 18 specialized tools:
8
+
9
+ ### Literature Search & Discovery
10
+ - **search_works**: Advanced search with Boolean operators, filters, and sorting
11
+ - **get_work**: Get detailed metadata for a specific work
12
+ - **get_related_works**: Find similar papers based on citations and topics
13
+ - **search_by_topic**: Explore literature in specific research domains
14
+ - **autocomplete_search**: Fast typeahead search for all entity types
15
+
16
+ ### Citation Analysis
17
+ - **get_work_citations**: Forward citation analysis (who cites this work)
18
+ - **get_work_references**: Backward citation analysis (what this work cites)
19
+ - **get_citation_network**: Build complete citation networks for visualization
20
+ - **get_top_cited_works**: Find the most influential papers in a field
21
+
22
+ ### Author & Institution Analysis
23
+ - **search_authors**: Find researchers with publication and citation metrics
24
+ - **get_author_works**: Analyze an author's publication history
25
+ - **get_author_collaborators**: Map co-authorship networks
26
+ - **search_institutions**: Find leading academic institutions
27
+
28
+ ### Research Landscape & Trends
29
+ - **analyze_topic_trends**: Track research evolution over time
30
+ - **compare_research_areas**: Compare activity across different fields
31
+ - **get_trending_topics**: Discover emerging research areas
32
+ - **analyze_geographic_distribution**: Map global research activity
33
+
34
+ ### Entity Lookup
35
+ - **get_entity**: Get detailed information for any OpenAlex entity
36
+ - **search_sources**: Find journals, conferences, and publication venues
37
+
38
+ ## Installation
39
+
40
+ ### Option 1: Install from npm (Recommended)
41
+
42
+ ```bash
43
+ # Install globally
44
+ npm install -g openalex-research-mcp
45
+
46
+ # Or use directly with npx (no installation needed)
47
+ npx openalex-research-mcp
48
+ ```
49
+
50
+ ### Option 2: Install from source
51
+
52
+ ```bash
53
+ # Clone the repository
54
+ git clone https://github.com/oksure/openalex-research-mcp.git
55
+ cd openalex-research-mcp
56
+
57
+ # Install dependencies
58
+ npm install
59
+
60
+ # Build the TypeScript code
61
+ npm run build
62
+ ```
63
+
64
+ ## Configuration
65
+
66
+ ### Environment Variables (Optional but Recommended)
67
+
68
+ Set your email to join the "polite pool" for better rate limits:
69
+
70
+ ```bash
71
+ export OPENALEX_EMAIL="your.email@example.com"
72
+ ```
73
+
74
+ For premium users with an API key:
75
+
76
+ ```bash
77
+ export OPENALEX_API_KEY="your-api-key"
78
+ ```
79
+
80
+ ### Claude Desktop Configuration
81
+
82
+ Add to your Claude Desktop config file:
83
+
84
+ **MacOS**: `~/Library/Application Support/Claude/claude_desktop_config.json`
85
+ **Windows**: `%APPDATA%/Claude/claude_desktop_config.json`
86
+
87
+ **If you installed via npm/npx:**
88
+ ```json
89
+ {
90
+ "mcpServers": {
91
+ "openalex": {
92
+ "command": "npx",
93
+ "args": ["-y", "openalex-research-mcp"],
94
+ "env": {
95
+ "OPENALEX_EMAIL": "your.email@example.com"
96
+ }
97
+ }
98
+ }
99
+ }
100
+ ```
101
+
102
+ **If you installed from source:**
103
+ ```json
104
+ {
105
+ "mcpServers": {
106
+ "openalex": {
107
+ "command": "node",
108
+ "args": ["/absolute/path/to/openalex-research-mcp/build/index.js"],
109
+ "env": {
110
+ "OPENALEX_EMAIL": "your.email@example.com"
111
+ }
112
+ }
113
+ }
114
+ }
115
+ ```
116
+
117
+ ## Usage Examples
118
+
119
+ ### Example 1: Literature Review for AI Safety
120
+
121
+ ```
122
+ Find the most influential papers on AI safety published since 2020
123
+ ```
124
+
125
+ The assistant will use `get_top_cited_works` with appropriate filters to find highly-cited papers in AI safety research.
126
+
127
+ ### Example 2: Citation Network Analysis
128
+
129
+ ```
130
+ Get the citation network for the paper "Attention Is All You Need" (DOI: 10.48550/arXiv.1706.03762)
131
+ ```
132
+
133
+ The assistant will use `get_citation_network` to build a network of citing and referenced papers, enabling visualization of research impact.
134
+
135
+ ### Example 3: Research Trend Analysis
136
+
137
+ ```
138
+ Show me how quantum computing research has evolved over the past 10 years
139
+ ```
140
+
141
+ The assistant will use `analyze_topic_trends` to group publications by year and show growth patterns.
142
+
143
+ ### Example 4: Finding Collaborators
144
+
145
+ ```
146
+ Who are the main collaborators of Geoffrey Hinton?
147
+ ```
148
+
149
+ The assistant will use `get_author_collaborators` to analyze co-authorship patterns.
150
+
151
+ ### Example 5: Comparative Research Analysis
152
+
153
+ ```
154
+ Compare research activity in "deep learning", "reinforcement learning", and "federated learning" from 2018-2024
155
+ ```
156
+
157
+ The assistant will use `compare_research_areas` to show relative publication volumes.
158
+
159
+ ### Example 6: Geographic Research Mapping
160
+
161
+ ```
162
+ Which countries are leading research in climate change mitigation?
163
+ ```
164
+
165
+ The assistant will use `analyze_geographic_distribution` to map research activity by country.
166
+
167
+ ## Tool Reference
168
+
169
+ ### Search Parameters
170
+
171
+ Most search tools support these common parameters:
172
+
173
+ - **from_year / to_year**: Filter by publication year range
174
+ - **cited_by_count**: Filter by citation count (e.g., ">100")
175
+ - **is_oa**: Filter for open access works only
176
+ - **sort**: Sort results (relevance_score, cited_by_count, publication_year)
177
+ - **page / per_page**: Pagination (max 200 per page)
178
+
179
+ ### Boolean Search
180
+
181
+ The `search_works` and related tools support Boolean operators:
182
+
183
+ ```
184
+ "machine learning" AND (ethics OR fairness)
185
+ "climate change" NOT "climate denial"
186
+ (AI OR "artificial intelligence") AND safety
187
+ ```
188
+
189
+ ### Identifiers
190
+
191
+ OpenAlex accepts multiple identifier formats:
192
+
193
+ - **OpenAlex IDs**: W2741809807, A5023888391
194
+ - **DOIs**: 10.1371/journal.pone.0000000
195
+ - **ORCIDs**: 0000-0001-2345-6789
196
+ - **URLs**: Full OpenAlex URLs
197
+
198
+ ## API Rate Limits
199
+
200
+ - **Default**: 100,000 requests/day, 10 requests/second
201
+ - **Polite Pool** (with email): Better performance and reliability
202
+ - **Premium** (with API key): Higher limits and exclusive filters
203
+
204
+ ## Development
205
+
206
+ ```bash
207
+ # Watch mode for development
208
+ npm run watch
209
+
210
+ # Build
211
+ npm run build
212
+
213
+ # Run
214
+ npm start
215
+ ```
216
+
217
+ ## Data Source
218
+
219
+ All data comes from [OpenAlex](https://openalex.org), an open and comprehensive catalog of scholarly papers, authors, institutions, and more. OpenAlex indexes:
220
+
221
+ - 240+ million works (papers, books, datasets)
222
+ - 50,000+ new works added daily
223
+ - Full citation network and metadata
224
+ - Author affiliations and collaboration data
225
+ - Publication venues and impact metrics
226
+
227
+ ## Use Cases
228
+
229
+ This MCP server is ideal for:
230
+
231
+ - **Literature Reviews**: Systematically search and analyze research papers
232
+ - **Citation Analysis**: Understand research impact and influence
233
+ - **Trend Analysis**: Track how research topics evolve over time
234
+ - **Collaboration Mapping**: Identify research networks and partnerships
235
+ - **Gap Analysis**: Find understudied areas in research
236
+ - **Comparative Studies**: Compare research activity across fields
237
+ - **Institution Benchmarking**: Analyze research output by institution
238
+ - **Author Profiling**: Study researcher publication patterns
239
+
240
+ ## License
241
+
242
+ MIT
243
+
244
+ ## Contributing
245
+
246
+ Contributions are welcome! Please feel free to submit issues or pull requests.
247
+
248
+ ## Resources
249
+
250
+ - [OpenAlex Documentation](https://docs.openalex.org)
251
+ - [OpenAlex API](https://docs.openalex.org/how-to-use-the-api/api-overview)
252
+ - [Model Context Protocol](https://modelcontextprotocol.io)
253
+ - [MCP Specification](https://spec.modelcontextprotocol.io)
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env node
2
+ export {};
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":""}