academia-mcp 1.5.0__tar.gz → 1.6.0__tar.gz
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.
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/PKG-INFO +6 -1
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/README.md +5 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/server.py +5 -1
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/tools/__init__.py +2 -1
- academia_mcp-1.6.0/academia_mcp/tools/review.py +185 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp.egg-info/PKG-INFO +6 -1
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/pyproject.toml +1 -1
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/tests/test_review.py +1 -1
- academia_mcp-1.5.0/academia_mcp/tools/review.py +0 -51
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/LICENSE +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/__init__.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/__main__.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/files.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/latex_templates/agents4science_2025/agents4science_2025.sty +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/latex_templates/agents4science_2025/agents4science_2025.tex +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/llm.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/pdf.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/py.typed +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/tools/anthology_search.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/tools/arxiv_download.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/tools/arxiv_search.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/tools/bitflip.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/tools/document_qa.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/tools/hf_datasets_search.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/tools/latex.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/tools/py.typed +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/tools/s2_citations.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/tools/visit_webpage.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/tools/web_search.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp/utils.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp.egg-info/SOURCES.txt +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp.egg-info/dependency_links.txt +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp.egg-info/entry_points.txt +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp.egg-info/requires.txt +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/academia_mcp.egg-info/top_level.txt +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/setup.cfg +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/tests/test_anthology_search.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/tests/test_arxiv_download.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/tests/test_arxiv_search.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/tests/test_bitflip.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/tests/test_document_qa.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/tests/test_extract_json.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/tests/test_hf_dataset_search.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/tests/test_latex.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/tests/test_s2_citations.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/tests/test_visit_webpage.py +0 -0
- {academia_mcp-1.5.0 → academia_mcp-1.6.0}/tests/test_web_search.py +0 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: academia-mcp
|
3
|
-
Version: 1.
|
3
|
+
Version: 1.6.0
|
4
4
|
Summary: MCP server that provides different tools to search for scientific publications
|
5
5
|
Author-email: Ilya Gusev <phoenixilya@gmail.com>
|
6
6
|
Project-URL: Homepage, https://github.com/IlyaGusev/academia_mcp
|
@@ -33,6 +33,11 @@ Dynamic: license-file
|
|
33
33
|
|
34
34
|
# Academia MCP
|
35
35
|
|
36
|
+
[](https://pypi.org/project/academia-mcp/)
|
37
|
+
[](https://github.com/IlyaGusev/academia_mcp/actions/workflows/python.yml)
|
38
|
+
[](LICENSE)
|
39
|
+
[](https://smithery.ai/server/@IlyaGusev/academia_mcp)
|
40
|
+
|
36
41
|
A collection of MCP tools related to the search of scientific papers:
|
37
42
|
- ArXiv search and download
|
38
43
|
- ACL Anthology search
|
@@ -1,5 +1,10 @@
|
|
1
1
|
# Academia MCP
|
2
2
|
|
3
|
+
[](https://pypi.org/project/academia-mcp/)
|
4
|
+
[](https://github.com/IlyaGusev/academia_mcp/actions/workflows/python.yml)
|
5
|
+
[](LICENSE)
|
6
|
+
[](https://smithery.ai/server/@IlyaGusev/academia_mcp)
|
7
|
+
|
3
8
|
A collection of MCP tools related to the search of scientific papers:
|
4
9
|
- ArXiv search and download
|
5
10
|
- ACL Anthology search
|
@@ -25,6 +25,7 @@ from .tools.bitflip import (
|
|
25
25
|
generate_research_proposal,
|
26
26
|
score_research_proposals,
|
27
27
|
)
|
28
|
+
from .tools.review import review_pdf
|
28
29
|
|
29
30
|
|
30
31
|
load_dotenv()
|
@@ -84,9 +85,12 @@ def run(
|
|
84
85
|
server.add_tool(generate_research_proposal)
|
85
86
|
server.add_tool(score_research_proposals)
|
86
87
|
server.add_tool(document_qa)
|
88
|
+
server.add_tool(review_pdf)
|
87
89
|
|
88
90
|
if port is None:
|
89
|
-
port =
|
91
|
+
port = int(os.environ.get("PORT", -1))
|
92
|
+
if port == -1:
|
93
|
+
port = find_free_port()
|
90
94
|
server.settings.port = port
|
91
95
|
server.settings.host = host
|
92
96
|
server.run(transport=transport)
|
@@ -13,7 +13,7 @@ from .latex import (
|
|
13
13
|
from .web_search import web_search, tavily_web_search, exa_web_search, brave_web_search
|
14
14
|
from .visit_webpage import visit_webpage
|
15
15
|
from .bitflip import extract_bitflip_info, generate_research_proposal, score_research_proposals
|
16
|
-
|
16
|
+
from .review import review_pdf
|
17
17
|
|
18
18
|
__all__ = [
|
19
19
|
"arxiv_search",
|
@@ -35,4 +35,5 @@ __all__ = [
|
|
35
35
|
"extract_bitflip_info",
|
36
36
|
"generate_research_proposal",
|
37
37
|
"score_research_proposals",
|
38
|
+
"review_pdf",
|
38
39
|
]
|
@@ -0,0 +1,185 @@
|
|
1
|
+
import base64
|
2
|
+
import os
|
3
|
+
from io import BytesIO
|
4
|
+
from pathlib import Path
|
5
|
+
from typing import List, Dict, Any
|
6
|
+
|
7
|
+
from academia_mcp.pdf import parse_pdf_file_to_images, parse_pdf_file
|
8
|
+
from academia_mcp.llm import llm_acall, ChatMessage
|
9
|
+
from academia_mcp.files import get_workspace_dir
|
10
|
+
|
11
|
+
|
12
|
+
PROMPT = """
|
13
|
+
You are an expert peer reviewer for top CS/ML venues (e.g., NeurIPS/ICML/ACL).
|
14
|
+
Your goal is to produce a fair, rigorous, and reproducible review that is maximally useful to authors and area chairs.
|
15
|
+
Be specific: cite paper sections/figures/tables when criticizing or praising.
|
16
|
+
Use actionable language ("Provide variance across 5 seeds on Dataset X; add leakage control Y").
|
17
|
+
Try to be as harsh as possible, but still be fair and constructive.
|
18
|
+
|
19
|
+
# Summary
|
20
|
+
Briefly summarize the paper and its contributions.
|
21
|
+
This is not the place to critique the paper; the authors should generally agree with a well-written summary.
|
22
|
+
This is also not the place to paste the abstract—please provide the summary in your own understanding after reading.
|
23
|
+
|
24
|
+
# Strengths and Weaknesses
|
25
|
+
Please provide a thorough assessment of the strengths and weaknesses of the paper.
|
26
|
+
A good mental framing for strengths and weaknesses is to think of reasons you might accept or reject the paper.
|
27
|
+
Please touch on the following dimensions:
|
28
|
+
|
29
|
+
## Quality
|
30
|
+
Is the submission technically sound?
|
31
|
+
Are claims well supported (e.g., by theoretical analysis or experimental results)?
|
32
|
+
Are the methods used appropriate?
|
33
|
+
Is this a complete piece of work or work in progress?
|
34
|
+
Are the authors careful and honest about evaluating both the strengths and weaknesses of their work?
|
35
|
+
|
36
|
+
## Clarity
|
37
|
+
Is the submission clearly written?
|
38
|
+
Is it well organized? (If not, please make constructive suggestions for improving its clarity.)
|
39
|
+
Does it adequately inform the reader? (Note that a superbly written paper provides enough information for an expert reader to reproduce its results.)
|
40
|
+
|
41
|
+
## Significance
|
42
|
+
Are the results impactful for the community?
|
43
|
+
Are others (researchers or practitioners) likely to use the ideas or build on them?
|
44
|
+
Does the submission address a difficult task in a better way than previous work?
|
45
|
+
Does it advance our understanding/knowledge on the topic in a demonstrable way?
|
46
|
+
Does it provide unique data, unique conclusions about existing data, or a unique theoretical or experimental approach?
|
47
|
+
|
48
|
+
## Originality
|
49
|
+
Does the work provide new insights, deepen understanding, or highlight important properties of existing methods?
|
50
|
+
Is it clear how this work differs from previous contributions, with relevant citations provided?
|
51
|
+
Does the work introduce novel tasks or methods that advance the field?
|
52
|
+
Does this work offer a novel combination of existing techniques, and is the reasoning behind this combination well-articulated?
|
53
|
+
As the questions above indicates, originality does not necessarily require introducing an entirely new method.
|
54
|
+
Rather, a work that provides novel insights by evaluating existing methods, or demonstrates improved efficiency, fairness, etc. is also equally valuable.
|
55
|
+
|
56
|
+
# Scores
|
57
|
+
Quality: Based on what you discussed in “Strengths and Weaknesses”, please assign the paper a numerical rating on the following scale to indicate the quality of the work.
|
58
|
+
4 = excellent
|
59
|
+
3 = good
|
60
|
+
2 = fair
|
61
|
+
1 = poor
|
62
|
+
|
63
|
+
Clarity: Based on what you discussed in “Strengths and Weaknesses”, please assign the paper a numerical rating on the following scale to indicate the clarity of the paper.
|
64
|
+
4 = excellent
|
65
|
+
3 = good
|
66
|
+
2 = fair
|
67
|
+
1 = poor
|
68
|
+
|
69
|
+
Significance: Based on what you discussed in “Strengths and Weaknesses”, please assign the paper a numerical rating on the following scale to indicate the significance of the paper.
|
70
|
+
4 = excellent
|
71
|
+
3 = good
|
72
|
+
2 = fair
|
73
|
+
1 = poor
|
74
|
+
|
75
|
+
Originality: Based on what you discussed in “Strengths and Weaknesses”, please assign the paper a numerical rating on the following scale to indicate the originality of the paper.
|
76
|
+
4 = excellent
|
77
|
+
3 = good
|
78
|
+
2 = fair
|
79
|
+
1 = poor
|
80
|
+
|
81
|
+
# Questions
|
82
|
+
Please list up and carefully describe questions and suggestions for the authors, which should focus on key points (ideally around 3–5) that are actionable with clear guidance.
|
83
|
+
Think of the things where a response from the author can change your opinion, clarify a confusion or address a limitation.
|
84
|
+
You are strongly encouraged to state the clear criteria under which your evaluation score could increase or decrease.
|
85
|
+
This can be very important for a productive rebuttal and discussion phase with the authors.
|
86
|
+
|
87
|
+
# Limitations
|
88
|
+
Have the authors adequately addressed the limitations and potential negative societal impact of their work?
|
89
|
+
If so, simply leave “yes”; if not, please include constructive suggestions for improvement.
|
90
|
+
In general, authors should be rewarded rather than punished for being up front about the limitations of their work and any potential negative societal impact.
|
91
|
+
You are encouraged to think through whether any critical points are missing and provide these as feedback for the authors.
|
92
|
+
|
93
|
+
|
94
|
+
# Overall
|
95
|
+
Please provide an "overall score" for this submission. Choices:
|
96
|
+
6: Strong Accept: Technically flawless paper with groundbreaking impact on one or more areas of AI, with exceptionally strong evaluation, reproducibility, and resources, and no unaddressed ethical considerations.
|
97
|
+
5: Accept: Technically solid paper, with high impact on at least one sub-area of AI or moderate-to-high impact on more than one area of AI, with good-to-excellent evaluation, resources, reproducibility, and no unaddressed ethical considerations.
|
98
|
+
4: Borderline accept: Technically solid paper where reasons to accept outweigh reasons to reject, e.g., limited evaluation. Please use sparingly.
|
99
|
+
3: Borderline reject: Technically solid paper where reasons to reject, e.g., limited evaluation, outweigh reasons to accept, e.g., good evaluation. Please use sparingly.
|
100
|
+
2: Reject: For instance, a paper with technical flaws, weak evaluation, inadequate reproducibility and incompletely addressed ethical considerations.
|
101
|
+
1: Strong Reject: For instance, a paper with well-known results or unaddressed ethical considerations
|
102
|
+
|
103
|
+
# Confidence
|
104
|
+
Please provide a "confidence score" for your assessment of this submission to indicate how confident you are in your evaluation. Choices
|
105
|
+
5: You are absolutely certain about your assessment. You are very familiar with the related work and checked the math/other details carefully.
|
106
|
+
4: You are confident in your assessment, but not absolutely certain. It is unlikely, but not impossible, that you did not understand some parts of the submission or that you are unfamiliar with some pieces of related work.
|
107
|
+
3: You are fairly confident in your assessment. It is possible that you did not understand some parts of the submission or that you are unfamiliar with some pieces of related work. Math/other details were not carefully checked.
|
108
|
+
2: You are willing to defend your assessment, but it is quite likely that you did not understand the central parts of the submission or that you are unfamiliar with some pieces of related work. Math/other details were not carefully checked.
|
109
|
+
1: Your assessment is an educated guess. The submission is not in your area or the submission was difficult to understand. Math/other details were not carefully checked.
|
110
|
+
|
111
|
+
# Format issues
|
112
|
+
Find problems with the paper formatting. Report them separately.
|
113
|
+
|
114
|
+
# Result
|
115
|
+
Return the result as a JSON object in the following format:
|
116
|
+
{
|
117
|
+
"summary": "Summary of the paper",
|
118
|
+
"strengths_and_weaknesses": {
|
119
|
+
"quality": "Quality-related strengths and weaknesses",
|
120
|
+
"clarity": "Clarity-related strengths and weaknesses",
|
121
|
+
"significance": "Significance-related strengths and weaknesses",
|
122
|
+
"originality": "Originality-related strengths and weaknesses",
|
123
|
+
},
|
124
|
+
"scores": {
|
125
|
+
"quality": ...,
|
126
|
+
"clarity": ...,
|
127
|
+
"significance": ...,
|
128
|
+
"originality": ...,
|
129
|
+
},
|
130
|
+
"questions": "Questions and suggestions for the authors",
|
131
|
+
"limitations": "Limitations of the paper",
|
132
|
+
"overall": ...,
|
133
|
+
"confidence": ...,
|
134
|
+
"format_issues": "Format issues",
|
135
|
+
}
|
136
|
+
"""
|
137
|
+
|
138
|
+
|
139
|
+
async def review_pdf(pdf_filename: str) -> str:
|
140
|
+
"""
|
141
|
+
Review a pdf file.
|
142
|
+
It parses the pdf file into images and then sends the images to the LLM for review.
|
143
|
+
It can detect different issues with the paper formatting.
|
144
|
+
It also returns a proper NeurIPS-stylereview.
|
145
|
+
|
146
|
+
Args:
|
147
|
+
pdf_filename: The path to the pdf file.
|
148
|
+
"""
|
149
|
+
pdf_filename_path = Path(pdf_filename)
|
150
|
+
if not pdf_filename_path.exists():
|
151
|
+
pdf_filename_path = Path(get_workspace_dir()) / pdf_filename
|
152
|
+
|
153
|
+
images = parse_pdf_file_to_images(pdf_filename_path)
|
154
|
+
text = "\n\n\n".join(parse_pdf_file(pdf_filename_path))
|
155
|
+
content_parts: List[Dict[str, Any]] = [
|
156
|
+
{
|
157
|
+
"type": "text",
|
158
|
+
"text": "Paper text:\n\n" + text,
|
159
|
+
}
|
160
|
+
]
|
161
|
+
for image in images:
|
162
|
+
buffer_io = BytesIO()
|
163
|
+
image.save(buffer_io, format="PNG")
|
164
|
+
img_bytes = buffer_io.getvalue()
|
165
|
+
image_base64 = base64.b64encode(img_bytes).decode("utf-8")
|
166
|
+
image_content = {
|
167
|
+
"type": "image_url",
|
168
|
+
"image_url": {"url": f"data:image/png;base64,{image_base64}"},
|
169
|
+
}
|
170
|
+
content_parts.append(image_content)
|
171
|
+
|
172
|
+
content_parts.append(
|
173
|
+
{
|
174
|
+
"type": "text",
|
175
|
+
"text": "####\n\nInstructions:\n\n" + PROMPT,
|
176
|
+
}
|
177
|
+
)
|
178
|
+
model_name = os.getenv("REVIEW_MODEL_NAME", "gpt-5")
|
179
|
+
llm_response = await llm_acall(
|
180
|
+
model_name=model_name,
|
181
|
+
messages=[
|
182
|
+
ChatMessage(role="user", content=content_parts),
|
183
|
+
],
|
184
|
+
)
|
185
|
+
return llm_response.strip()
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: academia-mcp
|
3
|
-
Version: 1.
|
3
|
+
Version: 1.6.0
|
4
4
|
Summary: MCP server that provides different tools to search for scientific publications
|
5
5
|
Author-email: Ilya Gusev <phoenixilya@gmail.com>
|
6
6
|
Project-URL: Homepage, https://github.com/IlyaGusev/academia_mcp
|
@@ -33,6 +33,11 @@ Dynamic: license-file
|
|
33
33
|
|
34
34
|
# Academia MCP
|
35
35
|
|
36
|
+
[](https://pypi.org/project/academia-mcp/)
|
37
|
+
[](https://github.com/IlyaGusev/academia_mcp/actions/workflows/python.yml)
|
38
|
+
[](LICENSE)
|
39
|
+
[](https://smithery.ai/server/@IlyaGusev/academia_mcp)
|
40
|
+
|
36
41
|
A collection of MCP tools related to the search of scientific papers:
|
37
42
|
- ArXiv search and download
|
38
43
|
- ACL Anthology search
|
@@ -1,51 +0,0 @@
|
|
1
|
-
import base64
|
2
|
-
from io import BytesIO
|
3
|
-
from pathlib import Path
|
4
|
-
|
5
|
-
from academia_mcp.pdf import parse_pdf_file_to_images
|
6
|
-
from academia_mcp.llm import llm_acall, ChatMessage
|
7
|
-
from academia_mcp.files import get_workspace_dir
|
8
|
-
|
9
|
-
|
10
|
-
PROMPT = """
|
11
|
-
Find problems with the paper formatiing.
|
12
|
-
"""
|
13
|
-
|
14
|
-
|
15
|
-
async def review_pdf(pdf_filename: str) -> str:
|
16
|
-
"""
|
17
|
-
Review a pdf file.
|
18
|
-
|
19
|
-
Args:
|
20
|
-
pdf_path: The path to the pdf file.
|
21
|
-
"""
|
22
|
-
pdf_filename_path = Path(pdf_filename)
|
23
|
-
if not pdf_filename_path.exists():
|
24
|
-
pdf_filename_path = Path(get_workspace_dir()) / pdf_filename
|
25
|
-
|
26
|
-
images = parse_pdf_file_to_images(pdf_filename_path)
|
27
|
-
content_parts = []
|
28
|
-
for image in images:
|
29
|
-
buffer_io = BytesIO()
|
30
|
-
image.save(buffer_io, format="PNG")
|
31
|
-
img_bytes = buffer_io.getvalue()
|
32
|
-
image_base64 = base64.b64encode(img_bytes).decode("utf-8")
|
33
|
-
image_content = {
|
34
|
-
"type": "image_url",
|
35
|
-
"image_url": {"url": f"data:image/png;base64,{image_base64}"},
|
36
|
-
}
|
37
|
-
content_parts.append(image_content)
|
38
|
-
|
39
|
-
content_parts.append(
|
40
|
-
{
|
41
|
-
"type": "text",
|
42
|
-
"text": "Please review the paper and provide a summary of its content.",
|
43
|
-
}
|
44
|
-
)
|
45
|
-
llm_response = await llm_acall(
|
46
|
-
model_name="gpt-4o",
|
47
|
-
messages=[
|
48
|
-
ChatMessage(role="user", content=content_parts),
|
49
|
-
],
|
50
|
-
)
|
51
|
-
return llm_response.strip()
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|