Code Monkey home page Code Monkey logo

chatreviewer's Introduction


ChatReviewer

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

ChatReviewer收到了大多数人的肯定,同时也收到少数质疑和担忧。

因此,为了防止极少数人直接使用生成的内容进行论文审稿,在每次生成的内容最后加上了的伦理声明,

输出中间插入了警告:Generated by ChatGPT, no copying allowed! (为了伦理安全,只能牺牲内容的可读性~)

从生成的内容里扣字,不如直接使用ChatGPT更有效率,相信可以防止有人使用该工具对分配的论文进行审稿。

该工具帮助了不少人从审稿人角度对论文进行快速的总结和评估,提高了科研和学习的效率,目前看来是利大于弊。

如果谁有更好的方法来限制少数人的不规范使用,欢迎留言,为科研界做一份贡献。

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

其他相关工具--学术GPT https://huggingface.co/spaces/ShiwenNi/gpt-academic image 💥💥💥ChatReviewer的第一版网页出来了!网页版不需要翻墙,直接点击:https://huggingface.co/spaces/ShiwenNi/ChatReviewer image 💥💥💥ChatResponse的第一版网页也出来了!网页版不需要翻墙,直接点击:https://huggingface.co/spaces/ShiwenNi/ChatResponse image ChatPaper https://chatwithpaper.org/ image

ChatReviewer是一款基于ChatGPT-3.5的API开发的智能论文分析与建议助手。其用途如下: ⭐️对论文的优缺点进行快速总结和分析,提高科研人员的文献阅读和理解的效率,紧跟研究前沿。 ⭐️对自己的论文进行分析,根据ChatReviewer生成的改进建议进行查漏补缺,进一步提高自己的论文质量。

ChatResponse是一款根据审稿人的评论自动生成作者回复的AI助手。用途如下: ⭐️根据收到的审稿意见,ChatResponse自动提取其中各个审稿人的问题和担忧,并生成点对点的回复。

基于之前ChatPaper的启发,本人在周末开发了这款ChatReviewer,并且开源给大家。欢迎大家使用、提问和转发!

♥本项目是本人利用休息时间进行更新,如果对您有帮助,欢迎Star和Fork,也欢迎您进行赞助!♥

⭐️⭐️⭐️ 声明:请对审稿的论文负责,不要直接复制粘贴ChatReviewer生成的任何审稿意见!!!

主要更新:

  • 💥增加了ChatResponse的网页版! 2023/3/27
  • 💥💥💥为了方便没有太多计算机背景的人的使用,经过本人昨晚上的辛苦加班TAT,ChatReviewer的第一版网页出来了!!! 2023/3/22
  • 重写了section split的逻辑, fix了可能抓不到固定标题的问题;修改prompt机制:先询问chatgpt 它感兴趣的章节, 随后再发送相应的章节。2023/3/21
  • 更新了ChatResponse,这个是根据审稿人的评论自动生成作者回复的AI助手。(ChatResponse和ChatReviewer有点左右互博的意思...) 2023/3/19
  • 增加了Docker部署的方式。将服务部署在自己的服务器上,速度更快,更安全。一行命令可以部署两个服务。2023/5/28

使用步骤:

Windows, Mac和Linux系统都可,python版本最好是3.8或3.9,因为低于3.8就不支持tiktoken这个包。

  1. 在apikey.ini中填入你的openai的api key(sk开头的那串)
  2. 使用过程要使用VPN而且保证全局代理(因为ChatGPT把**ban了)。
  3. 在ReviewFormat.txt中输入你想要的特殊审稿格式(不然就是默认格式)。 image
  4. 安装依赖:使用VPN。
pip install -r requirements.txt

或者使用国内镜像:

pip install -r requirements.txt -i  http://pypi.douban.com/simple  --trusted-host pypi.douban.com
  1. 对本地的论文进行分析: 运行chat_reviewer.py, 比如:
python chat_reviewer.py --paper_path "input_file/demo1.pdf"

对本地的论文进行批量分析: 运行chat_reviewer.py, 比如:

python chat_reviewer.py --paper_path "input_file"

Docker部署:

docker run -d -p 7000:7000 -p 8000:8000 hanhongyong/chatreviewer:latest

其中,7000端口为ChatReviewer服务,8000端口为ChatResponse服务。注意:本服务一定要部署在国外服务器上!

例子:

image

使用ChatResponse

对本地的审稿评论review_comments.txt进行回复: 运行chat_response.py, 比如:

