automateyournetwork / packet_buddy

pcap analysis provided by chatGPT4 Turbo
GNU General Public License v3.0
79 stars 15 forks source link

readme update notes #7

Open ibenrodriguez opened 2 months ago

ibenrodriguez commented 2 months ago

I can update the readme with results of my testing. Taking notes here so we can plan that once done.

  1. On windows machine with Docker Desktop installed - if you get a message like this it might mean docker isn't running - start docker and try again. "open //./pipe/dockerDesktopLinuxEngine: The system cannot find the file specified."
  2. ! packet_buddy Warning pull access denied for johncapobianco/packet_buddy, repository does not exist or may require 'docker login': denied: requested access to the resource is denied
ibenrodriguez commented 2 months ago

http://localhost:8505/#packet-buddy-chat-with-packet-captures

using llama3.1 https://ollama.com/library/llama3.1

Captures RuntimeError: CUDA error: out of memory CUDA kernel errors might be asynchronously reported at some other API call, so the stacktrace below might be incorrect. For debugging consider passing CUDA_LAUNCH_BLOCKING=1 Compile with TORCH_USE_CUDA_DSA to enable device-side assertions. Traceback:

File "/usr/local/lib/python3.12/dist-packages/streamlit/runtime/scriptrunner/exec_code.py", line 88, in exec_func_with_error_handling result = func() ^^^^^^ File "/usr/local/lib/python3.12/dist-packages/streamlit/runtime/scriptrunner/script_runner.py", line 590, in code_to_exec exec(code, module.dict) File "/packet_buddy/packet_buddy.py", line 191, in chat_interface() File "/packet_buddy/packet_buddy.py", line 167, in chat_interface st.session_state['chat_instance'] = ChatWithPCAP(json_path=json_path) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/packet_buddy/packet_buddy.py", line 70, in init self.store_in_chroma() File "/packet_buddy/packet_buddy.py", line 91, in store_in_chroma self.vectordb = Chroma.from_documents(self.docs, self.embedding_model) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/dist-packages/langchain_community/vectorstores/chroma.py", line 878, in from_documents return cls.from_texts( ^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/dist-packages/langchain_community/vectorstores/chroma.py", line 842, in from_texts chroma_collection.add_texts(texts=texts, metadatas=metadatas, ids=ids) File "/usr/local/lib/python3.12/dist-packages/langchain_community/vectorstores/chroma.py", line 277, in add_texts embeddings = self._embedding_function.embed_documents(texts) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/dist-packages/langchain_community/embeddings/huggingface.py", line 222, in embed_documents embeddings = self.client.encode( ^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/dist-packages/InstructorEmbedding/instructor.py", line 539, in encode out_features = self.forward(features) ^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/dist-packages/torch/nn/modules/container.py", line 219, in forward input = module(input) ^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/dist-packages/torch/nn/modules/module.py", line 1553, in _wrapped_call_impl return self._call_impl(*args, *kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/dist-packages/torch/nn/modules/module.py", line 1562, in _call_impl return forward_call(args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/dist-packages/InstructorEmbedding/instructor.py", line 278, in forward assert torch.sum(attention_mask[local_idx]).item() >= context_masks[local_idx].item(),\ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

ibenrodriguez commented 1 week ago

Still same issue - using Geforce GTX 1650 image

http://localhost:8505/

Packet Buddy - Chat with Packet Captures RuntimeError: CUDA error: out of memory CUDA kernel errors might be asynchronously reported at some other API call, so the stacktrace below might be incorrect. For debugging consider passing CUDA_LAUNCH_BLOCKING=1 Compile with TORCH_USE_CUDA_DSA to enable device-side assertions. Traceback: File "/usr/local/lib/python3.12/dist-packages/streamlit/runtime/scriptrunner/exec_code.py", line 88, in exec_func_with_error_handling result = func() ^^^^^^ File "/usr/local/lib/python3.12/dist-packages/streamlit/runtime/scriptrunner/script_runner.py", line 590, in code_to_exec exec(code, module.dict) File "/packet_buddy/packet_buddy.py", line 191, in chat_interface() File "/packet_buddy/packet_buddy.py", line 167, in chat_interface st.session_state['chat_instance'] = ChatWithPCAP(json_path=json_path) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/packet_buddy/packet_buddy.py", line 70, in init self.store_in_chroma() File "/packet_buddy/packet_buddy.py", line 91, in store_in_chroma self.vectordb = Chroma.from_documents(self.docs, self.embedding_model) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/dist-packages/langchain_community/vectorstores/chroma.py", line 878, in from_documents return cls.from_texts( ^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/dist-packages/langchain_community/vectorstores/chroma.py", line 842, in from_texts chroma_collection.add_texts(texts=texts, metadatas=metadatas, ids=ids) File "/usr/local/lib/python3.12/dist-packages/langchain_community/vectorstores/chroma.py", line 277, in add_texts embeddings = self._embedding_function.embed_documents(texts) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/dist-packages/langchain_community/embeddings/huggingface.py", line 222, in embed_documents embeddings = self.client.encode( ^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/dist-packages/InstructorEmbedding/instructor.py", line 539, in encode out_features = self.forward(features) ^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/dist-packages/torch/nn/modules/container.py", line 219, in forward input = module(input) ^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/dist-packages/torch/nn/modules/module.py", line 1553, in _wrapped_call_impl return self._call_impl(*args, *kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/dist-packages/torch/nn/modules/module.py", line 1562, in _call_impl return forward_call(args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/dist-packages/InstructorEmbedding/instructor.py", line 278, in forward assert torch.sum(attention_mask[local_idx]).item() >= context_masks[local_idx].item(),\ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^