Convert an absolute path to a tilde path by replacing the user's home directory with ~
93
Evaluation — 93%
↑ 1.09xAgent success when using this tile
{
"context": "This criteria evaluates how well the engineer leverages the tildify package's precise home directory prefix matching technique to solve the path validation problem. The focus is on understanding and applying tildify's approach of using path separators to prevent false positive matches when checking if paths share a common directory prefix.",
"type": "weighted_checklist",
"checklist": [
{
"name": "Uses path separators",
"description": "Implementation appends path separators (e.g., path.sep or '/') to both the base directory and target path before comparison, following tildify's technique for precise prefix matching",
"max_score": 35
},
{
"name": "Implements startsWith check",
"description": "Uses string comparison (e.g., startsWith() or similar) to verify that the target path begins with the base directory prefix after separator normalization",
"max_score": 25
},
{
"name": "Handles exact matches",
"description": "Correctly returns true when the target path exactly equals the base directory, accounting for the separator-based comparison logic",
"max_score": 20
},
{
"name": "Prevents false positives",
"description": "Successfully prevents false matches for similar-looking paths (e.g., /home/user vs /home/username) by using the separator-appending technique",
"max_score": 20
}
]
}Install with Tessl CLI
npx tessl i tessl/npm-tildify