can anyone provide sample configuration files to enable searching markdown files #213
Replies: 3 comments 5 replies
-
Hey @parimalpuranik, I've just fixed these issues today and released khoj version 0.6.1 with these fixes. You should:
Let me know if that fixes the issues you mentioned? As for a sample configs, see khoj_docker.yml or khoj_sample.yml |
Beta Was this translation helpful? Give feedback.
-
I deleted the khoj.yml file and reinstalled / re-enabled the upgraded 0.6.1 plugin and restarted the khoj server. I had the auto-configure option enabled and indexed the notes and I think I have restarted the server a couple of times but I dont see a khoj.yml file in the directory you mention. PS C:\Users%USER%> C:\Users%USER%\AppData\Local\Programs\Python\Python310\Scripts\khoj.exe --no-gui When I tried to run a search I got the familiar check khoj backend is running message. |
Beta Was this translation helpful? Give feedback.
-
Thanks for your help, I have khoj working on my setup now. I will try running the chat part next. |
Beta Was this translation helpful? Give feedback.
-
I want to enable khoj to search Obsidian markdown files and I tried to configure the UI using *.md ( I didn't know better) and when I tried to run khoj from command line I ran into following error:
PS C:\Users%USER%> C:\Users%USER%\AppData\Local\Programs\Python\Python310\Scripts\khoj.exe
--- Logging error ---
Traceback (most recent call last):
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\logging_init_.py", line 1101, in emit
stream.write(msg + self.terminator)
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\encodings\cp1252.py", line 19, in encode
return codecs.charmap_encode(input,self.errors,encoding_table)[0]
UnicodeEncodeError: 'charmap' codec can't encode character '\U0001f318' in position 0: character maps to
Call stack:
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main
return run_code(code, main_globals, None,
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 86, in run_code
exec(code, run_globals)
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\Scripts\khoj.exe_main.py", line 7, in
sys.exit(run())
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\site-packages\khoj\main.py", line 64, in run
logger.info("🌘 Starting Khoj")
Message: '🌘 Starting Khoj'
Arguments: ()
[08:34:12] INFO 🌘 Starting Khoj main.py:64
--- Logging error ---
Traceback (most recent call last):
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\logging_init.py", line 1101, in emit
stream.write(msg + self.terminator)
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\encodings\cp1252.py", line 19, in encode
return codecs.charmap_encode(input,self.errors,encoding_table)[0]
UnicodeEncodeError: 'charmap' codec can't encode character '\U0001f4ac' in position 0: character maps to
Call stack:
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main
return run_code(code, main_globals, None,
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 86, in run_code
exec(code, run_globals)
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\Scripts\khoj.exe_main.py", line 7, in
sys.exit(run())
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\site-packages\khoj\main.py", line 88, in run
configure_server(args, required=False)
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\site-packages\khoj\configure.py", line 44, in configure_server
state.processor_config = configure_processor(args.config.processor)
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\site-packages\khoj\configure.py", line 169, in configure_processor
logger.info("💬 Setting up conversation processor")
Message: '💬 Setting up conversation processor'
Arguments: ()
INFO 💬 Setting up conversation processor configure.py:169
--- Logging error ---
Traceback (most recent call last):
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\logging_init.py", line 1101, in emit
stream.write(msg + self.terminator)
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\encodings\cp1252.py", line 19, in encode
return codecs.charmap_encode(input,self.errors,encoding_table)[0]
UnicodeEncodeError: 'charmap' codec can't encode character '\U0001f48e' in position 0: character maps to
Call stack:
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 86, in run_code
exec(code, run_globals)
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\Scripts\khoj.exe_main.py", line 7, in
sys.exit(run())
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\site-packages\khoj\main.py", line 88, in run
configure_server(args, required=False)
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\site-packages\khoj\configure.py", line 49, in configure_server
state.model = configure_search(state.model, state.config, args.regenerate)
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\site-packages\khoj\configure.py", line 112, in configure_search
logger.info("💎 Setting up search for markdown notes")
Message: '💎 Setting up search for markdown notes'
Arguments: ()
INFO 💎 Setting up search for markdown notes configure.py:112
Traceback (most recent call last):
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 86, in run_code
exec(code, run_globals)
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\Scripts\khoj.exe_main.py", line 7, in
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\site-packages\khoj\main.py", line 88, in run
configure_server(args, required=False)
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\site-packages\khoj\configure.py", line 49, in configure_server
state.model = configure_search(state.model, state.config, args.regenerate)
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\site-packages\khoj\configure.py", line 114, in configure_search
model.markdown_search = text_search.setup(
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\site-packages\khoj\search_type\text_search.py", line 180, in setup
entries_with_indices = text_to_jsonl(config).process(previous_entries)
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\site-packages\khoj\processor\markdown\markdown_to_jsonl.py", line 41, in process
MarkdownToJsonl.extract_markdown_entries(markdown_files)
File "C:\Users%USER%\AppData\Local\Programs\Python\Python310\lib\site-packages\khoj\processor\markdown\markdown_to_jsonl.py", line 110, in extract_markdown_entries
with open(markdown_file, "r", encoding="utf8") as f:
OSError: [Errno 22] Invalid argument: 'C:\Users\%USER%\.md'
PS C:\Users%USER%>
I even tried autoconfigure from obsidian but even that didnt work. Perhaps if I had a sample configuration file to go by I could try using that
Beta Was this translation helpful? Give feedback.
All reactions