[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6HWGPT925PXYN1T0646AN67":3,"skill-same:01M6HWGPT925PXYN1T0646AN67":59},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":26,"linkOnly":27,"markdownContent":28,"markdownBody":29,"frontMatter":30,"refName":31,"commitSha":32,"skillDirectory":33,"forksCount":34,"repositoryHtmlUrl":35,"repositoryHomepageUrl":6,"ownerHtmlUrl":36,"ownerBlogUrl":37,"ownerDescription":6,"updatedAt":38,"install":39,"resources":52},"01M6HWGPT925PXYN1T0646AN67","file-locate-verify",null,"Systematic workflow to resolve FileNotFoundError by locating and verifying file paths","HKUDS\u002FAgentPilot","HKUDS","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F118165258?v=4","01M6HW8VRNZP64G0P4MVJW2KKQ","✨Data Intelligence Lab@HKU✨","01M6HW8VWZVHBRHYH3T330PFWV",8029,"MIT","https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Fbenchmarks\u002Fgdpval\u002Fskills\u002Ffile-locate-verify\u002FSKILL.md",[],[19,20,21,22,23,24,25],"file","verify","locate","file locate verify","workflow","systematic","paths","2026-11-10 10:12:30",false,"---\nname: file-locate-verify\ndescription: Systematic workflow to resolve FileNotFoundError by locating and verifying file paths\n---\n\n# File Locate and Verify Workflow\n\nWhen encountering FileNotFoundError or uncertain file paths, follow this systematic pattern to safely locate and verify files before executing operations.\n\n## When to Use\n\n- You receive a FileNotFoundError or similar path-related error\n- You need to work with files whose exact location is unknown\n- You want to verify file existence before executing operations that depend on those files\n\n## Step-by-Step Procedure\n\n### Step 1: Check Current Directory Contents\n\nFirst, use `list_dir` to inspect what files exist in your current working directory:\n\n```python\n# Use the list_dir tool to see current directory contents\nlist_dir(path=\".\")\n```\n\nThis reveals files in the immediate context and helps determine if you need to search elsewhere.\n\n### Step 2: Search for the File Using Find\n\nIf the file is not in the current directory, use the `find` command to locate it by name:\n\n```bash\n# Search for a specific file by name (case-insensitive)\nfind . -iname \"filename.pdf\" 2>\u002Fdev\u002Fnull\n\n# Or search from root for system-wide files\nfind \u002F -name \"filename.pdf\" 2>\u002Fdev\u002Fnull\n```\n\n**Tips:**\n- Use `-iname` for case-insensitive matching\n- Redirect stderr with `2>\u002Fdev\u002Fnull` to suppress permission errors\n- Narrow the search scope when possible for better performance\n\n### Step 3: Verify the Discovered Path\n\nBefore executing any operations on the discovered file, verify it exists and check its properties:\n\n```bash\n# Verify file existence and permissions at the full path\nls -la \u002Ffull\u002Fpath\u002Fto\u002Fdiscovered\u002Ffile.pdf\n```\n\nThis confirms:\n- The file actually exists at the located path\n- File permissions (can you read\u002Fwrite it?)\n- File size and modification time\n\n### Step 4: Execute Your Operation Safely\n\nOnly after verification, proceed with your intended operation:\n\n```python\n# Now safe to work with the verified path\nfile_path = \"\u002Ffull\u002Fpath\u002Fto\u002Fdiscovered\u002Ffile.pdf\"\n# ... your extraction or processing code here\n```\n\n## Complete Example\n\n```python\n# Task: Process a file that may be in an unknown location\n\n# Step 1: Check current directory\ndir_contents = list_dir(path=\".\")\nprint(f\"Current directory contains: {dir_contents}\")\n\n# Step 2: Find the file if not present\nif \"target_file.xlsx\" not in dir_contents:\n    result = run_shell(command='find . -iname \"target_file.xlsx\" 2>\u002Fdev\u002Fnull')\n    file_path = result.stdout.strip().split('\\n')[0]\n    print(f\"Found file at: {file_path}\")\n\n# Step 3: Verify before proceeding\nverification = run_shell(command=f'ls -la {file_path}')\nprint(f\"Verification: {verification.stdout}\")\n\n# Step 4: Proceed with operation\n# ... your code to process the file\n```\n\n## Common Pitfalls to Avoid\n\n1. **Skipping verification**: Never assume the path from `find` is correct without checking\n2. **Using relative paths blindly**: Always convert to absolute paths when possible\n3. **Ignoring permissions**: `ls -la` reveals if you have read\u002Fwrite access\n4. **Hardcoding paths**: Always dynamically locate files when location is uncertain\n\n## Related Tools\n\n- `list_dir`: Inspect directory contents\n- `run_shell`: Execute find and ls commands\n- `read_file`: Read file contents after verification\n- `shell_agent`: Delegate complex file operations after path is confirmed","# File Locate and Verify Workflow\n\nWhen encountering FileNotFoundError or uncertain file paths, follow this systematic pattern to safely locate and verify files before executing operations.\n\n## When to Use\n\n- You receive a FileNotFoundError or similar path-related error\n- You need to work with files whose exact location is unknown\n- You want to verify file existence before executing operations that depend on those files\n\n## Step-by-Step Procedure\n\n### Step 1: Check Current Directory Contents\n\nFirst, use `list_dir` to inspect what files exist in your current working directory:\n\n```python\n# Use the list_dir tool to see current directory contents\nlist_dir(path=\".\")\n```\n\nThis reveals files in the immediate context and helps determine if you need to search elsewhere.\n\n### Step 2: Search for the File Using Find\n\nIf the file is not in the current directory, use the `find` command to locate it by name:\n\n```bash\n# Search for a specific file by name (case-insensitive)\nfind . -iname \"filename.pdf\" 2>\u002Fdev\u002Fnull\n\n# Or search from root for system-wide files\nfind \u002F -name \"filename.pdf\" 2>\u002Fdev\u002Fnull\n```\n\n**Tips:**\n- Use `-iname` for case-insensitive matching\n- Redirect stderr with `2>\u002Fdev\u002Fnull` to suppress permission errors\n- Narrow the search scope when possible for better performance\n\n### Step 3: Verify the Discovered Path\n\nBefore executing any operations on the discovered file, verify it exists and check its properties:\n\n```bash\n# Verify file existence and permissions at the full path\nls -la \u002Ffull\u002Fpath\u002Fto\u002Fdiscovered\u002Ffile.pdf\n```\n\nThis confirms:\n- The file actually exists at the located path\n- File permissions (can you read\u002Fwrite it?)\n- File size and modification time\n\n### Step 4: Execute Your Operation Safely\n\nOnly after verification, proceed with your intended operation:\n\n```python\n# Now safe to work with the verified path\nfile_path = \"\u002Ffull\u002Fpath\u002Fto\u002Fdiscovered\u002Ffile.pdf\"\n# ... your extraction or processing code here\n```\n\n## Complete Example\n\n```python\n# Task: Process a file that may be in an unknown location\n\n# Step 1: Check current directory\ndir_contents = list_dir(path=\".\")\nprint(f\"Current directory contains: {dir_contents}\")\n\n# Step 2: Find the file if not present\nif \"target_file.xlsx\" not in dir_contents:\n    result = run_shell(command='find . -iname \"target_file.xlsx\" 2>\u002Fdev\u002Fnull')\n    file_path = result.stdout.strip().split('\\n')[0]\n    print(f\"Found file at: {file_path}\")\n\n# Step 3: Verify before proceeding\nverification = run_shell(command=f'ls -la {file_path}')\nprint(f\"Verification: {verification.stdout}\")\n\n# Step 4: Proceed with operation\n# ... your code to process the file\n```\n\n## Common Pitfalls to Avoid\n\n1. **Skipping verification**: Never assume the path from `find` is correct without checking\n2. **Using relative paths blindly**: Always convert to absolute paths when possible\n3. **Ignoring permissions**: `ls -la` reveals if you have read\u002Fwrite access\n4. **Hardcoding paths**: Always dynamically locate files when location is uncertain\n\n## Related Tools\n\n- `list_dir`: Inspect directory contents\n- `run_shell`: Execute find and ls commands\n- `read_file`: Read file contents after verification\n- `shell_agent`: Delegate complex file operations after path is confirmed",{"name":5,"description":7},"main","6b84b0689ca0d9e7b1e4061188ff6b60758e0f8a","openspace\u002Fbenchmarks\u002Fgdpval\u002Fskills\u002Ffile-locate-verify",944,"https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot","https:\u002F\u002Fgithub.com\u002FHKUDS","https:\u002F\u002Fsites.google.com\u002Fview\u002Fchaoh","2026-11-12 22:26:39",{"source":8,"skillName":5,"commands":40,"prompt":50,"zipAvailable":51},[41,44,47],{"tool":42,"command":43},"npx","npx skills add HKUDS\u002FAgentPilot --skill file-locate-verify",{"tool":45,"command":46},"bunx","bunx skills add HKUDS\u002FAgentPilot --skill file-locate-verify",{"tool":48,"command":49},"pnpm","pnpm dlx skills add HKUDS\u002FAgentPilot --skill file-locate-verify","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Fbenchmarks\u002Fgdpval\u002Fskills\u002Ffile-locate-verify\u002FSKILL.md",true,[53],{"path":54,"resourceType":55,"resourceTypeDesc":56,"sizeBytes":57,"sourceHtmlUrl":58},".skill_id","OTHER","其他",32,"https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Fbenchmarks\u002Fgdpval\u002Fskills\u002Ffile-locate-verify\u002F.skill_id",[60,80,99,124,148,170],{"skillNo":61,"name":62,"nameZh":6,"description":63,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":64,"categories":65,"keywords":66,"publishedAt":26},"01M6HYB297NDABRERJRVG0K8R0","agentpilot","Set up AgentPilot and use its single entry to prepare missing inputs and run configured RSI experiments. Use when the user requests AgentPilot installation or work with AgentPilot.","https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fplugins\u002Fagentpilot\u002Fskills\u002Fagentpilot\u002FSKILL.md",[],[62,67,68,69,70,71,72,73,74,75,76,77,78,79],"prepare","requests","with","missing","installation","rsi","up","use","user","work","SET","run","experiments",{"skillNo":81,"name":82,"nameZh":6,"description":83,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":84,"categories":85,"keywords":86,"publishedAt":26},"01M6HYAYWXTTE1J7DJM0MFNQ4H","remember","Review auto-memory entries and propose promotions to OPENSPACE.md, OPENSPACE.local.md, or retained auto-memory topics; detect duplicates, stale facts, conflicts, and ambiguous entries before making changes.","https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Fopenspace\u002Fskills\u002Fremember\u002FSKILL.md",[],[82,87,88,89,90,91,92,93,94,95,96,97,98],"memory","review","auto","openspace","changes","facts","detect","entries","local","conflicts","stale","duplicates",{"skillNo":100,"name":101,"nameZh":6,"description":102,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":103,"categories":104,"keywords":110,"publishedAt":26},"01M6HYAVMPM4SBDV60R2B5HPV8","skill-discovery","Search reusable OpenSpace skills locally, and browse cloud packages step by step when a cloud skill may help. Reusing proven skills saves tokens, improves reliability, and extends your capabilities beyond built-in tools.","https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Fopenspace\u002Fhost_skills\u002Fskill-discovery\u002FSKILL.md",[105],{"categoryNo":106,"categoryName":107,"taxonomyType":108,"taxonomyTypeDesc":109},"01JBSEEDCAT000000000000023","Skill与智能体开发","SCENARIO","使用场景",[111,112,113,90,114,115,116,117,118,119,120,121,122,123],"skill discovery","discovery","reusable","step by step","tokens","packages","help","cloud","reliability","capabilities","browse","search","Tools",{"skillNo":125,"name":126,"nameZh":6,"description":127,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":128,"categories":129,"keywords":131,"publishedAt":26},"01M6HYAR811B3RB0M50RBEDGN6","delegate-task","Delegate tasks to OpenSpace — a full-stack autonomous worker for coding, DevOps, web research, and desktop automation, backed by an extensive MCP tool and skill library. Skills auto-improve through use, reducing token consumption over time. A cloud community lets agents share and collectively evolve reusable skills.","https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Fopenspace\u002Fhost_skills\u002Fdelegate-task\u002FSKILL.md",[130],{"categoryNo":106,"categoryName":107,"taxonomyType":108,"taxonomyTypeDesc":109},[132,133,134,90,135,136,137,138,139,113,89,74,140,141,142,143,144,145,146,147],"delegate","task","delegate task","time","improve","desktop automation","worker","community","autonomous","tool","stack","for","share","tasks","automation","MCP",{"skillNo":149,"name":150,"nameZh":6,"description":151,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":152,"categories":153,"keywords":154,"publishedAt":26},"01M6HYAM9FSGV6E52AYENDQXYH","write-special-chars-ts-check","Workaround for write_file failures caused by special characters (apostrophes, backticks, template literals) using a Python heredoc script, plus a reliable TypeScript type-checking step that filters output to only the newly-written files to avoid being misled by pre-existing errors.","https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Flegacy\u002Fv1\u002Fshowcase\u002Fskills\u002Fwrite-special-chars-ts-check\u002FSKILL.md",[],[155,156,157,158,159,160,161,162,19,163,164,165,166,167,143,168,169],"write special chars ts check","write","check","type","files","filters","only","template","python","typescript","output","Existing","type-checking","errors","script",{"skillNo":171,"name":172,"nameZh":6,"description":173,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":174,"categories":175,"keywords":176,"publishedAt":26},"01M6HYAH05HGV7SVWSVR8PJRQD","write-special-chars-readback","Workaround for write_file failures caused by special characters (apostrophes, backticks, template literals) using a Python heredoc script, with mandatory post-write verification via read_file and cleanup of \u002Ftmp helper scripts.","https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Flegacy\u002Fv1\u002Fshowcase\u002Fskills\u002Fwrite-special-chars-readback\u002FSKILL.md",[],[177,178,156,69,143,169,179,180,181,182,183,162,19,184,185,163],"write special chars readback","readback","helper","post","via","scripts","read","verification","cleanup"]