jacoblee93 / fully-local-pdf-chatbot

Yes, it's another chat over documents implementation... but this one is entirely local!
https://webml-demo.vercel.app
MIT License
1.68k stars 307 forks source link

How to setup for Windows? #11

Closed windowshopr closed 8 months ago

windowshopr commented 9 months ago

Ollama Windows preview came out the other day, and looking to try this web app with it. Running into the below issues:

PS C:\Users\chalu> $ OLLAMA_ORIGINS=https://webml-demo.vercel.app OLLAMA_HOST=127.0.0.1:11435 ollama serve
$ : The term '$' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ $ OLLAMA_ORIGINS=https://webml-demo.vercel.app OLLAMA_HOST=127.0.0.1: ...
+ ~
    + CategoryInfo          : ObjectNotFound: ($:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

PS C:\Users\chalu> OLLAMA_ORIGINS=https://webml-demo.vercel.app OLLAMA_HOST=127.0.0.1:11435 ollama serve
OLLAMA_ORIGINS=https://webml-demo.vercel.app : The term 'OLLAMA_ORIGINS=https://webml-demo.vercel.app' is not
recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if
a path was included, verify that the path is correct and try again.
At line:1 char:1
+ OLLAMA_ORIGINS=https://webml-demo.vercel.app OLLAMA_HOST=127.0.0.1:11 ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (OLLAMA_ORIGINS=...demo.vercel.app:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

PS C:\Users\chalu> $OLLAMA_ORIGINS=https://webml-demo.vercel.app OLLAMA_HOST=127.0.0.1:11435 ollama serve
https://webml-demo.vercel.app : The term 'https://webml-demo.vercel.app' is not recognized as the name of a cmdlet,
function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the
path is correct and try again.
At line:1 char:17
+ $OLLAMA_ORIGINS=https://webml-demo.vercel.app OLLAMA_HOST=127.0.0.1:1 ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (https://webml-demo.vercel.app:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

PS C:\Users\chalu> $OLLAMA_ORIGINS="https://webml-demo.vercel.app" OLLAMA_HOST=127.0.0.1:11435 ollama serve
At line:1 char:49
+ ... S="https://webml-demo.vercel.app" OLLAMA_HOST=127.0.0.1:11435 ollama  ...
+                                       ~~~~~~~~~~~~~~~~~~~~~~~~~~~
Unexpected token 'OLLAMA_HOST=127.0.0.1:11435' in expression or statement.
    + CategoryInfo          : ParserError: (:) [], ParentContainsErrorRecordException
    + FullyQualifiedErrorId : UnexpectedToken

As you can see, I've tried setting that variable value to the web app address, but no success. Would be good for someone to post the Windows equivalent if they have it.

elecraft2002 commented 8 months ago

Try this on windows CMD CMD one: set OLLAMA_ORIGINS=https://webml-demo.vercel.app set OLLAMA_HOST=127.0.0.1:11435 ollama serve CMD two: ollama run mistral

jacoblee93 commented 8 months ago

Thank you @elecraft2002! Would you be up for a quick PR to add it to the README?

windowshopr commented 8 months ago

image

image

Should I not be seeing a frontend gui like in the main documentation, or is this correct? I see the "Send a message" in the second CMD prompt window, but I feel like I'm still missing something here?