[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6KK0KWHARB0WN6D6KRQ3VFQ":3,"skill-same:01M6KK0KWHARB0WN6D6KRQ3VFQ":70},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":22,"publishedAt":38,"linkOnly":39,"markdownContent":40,"markdownBody":41,"frontMatter":42,"refName":43,"commitSha":44,"skillDirectory":45,"forksCount":13,"repositoryHtmlUrl":46,"repositoryHomepageUrl":6,"ownerHtmlUrl":47,"ownerBlogUrl":6,"ownerDescription":48,"updatedAt":49,"install":50,"resources":63},"01M6KK0KWHARB0WN6D6KRQ3VFQ","shell-agent-file-ops",null,"Leverage shell_agent for autonomous file creation and modification with automatic tool selection and error recovery","AG064\u002FOpenSpace","AG064","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F184930299?v=4","01M6KHVFG7TB73NHX3RDYSTMH2","01M6KHVFMM7XA2PZA9Z83PHS3V",0,"MIT","https:\u002F\u002Fgithub.com\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fgdpval_bench\u002Fskills\u002Fshell-agent-file-ops\u002FSKILL.md",[17],{"categoryNo":18,"categoryName":19,"taxonomyType":20,"taxonomyTypeDesc":21},"01JBSEEDCAT000000000000023","Skill与智能体开发","SCENARIO","使用场景",[23,24,25,26,27,28,29,30,31,32,33,34,35,36,37],"file","shell","ops","shell agent file ops","error recovery","recovery","tool","autonomous","selection","creation","leverage","error","with","for","automatic","2026-11-10 10:12:30",false,"---\nname: shell-agent-file-ops\ndescription: Leverage shell_agent for autonomous file creation and modification with automatic tool selection and error recovery\n---\n\n# Shell Agent File Operations\n\n## Purpose\n\nUse `shell_agent` for file operations when you want the tool to autonomously decide how to accomplish the task (Python vs Bash, which commands to use, error recovery) rather than manually selecting specific tools like `write_file` or `run_shell`.\n\n## When to Use\n\nUse this pattern when:\n- You need to create, modify, or organize files\n- The optimal approach (Python script, Bash commands, direct file write) is unclear\n- You want automatic error handling and retry logic\n- You prefer to describe **what** to accomplish rather than **how**\n\n## How to Use\n\n### Basic Pattern\n\n```\nDelegate to shell_agent with a clear natural-language task description.\n```\n\n### Example: Create a Document File\n\n**Task description to shell_agent:**\n```\nCreate a comprehensive SOAP note file containing four sections:\nSubjective, Objective, Assessment, and Plan. Include all relevant\npatient visit details in a professional medical format.\n```\n\nThe shell_agent will:\n1. Decide whether to use Python or Bash\n2. Write and execute the appropriate code\n3. Handle any errors automatically (up to several retry rounds)\n4. Return the result\n\n### Example: Modify Existing Files\n\n**Task description to shell_agent:**\n```\nUpdate all configuration files in the config\u002F directory to add\na new setting \"timeout: 300\" under the general section.\n```\n\n### Example: Complex File Operations\n\n**Task description to shell_agent:**\n```\nCreate a project structure with README.md, src\u002Fmain.py, and\ntests\u002Ftest_main.py. Include appropriate content in each file\nbased on a Python data processing project template.\n```\n\n## Best Practices\n\n1. **Be specific about content requirements** - Describe what should be in the file(s), not just that files should be created.\n\n2. **Include format specifications** - Mention desired formats (markdown, JSON, CSV, etc.) when relevant.\n\n3. **Specify file locations** - Include paths when files should be in specific directories.\n\n4. **Let shell_agent handle complexity** - Don't pre-decide the implementation approach; trust the autonomous selection.\n\n5. **Check the output** - Review what shell_agent created to ensure it meets requirements.\n\n## Comparison: When NOT to Use This Pattern\n\nUse direct tools instead when:\n- You already know the exact command\u002Fscript to run → use `run_shell`\n- You have the exact file content ready → use `write_file` directly\n- The operation is trivial (single-line file write) → use `write_file`\n- You need fine-grained control over the implementation\n\n## Anti-Patterns to Avoid\n\n❌ Don't over-specify the implementation:\n```\nUse Python to write a file called notes.md with this content...\n```\n\n✅ Do describe the desired outcome:\n```\nCreate a notes.md file with comprehensive documentation about...\n```\n\n❌ Don't use shell_agent for simple direct operations:\n```\nWrite \"hello\" to hello.txt\n```\n\n✅ Do use `write_file` directly for simple cases:\n```\nwrite_file(path=\"hello.txt\", content=\"hello\")\n```\n\n## Summary\n\nThis pattern shifts focus from **implementation mechanics** to **task intent**, leveraging shell_agent's autonomous decision-making for file operations that benefit from intelligent tool selection and automatic error recovery.","# Shell Agent File Operations\n\n## Purpose\n\nUse `shell_agent` for file operations when you want the tool to autonomously decide how to accomplish the task (Python vs Bash, which commands to use, error recovery) rather than manually selecting specific tools like `write_file` or `run_shell`.\n\n## When to Use\n\nUse this pattern when:\n- You need to create, modify, or organize files\n- The optimal approach (Python script, Bash commands, direct file write) is unclear\n- You want automatic error handling and retry logic\n- You prefer to describe **what** to accomplish rather than **how**\n\n## How to Use\n\n### Basic Pattern\n\n```\nDelegate to shell_agent with a clear natural-language task description.\n```\n\n### Example: Create a Document File\n\n**Task description to shell_agent:**\n```\nCreate a comprehensive SOAP note file containing four sections:\nSubjective, Objective, Assessment, and Plan. Include all relevant\npatient visit details in a professional medical format.\n```\n\nThe shell_agent will:\n1. Decide whether to use Python or Bash\n2. Write and execute the appropriate code\n3. Handle any errors automatically (up to several retry rounds)\n4. Return the result\n\n### Example: Modify Existing Files\n\n**Task description to shell_agent:**\n```\nUpdate all configuration files in the config\u002F directory to add\na new setting \"timeout: 300\" under the general section.\n```\n\n### Example: Complex File Operations\n\n**Task description to shell_agent:**\n```\nCreate a project structure with README.md, src\u002Fmain.py, and\ntests\u002Ftest_main.py. Include appropriate content in each file\nbased on a Python data processing project template.\n```\n\n## Best Practices\n\n1. **Be specific about content requirements** - Describe what should be in the file(s), not just that files should be created.\n\n2. **Include format specifications** - Mention desired formats (markdown, JSON, CSV, etc.) when relevant.\n\n3. **Specify file locations** - Include paths when files should be in specific directories.\n\n4. **Let shell_agent handle complexity** - Don't pre-decide the implementation approach; trust the autonomous selection.\n\n5. **Check the output** - Review what shell_agent created to ensure it meets requirements.\n\n## Comparison: When NOT to Use This Pattern\n\nUse direct tools instead when:\n- You already know the exact command\u002Fscript to run → use `run_shell`\n- You have the exact file content ready → use `write_file` directly\n- The operation is trivial (single-line file write) → use `write_file`\n- You need fine-grained control over the implementation\n\n## Anti-Patterns to Avoid\n\n❌ Don't over-specify the implementation:\n```\nUse Python to write a file called notes.md with this content...\n```\n\n✅ Do describe the desired outcome:\n```\nCreate a notes.md file with comprehensive documentation about...\n```\n\n❌ Don't use shell_agent for simple direct operations:\n```\nWrite \"hello\" to hello.txt\n```\n\n✅ Do use `write_file` directly for simple cases:\n```\nwrite_file(path=\"hello.txt\", content=\"hello\")\n```\n\n## Summary\n\nThis pattern shifts focus from **implementation mechanics** to **task intent**, leveraging shell_agent's autonomous decision-making for file operations that benefit from intelligent tool selection and automatic error recovery.",{"name":5,"description":7},"main","ff671ef61ed6587c49bd54c81cdc751c0b99e363","gdpval_bench\u002Fskills\u002Fshell-agent-file-ops","https:\u002F\u002Fgithub.com\u002FAG064\u002FOpenSpace","https:\u002F\u002Fgithub.com\u002FAG064","AG064, E.Mi.\r\n\r\nA person who thinks all the time, yet all they have to think about is nothing. I want to improve the world and work on open source projects","2026-10-08 06:53:48",{"source":8,"skillName":5,"commands":51,"prompt":61,"zipAvailable":62},[52,55,58],{"tool":53,"command":54},"npx","npx skills add AG064\u002FOpenSpace --skill shell-agent-file-ops",{"tool":56,"command":57},"bunx","bunx skills add AG064\u002FOpenSpace --skill shell-agent-file-ops",{"tool":59,"command":60},"pnpm","pnpm dlx skills add AG064\u002FOpenSpace --skill shell-agent-file-ops","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fgdpval_bench\u002Fskills\u002Fshell-agent-file-ops\u002FSKILL.md",true,[64],{"path":65,"resourceType":66,"resourceTypeDesc":67,"sizeBytes":68,"sourceHtmlUrl":69},".skill_id","OTHER","其他",34,"https:\u002F\u002Fgithub.com\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fgdpval_bench\u002Fskills\u002Fshell-agent-file-ops\u002F.skill_id",[71,93,109,117,147,163],{"skillNo":72,"name":73,"nameZh":6,"description":74,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":75,"categories":76,"keywords":77,"publishedAt":38},"01M6KKMPWA0B5SCCH766F8M5EA","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\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fshowcase\u002Fskills\u002Fwrite-special-chars-ts-check\u002FSKILL.md",[],[78,79,80,81,82,83,36,84,85,86,87,88,89,90,23,91,92],"write special chars ts check","check","write","filters","Existing","type-checking","errors","script","output","type","files","only","template","python","typescript",{"skillNo":94,"name":95,"nameZh":6,"description":96,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":97,"categories":98,"keywords":99,"publishedAt":38},"01M6KKMJXVBNVEY3TRK055F4A7","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\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fshowcase\u002Fskills\u002Fwrite-special-chars-readback\u002FSKILL.md",[],[100,101,80,90,102,103,23,91,104,105,106,107,108,36,85,35],"readback","write special chars readback","cleanup","read","scripts","verification","via","post","helper",{"skillNo":110,"name":111,"nameZh":6,"description":112,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":113,"categories":114,"keywords":115,"publishedAt":38},"01M6KKMEGX9M9NC105J0W3Q5B9","write-special-chars-heredoc","Workaround for write_file failures caused by special characters (apostrophes, backticks, template literals) by using a Python heredoc script executed via shell.","https:\u002F\u002Fgithub.com\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fshowcase\u002Fskills\u002Fwrite-special-chars-heredoc\u002FSKILL.md",[],[80,116,91,36,106,90,24,23,85],"write special chars heredoc",{"skillNo":118,"name":119,"nameZh":6,"description":120,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":121,"categories":122,"keywords":128,"publishedAt":38},"01M6KKM8EJ2AATVHZBNB916WT0","worldmonitor-reference","Curated architecture index of the WorldMonitor open-source dashboard. Reference for extracting patterns — vanilla TypeScript, Panel class hierarchy, service layer, CSS grid, API edge functions, refresh scheduler, and 60+ data source integrations.","https:\u002F\u002Fgithub.com\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fshowcase\u002Fskills\u002Fworldmonitor-reference\u002FSKILL.md",[123],{"categoryNo":124,"categoryName":125,"taxonomyType":126,"taxonomyTypeDesc":127},"01JBSEEDCAT000000000000033","数据分析师","PROFESSION","适用职业",[129,130,131,132,92,133,134,135,136,137,36,138,139,140,141,142,143,144,145,146],"reference","worldmonitor","worldmonitor reference","dashboard","css","architecture","extracting","hierarchy","source","layer","panel","patterns","edge functions","integrations","open","api","data","scheduler",{"skillNo":148,"name":149,"nameZh":6,"description":150,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":151,"categories":152,"keywords":153,"publishedAt":38},"01M6KKM39PHYK627F19GE2B9XN","virtual-list","Implement efficient virtual scrolling for rendering large lists with DOM recycling, chunk-based rendering, and performance optimizations","https:\u002F\u002Fgithub.com\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fshowcase\u002Fskills\u002Fvirtual-list\u002FSKILL.md",[],[154,155,156,157,36,158,35,159,160,161,162],"virtual list","list","virtual","chunk","dom","rendering","recycling","implement","performance",{"skillNo":164,"name":165,"nameZh":6,"description":166,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":167,"categories":168,"keywords":169,"publishedAt":38},"01M6KKKY7T2P61Y0JH54CDEJKQ","verify-directory-structure","Diagnose and resolve file access issues by first verifying the directory structure.","https:\u002F\u002Fgithub.com\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fshowcase\u002Fskills\u002Fverify-directory-structure\u002FSKILL.md",[],[170,171,172,173,174,175,23,176,177,178],"directory","verify","structure","verify directory structure","access","first","issues","diagnose","file access"]