tessl install tessl/pypi-titlecase@2.4.0Python port of John Gruber's titlecase.pl for intelligent title case conversion with style guide compliance
Agent Success
Agent success rate when using this tile
79%
Improvement
Agent success rate improvement when using this tile compared to baseline
0.92x
Baseline
Agent success rate without this tile
86%
Build a text formatting tool that processes multi-part titles containing various types of dash delimiters. The tool should properly capitalize text segments separated by different dash characters commonly used in typography.
Your implementation should:
- (U+002D)– (U+2013)‒ (U+2012)— (U+2014)― (U+2015)@test Input: "episode 7 — the force awakens"
Expected output: Properly capitalize "the" after the em dash
@test Input: "new york – london flight"
Expected output: Properly capitalize "london" after the en dash
@test Input: "part one — introduction: part two – the story begins"
Expected output: Handle both em dash and en dash correctly, capitalizing words after each
formatter.py - Main implementation file containing the text formatting logictests.py - Test file with test cases demonstrating correct dash handlingProvides intelligent title case conversion with support for various punctuation marks and delimiters.