You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
File "/home/user/chatglm/llm_ki/fastapi_demo.py", line 41, in create_item
json_post_raw = await request.json()
File "y/lib/python3.10/site-packages/starlette/requests.py", line 252, in json
self._json = json.loads(body)
File "y/lib/python3.10/json/init.py", line 346, in loads
return _default_decoder.decode(s)
File "y/lib/python3.10/json/decoder.py", line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "y/lib/python3.10/json/decoder.py", line 353, in raw_decode
obj, end = self.scan_once(s, idx)
json.decoder.JSONDecodeError: Expecting ',' delimiter: line 1 column 18 (char 17)
422 Unprocessable Entity
Expected Behavior
No response
Steps To Reproduce
curl -X POST "http://0.0.0.0:8000" -H 'Content-Type: application/json' -d '{"promt": """
科目
区间
单价
应缴金额
上次
量
公费
2024.2.26-2024.3.26
0.7071
14368.27
16731
16985
20320
费
2024.2.26-2024.3.26
6.35
1574.8
12524
12772
248
大写
壹万伍仟玖佰肆拾叁元零柒分
合计
15943.07
""","history":[]}'
Environment
- OS:
- Python:3.10
- Transformers:4.40.0
- PyTorch:2.1
- CUDA Support (`python -c "import torch; 12.1 print(torch.cuda.is_available())"`) :
Anything else?
No response
The text was updated successfully, but these errors were encountered:
Is there an existing issue for this?
Current Behavior
curl -X POST "http://0.0.0.0:8000" -H 'Content-Type: application/json' -d '{"promt": "
传入以上数据html文本的时候,页面自动渲染出来表格了,实际是一个html的文本:报以下错误,json解析不了,不能传html文本?只是一个文本而已为什么不能解析?传其他的文本就可以跑
File "/home/user/chatglm/llm_ki/fastapi_demo.py", line 41, in create_item
json_post_raw = await request.json()
File "y/lib/python3.10/site-packages/starlette/requests.py", line 252, in json
self._json = json.loads(body)
File "y/lib/python3.10/json/init.py", line 346, in loads
return _default_decoder.decode(s)
File "y/lib/python3.10/json/decoder.py", line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "y/lib/python3.10/json/decoder.py", line 353, in raw_decode
obj, end = self.scan_once(s, idx)
json.decoder.JSONDecodeError: Expecting ',' delimiter: line 1 column 18 (char 17)
422 Unprocessable Entity
Expected Behavior
No response
Steps To Reproduce
curl -X POST "http://0.0.0.0:8000" -H 'Content-Type: application/json' -d '{"promt": """
Environment
Anything else?
No response
The text was updated successfully, but these errors were encountered: