This repository was archived by the owner on Jan 21, 2026. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 7
This repository was archived by the owner on Jan 21, 2026. It is now read-only.
Once llm fails to output json. Insert infinite loops #9
Copy link
Copy link
Open
Description
Whenever llm fails to output valid json, the insert infinite loops. We will need a way to skip the record and log it.
[GIN] 2025/07/27 - 11:04:25 | 200 | 11.068352935s | 127.0.0.1 | POST "/api/chat"
time=2025-07-27T11:04:25.445-04:00 level=WARN msg="Retry parse result" package=golightrag function=Insert retry=1311 error="failed to parse llm result: unexpected end of JSON input"
[GIN] 2025/07/27 - 11:04:36 | 200 | 11.09455642s | 127.0.0.1 | POST "/api/chat"
time=2025-07-27T11:04:36.545-04:00 level=WARN msg="Retry parse result" package=golightrag function=Insert retry=1312 error="failed to parse llm result: unexpected end of JSON input"
[GIN] 2025/07/27 - 11:04:47 | 200 | 11.044513869s | 127.0.0.1 | POST "/api/chat"
time=2025-07-27T11:04:47.595-04:00 level=WARN msg="Retry parse result" package=golightrag function=Insert retry=1313 error="failed to parse llm result: unexpected end of JSON input"
[GIN] 2025/07/27 - 11:04:58 | 200 | 11.05047549s | 127.0.0.1 | POST "/api/chat"
time=2025-07-27T11:04:58.655-04:00 level=WARN msg="Retry parse result" package=golightrag function=Insert retry=1314 error="failed to parse llm result: unexpected end of JSON input"
[GIN] 2025/07/27 - 11:05:09 | 200 | 11.089884062s | 127.0.0.1 | POST "/api/chat"
time=2025-07-27T11:05:09.755-04:00 level=WARN msg="Retry parse result" package=golightrag function=Insert retry=1315 error="failed to parse llm result: unexpected end of JSON input"
[GIN] 2025/07/27 - 11:05:20 | 200 | 11.065728696s | 127.0.0.1 | POST "/api/chat"
time=2025-07-27T11:05:20.907-04:00 level=WARN msg="Retry parse result" package=golightrag function=Insert retry=1316 error="failed to parse llm result: unexpected end of JSON input"
[GIN] 2025/07/27 - 11:05:31 | 200 | 11.070242225s | 127.0.0.1 | POST "/api/chat"
time=2025-07-27T11:05:31.983-04:00 level=WARN msg="Retry parse result" package=golightrag function=Insert retry=1317 error="failed to parse llm result: unexpected end of JSON input"
[GIN] 2025/07/27 - 11:05:43 | 200 | 11.080259857s | 127.0.0.1 | POST "/api/chat"
time=2025-07-27T11:05:43.068-04:00 level=WARN msg="Retry parse result" package=golightrag function=Insert retry=1318 error="failed to parse llm result: unexpected end of JSON input"
[GIN] 2025/07/27 - 11:05:54 | 200 | 11.100380904s | 127.0.0.1 | POST "/api/chat"
https://github.com/MegaGrindStone/go-light-rag/blob/main/insert.go#L227
Related #4
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels