How to use local DeepSeek R1 #272
Replies: 5 comments 2 replies
-
hmm, yeah, deepseek the new kid on the block.... deepseek is great.... for jailbreak prompts as it lacks every safety measure around. :-) |
Beta Was this translation helpful? Give feedback.
-
putting all my tags as part of the prompt, would break every prompting, as i have +/- 450 tags. This whole "put all tags in prompt" i still don't understand to use and/or cannot use because of prompt size. |
Beta Was this translation helpful? Give feedback.
-
Thanks for figuring out how to use DeepSeek. I have created #381 to add support for DeepSeek (and others) on Ollama by adding support for structured output. However, I am not happy with the results. I have tried the same document a couple of times. 2 out of 10 times the results are garbage, values are english (instead of german) and even the date is in a wrong format (document says 31.01.2025, DeepSeek returns 3101-02-25). In 2 out of 10 times it is OK, but not good, and in the remaining 6 times, it is perfect. No idea why, it is always the exact same prompt. Similar things happen with other models as well, but never as much as with DeepSeek. Might be a problem that all of my documents are german. |
Beta Was this translation helpful? Give feedback.
-
no i guess thats AI like it is today. Even ChatGPT is like that sometimes |
Beta Was this translation helpful? Give feedback.
-
I can Confirm this. Holy crap Google Gemini was already freespirited in that regard, but this is WAY over the top. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I just used DeepSeek-R1-Distill-Llama-8B-Q4_K_M.gguf for analyzing 100 documents locally, and I'm fairly impressed by both speed and accuracy:
How to
If you want to try it yourself, here are the settings I used:
Settings: Paperless Assistant
AI Configuration
AI Provider
-> Custom
Base URL (local IP of my pc, not localhost!, note the /v1 at the end if the URL!)
-> http://192.168.7.99:1234/v1
API Key (just a random '0' as LM Studio doesn't need a key)
-> 0
Model
-> deepseek-r1-distill-llama-8b
Prompt
Settings LM Studio
I used LM Studio 0.3.9 running on a RTX 2060
My Server settings:
Inference settings
Important: You have to use "structured output" in order to get the right output that paperless-ai can understand!
Here is the Schema I used, paste it into the "Structured Output" setting in LM Studio as shown in the screenshot above.
Load Settings
Beta Was this translation helpful? Give feedback.
All reactions