�
{�8i� � �� � d dl mZ d dlmZ d dlmZ d dlZ G d� de� Z G d� de� Zed e d
e de fd�� Z
ed
e fd�� Zeddee d ee de fd�� Z
eddee d ee fd�� Zy)� )�Enum)�tool)�OptionalNc �, � e Zd ZdZdZdZdZdZdZdZ dZ
y )
�Category�work�health�learning�personal�finance�social�hobby� self_careN)�__name__�
__module__�__qualname__�WORK�HEALTH�LEARNING�PERSONAL�FINANCE�SOCIAL�HOBBY� SELF_CARE� � �/C:\Users\Workspace\ProductivityTracker\tools.pyr r s* � ��D�
�F��H��H��G�
�F��E��Ir r c � � e Zd ZdZdZdZdZy)�Status�todo�blocked�started� completedN)r r r �TODO�BLOCKED�STARTED� COMPLETEDr r r r r s � ��D��G��G��Ir r � task_name�category�statusc
�t ��� t �fd�t D � � }t �fd�t D � � }t d�� d|� d�� d|� �� t j
| |j |j � d| � d|j � d|j � d �S # t $ r}d
t |� � �cY d}~S d}~ww xY w)aQ
Log a new task with its category and current status.
Use this tool when the user wants to record or track a task they're working on or planning to do.
Common phrases that should use this tool:
- "Log a task..."
- "Add a task..."
- "I'm starting/working on..."
- "Track this task..."
Args:
task_name: Name or description of the task
category: Type of task
- work: Professional tasks, meetings, projects, deadlines
- health: Exercise, medical appointments, nutrition, wellness
- learning: Study, courses, reading, skill development
- personal: Errands, household chores, organization
- finance: Budgeting, bills, expenses, financial planning
- social: Time with friends, family interactions, social events
- hobby: Creative projects, recreational activities, entertainment
- self_care: Meditation, journaling, relaxation, personal growth
status: Current state - todo (planned), started (in progress), completed (finished), blocked (waiting on something)
Returns:
Confirmation message with task details
Examples:
- Log workout task: category=health, status=completed
- Log code review: category=work, status=started
- Log bill payment: category=finance, status=todo
c 3 �^ �K � | ]$ }|j �j � k( s�!|�� �& y �w�N��value�lower)�.0�cr) s �r � <genexpr>zlog_task.<locals>.<genexpr>>