llSourcell / Doctor-Dignity

Doctor Dignity is an LLM that can pass the US Medical Licensing Exam. It works offline, it's cross-platform, & your health data stays private.
Apache License 2.0
3.85k stars 403 forks source link

[Bug] rwkv-raven-3b-q4f16_2 not found when compiling the iOS project #31

Open yuehengwu opened 1 year ago

yuehengwu commented 1 year ago

🐛 Bug

To Reproduce

In the DoctorGPT project, following the compilation documentation for mlc-llm, I get an error when executing the script.

sh ./prepare_libs.sh
Traceback (most recent call last):
  File "/Users/wyh/Desktop/Programs/DoctorGPT/ios/prepare_model_lib.py", line 29, in <module>
    main()
  File "/Users/wyh/Desktop/Programs/DoctorGPT/ios/prepare_model_lib.py", line 19, in main
    raise RuntimeError(
RuntimeError: Cannot find lib for rwkv-raven-3b-q4f16_2 in the following candidate path: ['/Users/wyh/Desktop/Programs/DoctorGPT/dist/rwkv-raven-3b-q4f16_2/rwkv-raven-3b-q4f16_2-iphone.tar', '/Users/wyh/Desktop/Programs/DoctorGPT/dist/prebuilt/lib/rwkv-raven-3b-q4f16_2-iphone.tar']

But after I modified /ios/MLCChat/app-config.json, the prepare_libs.sh script executed successfully, and Xcode was able to compile successfully.

IMG_9084B58BB2C7-1

However, the program crashes when running.

截屏2023-09-13 22 58 41
altruismb commented 1 year ago

hello, how did you fix it, what needs to be modify, can you please provide guidance

altruismb commented 1 year ago

🐛 Bug

To Reproduce

In the DoctorGPT project, following the compilation documentation for mlc-llm, I get an error when executing the script.

sh ./prepare_libs.sh
Traceback (most recent call last):
  File "/Users/wyh/Desktop/Programs/DoctorGPT/ios/prepare_model_lib.py", line 29, in <module>
    main()
  File "/Users/wyh/Desktop/Programs/DoctorGPT/ios/prepare_model_lib.py", line 19, in main
    raise RuntimeError(
RuntimeError: Cannot find lib for rwkv-raven-3b-q4f16_2 in the following candidate path: ['/Users/wyh/Desktop/Programs/DoctorGPT/dist/rwkv-raven-3b-q4f16_2/rwkv-raven-3b-q4f16_2-iphone.tar', '/Users/wyh/Desktop/Programs/DoctorGPT/dist/prebuilt/lib/rwkv-raven-3b-q4f16_2-iphone.tar']

But after I modified /ios/MLCChat/app-config.json, the prepare_libs.sh script executed successfully, and Xcode was able to compile successfully.

IMG_9084B58BB2C7-1

However, the program crashes when running.

截屏2023-09-13 22 58 41

hello, how did you fix it, what needs to be modify, can you please provide guidance

yuehengwu commented 1 year ago

hello, how did you fix it, what needs to be modify, can you please provide guidance

I didn't fix it. I can just compile success it in Xcode, but it will crash after running it.

princeomon commented 1 year ago

What did you change in /ios/MLCChat/app-config.json, the prepare_libs.sh script?

yuehengwu commented 1 year ago

What did you change in /ios/MLCChat/app-config.json, the prepare_libs.sh script?

I did not modify the prepare_libs.sh file and I changed app-config.json to the following code because rwkv-raven-3b-q4f16_2 was not found

截屏2023-10-30 09 05 25
princeomon commented 1 year ago

What did you change in /ios/MLCChat/app-config.json, the prepare_libs.sh script?

I did not modify the prepare_libs.sh file and I changed app-config.json to the following code because rwkv-raven-3b-q4f16_2 was not found

截屏2023-10-30 09 05 25

Thank you. I got it.