Install any skill in seconds. Free to start, no credit card required.
Get Started Free →dpearson2699/vision-framework
Implement computer vision features including text recognition (OCR), face detection, barcode scanning, image segmentation, object tracking, and document scanning in iOS apps. Covers both the modern Swift-native Vision API (iOS 18+) and legacy VNRequest patterns, VisionKit DataScannerViewController for live camera scanning, and CoreMLRequest/VNCoreMLRequest for custom model inference.
Passed 22 of 22 test cases with the skill, and 15 of 22 without it.
and 9 more in the full report
7 fixed15 passed either way0 still failing0 broke
Tokens, turns and time describe resource use, not a dollar price.
One of 7 test cases the skill fixed. Same model, same prompt, with and without the skill.
Can you show me how to scan a CGImage for QR codes and EAN-13 barcodes in Swift for iOS 18 using Vision? Write an asynchronous function that accepts the image input and returns a list of items containing each barcode's string payload and normalized bounding rectangle.
| Checked | Without skill | With skill |
|---|---|---|
| Uses DetectBarcodesRequest rather than VNDetectBarcodesRequest. | Missed | Passed |
| Invokes perform(on:) with async/await directly on the request instance instead of using VNImageRequestHandler. | Missed | Passed |
| Configures request symbologies using BarcodeSymbology array values such as .qr and .ean13. | Passed | Passed |
The instructions your model reads when the skill loads.
Detect text, faces, barcodes, objects, and body poses in images and video using on-device computer vision. Prefer the modern iOS 18+ request APIs and load the legacy reference only when the deployment target requires it.
See references/vision-requests.md for complete code patterns and references/visionkit-scanner.md for DataScannerViewController integration.
Vision has two distinct API layers. Prefer the modern API for new code:
Swift-native request types plus try await request.perform(on:). Keep VN*,
VNImageRequestHandler, VNSequenceRequestHandler, completion handlers, and
legacy CGRect helpers inside explicit legacy fallback sections or files.
| Aspect | Modern (iOS 18+) | Legacy |
|---|---|---|
| Pattern | let result = try await request.perform(on: image) | VNImageRequestHandler + completion handler |
| Request types | Swift types — structs and classes (RecognizeTextRequest, DetectFaceRectanglesRequest) | ObjC classes (VNRecognizeTextRequest, VNDetectFaceRectanglesRequest) |
| Concurrency | Native async/await | Completion handlers or synchronous perform |
| Observations | Typed return values | Cast results from [Any] |
| Availability | iOS 18+ / macOS 15+ | iOS 11+ |
test cases passed, vs 15 / 22 without
More skills from the same source and nearby in the registry, with their headline benchmark lift.