Write the logic for a key press buzzer implementation in an embedded system.
Implement key_press_buzzer(events, debounce_ms, beep_ms). Events are chronological dictionaries with timestamp, key, and boolean pressed fields. Return [start, end, key] intervals for every accepted press. A press is accepted when the key is currently released. A release is accepted only when the key has remained pressed for at least debounce_ms; shorter releases are treated as bounce. Duplicate events do not produce additional buzzer intervals.
Input: events is a list of dictionaries, and debounce_ms and beep_ms are non-negative integers. Output: a list of intervals in accepted event order.
def key_press_buzzer(events, debounce_ms, beep_ms):