cyber_query_ai.chatbot

Chatbot logic for the CyberQueryAI application.

Classes

Chatbot(model, embedding_model, ...)

Chatbot class for LLM queries with RAG support.

class cyber_query_ai.chatbot.Chatbot(model, embedding_model, tools_json_filepath)[source]

Chatbot class for LLM queries with RAG support.

__init__(model, embedding_model, tools_json_filepath)[source]

Initialize the Chatbot with necessary components.

property profile: str

Profile description and context for the cybersecurity assistant.

property pt_chat: PromptTemplate

Prompt template for conversational chat.

property pt_code_generation: PromptTemplate

Prompt template for unified code generation (commands and scripts).

property pt_code_explanation: PromptTemplate

Prompt template for unified code explanation (commands and scripts).

Prompt template for exploit search.

prompt_chat(message, history)[source]

Generate the prompt template for conversational chat.

Return type:

str

prompt_code_generation(prompt)[source]

Generate the prompt template for unified code generation.

Return type:

str

prompt_code_explanation(prompt)[source]

Generate the prompt template for unified code explanation.

Return type:

str

Generate the prompt template for exploit search.

Return type:

str