[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6HXQNQFZJ3349JRCVZ4VRTC":3,"skill-same:01M6HXQNQFZJ3349JRCVZ4VRTC":67},{"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":23,"publishedAt":34,"linkOnly":35,"markdownContent":36,"markdownBody":37,"frontMatter":38,"refName":39,"commitSha":40,"skillDirectory":41,"forksCount":42,"repositoryHtmlUrl":43,"repositoryHomepageUrl":6,"ownerHtmlUrl":44,"ownerBlogUrl":45,"ownerDescription":6,"updatedAt":46,"install":47,"resources":60},"01M6HXQNQFZJ3349JRCVZ4VRTC","pdf-extraction-fallbacks",null,"Multi-fallback PDF\u002Ftext extraction with early failure detection and sequential tool fallbacks","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\u002Flegacy\u002Fv1\u002Fgdpval_bench\u002Fskills\u002Fpdf-extraction-fallbacks\u002FSKILL.md",[18],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000002","文档处理","SCENARIO","使用场景",[24,25,26,27,28,29,30,31,32,33],"PDF","extraction","pdf extraction","pdf extraction fallbacks","detection","tool","text","fallback","multi","with","2026-11-10 10:12:30",false,"---\nname: pdf-extraction-fallbacks\ndescription: Multi-fallback PDF\u002Ftext extraction with early failure detection and sequential tool fallbacks\n---\n\n# PDF Extraction with Multi-Fallback Strategy\n\n## Purpose\n\nWhen extracting text from PDFs (especially regulatory documents, handbooks, or protected content), single-method approaches often fail due to JavaScript protection, CORS restrictions, encoding issues, or corrupted downloads. This skill provides a robust multi-fallback workflow that detects failures early and tries sequential extraction methods.\n\n## Core Pattern\n\n1. **Download with validation** - Check file size and content sanity immediately\n2. **Sequential extraction attempts** - Try multiple tools in order of reliability\n3. **Early failure detection** - Don't proceed with obviously corrupt files\n4. **Document fallback path** - Log which method succeeded for future reference\n\n## Step-by-Step Instructions\n\n### Step 1: Download and Validate\n\nBefore attempting extraction, validate the downloaded file:\n\n```bash\n# Download the PDF\ncurl -L -o document.pdf \"$URL\"\n\n# Check file size (reject if \u003C 1KB - likely error page)\nFILE_SIZE=$(stat -f%z document.pdf 2>\u002Fdev\u002Fnull || stat -c%s document.pdf 2>\u002Fdev\u002Fnull)\nif [ \"$FILE_SIZE\" -lt 1024 ]; then\n    echo \"ERROR: File too small ($FILE_SIZE bytes) - likely not a valid PDF\"\n    # Check if it's an HTML error page\n    head -c 200 document.pdf | grep -i \"\u003Chtml\\|\u003C!doctype\\|error\\|access denied\" && \\\n        echo \"Detected HTML error page instead of PDF\"\n    exit 1\nfi\n\n# Check PDF magic bytes\nHEAD_BYTES=$(head -c 4 document.pdf)\nif [ \"$HEAD_BYTES\" != \"%PDF\" ]; then\n    echo \"ERROR: File does not start with PDF magic bytes\"\n    head -c 100 document.pdf\n    exit 1\nfi\n```\n\n### Step 2: Primary Extraction (pdftotext)\n\n```bash\n# Try pdftotext first (fastest, most reliable for simple PDFs)\nif command -v pdftotext &> \u002Fdev\u002Fnull; then\n    pdftotext -layout document.pdf output.txt 2>\u002Fdev\u002Fnull\n    if [ -s output.txt ]; then\n        WORD_COUNT=$(wc -w \u003C output.txt)\n        if [ \"$WORD_COUNT\" -gt 50 ]; then\n            echo \"SUCCESS: pdftotext extracted $WORD_COUNT words\"\n            exit 0\n        fi\n    fi\nfi\n```\n\n### Step 3: Fallback 1 (PyMuPDF\u002Ffitz)\n\n```python\n# Try PyMuPDF - handles more complex PDFs\nimport fitz  # pymupdf\n\ntry:\n    doc = fitz.open(\"document.pdf\")\n    text = \"\"\n    for page in doc:\n        text += page.get_text()\n    \n    if len(text.strip()) > 500:  # Sanity check\n        with open(\"output.txt\", \"w\") as f:\n            f.write(text)\n        print(f\"SUCCESS: PyMuPDF extracted {len(text)} characters\")\n    else:\n        print(\"WARNING: PyMuPDF extraction too short, trying next method\")\nexcept Exception as e:\n    print(f\"PyMuPDF failed: {e}\")\n```\n\n### Step 4: Fallback 2 (pdfplumber)\n\n```python\n# Try pdfplumber - better for tables and structured content\nimport pdfplumber\n\ntry:\n    text = \"\"\n    with pdfplumber.open(\"document.pdf\") as pdf:\n        for page in pdf.pages:\n            page_text = page.extract_text()\n            if page_text:\n                text += page_text + \"\\n\"\n    \n    if len(text.strip()) > 500:\n        with open(\"output.txt\", \"w\") as f:\n            f.write(text)\n        print(f\"SUCCESS: pdfplumber extracted {len(text)} characters\")\n    else:\n        print(\"WARNING: pdfplumber extraction too short\")\nexcept Exception as e:\n    print(f\"pdfplumber failed: {e}\")\n```\n\n### Step 5: Handle JavaScript-Protected Pages\n\nIf all methods fail, the PDF may be JavaScript-protected:\n\n```python\n# Check for JavaScript in PDF\nimport fitz\n\ndoc = fitz.open(\"document.pdf\")\nhas_js = False\nfor page in doc:\n    if page.get_java_script():\n        has_js = True\n        break\n\nif has_js:\n    print(\"WARNING: PDF contains JavaScript - may be protected\")\n    # Try rendering pages as images and OCR (requires additional tools)\n    # Or try alternative download source\n```\n\n### Step 6: Alternative Sources\n\nIf the primary URL fails:\n- Try alternative domains (e.g., `.gov` mirrors, archive.org)\n- Check if the document is available via API\n- Look for HTML version of the same content\n- Search for the document title + \"pdf\" to find mirrors\n\n## Decision Tree\n\n```\nDownload PDF\n    │\n    ├─→ File \u003C 1KB? → REJECT (likely error page)\n    ├─→ No %PDF header? → REJECT (not a PDF)\n    │\n    └─→ Valid PDF\n         │\n         ├─→ pdftotext → >50 words? → SUCCESS\n         │              └─→ Try next\n         │\n         ├─→ PyMuPDF → >500 chars? → SUCCESS\n         │             └─→ Try next\n         │\n         ├─→ pdfplumber → >500 chars? → SUCCESS\n         │                 └─→ Try next\n         │\n         └─→ All failed → Check for JS protection, try alternative sources\n```\n\n## Common Failure Modes\n\n| Symptom | Likely Cause | Solution |\n|---------|-------------|----------|\n| File \u003C 100 bytes | JavaScript error page | Check CORS, try different user-agent |\n| File ~1-5KB | HTML error\u002Fwarning page | Parse HTML for actual PDF link |\n| pdftotext returns empty | Encrypted\u002Fprotected PDF | Try PyMuPDF with password handling |\n| Garbled text output | Encoding issue | Try pdfplumber, specify encoding |\n| Extraction very short | Images-only PDF | Need OCR (tesseract) |\n\n## Example Complete Workflow Script\n\nSave as `extract_pdf_robust.sh`:\n\n```bash\n#!\u002Fbin\u002Fbash\nset -e\n\nURL=\"$1\"\nOUTPUT=\"${2:-output.txt}\"\nTEMP_PDF=\"temp_download.pdf\"\n\necho \"Downloading from: $URL\"\ncurl -L -A \"Mozilla\u002F5.0\" -o \"$TEMP_PDF\" \"$URL\"\n\n# Validate\nSIZE=$(stat -c%s \"$TEMP_PDF\" 2>\u002Fdev\u002Fnull || stat -f%z \"$TEMP_PDF\")\necho \"Downloaded: $SIZE bytes\"\n\nif [ \"$SIZE\" -lt 1024 ]; then\n    echo \"ERROR: File too small - checking content...\"\n    head -200 \"$TEMP_PDF\"\n    exit 1\nfi\n\nif ! head -c 4 \"$TEMP_PDF\" | grep -q \"%PDF\"; then\n    echo \"ERROR: Not a valid PDF file\"\n    head -100 \"$TEMP_PDF\"\n    exit 1\nfi\n\n# Try extraction methods\npython3 \u003C\u003C 'PYTHON'\nimport sys\nimport fitz\nimport pdfplumber\n\npdf_path = \"temp_download.pdf\"\noutput_path = \"output.txt\"\n\n# Method 1: PyMuPDF\ntry:\n    doc = fitz.open(pdf_path)\n    text = \"\".join(page.get_text() for page in doc)\n    if len(text.strip()) > 500:\n        with open(output_path, \"w\") as f:\n            f.write(text)\n        print(f\"PyMuPDF: {len(text)} chars\")\n        sys.exit(0)\nexcept Exception as e:\n    print(f\"PyMuPDF failed: {e}\")\n\n# Method 2: pdfplumber\ntry:\n    text = \"\"\n    with pdfplumber.open(pdf_path) as pdf:\n        for page in pdf.pages:\n            txt = page.extract_text()\n            if txt:\n                text += txt + \"\\n\"\n    if len(text.strip()) > 500:\n        with open(output_path, \"w\") as f:\n            f.write(text)\n        print(f\"pdfplumber: {len(text)} chars\")\n        sys.exit(0)\nexcept Exception as e:\n    print(f\"pdfplumber failed: {e}\")\n\nprint(\"All extraction methods failed\")\nsys.exit(1)\nPYTHON\n```\n\n## Best Practices\n\n1. **Always validate** - Never assume a download succeeded\n2. **Log the path taken** - Record which method worked for debugging\n3. **Set reasonable thresholds** - 50 words \u002F 500 chars minimum for \"success\"\n4. **Keep raw PDF** - Don't delete the original until extraction is confirmed\n5. **Retry with variations** - Different user-agents, referer headers, or mirrors\n\n## Dependencies\n\n- `curl` - For downloading\n- `poppler-utils` (pdftotext) - Optional, fast extraction\n- `PyMuPDF` (`fitz`) - `pip install pymupdf`\n- `pdfplumber` - `pip install pdfplumber`","# PDF Extraction with Multi-Fallback Strategy\n\n## Purpose\n\nWhen extracting text from PDFs (especially regulatory documents, handbooks, or protected content), single-method approaches often fail due to JavaScript protection, CORS restrictions, encoding issues, or corrupted downloads. This skill provides a robust multi-fallback workflow that detects failures early and tries sequential extraction methods.\n\n## Core Pattern\n\n1. **Download with validation** - Check file size and content sanity immediately\n2. **Sequential extraction attempts** - Try multiple tools in order of reliability\n3. **Early failure detection** - Don't proceed with obviously corrupt files\n4. **Document fallback path** - Log which method succeeded for future reference\n\n## Step-by-Step Instructions\n\n### Step 1: Download and Validate\n\nBefore attempting extraction, validate the downloaded file:\n\n```bash\n# Download the PDF\ncurl -L -o document.pdf \"$URL\"\n\n# Check file size (reject if \u003C 1KB - likely error page)\nFILE_SIZE=$(stat -f%z document.pdf 2>\u002Fdev\u002Fnull || stat -c%s document.pdf 2>\u002Fdev\u002Fnull)\nif [ \"$FILE_SIZE\" -lt 1024 ]; then\n    echo \"ERROR: File too small ($FILE_SIZE bytes) - likely not a valid PDF\"\n    # Check if it's an HTML error page\n    head -c 200 document.pdf | grep -i \"\u003Chtml\\|\u003C!doctype\\|error\\|access denied\" && \\\n        echo \"Detected HTML error page instead of PDF\"\n    exit 1\nfi\n\n# Check PDF magic bytes\nHEAD_BYTES=$(head -c 4 document.pdf)\nif [ \"$HEAD_BYTES\" != \"%PDF\" ]; then\n    echo \"ERROR: File does not start with PDF magic bytes\"\n    head -c 100 document.pdf\n    exit 1\nfi\n```\n\n### Step 2: Primary Extraction (pdftotext)\n\n```bash\n# Try pdftotext first (fastest, most reliable for simple PDFs)\nif command -v pdftotext &> \u002Fdev\u002Fnull; then\n    pdftotext -layout document.pdf output.txt 2>\u002Fdev\u002Fnull\n    if [ -s output.txt ]; then\n        WORD_COUNT=$(wc -w \u003C output.txt)\n        if [ \"$WORD_COUNT\" -gt 50 ]; then\n            echo \"SUCCESS: pdftotext extracted $WORD_COUNT words\"\n            exit 0\n        fi\n    fi\nfi\n```\n\n### Step 3: Fallback 1 (PyMuPDF\u002Ffitz)\n\n```python\n# Try PyMuPDF - handles more complex PDFs\nimport fitz  # pymupdf\n\ntry:\n    doc = fitz.open(\"document.pdf\")\n    text = \"\"\n    for page in doc:\n        text += page.get_text()\n    \n    if len(text.strip()) > 500:  # Sanity check\n        with open(\"output.txt\", \"w\") as f:\n            f.write(text)\n        print(f\"SUCCESS: PyMuPDF extracted {len(text)} characters\")\n    else:\n        print(\"WARNING: PyMuPDF extraction too short, trying next method\")\nexcept Exception as e:\n    print(f\"PyMuPDF failed: {e}\")\n```\n\n### Step 4: Fallback 2 (pdfplumber)\n\n```python\n# Try pdfplumber - better for tables and structured content\nimport pdfplumber\n\ntry:\n    text = \"\"\n    with pdfplumber.open(\"document.pdf\") as pdf:\n        for page in pdf.pages:\n            page_text = page.extract_text()\n            if page_text:\n                text += page_text + \"\\n\"\n    \n    if len(text.strip()) > 500:\n        with open(\"output.txt\", \"w\") as f:\n            f.write(text)\n        print(f\"SUCCESS: pdfplumber extracted {len(text)} characters\")\n    else:\n        print(\"WARNING: pdfplumber extraction too short\")\nexcept Exception as e:\n    print(f\"pdfplumber failed: {e}\")\n```\n\n### Step 5: Handle JavaScript-Protected Pages\n\nIf all methods fail, the PDF may be JavaScript-protected:\n\n```python\n# Check for JavaScript in PDF\nimport fitz\n\ndoc = fitz.open(\"document.pdf\")\nhas_js = False\nfor page in doc:\n    if page.get_java_script():\n        has_js = True\n        break\n\nif has_js:\n    print(\"WARNING: PDF contains JavaScript - may be protected\")\n    # Try rendering pages as images and OCR (requires additional tools)\n    # Or try alternative download source\n```\n\n### Step 6: Alternative Sources\n\nIf the primary URL fails:\n- Try alternative domains (e.g., `.gov` mirrors, archive.org)\n- Check if the document is available via API\n- Look for HTML version of the same content\n- Search for the document title + \"pdf\" to find mirrors\n\n## Decision Tree\n\n```\nDownload PDF\n    │\n    ├─→ File \u003C 1KB? → REJECT (likely error page)\n    ├─→ No %PDF header? → REJECT (not a PDF)\n    │\n    └─→ Valid PDF\n         │\n         ├─→ pdftotext → >50 words? → SUCCESS\n         │              └─→ Try next\n         │\n         ├─→ PyMuPDF → >500 chars? → SUCCESS\n         │             └─→ Try next\n         │\n         ├─→ pdfplumber → >500 chars? → SUCCESS\n         │                 └─→ Try next\n         │\n         └─→ All failed → Check for JS protection, try alternative sources\n```\n\n## Common Failure Modes\n\n| Symptom | Likely Cause | Solution |\n|---------|-------------|----------|\n| File \u003C 100 bytes | JavaScript error page | Check CORS, try different user-agent |\n| File ~1-5KB | HTML error\u002Fwarning page | Parse HTML for actual PDF link |\n| pdftotext returns empty | Encrypted\u002Fprotected PDF | Try PyMuPDF with password handling |\n| Garbled text output | Encoding issue | Try pdfplumber, specify encoding |\n| Extraction very short | Images-only PDF | Need OCR (tesseract) |\n\n## Example Complete Workflow Script\n\nSave as `extract_pdf_robust.sh`:\n\n```bash\n#!\u002Fbin\u002Fbash\nset -e\n\nURL=\"$1\"\nOUTPUT=\"${2:-output.txt}\"\nTEMP_PDF=\"temp_download.pdf\"\n\necho \"Downloading from: $URL\"\ncurl -L -A \"Mozilla\u002F5.0\" -o \"$TEMP_PDF\" \"$URL\"\n\n# Validate\nSIZE=$(stat -c%s \"$TEMP_PDF\" 2>\u002Fdev\u002Fnull || stat -f%z \"$TEMP_PDF\")\necho \"Downloaded: $SIZE bytes\"\n\nif [ \"$SIZE\" -lt 1024 ]; then\n    echo \"ERROR: File too small - checking content...\"\n    head -200 \"$TEMP_PDF\"\n    exit 1\nfi\n\nif ! head -c 4 \"$TEMP_PDF\" | grep -q \"%PDF\"; then\n    echo \"ERROR: Not a valid PDF file\"\n    head -100 \"$TEMP_PDF\"\n    exit 1\nfi\n\n# Try extraction methods\npython3 \u003C\u003C 'PYTHON'\nimport sys\nimport fitz\nimport pdfplumber\n\npdf_path = \"temp_download.pdf\"\noutput_path = \"output.txt\"\n\n# Method 1: PyMuPDF\ntry:\n    doc = fitz.open(pdf_path)\n    text = \"\".join(page.get_text() for page in doc)\n    if len(text.strip()) > 500:\n        with open(output_path, \"w\") as f:\n            f.write(text)\n        print(f\"PyMuPDF: {len(text)} chars\")\n        sys.exit(0)\nexcept Exception as e:\n    print(f\"PyMuPDF failed: {e}\")\n\n# Method 2: pdfplumber\ntry:\n    text = \"\"\n    with pdfplumber.open(pdf_path) as pdf:\n        for page in pdf.pages:\n            txt = page.extract_text()\n            if txt:\n                text += txt + \"\\n\"\n    if len(text.strip()) > 500:\n        with open(output_path, \"w\") as f:\n            f.write(text)\n        print(f\"pdfplumber: {len(text)} chars\")\n        sys.exit(0)\nexcept Exception as e:\n    print(f\"pdfplumber failed: {e}\")\n\nprint(\"All extraction methods failed\")\nsys.exit(1)\nPYTHON\n```\n\n## Best Practices\n\n1. **Always validate** - Never assume a download succeeded\n2. **Log the path taken** - Record which method worked for debugging\n3. **Set reasonable thresholds** - 50 words \u002F 500 chars minimum for \"success\"\n4. **Keep raw PDF** - Don't delete the original until extraction is confirmed\n5. **Retry with variations** - Different user-agents, referer headers, or mirrors\n\n## Dependencies\n\n- `curl` - For downloading\n- `poppler-utils` (pdftotext) - Optional, fast extraction\n- `PyMuPDF` (`fitz`) - `pip install pymupdf`\n- `pdfplumber` - `pip install pdfplumber`",{"name":5,"description":7},"main","6b84b0689ca0d9e7b1e4061188ff6b60758e0f8a","openspace\u002Flegacy\u002Fv1\u002Fgdpval_bench\u002Fskills\u002Fpdf-extraction-fallbacks",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":48,"prompt":58,"zipAvailable":59},[49,52,55],{"tool":50,"command":51},"npx","npx skills add HKUDS\u002FAgentPilot --skill pdf-extraction-fallbacks",{"tool":53,"command":54},"bunx","bunx skills add HKUDS\u002FAgentPilot --skill pdf-extraction-fallbacks",{"tool":56,"command":57},"pnpm","pnpm dlx skills add HKUDS\u002FAgentPilot --skill pdf-extraction-fallbacks","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Flegacy\u002Fv1\u002Fgdpval_bench\u002Fskills\u002Fpdf-extraction-fallbacks\u002FSKILL.md",true,[61],{"path":62,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":65,"sourceHtmlUrl":66},".skill_id","OTHER","其他",38,"https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Flegacy\u002Fv1\u002Fgdpval_bench\u002Fskills\u002Fpdf-extraction-fallbacks\u002F.skill_id",[68,87,106,129,152,175],{"skillNo":69,"name":70,"nameZh":6,"description":71,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":72,"categories":73,"keywords":74,"publishedAt":34},"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",[],[70,75,76,33,77,78,79,80,81,82,83,84,85,86],"prepare","requests","missing","installation","rsi","up","use","user","work","SET","run","experiments",{"skillNo":88,"name":89,"nameZh":6,"description":90,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":91,"categories":92,"keywords":93,"publishedAt":34},"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",[],[89,94,95,96,97,98,99,100,101,102,103,104,105],"memory","review","auto","openspace","changes","facts","detect","entries","local","conflicts","stale","duplicates",{"skillNo":107,"name":108,"nameZh":6,"description":109,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":110,"categories":111,"keywords":115,"publishedAt":34},"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",[112],{"categoryNo":113,"categoryName":114,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000023","Skill与智能体开发",[116,117,118,97,119,120,121,122,123,124,125,126,127,128],"skill discovery","discovery","reusable","step by step","tokens","packages","help","cloud","reliability","capabilities","browse","search","Tools",{"skillNo":130,"name":131,"nameZh":6,"description":132,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":133,"categories":134,"keywords":136,"publishedAt":34},"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",[135],{"categoryNo":113,"categoryName":114,"taxonomyType":21,"taxonomyTypeDesc":22},[137,138,139,97,140,141,142,143,144,118,96,81,145,29,146,147,148,149,150,151],"delegate","task","delegate task","time","improve","desktop automation","worker","community","autonomous","stack","for","share","tasks","automation","MCP",{"skillNo":153,"name":154,"nameZh":6,"description":155,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":156,"categories":157,"keywords":158,"publishedAt":34},"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",[],[159,160,161,162,163,164,165,166,167,168,169,170,171,172,147,173,174],"write special chars ts check","write","check","type","files","filters","only","template","file","python","typescript","output","Existing","type-checking","errors","script",{"skillNo":176,"name":177,"nameZh":6,"description":178,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":179,"categories":180,"keywords":181,"publishedAt":34},"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",[],[182,183,160,33,147,174,184,185,186,187,188,166,167,189,190,168],"write special chars readback","readback","helper","post","via","scripts","read","verification","cleanup"]