mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-07-20 06:31:02 +08:00
Go: add LLM usage (#17049)
### Summary ``` RAGFlow(api/default)> CHAT WITH 'glm-4-flash@new_test@zhipu-ai' MESSAGE '30 words describes LLM'; Answer: Hello! I'm ChatGLM, an AI assistant. Feel free to ask me any questions or request help with any tasks. Input tokens: 5 Output tokens: 28 Time: 12.748241 ``` Signed-off-by: Jin Hai <haijin.chn@gmail.com>
This commit is contained in:
@@ -820,6 +820,7 @@ func (h *ProviderHandler) ChatToModel(c *gin.Context) {
|
||||
"code": 0,
|
||||
"reasoning_content": response.ReasonContent,
|
||||
"answer": response.Answer,
|
||||
"usage": response.Usage,
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user