dify icon indicating copy to clipboard operation
dify copied to clipboard

The mathematical formula of the answer cannot be displayed when using azure deepseek r1 api

Open jeef111111 opened this issue 11 months ago • 4 comments

Self Checks

  • [x] This is only for bug report, if you would like to ask a question, please head to Discussions.
  • [x] I have searched for existing issues search for existing issues, including closed ones.
  • [x] I confirm that I am using English to submit this report (我已阅读并同意 Language Policy).
  • [x] [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)
  • [x] Please do not modify this template :) and fill in all the required fields.

Dify version

V0.15.3

Cloud or Self Hosted

Cloud

Steps to reproduce

Image It can be seen that the formula cannot be displayed completely

Image

✔️ Expected Behavior

Hope this problem can be solved, thanks!

❌ Actual Behavior

No response

jeef111111 avatar Feb 17 '25 11:02 jeef111111

Image

jeef111111 avatar Feb 17 '25 11:02 jeef111111

@jeef111111 你好! 我是Dosu,我是一个可以帮你解决bug,回答问题,并成为贡献者的机器人。我会在等待人类维护者的过程中为你提供帮助哦! 🤖

The issue you're experiencing with the mathematical formula not being displayed when using the Azure DeepSeek R1 API in Dify might be related to the libraries used for rendering LaTeX. Dify uses katex, rehype-katex, and remark-math for rendering mathematical formulas or LaTeX [1].

Here are a few steps you can take to troubleshoot and potentially resolve the issue:

  1. Check LaTeX Syntax: Ensure that the LaTeX syntax in your input is correct and supported by the katex library, as it might not support all LaTeX commands.

  2. Update Dependencies: Make sure that your Dify installation is using the latest versions of these libraries, as updates might include bug fixes or improvements in rendering capabilities.

  3. Configuration: Verify if there are any specific configurations required for rendering LaTeX with the Azure DeepSeek R1 API. Unfortunately, I couldn't find specific configuration details in the current documentation.

If the issue persists, it might be a limitation or bug in the current version of Dify (V0.15.3) or the Azure DeepSeek R1 API integration. You might want to keep an eye on updates or patches that address this issue.

To continue talking to Dosu, mention @dosu.


Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Bug Report | Other

dosubot[bot] avatar Feb 17 '25 11:02 dosubot[bot]

same issue:

Image

mrFranklin avatar Feb 26 '25 02:02 mrFranklin

Hi, @jeef111111. I'm Dosu, and I'm helping the Dify team manage their backlog and am marking this issue as stale.

Issue Summary:

  • Reported bug in Azure Deepseek R1 API: Mathematical formulas not displaying correctly in version V0.15.3 on cloud setup.
  • You provided images to illustrate the issue.
  • I suggested troubleshooting steps: check LaTeX syntax, update dependencies, verify configurations.
  • Another user, mrFranklin, confirmed the issue and provided an image.

Next Steps:

  • Please confirm if this issue is still relevant to the latest version of the Dify repository by commenting here.
  • If there is no further activity, this issue will be automatically closed in 15 days.

Thank you for your understanding and contribution!

dosubot[bot] avatar Mar 29 '25 16:03 dosubot[bot]