Personal Productivity Agent
About
Personal Productivity Agent (Python) for Windows. Automates tasks, provides system info, and uses Google Gemini for intelligent Windows Event Log analysis. Supports interactive CLI and MCP server mode.
Details
- Author
- mwill20
- Downloads
- 273
- Categories
- AI, Productivity, Automation
Jump to
- Find, move, rename files and create directories (with confirmation)
- Get disk usage, memory, CPU, and network information
- Launch applications and find duplicate files
- Summarize documents (currently using a mock LLM)
- Retrieve upcoming events from .ics calendar files
- Set desktop reminders/notifications
- Analyze Windows Event Logs with Gemini LLM (suggested causes and fixes)
Ensure Python 3.x is installed, set the GEMINI_API_KEY environment variable, and install the required package (google-generativeai). Run python main_agent.py for the interactive CLI, or python main_agent.py --mcp-mode to start the MCP server that accepts JSON requests on stdin.
Personal Productivity Agent
Overview
The Personal Productivity Agent is a Python-based tool designed to assist with various tasks on a Windows system and leverage the power of Large Language Models (LLMs) for intelligent analysis. It can operate as an interactive command-line assistant or as a backend server component for integration with orchestrators.
Features
The agent currently offers the following capabilities:
Interactive File System Operations:
Find files
Move files (with confirmation)
Rename files (with confirmation)
Create directories (with confirmation)
System Information & Utilities:
Get disk usage, memory info, CPU info, network info
Launch applications
Find duplicate files
Productivity Tools:
Summarize documents (currently uses a mock LLM for this CLI feature)
Get upcoming calendar events from .ics files
Set desktop reminders/notifications
Windows Event Log Analysis (with LLM Integration):
Fetch Windows Event Logs based on specified criteria (log names, levels, time range).
Utilize Google's Gemini LLM to analyze event log entries, provide explanations, suggest potential causes, troubleshooting steps, and a safe command-line fix.
Modes of Operation
The agent can run in two distinct modes:
1. Interactive CLI Mode
How to Run: python main_agent.py
Description: In this mode, the agent presents a menu-driven interface directly in your PowerShell or command prompt. You can select various actions, and the agent will prompt you for necessary inputs and display results directly. This mode is intended for direct user interaction.
2. MCP (Multi-Capability Protocol) Server Mode
How to Run: python main_agent.py --mcp-mode
Description: When started in MCP mode, the agent runs as a background process, listening for JSON-formatted requests on its standard input (stdin) and sending JSON-formatted responses to its standard output (stdout).
Purpose: This mode is designed for programmatic integration. Other applications or orchestrators (like a TypeScript-based agent or a central automation system) can communicate with this Python agent by sending it standardized JSON messages to invoke its capabilities.
Example MCP Tool: The analyze_windows_event_logs functionality is exposed via MCP. An orchestrator can send a JSON request specifying event log parameters, and the agent will return a JSON response containing the LLM's analysis, a suggested command, and whether the command requires administrator privileges.
Benefits:
Automation: Allows other systems to use the agent's features automatically.
Modularity: Enables building specialized agents that can be orchestrated by a central controller.
Structured Data Exchange: Ensures reliable communication between software components using JSON.
Key Technologies
Python 3.x
Google Gemini LLM: Used for intelligent analysis of event logs.
Requires a GEMINI_API_KEY environment variable to be set for authentication. If not set, the agent will indicate that it's using a mock LLM for features requiring it.
MCP (Multi-Capability Protocol): A simple JSON-based protocol over stdio for inter-process communication in server mode.
Setup and Requirements
1. Python: Ensure Python 3.x is installed.
2. Dependencies: Install necessary Python packages. The primary one for LLM interaction is google-generativeai. A requirements.txt file would typically list all dependencies.
pip install google-generativeai
# Potentially other packages like 'plyer' for notifications
3. API Key: For Gemini LLM features, obtain an API key from Google AI Studio and set it as an environment variable:
In PowerShell:
$env:GEMINI_API_KEY = "YOUR_API_KEY_HERE"(Remember to replace
"YOUR_API_KEY_HERE" with your actual key. Do not commit your key to GitHub.)
How to Run
Interactive Mode:
cd path\to\PersonalProductivityAgent
# Set API Key if using LLM features
$env:GEMINI_API_KEY = "YOUR_API_KEY_HERE"
python main_agent.py
MCP Server Mode (for integration):
cd path\to\PersonalProductivityAgent
# Set API Key if using LLM features
$env:GEMINI_API_KEY = "YOUR_API_KEY_HERE"
python main_agent.py --mcp-mode
The agent will then listen for JSON requests on stdin.
Future Enhancements
Integration with a TypeScript-based orchestrator (agent.ts) to manage and utilize MCP tools.
Expansion of tools available via MCP server mode.
- Development of a more user-friendly graphical interface (Web UI or Desktop App) that leverages the agent's capabilities.
Sign in to leave a review
Use Google, GitHub, or an email account so ratings stay tied to real people.
No reviews posted yet.


