From e89df617ef8474fe80ef2c2d2e1ae2979863b123 Mon Sep 17 00:00:00 2001 From: Chandrapal Badshah Date: Thu, 17 Jul 2025 19:55:32 +0530 Subject: [PATCH] chore(lighthouse): Rename to Lighthouse AI (#8262) Co-authored-by: Chandrapal Badshah <12944530+Chan9390@users.noreply.github.com> Co-authored-by: alejandrobailo --- docs/developer-guide/lighthouse.md | 14 +++---- docs/tutorials/prowler-app-lighthouse.md | 40 +++++++++--------- ui/app/(prowler)/lighthouse/config/page.tsx | 2 +- ui/app/(prowler)/lighthouse/page.tsx | 3 +- ui/components/icons/Icons.tsx | 46 +++++++++++++++++++++ ui/components/lighthouse/chat.tsx | 4 +- ui/components/lighthouse/chatbot-config.tsx | 4 +- ui/lib/menu-list.ts | 33 +++++++-------- 8 files changed, 96 insertions(+), 50 deletions(-) diff --git a/docs/developer-guide/lighthouse.md b/docs/developer-guide/lighthouse.md index e0a8d939dc..e01067844f 100644 --- a/docs/developer-guide/lighthouse.md +++ b/docs/developer-guide/lighthouse.md @@ -1,6 +1,6 @@ -# Extending Prowler Lighthouse +# Extending Prowler Lighthouse AI -This guide helps developers customize and extend Prowler Lighthouse by adding or modifying AI agents. +This guide helps developers customize and extend Prowler Lighthouse AI by adding or modifying AI agents. ## Understanding AI Agents @@ -13,7 +13,7 @@ AI agents fall into two main categories: - **Autonomous Agents**: Freely chooses from available tools to complete tasks, adapting their approach based on context. They decide which tools to use and when. - **Workflow Agents**: Follows structured paths with predefined logic. They execute specific tool sequences and can include conditional logic. -Prowler Lighthouse is an autonomous agent - selecting the right tool(s) based on the users query. +Prowler Lighthouse AI is an autonomous agent - selecting the right tool(s) based on the users query. ???+ note To learn more about AI agents, read [Anthropic's blog post on building effective agents](https://www.anthropic.com/engineering/building-effective-agents). @@ -24,15 +24,15 @@ The autonomous nature of agents depends on the underlying LLM. Autonomous agents After evaluating multiple LLM providers (OpenAI, Gemini, Claude, LLama) based on tool calling features and response accuracy, we recommend using the `gpt-4o` model. -## Prowler Lighthouse Architecture +## Prowler Lighthouse AI Architecture -Prowler Lighthouse uses a multi-agent architecture orchestrated by the [Langgraph-Supervisor](https://www.npmjs.com/package/@langchain/langgraph-supervisor) library. +Prowler Lighthouse AI uses a multi-agent architecture orchestrated by the [Langgraph-Supervisor](https://www.npmjs.com/package/@langchain/langgraph-supervisor) library. ### Architecture Components Prowler Lighthouse architecture -Prowler Lighthouse integrates with the NextJS application: +Prowler Lighthouse AI integrates with the NextJS application: - The [Langgraph-Supervisor](https://www.npmjs.com/package/@langchain/langgraph-supervisor) library integrates directly with NextJS - The system uses the authenticated user session to interact with the Prowler API server @@ -74,7 +74,7 @@ Modifying the supervisor prompt allows you to: The supervisor agent and all specialized agents are defined in the `route.ts` file. The supervisor agent uses [langgraph-supervisor](https://www.npmjs.com/package/@langchain/langgraph-supervisor), while other agents use the prebuilt [create-react-agent](https://langchain-ai.github.io/langgraphjs/how-tos/create-react-agent/). -To add new capabilities or all Lighthouse to interact with other APIs, create additional specialized agents: +To add new capabilities or all Lighthouse AI to interact with other APIs, create additional specialized agents: 1. First determine what the new agent would do. Create a detailed prompt defining the agent's purpose and capabilities. You can see an example from [here](https://github.com/prowler-cloud/prowler/blob/master/ui/lib/lighthouse/prompts.ts#L359-L385). ???+ note diff --git a/docs/tutorials/prowler-app-lighthouse.md b/docs/tutorials/prowler-app-lighthouse.md index 52e94cfe9d..2524818c32 100644 --- a/docs/tutorials/prowler-app-lighthouse.md +++ b/docs/tutorials/prowler-app-lighthouse.md @@ -1,12 +1,12 @@ -# Prowler Lighthouse +# Prowler Lighthouse AI -Prowler Lighthouse is an AI Cloud Security Analyst chatbot that helps you understand, prioritize, and remediate security findings in your cloud environments. It's designed to provide security expertise for teams without dedicated resources, acting as your 24/7 virtual cloud security analyst. +Prowler Lighthouse AI is a Cloud Security Analyst chatbot that helps you understand, prioritize, and remediate security findings in your cloud environments. It's designed to provide security expertise for teams without dedicated resources, acting as your 24/7 virtual cloud security analyst. Prowler Lighthouse ## How It Works -Prowler Lighthouse uses OpenAI's language models and integrates with your Prowler security findings data. +Prowler Lighthouse AI uses OpenAI's language models and integrates with your Prowler security findings data. Here's what's happening behind the scenes: @@ -14,28 +14,28 @@ Here's what's happening behind the scenes: - It uses a ["supervisor" architecture](https://langchain-ai.lang.chat/langgraphjs/tutorials/multi_agent/agent_supervisor/) that interacts with different agents for specialized tasks. For example, `findings_agent` can analyze detected security findings, while `overview_agent` provides a summary of connected cloud accounts. - The system connects to OpenAI models to understand, fetch the right data, and respond to the user's query. ???+ note - Lighthouse is tested against `gpt-4o` and `gpt-4o-mini` OpenAI models. + Lighthouse AI is tested against `gpt-4o` and `gpt-4o-mini` OpenAI models. - The supervisor agent is the main contact point. It is what users interact with directly from the chat interface. It coordinates with other agents to answer users' questions comprehensively. -Lighthouse Architecture +Lighthouse AI Architecture ???+ note All agents can only read relevant security data. They cannot modify your data or access sensitive information like configured secrets or tenant details. ## Set up -Getting started with Prowler Lighthouse is easy: +Getting started with Prowler Lighthouse AI is easy: 1. Go to the configuration page in your Prowler dashboard. 2. Enter your OpenAI API key. 3. Select your preferred model. The recommended one for best results is `gpt-4o`. 4. (Optional) Add business context to improve response quality and prioritization. -Lighthouse Configuration +Lighthouse AI Configuration ### Adding Business Context -The optional business context field lets you provide additional information to help Lighthouse understand your environment and priorities, including: +The optional business context field lets you provide additional information to help Lighthouse AI understand your environment and priorities, including: - Your organization's cloud security goals - Information about account owners or responsible teams @@ -46,7 +46,7 @@ Better context leads to more relevant responses and prioritization that aligns w ## Capabilities -Prowler Lighthouse is designed to be your AI security team member, with capabilities including: +Prowler Lighthouse AI is designed to be your AI security team member, with capabilities including: ### Natural Language Querying @@ -70,7 +70,7 @@ Get tailored step-by-step instructions for fixing security issues: ### Enhanced Context and Analysis -Lighthouse can provide additional context to help you understand the findings: +Lighthouse AI can provide additional context to help you understand the findings: - Explain security concepts related to findings in simple terms - Provide risk assessments based on your environment and context @@ -82,20 +82,20 @@ Lighthouse can provide additional context to help you understand the findings: ## Important Notes -Prowler Lighthouse is powerful, but there are limitations: +Prowler Lighthouse AI is powerful, but there are limitations: - **Continuous improvement**: Please report any issues, as the feature may make mistakes or encounter errors, despite extensive testing. -- **Access limitations**: Lighthouse can only access data the logged-in user can view. If you can't see certain information, Lighthouse can't see it either. -- **NextJS session dependence**: If your Prowler application session expires or logs out, Lighthouse will error out. Refresh and log back in to continue. +- **Access limitations**: Lighthouse AI can only access data the logged-in user can view. If you can't see certain information, Lighthouse AI can't see it either. +- **NextJS session dependence**: If your Prowler application session expires or logs out, Lighthouse AI will error out. Refresh and log back in to continue. - **Response quality**: The response quality depends on the selected OpenAI model. For best results, use gpt-4o. ### Getting Help -If you encounter issues with Prowler Lighthouse or have suggestions for improvements, please [reach out through our Slack channel](https://goto.prowler.com/slack). +If you encounter issues with Prowler Lighthouse AI or have suggestions for improvements, please [reach out through our Slack channel](https://goto.prowler.com/slack). ### What Data Is Shared to OpenAI? -The following API endpoints are accessible to Prowler Lighthouse. Data from the following API endpoints could be shared with OpenAI depending on the scope of user's query: +The following API endpoints are accessible to Prowler Lighthouse AI. Data from the following API endpoints could be shared with OpenAI depending on the scope of user's query: #### Accessible API Endpoints @@ -139,7 +139,7 @@ The following API endpoints are accessible to Prowler Lighthouse. Data from the #### Excluded API Endpoints -Not all Prowler API endpoints are integrated with Lighthouse. They are intentionally excluded for the following reasons: +Not all Prowler API endpoints are integrated with Lighthouse AI. They are intentionally excluded for the following reasons: - OpenAI/other LLM providers shouldn't have access to sensitive data (like fetching provider secrets and other sensitive config) - Users queries don't need responses from those API endpoints (ex: tasks, tenant details, downloading zip file, etc.) @@ -173,7 +173,7 @@ Not all Prowler API endpoints are integrated with Lighthouse. They are intention - List all tasks - `/api/v1/tasks` - Retrieve data from a specific task - `/api/v1/tasks/{id}` -**Lighthouse Configuration:** +**Lighthouse AI Configuration:** - List OpenAI configuration - `/api/v1/lighthouse-config` - Retrieve OpenAI key and configuration - `/api/v1/lighthouse-config/{id}` @@ -187,7 +187,7 @@ Not all Prowler API endpoints are integrated with Lighthouse. They are intention During feature development, we evaluated other LLM models. -- **Claude AI** - Claude models have [tier-based ratelimits](https://docs.anthropic.com/en/api/rate-limits#requirements-to-advance-tier). For Lighthouse to answer slightly complex questions, there are a handful of API calls to the LLM provider within few seconds. With Claude's tiering system, users must purchase $400 credits or convert their subscription to monthly invoicing after talking to their sales team. This pricing may not suit all Prowler users. +- **Claude AI** - Claude models have [tier-based ratelimits](https://docs.anthropic.com/en/api/rate-limits#requirements-to-advance-tier). For Lighthouse AI to answer slightly complex questions, there are a handful of API calls to the LLM provider within few seconds. With Claude's tiering system, users must purchase $400 credits or convert their subscription to monthly invoicing after talking to their sales team. This pricing may not suit all Prowler users. - **Gemini Models** - Gemini lacks a solid tool calling feature like OpenAI. It calls functions recursively until exceeding limits. Gemini-2.5-Pro-Experimental is better than previous models regarding tool calling and responding, but it's still experimental. - **Deepseek V3** - Doesn't support system prompt messages. @@ -197,8 +197,8 @@ Context windows are limited. While demo data fits inside the context window, que **3. Is my security data shared with OpenAI?** -Minimal data is shared to generate useful responses. Agents can access security findings and remediation details when needed. Provider secrets are protected by design and cannot be read. The Lighthouse key is only accessible to our NextJS server and is never sent to LLMs. Resource metadata (names, tags, account/project IDs, etc) may be shared with OpenAI based on your query requirements. +Minimal data is shared to generate useful responses. Agents can access security findings and remediation details when needed. Provider secrets are protected by design and cannot be read. The OpenAI key configured with Lighthouse AI is only accessible to our NextJS server and is never sent to LLMs. Resource metadata (names, tags, account/project IDs, etc) may be shared with OpenAI based on your query requirements. -**4. Can the Lighthouse change my cloud environment?** +**4. Can the Lighthouse AI change my cloud environment?** No. The agent doesn't have the tools to make the changes, even if the configured cloud provider API keys contain permissions to modify resources. diff --git a/ui/app/(prowler)/lighthouse/config/page.tsx b/ui/app/(prowler)/lighthouse/config/page.tsx index ce7b2017e7..e8e223783a 100644 --- a/ui/app/(prowler)/lighthouse/config/page.tsx +++ b/ui/app/(prowler)/lighthouse/config/page.tsx @@ -21,7 +21,7 @@ export default async function ChatbotConfigPage() { const configExists = !!response; return ( - + + }> ); diff --git a/ui/components/icons/Icons.tsx b/ui/components/icons/Icons.tsx index f2cfc22c6e..86ed943b65 100644 --- a/ui/components/icons/Icons.tsx +++ b/ui/components/icons/Icons.tsx @@ -1117,3 +1117,49 @@ export const KubernetesIcon: React.FC = ({ ); }; + +export const LighthouseIcon: React.FC = ({ + size = 24, + width, + height, + ...props +}) => { + return ( + + {/* Square container with rounded corners, broken top-right edge */} + + + {/* Slightly smaller center star */} + + + {/* Small star in top-right corner */} + + + ); +}; diff --git a/ui/components/lighthouse/chat.tsx b/ui/components/lighthouse/chat.tsx index cfc350f4da..c31c6a08b9 100644 --- a/ui/components/lighthouse/chat.tsx +++ b/ui/components/lighthouse/chat.tsx @@ -135,8 +135,8 @@ export const Chat = ({ hasConfig, isActive }: ChatProps) => {

{!hasConfig - ? "Please configure your OpenAI API key to use Lighthouse." - : "OpenAI API key is invalid. Please update your key to use Lighthouse."} + ? "Please configure your OpenAI API key to use Lighthouse AI." + : "OpenAI API key is invalid. Please update your key to use Lighthouse AI."}