python chat_response.py --comment_path "review_comments.txt"

例子: image

致谢:

  • 感谢OpenAI提供的强大ChatGPT-API;
  • 感谢kaixindelele同学的ChatPaper和开源精神 ,ChatReviewer的代码是基于ChatPaper修改而来。

chatreviewer's People

Contributors

azureleon1 avatar caopulan avatar jackory avatar merak0514 avatar nishiwen1214 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

chatreviewer's Issues

网页版Error

网页版 点击 submit之后,读条到达预期时间左右,显示Error

NameErro

平台 OS: Ubuntu 22.04.2 LTS x86_64

python3 chat_reviewer.py --paper_path "demo.pdf"

line 218, in
reviewer_args = ReviewerParams(**vars(parser.parse_args()))
NameError: name 'ReviewerParams' is not defined

errors when run the demo

Traceback (most recent call last):
File "/Users/wangpengan/Desktop/education/ChatReviewer/chat_reviewer.py", line 181, in
main(args=args)
File "/Users/wangpengan/Desktop/education/ChatReviewer/chat_reviewer.py", line 158, in main
paper_list.append(Paper(path=args.paper_path))
File "/Users/wangpengan/Desktop/education/ChatReviewer/get_paper_from_pdf.py", line 21, in init
self.parse_pdf()
File "/Users/wangpengan/Desktop/education/ChatReviewer/get_paper_from_pdf.py", line 33, in parse_pdf
self.extract_section_infomation()
File "/Users/wangpengan/Desktop/education/ChatReviewer/get_paper_from_pdf.py", line 141, in extract_section_infomation
text = json.dumps(block)
File "/opt/anaconda3/envs/python39/lib/python3.9/json/init.py", line 231, in dumps
return _default_encoder.encode(obj)
File "/opt/anaconda3/envs/python39/lib/python3.9/json/encoder.py", line 199, in encode
chunks = self.iterencode(o, _one_shot=True)
File "/opt/anaconda3/envs/python39/lib/python3.9/json/encoder.py", line 257, in iterencode
return _iterencode(o, 0)
File "/opt/anaconda3/envs/python39/lib/python3.9/json/encoder.py", line 179, in default
raise TypeError(f'Object of type {o.class.name} '
TypeError: Object of type bytes is not JSON serializable

error

提交了API-key和文档之后,右边生成框进度条拉满之后只显示一个Error,请问是什么情况呢

maximum token and format

chat reviewer 有两个小问题:

  1. this model's maximum context length is 4097 tokens. 这是API 的limit 决定的,所以太长的文章不太行。
  2. I'm sorry, but there seems to be an error with the paper you've provided. The title, abstract, introduction, and conclusion are all labeled as "for peer review." Can you please provide me with the correct paper? 不同于有些 的conference paper. 很多journal 要求review的版本都会打 for peer review的水印。 所以会有这个问题。

谢谢!

A license to allow derivative work?

I wanted to add a web interface for this. But current license is CC no derivatives. My understanding is that the license prevents me from doing so. Can you change to an open source license that permits derivative work?

api额度

请问chatgpt api额度使用完后国外充值有一定门槛,可以使用类似平台API2D的key来实现项目的运行吗?

网页版错误

您好,网页版运行会出现以下错误:

openai.error.InvalidRequestError: This model's maximum context length is 4097 tokens. However, your messages resulted in 27476 tokens. Please reduce the length of the messages.

关于连接问题,已开全局代理,请问这个错误有人遇到过吗?怎么解决的。

openai.error.APIConnectionError: Error communicating with OpenAI: HTTPSConnectionPool(host='api.openai.com', port=443): Max retries exceeded with url: /v1/chat/completio
ns (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x000001F748967F70>: Failed to establish a new connection: [WinError 10060] 由于连接方在
一段时间后没有正确答复或连接的主机没有反应,连接尝试失败。'))

错误的最大令牌

在解析一个文件时,我发现以下错误:

Traceback (most recent call last):
  File "/Users/paco/Downloads/ChatPaper-main4/chat_reviewer.py", line 181, in <module>
    main(args=args)
  File "/Users/paco/Downloads/ChatPaper-main4/chat_reviewer.py", line 168, in main
    reviewer1.review_by_chatgpt(paper_list=paper_list)
  File "/Users/paco/Downloads/ChatPaper-main4/chat_reviewer.py", line 45, in review_by_chatgpt
    sections_of_interest = self.stage_1(paper)
  File "/Users/paco/Downloads/ChatPaper-main4/chat_reviewer.py", line 100, in stage_1
    response = openai.ChatCompletion.create(
  File "/Users/paco/opt/miniconda3/lib/python3.9/site-packages/openai/api_resources/chat_completion.py", line 25, in create
    return super().create(*args, **kwargs)
  File "/Users/paco/opt/miniconda3/lib/python3.9/site-packages/openai/api_resources/abstract/engine_api_resource.py", line 153, in create
    response, _, api_key = requestor.request(
  File "/Users/paco/opt/miniconda3/lib/python3.9/site-packages/openai/api_requestor.py", line 226, in request
    resp, got_stream = self._interpret_response(result, stream)
  File "/Users/paco/opt/miniconda3/lib/python3.9/site-packages/openai/api_requestor.py", line 619, in _interpret_response
    self._interpret_response_line(
  File "/Users/paco/opt/miniconda3/lib/python3.9/site-packages/openai/api_requestor.py", line 679, in _interpret_response_line
    raise self.handle_error_response(
openai.error.InvalidRequestError: This model's maximum context length is 4097 tokens. However, your messages resulted in 8484 tokens. Please reduce the length of the messages.

找不到文件,换了几个都不行

File "D:\anaconda3\envs\chatgpt\Lib\site-packages\fitz\fitz.py", line
3953, in init
raise FileNotFoundError(msg)
fitz.fitz.FileNotFoundError: no such file: '‪D:\Users\Downloads\Photocat
alytic behavior of biochar-modified carbon nitride with enriched visible-light reactivity.pdf'

SSL Error

ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:1129)
During handling of the above exception, another exception occurred:
raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='openaipublic.blob.core.windows.net', port=443): Max retries exceeded with url: /gpt-2/encodings/main/vocab.bpe (Caused by SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1129)')))
During handling of the above exception, another exception occurred:
raise SSLError(e, request=request)
requests.exceptions.SSLError: HTTPSConnectionPool(host='openaipublic.blob.core.windows.net', port=443): Max retries exceeded with url: /gpt-2/encodings/main/vocab.bpe (Caused by SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1129)')))

已经开了全局代理,访问网站没有问题,但本地运行就报错

RuntimeError: Directory 'static/' does not exist

报错信息为:
Traceback (most recent call last):
File "chat_reviewer.py", line 11, in
from get_paper_from_pdf import Paper
File "C:\Users\18325\Desktop\ChatReviewer-main\ChatReviewer-main\get_paper_from_pdf.py", line 1, in
import fitz, io, os
File "C:\Users\18325\anaconda3\lib\site-packages\fitz_init_.py", line 1, in
from frontend import *
File "C:\Users\18325\anaconda3\lib\site-packages\frontend_init_.py", line 1, in
from .events import *
File "C:\Users\18325\anaconda3\lib\site-packages\frontend\events_init_.py", line 1, in
from .clipboard import *
File "C:\Users\18325\anaconda3\lib\site-packages\frontend\events\clipboard.py", line 2, in
from ..dom import Event
File "C:\Users\18325\anaconda3\lib\site-packages\frontend\dom.py", line 439, in
from . import dispatcher
File "C:\Users\18325\anaconda3\lib\site-packages\frontend\dispatcher.py", line 15, in
from . import config, server
File "C:\Users\18325\anaconda3\lib\site-packages\frontend\server.py", line 24, in
app.mount(config.STATIC_ROUTE, StaticFiles(directory=config.STATIC_DIRECTORY), name=config.STATIC_NAME)
File "C:\Users\18325\anaconda3\lib\site-packages\starlette\staticfiles.py", line 57, in init
raise RuntimeError(f"Directory '{directory}' does not exist")
RuntimeError: Directory 'static/' does not exist
请问如何解决?

Ethical concerns

I tried this tool with several papers I reviewed.

However, this tool seems to give only "ABSTRACT" strengths and weaknesses that are, mostly, useless for authors for further improvements.

  • No specific questions/suggestions are provided, only general assessments (e.g., more experiments should be conducted with more baselines". This issue should be particularly avoided for research reviews.
  • The overall rating seems always to be 4 from 1 to 5 (three tries plus the one in README example)
  • It doesn't understand the paper but gives mediocre and vague reviews.

Therefore, I suggest the authors of this tool to add more warnings in the repo README.md that any reviewers should not use this tool for any papers they are going to review.

Thank you for create this tool for experiments. I recognize and appreciate the power of GPT-based services but still concern their negative impacts to the society and research community when misused.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.