SystemIQ is an interactive, explainable expert system for diagnosing PC hardware and boot issues using a knowledge base of facts, rules, and confidence factors. The system uses intelligent question adaptation to minimize unnecessary questions and provide accurate diagnostics efficiently.
SystemIQ features two diagnostic modes:
-
Smart Mode (Default): Intelligently skips irrelevant questions based on previous answers
- If power LED is off, skips questions about BIOS, OS, and other components
- If BIOS is inaccessible, skips questions about BIOS-visible hardware status
- If no display output, skips questions about visual artifacts
- If OS doesn't load, skips runtime-specific questions
- And more conditional logic to streamline diagnostics
-
All Mode: Asks all questions for comprehensive data collection
- Useful for thorough documentation or edge cases
- Provides complete dataset for knowledge base refinement
- Diagnoses are ranked by confidence factor (CF)
- Each diagnosis includes the triggering rule ID and explanation
- Multiple diagnoses may be returned when symptoms overlap
- Easily extensible without modifying Python code
- Facts define diagnostic questions and valid answers
- Rules define condition-diagnosis mappings with confidence factors
- Clean separation between logic and domain knowledge
The command-line interface uses only Python standard library:
# Clone or download the repository
cd SystemIQ
# Run directly
python systemiq_cli.pyThe web interface requires Flask:
# Clone or download the repository
cd SystemIQ
# Install dependencies
pip install -r requirements.txt
# Run the web server
python app.pyThen open your browser to http://localhost:5000
The modern web interface provides a sleek, interactive experience:
-
Start the server:
python app.py
-
Open your browser to
http://localhost:5000 -
Choose your mode:
- Smart Mode: Adaptive questions that skip irrelevant diagnostics
- Complete Mode: All questions for comprehensive analysis
-
Answer questions by clicking on the answer buttons
-
View results with confidence-ranked diagnoses and explanations
Features:
- Modern, responsive UI with dark theme and gradient effects
- Real-time progress tracking
- Confidence factor visualization
- Detailed explanations for each diagnosis
- Easy reset for multiple diagnostics
- Responsive design for mobile and desktop
Run SystemIQ in smart mode (default):
python systemiq_cli.py# Smart mode (adaptive questions)
python systemiq_cli.py smart
python systemiq_cli.py --smart
python systemiq_cli.py -s
# All mode (ask all questions)
python systemiq_cli.py all
python systemiq_cli.py --all
python systemiq_cli.py -a
# Help
python systemiq_cli.py --help
python systemiq_cli.py -h$ python systemiq_cli.py
Welcome to SystemIQ — Intelligent PC Hardware Troubleshooter!
Running in SMART mode: Questions adapt based on your answers.
Answer the questions to receive ranked diagnoses with explanations.
Can you enter BIOS/UEFI setup? (yes/no): no
Is the power LED on? (yes/no): yes
Do you hear BIOS beep codes? (none/short/long/repeated): short
Are system fans spinning? (normal/slow/stopped): normal
Does the PC overheat or shut down under load? (yes/no): yes
Do you see visual artifacts/flickering on display? (yes/no): yes
Are fan noises unusually loud at idle? (yes/no): yes
Evaluating knowledge base...
Diagnosis ranking:
- gpu_overheating_or_vram_fault: CF=0.89 (via R10)
- motherboard_failure: CF=0.85 (via R4)
- dust_buildup_or_bearing_wear: CF=0.72 (via R18)
Explanations:
- R10: Visual artifacts combined with heat often indicate GPU thermal or VRAM issues.
- R4: Short POST beeps with no BIOS access suggest motherboard fault.
- R18: Normal RPM but loud fan noise usually indicates dust buildup or worn bearings.
Notice how in the example above, smart mode automatically skipped questions about:
- BIOS-visible hardware status (RAM, HDD detection) since BIOS is inaccessible
- OS loading and network connectivity (since we can't even reach BIOS)
- Boot device detection (requires BIOS access)
$ python systemiq_cli.py all
Welcome to SystemIQ — Intelligent PC Hardware Troubleshooter!
Running in ALL mode: All questions will be asked for comprehensive analysis.
Answer the questions to receive ranked diagnoses with explanations.
[All diagnostic questions will be asked regardless of previous answers]
The knowledge base is located at knowledge/knowledge_base.json and consists of two main sections:
Defines diagnostic facts (questions) and their valid answers:
{
"facts": {
"power_led": {
"question": "Is the power LED on? (yes/no): ",
"answers": ["yes", "no"]
},
"bios_access": {
"question": "Can you enter BIOS/UEFI setup? (yes/no): ",
"answers": ["yes", "no"]
}
...
}
}Defines diagnostic rules with conditions, diagnosis labels, confidence factors, and explanations:
{
"rules": [
{
"id": "R1",
"conditions": {"power_led": "no"},
"diagnosis": "power_supply_failure",
"cf": 0.96,
"explanation": "No power LED strongly indicates PSU failure or no PSU output."
}
...
]
}The smart mode implements conditional question dependencies to avoid asking illogical questions:
| Previous Answer | Questions Skipped | Reason |
|---|---|---|
power_led: no |
Most hardware questions | PC has no power - most diagnostics irrelevant |
bios_access: no |
ram_status, hdd_status |
Cannot view hardware in BIOS |
display_output: no |
artifacts |
Cannot see visual artifacts without display |
os_loads: no |
blue_screen (runtime) |
OS never starts, so no runtime crashes |
fan_speed: stopped |
high_noise |
Fans not spinning, so no noise |
os_loads: no |
network_link |
Network requires OS to be running |
bios_access: no |
usb_devices_fail (if OS also fails) |
Cannot test USB without BIOS or OS |
This logic can reduce question count by 30-50% while maintaining diagnostic accuracy.
- Open
knowledge/knowledge_base.json - Add a new fact definition in the
factssection:
"new_fact_name": {
"question": "Your diagnostic question? (answer1/answer2): ",
"answers": ["answer1", "answer2", "answer3"]
}Add a new rule in the rules section:
{
"id": "R21",
"conditions": {
"fact1": "value1",
"fact2": "value2"
},
"diagnosis": "diagnosis_label",
"cf": 0.85,
"explanation": "Why these conditions suggest this diagnosis."
}Tips for effective rules:
- Use confidence factors (cf) between 0.0 and 1.0
- Higher CF = stronger certainty of diagnosis
- Combine multiple symptoms for more specific diagnoses
- Write clear, actionable explanations
To modify question dependencies, edit the should_ask_question() function in systemiq_cli.py:
def should_ask_question(facts: dict[str, str | None], fact: str, smart_mode: bool) -> bool:
"""Determine if a question should be asked based on previous answers."""
if not smart_mode:
return True
# Add your conditional logic here
if facts.get("some_fact") == "some_value":
if fact in ["skip_this", "and_this"]:
return False
return True- Forward chaining inference: Questions are selected based on which facts could still satisfy unmatched rules
- Prioritized question selection: Facts that appear in more potential rules are asked first
- Dynamic question filtering: Smart mode skips questions that are logically impossible or irrelevant
- Each rule has a CF between 0.0 and 1.0 indicating diagnostic certainty
- Multiple rules can fire for the same diagnosis
- Results are ranked by confidence for clear prioritization
- Facts: Observable symptoms and hardware states
- Rules: IF-THEN mappings from symptom combinations to diagnoses
- Explanations: Human-readable justifications for each diagnosis
SystemIQ can diagnose issues across multiple hardware categories:
- Power System: PSU failures, power delivery issues
- Cooling: Fan failures, dust buildup, thermal issues
- Memory: RAM failures, seating issues, POST errors
- Storage: Drive failures, connection issues, bootloader problems
- Display: GPU failures, VRAM issues, display path problems
- Motherboard: Chipset issues, POST failures, USB controller problems
- Operating System: Boot failures, driver conflicts, corruption
- Network: Adapter failures, driver issues, connectivity problems
- Structured diagnostic workflow
- Documentation of troubleshooting steps
- Training tool for new technicians
- Consistent diagnostic approach
- Self-diagnosis before seeking professional help
- Understanding potential hardware issues
- Prioritizing repair actions by confidence
- Knowledge base for hardware failure patterns
- Testing ground for expert system techniques
- Dataset for diagnostic AI training
To improve SystemIQ:
- Test diagnostics against real hardware issues
- Refine confidence factors based on real-world accuracy
- Add new rules for additional failure modes
- Enhance conditional logic for smarter question flow
- Expand explanations for better user understanding
- Document edge cases where the system needs improvement
- Does not diagnose software-specific issues beyond boot failures
- Cannot detect intermittent hardware failures
- Requires user to accurately assess hardware symptoms
- Limited to common PC hardware configurations
- May produce multiple diagnoses with similar confidence
- Web-based interface for remote diagnostics
- Diagnostic history and session logging
- Machine learning to refine confidence factors
- Integration with hardware monitoring tools
- Multi-language support
- Cloud-based knowledge base sharing
This project is open source and available for educational and diagnostic purposes.
Built using expert system principles and forward-chaining inference techniques. Knowledge base compiled from common PC hardware troubleshooting scenarios.
SystemIQ - Making PC diagnostics smarter, one question at a time.