{ }, ], }, - { - groupLabel: "Issues", + groupLabel: "", + menus: [ + { + href: "/lighthouse", + label: "Lighthouse AI", + icon: LighthouseIcon, + }, + ], + }, + { + groupLabel: "", menus: [ { href: "", - label: "Top failed issues", + label: "Top failed findings", icon: Bookmark, submenus: [ { @@ -143,7 +152,7 @@ export const getMenuList = (pathname: string): GroupProps[] => { ], }, { - groupLabel: "Settings", + groupLabel: "", menus: [ { href: "", @@ -154,14 +163,14 @@ export const getMenuList = (pathname: string): GroupProps[] => { { href: "/manage-groups", label: "Provider Groups", icon: Group }, { href: "/scans", label: "Scan Jobs", icon: Timer }, { href: "/roles", label: "Roles", icon: UserCog }, - { href: "/lighthouse/config", label: "Lighthouse", icon: Cog }, + { href: "/lighthouse/config", label: "Lighthouse AI", icon: Cog }, ], defaultOpen: true, }, ], }, { - groupLabel: "Workspace", + groupLabel: "", menus: [ { href: "", @@ -175,16 +184,6 @@ export const getMenuList = (pathname: string): GroupProps[] => { }, ], }, - { - groupLabel: "Prowler Lighthouse", - menus: [ - { - href: "/lighthouse", - label: "Lighthouse", - icon: Bot, - }, - ], - }, { groupLabel: "", menus: [