11# 🔍 Lightman AI
22
3- > ** AI -Powered Cybersecurity News Intelligence Platform*
3+ > LLM -Powered Cybersecurity News Intelligence Platform
44
55---
66
@@ -31,7 +31,9 @@ Lightman AI is an intelligent cybersecurity news aggregation and risk assessment
3131
3232## 🚀 Quick Start
3333
34- ### pip
34+ ### Installation
35+
36+ #### pip
3537
36381 . ** Install Lightman AI** :
3739 ``` bash
@@ -60,10 +62,13 @@ Lightman AI is an intelligent cybersecurity news aggregation and risk assessment
6062 ``` bash
6163 lightman run
6264 ```
65+ #### Docker
66+ 1 . ** Pull the image**
67+ ``` bash
68+ docker pull elementsinteractive/lightman-ai:latest
69+ ```
6370
64- ### Docker
65-
66- 1 . ** Create configuration file** :
71+ 2 . ** Create configuration file** :
6772 ``` bash
6873 echo ' [default]
6974 agent = "openai"
@@ -74,7 +79,7 @@ Lightman AI is an intelligent cybersecurity news aggregation and risk assessment
7479 development = "Analyze cybersecurity news for relevance to our organization."' > lightman.toml
7580 ```
7681
77- 2 . ** Run with Docker** :
82+ 3 . ** Run with Docker** :
7883 ``` bash
7984 docker run --rm \
8085 -v $( pwd) /lightman.toml:/app/lightman.toml \
@@ -83,55 +88,37 @@ Lightman AI is an intelligent cybersecurity news aggregation and risk assessment
8388 lightman run --config-file /app/lightman.toml --score 7
8489 ```
8590
86- 4 . ** View results** : Lightman will analyze cybersecurity news and output relevant articles that meet your score threshold.
87-
88- ## 📥 Installation
89-
90- ### Docker
91- Lightman AI has an available Docker image on Docker Hub:
92-
93- ``` bash
94- # Pull the latest image
95- docker pull elementsinteractive/lightman-ai:latest
91+ ## 🔧 Usage
9692
97- # Create your configuration file
98-
99- echo ' [default]
100- agent = "openai"
101- score_threshold = 8
102- prompt = "development"
103-
104- [prompts]
105- development = "Analyze cybersecurity news for relevance to our organization."' > lightman.toml
106- ```
93+ ### CLI Options
10794
95+ | Option | Description | Default |
96+ | --------| -------------| ---------|
97+ | ` --agent ` | AI agent to use (` openai ` , ` gemini ` ) | From config file |
98+ | ` --score ` | Minimum relevance score (1-10) | From config file |
99+ | ` --prompt ` | Prompt template name | From config file |
100+ | ` --config-file ` | Path to configuration file | ` lightman.toml ` |
101+ | ` --config ` | Configuration section to use | ` default ` |
102+ | ` --env-file ` | Path to environment variables file | ` .env ` |
103+ | ` --dry-run ` | Preview results without taking action | ` false ` |
104+ | ` --prompt-file ` | File containing prompt templates | ` lightman.toml ` |
105+ | ` --start-date ` | Start date to retrieve articles | False |
106+ | ` --today ` | Retrieve articles from today | False |
107+ | ` --yesterday ` | Retrieve articles from yesterday | False |
108108
109- # Run with mounted configuration
110- ``` bash
111- docker run -d \
112- --name lightman-ai \
113- -v $( pwd) /lightman.toml:/app/lightman.toml \
114- -e OPENAI_API_KEY=" your-api-key" \
115- elementsinteractive/lightman-ai:latest \
116- lightman run --config-file /app/lightman.toml
117- ```
109+ ### Environment Variables:
110+ lightman-ai uses the following environment variables:
118111
119- ** Docker Environment Variables:**
120112- ` OPENAI_API_KEY ` - Your OpenAI API key
121113- ` GOOGLE_API_KEY ` - Your Google Gemini API key
122114- ` SERVICE_DESK_URL ` - Service desk instance URL (optional)
123115- ` SERVICE_DESK_USER ` - Service desk username (optional)
124116- ` SERVICE_DESK_TOKEN ` - Service desk API token (optional)
117+ - ` TIME_ZONE ` - Your time zone (optional, defaults to UTC. i.e. "Europe/Amsterdam".)
125118
119+ By default, it will try to load a ` .env ` file. You can also specify a different path with the ` --env-file ` option.
126120
127121
128- ### Development Installation
129- ``` bash
130- git clone
[email protected] :elementsinteractive/lightman-ai.git
131- cd lightman_ai
132- just venv # Creates virtual environment and installs dependencies
133- ```
134-
135122## ⚙️ Configuration
136123
137124Lightman AI uses TOML configuration files for flexible setup. Create a ` lightman.toml ` file:
@@ -185,30 +172,8 @@ custom_prompt = """
185172Your custom analysis prompt here...
186173"""
187174```
188- ### Environment Variables
189-
190- Set up your AI provider credentials:
191-
192- ``` bash
193- # For OpenAI
194- export OPENAI_API_KEY=" your-openai-api-key"
195-
196- # For Google Gemini
197- export GOOGLE_API_KEY=" your-google-api-key"
198-
199- # Optional: Service desk integration
200- export SERVICE_DESK_URL=" https://your-company.atlassian.net"
201- export SERVICE_DESK_USER=" your-username"
202- export SERVICE_DESK_TOKEN=" your-api-token"
203-
204- ```
205- You can also specify a different path for your .env file with the ` --env-file ` option
206-
207-
208- ## 🔧 Usage
209-
210- ### Basic Usage
211175
176+ ### Examples
212177``` bash
213178# Run with default settings
214179lightman run
@@ -224,70 +189,30 @@ lightman run --env-file production.env --agent openai --score 8
224189
225190# Dry run (preview results without creating service desk tickets)
226191lightman run --dry-run --agent openai --score 9
227- ```
228192
229- ### Command Line Options
193+ # Retrieve all the news from today
194+ lightman run --agent openai --score 8 --prompt security_critical --today
230195
231- | Option | Description | Default |
232- | --------| -------------| ---------|
233- | ` --agent ` | AI agent to use (` openai ` , ` gemini ` ) | From config file |
234- | ` --score ` | Minimum relevance score (1-10) | From config file |
235- | ` --prompt ` | Prompt template name | From config file |
236- | ` --config-file ` | Path to configuration file | ` lightman.toml ` |
237- | ` --config ` | Configuration section to use | ` default ` |
238- | ` --env-file ` | Path to environment variables file | ` .env ` |
239- | ` --dry-run ` | Preview results without taking action | ` false ` |
240- | ` --prompt-file ` | File containing prompt templates | ` lightman.toml ` |
241- | ` --start-date ` | Start date to retrieve articles | None |
242- | ` --today ` | Retrieve articles from today | None |
243- | ` --yesterday ` | Retrieve articles from yesterday | None |
244-
245- ### Example Workflows
246-
247- ** Daily Security Monitoring** :
248- ``` bash
249- # Local installation
250- lightman run --agent openai --score 8 --prompt security_critical
251-
252- # With custom environment file
253- lightman run --env-file production.env --agent openai --score 8
254-
255- # Docker
256- docker run --rm \
257- -v $( pwd) /lightman.toml:/app/lightman.toml \
258- -e OPENAI_API_KEY=" $OPENAI_API_KEY " \
259- elementsinteractive/lightman-ai:latest \
260- lightman run --config-file /app/lightman.toml --score 8
196+ # Retrieve all the news from yesterday
197+ lightman run --agent openai --score 8 --prompt security_critical --yesterday
261198```
262199
263200
264- ** Weekly Risk Assessment** :
265- ``` bash
266- # Local installation
267- lightman run --agent gemini --score 6 --prompt weekly_assessment
268-
269- # With environment-specific settings
270- lightman run --env-file weekly.env --agent gemini --score 6
271-
272- # Docker
273- docker run --rm \
274- -v $( pwd) /lightman.toml:/app/lightman.toml \
275- -e GOOGLE_API_KEY=" $GOOGLE_API_KEY " \
276- elementsinteractive/lightman-ai:latest \
277- lightman run --config-file /app/lightman.toml --agent gemini --score 6
278- ```
201+ ### Development Installation
202+ In order to fully use the provided setup for local development and testing, this project requires the following dependencies:
203+ - Python 3.13
204+ - [ just] ( https://github.com/casey/just )
205+ - [ uv] ( https://docs.astral.sh/uv/getting-started/installation/ )
279206
280- ** Integration Testing ** :
207+ Then simply :
281208``` bash
282- # Test configuration without creating tickets
283- lightman run --dry-run --config testing
284-
285- # Test with staging environment
286- lightman run --env-file staging.env --dry-run --config testing
209+ git clone [email protected] :elementsinteractive/lightman-ai.git 210+ cd lightman_ai
211+ just venv # Creates virtual environment and installs dependencies
212+ just test # Runs the tests
213+ just eval # Runs the evaluation framework
287214```
288215
289-
290-
291216## 📊 Evaluation & Testing
292217
293218Lightman AI includes a comprehensive evaluation framework to test and optimize AI agent performance:
0 commit comments