Install any skill in seconds. Free to start, no credit card required.
Get Started Free →rshankras/attributed-string
AttributedString patterns for rich text formatting, alignment, selection, and SwiftUI integration.
Passed 22 of 23 test cases with the skill, and 11 of 23 without it.
and 13 more in the full report
11 fixed11 passed either way1 still failing0 broke
Tokens, turns and time describe resource use, not a dollar price.
One of 11 test cases the skill fixed. Same model, same prompt, with and without the skill.
I want to replace a selected range of text in an AttributedString with a unstyled plain String in Swift. Which method should I call?
| Checked | Without skill | With skill |
|---|---|---|
| Uses replaceSelection(_:withCharacters:) method for plain character replacements | Missed | Passed |
The instructions your model reads when the skill loads.
Correct API shapes and patterns for Foundation's AttributedString. Covers creating styled text, applying attributes to ranges, text alignment, writing direction, line height control, text selection and editing, discontiguous substrings, and SwiftUI integration.
Use this skill when the user:
What do you need with AttributedString?
|
+-- Create or style text
| |
| +-- Simple inline attributes (font, color)
| | --> Creating and Styling section
| |
| +-- Paragraph-level formatting (alignment, line height)
| --> Text Alignment and Formatting section
|
+-- Control text layout
| |
| +-- Writing direction (LTR / RTL)
| | --> Writing Direction and Line Height section
| |
| +-- Line spacing / height
| --> Writing Direction and Line Height section
|
+-- Edit or select text programmatically
| |
test cases passed, vs 11 / 23 without
Published skills whose descriptions closely match this one, with their headline benchmark lift.
More skills from the same source and nearby in the registry, with their headline benchmark lift.