Closed iischajn closed 1 year ago
examor-server-1 | ERROR: Exception in ASGI application examor-server-1 | Traceback (most recent call last): examor-server-1 | File "/usr/local/lib/python3.11/site-packages/uvicorn/protocols/websockets/websockets_impl.py", line 247, in run_asgi examor-server-1 | result = await self.app(self.scope, self.asgi_receive, self.asgi_send) examor-server-1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ examor-server-1 | File "/usr/local/lib/python3.11/site-packages/uvicorn/middleware/proxy_headers.py", line 84, in call examor-server-1 | return await self.app(scope, receive, send) examor-server-1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ examor-server-1 | File "/usr/local/lib/python3.11/site-packages/fastapi/applications.py", line 289, in call examor-server-1 | await super().call(scope, receive, send) examor-server-1 | File "/usr/local/lib/python3.11/site-packages/starlette/applications.py", line 122, in call examor-server-1 | await self.middleware_stack(scope, receive, send) examor-server-1 | File "/usr/local/lib/python3.11/site-packages/starlette/middleware/errors.py", line 149, in call examor-server-1 | await self.app(scope, receive, send) examor-server-1 | File "/usr/local/lib/python3.11/site-packages/starlette/middleware/exceptions.py", line 79, in call examor-server-1 | raise exc examor-server-1 | File "/usr/local/lib/python3.11/site-packages/starlette/middleware/exceptions.py", line 68, in call examor-server-1 | await self.app(scope, receive, sender) examor-server-1 | File "/usr/local/lib/python3.11/site-packages/fastapi/middleware/asyncexitstack.py", line 20, in call examor-server-1 | raise e examor-server-1 | File "/usr/local/lib/python3.11/site-packages/fastapi/middleware/asyncexitstack.py", line 17, in call examor-server-1 | await self.app(scope, receive, send) examor-server-1 | File "/usr/local/lib/python3.11/site-packages/starlette/routing.py", line 718, in call examor-server-1 | await route.handle(scope, receive, send) examor-server-1 | File "/usr/local/lib/python3.11/site-packages/starlette/routing.py", line 341, in handle examor-server-1 | await self.app(scope, receive, send) examor-server-1 | File "/usr/local/lib/python3.11/site-packages/starlette/routing.py", line 82, in app examor-server-1 | await func(session) examor-server-1 | File "/usr/local/lib/python3.11/site-packages/fastapi/routing.py", line 324, in app examor-server-1 | await dependant.call(**values) examor-server-1 | File "/app/main.py", line 133, in websocket_endpoint examor-server-1 | await websocket.send_json(uploading_files) examor-server-1 | File "/usr/local/lib/python3.11/site-packages/starlette/websockets.py", line 173, in send_json examor-server-1 | await self.send({"type": "websocket.send", "text": text}) examor-server-1 | File "/usr/local/lib/python3.11/site-packages/starlette/websockets.py", line 85, in send examor-server-1 | await self._send(message) examor-server-1 | File "/usr/local/lib/python3.11/site-packages/starlette/middleware/exceptions.py", line 65, in sender examor-server-1 | await send(message) examor-server-1 | File "/usr/local/lib/python3.11/site-packages/uvicorn/protocols/websockets/websockets_impl.py", line 320, in asgi_send examor-server-1 | await self.send(data) # type: ignore[arg-type] examor-server-1 | ^^^^^^^^^^^^^^^^^^^^^ examor-server-1 | File "/usr/local/lib/python3.11/site-packages/websockets/legacy/protocol.py", line 635, in send examor-server-1 | await self.ensure_open() examor-server-1 | File "/usr/local/lib/python3.11/site-packages/websockets/legacy/protocol.py", line 944, in ensure_open examor-server-1 | raise self.connection_closed_exc() examor-server-1 | websockets.exceptions.ConnectionClosedOK: received 1000 (OK); then sent 1000 (OK) examor-server-1 | INFO: connection closed
好的,今天晚些时候我会查看这个问题,感谢您的issue
我也上传md文件报错,
{ "data": null, "code": 1, "message": "HTTPSConnectionPool(host='api.openai.com', port=443): Max retries exceeded with url: /v1/chat/completions (Caused by SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1002)')))" }
@kaisa911, 这个是由于连接失败引起的,如果在国内连接 Openai 可能需要设置 VPN 的 proxy地址或者代理的 base 地址。使用 docker 启动的话,也请查看 docker 的环境配置,是否有做网络代理
@iischajn 请问你的文档中是否有 emoji 这种 Unicode 类型的字符?
@iischajn 请问你的文档中是否有 emoji 这种 Unicode 类型的字符?
是的,是有的,那我试下纯文本的方式。另外我看目前好像只支持md,建议后续可考虑增加word、pdf、txt、excel等类型。
好的,我正在更新代码,更新后可以支持文档中存在 Unicode 字符,其他的文本类型也在计划中,更多的规划可以查看 ROADMAP
我已经更新了代码,请尝试更新你本地的代码,应该会修复之前的这个问题!感谢你的 issue 和建议!如果有其他问题欢迎继续与我沟通~
更新代码之后上面的错误提示依旧出现,设定了最简单的语句md,也会出现。如果有可以解析的md你可以更新放到示例里方便测试。另外这次app里的前端模块下载 pnpm install 似乎需要手动运行。
@iischajn,我预计你的markdown内容在分片后没有超过token长度为200的分片(因为内容较少的分片内容,GPT无法良好的生成问题,所以我增加了这个判断,可以看这个方法 is_there_no_enough_content),所以会出现报错,我会优化这个错误提示。同时你的建议很棒,下周我会创建一个“文件最佳实践”的文档,会将一些好的模版放出,并且给予文档盘版的建议!至于你说的前端模块下载内容,请问可否提供更多的信息,这样我能更好的确定问题所在
@iischajn, 我为仓库上传了一份 vue 的文档 zh-vue-props.md, 你可以使用这文档进行测试
Description of the bug
1 validation error for LLMChain prompt none is not an allowed value (type=type_error.none.not_allowed)