agentsclimarketplace

Schedule constraint parsing

Skill cxcscmu/SkillLearnBench/skills/b1-one-shot-gemini-3.1-pro-preview/schedule-planning/schedule-constraint-parsing

Uses regular expressions to parse dates, time ranges, and durations from natural language text like meeting requests.From its SKILL.md

Install
npx -y skills add cxcscmu/SkillLearnBench --skill schedule-constraint-parsing

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

SKILL.md

1.8 KB, 469 tokens by cl100k_base, as published. Nobody here has run it

Schedule Constraint Parsing

This skill outlines how to use standard Python re and datetime libraries to extract specific meeting requirements (duration, dates, start/end time windows) from email bodies.

Common Regex Patterns

1. Extracting Duration

People describe duration in hours or minutes (e.g., "1.5 hour", "one-hour", "45-minute").

import re

def parse_duration(text):
    duration_min = None
    
    # Hour pattern
    hr_match = re.search(r'([\d\.]+|(?:one|two|three|half))\s*(?:hour|hr)', text, re.IGNORECASE)
    if hr_match:
        val = hr_match.group(1).lower()
        if val == 'one': hours = 1.0
        elif val == 'two': hours = 2.0
        elif val == 'half': hours = 0.5
        else: hours = float(val)
        duration_min = int(hours * 60)
        
    # Minute pattern
    min_match = re.search(r'(\d+)\s*(?:minute|min)', text, re.IGNORECASE)
    if min_match:
        duration_min = int(min_match.group(1))
        
    return duration_min

2. Extracting Time Range

Extracting available start and end boundaries (e.g., "between 10:00am to 2:00pm", "between 1:00 PM and 5:00 PM PST").

def parse_time_window(text):
    # Extracts HH:MM AM/PM pairs
    pattern = r'(\d{1,2}(?::\d{2})?\s*(?:am|pm|AM|PM)).*?(?:to|and|-)\s*(\d{1,2}(?::\d{2})?\s*(?:am|pm|AM|PM))'
    match = re.search(pattern, text)
    if match:
        start_time_str = match.group(1)
        end_time_str = match.group(2)
        return start_time_str, end_time_str
    return None, None

These simple extraction functions are excellent bases for parsing natural language scheduling intents.

What ships with it

Read from the repository

Just SKILL.md. No reference files, no scripts.

Keep looking

Skills are one crate of 325,949. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.