[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6DTEMHD3EXD7GMMAWH4EPVN":3,"skill-same:01M6DTEMHD3EXD7GMMAWH4EPVN":100},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":22,"publishedAt":35,"linkOnly":36,"markdownContent":37,"markdownBody":38,"frontMatter":39,"refName":42,"commitSha":43,"skillDirectory":44,"forksCount":45,"repositoryHtmlUrl":46,"repositoryHomepageUrl":47,"ownerHtmlUrl":48,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":49,"install":50,"resources":63},"01M6DTEMHD3EXD7GMMAWH4EPVN","proteomics-enrichment",null,"Load for Fisher over-representation analysis of protein identifiers against caller-supplied pathways. Skip rank-based GSEA (use bulkrna-enrichment) or protein differential testing (use proteomics-de).","TianGzlab\u002FOmicsClaw","TianGzlab","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F150978281?v=4","01M6DT9WNJJ470ADHPSMFAA02Y","01M6DT9WSN09C5K65GB6RK18R9",161,"Apache-2.0","https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002FSKILL.md",[17],{"categoryNo":18,"categoryName":19,"taxonomyType":20,"taxonomyTypeDesc":21},"01JBSEEDCAT000000000000008","测试与质量","SCENARIO","使用场景",[23,24,25,26,27,28,29,30,31,32,33,34],"enrichment","proteomics","proteomics enrichment","testing","analysis","use","bulkrna","GSEA","ORA","pathway","de","fisher","2026-11-10 10:12:30",false,"---\nname: proteomics-enrichment\ndescription: Load for Fisher over-representation analysis of protein identifiers against caller-supplied pathways. Skip rank-based GSEA (use bulkrna-enrichment) or protein differential testing (use proteomics-de).\ntrigger: proteomics enrichment, pathway analysis, ORA\ntags:\n- proteomics\n- enrichment\n---\n\n# proteomics-enrichment\n\n## When to use\n\nORA uses one-sided Fisher tests and BH correction. Pass an explicit pathway_db and a background_size matching the measured universe.\nUse existing search-engine tables; this skill does not search raw spectra.\n\n## Use from a step\n\n```python\nfrom skills._sdk.notebook import load_skill, write_output\nlibrary = load_skill('proteomics-enrichment')\ndata = library.demo_data(random_state=42)\nresult = library.enrich(data['protein_id'].tolist(), pathway_db=library.demo_pathways())\nwrite_output(result, 'tables\u002Fenrichment_results.csv')\n```\n\nFor real data, use `read_input` and pass any `read_table` helper as `reader=`.\nThe executable `examples\u002Fexample_step.py` also checks the result and writes a Figure.\n\n## API\n\n\u003C!-- api:begin generated from _api.py; regenerate with run.py api \u003Cskill dir> --write -->\n\n### `enrich(genes: list[str], *, pathway_db: dict | None=None, background_size: int | None=None, method: str='ora') -> pd.DataFrame`\n\nRun one-sided Fisher tests with BH correction against an explicit pathway library.\n\n:param genes: Protein or gene identifiers in the same identifier space as pathway_db.\n:param pathway_db: Required pathway-to-member mapping; no default biological database is assumed.\n:param background_size: CLI default None uses the input\u002Flibrary union plus at least one background-only member.\n:param method: CLI default ora is the only implemented method.\n:returns: Ranked pathway overlaps, odds ratios and adjusted p values.\n:raises ValueError: The library is absent, the method is invalid, or the background is too small.\n\n### `run_info(table: pd.DataFrame, *, keep: bool=True) -> dict`\n\nRead enrichment diagnostics.\n\n:param table: Output of enrich.\n:param keep: True preserves attrs; False removes diagnostics.\n:returns: A separate dictionary with library provenance and summary.\n:raises TypeError: The input is not a DataFrame.\n\n### `enrichment_figure(table: pd.DataFrame, *, top_n: int=10)`\n\nPlot leading pathways by enrichment ratio.\n\n:param table: Enrichment results sorted by p value.\n:param top_n: Display ten pathways by default; change for a larger result table.\n:returns: A matplotlib Figure without writing files.\n:raises KeyError: pathway or enrichment_ratio is absent.\n\n### `demo_data(*, random_state: int=42) -> pd.DataFrame`\n\nGenerate a synthetic significant-protein list.\n\n:param random_state: CLI seed 42; change for another simulation.\n:returns: Eighteen example identifiers with simulated statistics.\n:raises ValueError: The seed is invalid.\n\n### `demo_pathways() -> dict`\n\nReturn the eight small illustrative pathway sets used by --demo.\n\n:returns: A separate mapping, not a production pathway database.\n:raises RuntimeError: No runtime failures are expected.\n\n\u003C!-- api:end -->\n\n## Methods and parameters\n\nORA uses one-sided Fisher tests and BH correction. Pass an explicit pathway_db and a background_size matching the measured universe.\nFunctions return new DataFrames. `run_info(result)` reads diagnostic attrs;\nuse `keep=False` before serialization when those attrs are not needed.\n\n## Gotchas\n\n- enrich requires pathway_db. demo_pathways contains eight illustrative sets and is only for demonstrations. The CLI requires --pathways for non-demo input; --species is recorded only.\n- `demo_data` uses seed 42, matching the CLI; every demo is synthetic.\n- `run_info` lives in DataFrame attrs and is not preserved by CSV serialization.\n\n## Inputs and outputs\n\nThe CLI reads CSV tables and writes:\n\n- tables\u002Fenrichment_results.csv\n- report.md\n- result.json\n- `demo_proteins.csv` is written only with `--demo`.\n\nFunctions return data and Figures without writing files. Steps own their outputs.\nDemo mode also writes its synthetic input when the original CLI used a file.\n\n## CLI\n\n```bash\npython skills\u002Fproteomics\u002Fproteomics-enrichment\u002Fprot_enrichment.py --demo --output \u002Ftmp\u002Fproteomics_enrichment\n```\n\nFor real input replace `--demo` with `--input \u003Ctable>`.\nNon-demo enrichment also requires `--pathways \u003Cpathways.json>`, a pathway-to-members object.\n\n## See also\n\n- `references\u002Fmethodology.md`\n- `references\u002Fparameters.md`\n- `references\u002Foutput_contract.md`\n- `proteomics-data-import` for protein-table normalization; `proteomics-de` for comparisons.\n\n## Dependencies\n\n`numpy`, `pandas`, `matplotlib`, `scipy`\n","# proteomics-enrichment\n\n## When to use\n\nORA uses one-sided Fisher tests and BH correction. Pass an explicit pathway_db and a background_size matching the measured universe.\nUse existing search-engine tables; this skill does not search raw spectra.\n\n## Use from a step\n\n```python\nfrom skills._sdk.notebook import load_skill, write_output\nlibrary = load_skill('proteomics-enrichment')\ndata = library.demo_data(random_state=42)\nresult = library.enrich(data['protein_id'].tolist(), pathway_db=library.demo_pathways())\nwrite_output(result, 'tables\u002Fenrichment_results.csv')\n```\n\nFor real data, use `read_input` and pass any `read_table` helper as `reader=`.\nThe executable `examples\u002Fexample_step.py` also checks the result and writes a Figure.\n\n## API\n\n\u003C!-- api:begin generated from _api.py; regenerate with run.py api \u003Cskill dir> --write -->\n\n### `enrich(genes: list[str], *, pathway_db: dict | None=None, background_size: int | None=None, method: str='ora') -> pd.DataFrame`\n\nRun one-sided Fisher tests with BH correction against an explicit pathway library.\n\n:param genes: Protein or gene identifiers in the same identifier space as pathway_db.\n:param pathway_db: Required pathway-to-member mapping; no default biological database is assumed.\n:param background_size: CLI default None uses the input\u002Flibrary union plus at least one background-only member.\n:param method: CLI default ora is the only implemented method.\n:returns: Ranked pathway overlaps, odds ratios and adjusted p values.\n:raises ValueError: The library is absent, the method is invalid, or the background is too small.\n\n### `run_info(table: pd.DataFrame, *, keep: bool=True) -> dict`\n\nRead enrichment diagnostics.\n\n:param table: Output of enrich.\n:param keep: True preserves attrs; False removes diagnostics.\n:returns: A separate dictionary with library provenance and summary.\n:raises TypeError: The input is not a DataFrame.\n\n### `enrichment_figure(table: pd.DataFrame, *, top_n: int=10)`\n\nPlot leading pathways by enrichment ratio.\n\n:param table: Enrichment results sorted by p value.\n:param top_n: Display ten pathways by default; change for a larger result table.\n:returns: A matplotlib Figure without writing files.\n:raises KeyError: pathway or enrichment_ratio is absent.\n\n### `demo_data(*, random_state: int=42) -> pd.DataFrame`\n\nGenerate a synthetic significant-protein list.\n\n:param random_state: CLI seed 42; change for another simulation.\n:returns: Eighteen example identifiers with simulated statistics.\n:raises ValueError: The seed is invalid.\n\n### `demo_pathways() -> dict`\n\nReturn the eight small illustrative pathway sets used by --demo.\n\n:returns: A separate mapping, not a production pathway database.\n:raises RuntimeError: No runtime failures are expected.\n\n\u003C!-- api:end -->\n\n## Methods and parameters\n\nORA uses one-sided Fisher tests and BH correction. Pass an explicit pathway_db and a background_size matching the measured universe.\nFunctions return new DataFrames. `run_info(result)` reads diagnostic attrs;\nuse `keep=False` before serialization when those attrs are not needed.\n\n## Gotchas\n\n- enrich requires pathway_db. demo_pathways contains eight illustrative sets and is only for demonstrations. The CLI requires --pathways for non-demo input; --species is recorded only.\n- `demo_data` uses seed 42, matching the CLI; every demo is synthetic.\n- `run_info` lives in DataFrame attrs and is not preserved by CSV serialization.\n\n## Inputs and outputs\n\nThe CLI reads CSV tables and writes:\n\n- tables\u002Fenrichment_results.csv\n- report.md\n- result.json\n- `demo_proteins.csv` is written only with `--demo`.\n\nFunctions return data and Figures without writing files. Steps own their outputs.\nDemo mode also writes its synthetic input when the original CLI used a file.\n\n## CLI\n\n```bash\npython skills\u002Fproteomics\u002Fproteomics-enrichment\u002Fprot_enrichment.py --demo --output \u002Ftmp\u002Fproteomics_enrichment\n```\n\nFor real input replace `--demo` with `--input \u003Ctable>`.\nNon-demo enrichment also requires `--pathways \u003Cpathways.json>`, a pathway-to-members object.\n\n## See also\n\n- `references\u002Fmethodology.md`\n- `references\u002Fparameters.md`\n- `references\u002Foutput_contract.md`\n- `proteomics-data-import` for protein-table normalization; `proteomics-de` for comparisons.\n\n## Dependencies\n\n`numpy`, `pandas`, `matplotlib`, `scipy`\n",{"name":5,"tags":40,"trigger":41,"description":7},[24,23],"proteomics enrichment, pathway analysis, ORA","main","90a3bec3e6549bc33dddbf67e4b23869736c49d1","skills\u002Fproteomics\u002Fproteomics-enrichment",27,"https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw","https:\u002F\u002FTianGzlab.github.io\u002FOmicsClaw\u002F","https:\u002F\u002Fgithub.com\u002FTianGzlab","2026-10-08 01:36:11",{"source":8,"skillName":5,"commands":51,"prompt":61,"zipAvailable":62},[52,55,58],{"tool":53,"command":54},"npx","npx skills add TianGzlab\u002FOmicsClaw --skill proteomics-enrichment",{"tool":56,"command":57},"bunx","bunx skills add TianGzlab\u002FOmicsClaw --skill proteomics-enrichment",{"tool":59,"command":60},"pnpm","pnpm dlx skills add TianGzlab\u002FOmicsClaw --skill proteomics-enrichment","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002FSKILL.md",true,[64,70,74,78,84,88,92,96],{"path":65,"resourceType":66,"resourceTypeDesc":67,"sizeBytes":68,"sourceHtmlUrl":69},"_api.py","SCRIPT","脚本",4097,"https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002F_api.py",{"path":71,"resourceType":66,"resourceTypeDesc":67,"sizeBytes":72,"sourceHtmlUrl":73},"examples\u002Fexample_step.py",555,"https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002Fexamples\u002Fexample_step.py",{"path":75,"resourceType":66,"resourceTypeDesc":67,"sizeBytes":76,"sourceHtmlUrl":77},"prot_enrichment.py",5866,"https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002Fprot_enrichment.py",{"path":79,"resourceType":80,"resourceTypeDesc":81,"sizeBytes":82,"sourceHtmlUrl":83},"references\u002Fmethodology.md","REFERENCE","参考文档",332,"https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002Freferences\u002Fmethodology.md",{"path":85,"resourceType":80,"resourceTypeDesc":81,"sizeBytes":86,"sourceHtmlUrl":87},"references\u002Foutput_contract.md",272,"https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002Freferences\u002Foutput_contract.md",{"path":89,"resourceType":80,"resourceTypeDesc":81,"sizeBytes":90,"sourceHtmlUrl":91},"references\u002Fparameters.md",307,"https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002Freferences\u002Fparameters.md",{"path":93,"resourceType":66,"resourceTypeDesc":67,"sizeBytes":94,"sourceHtmlUrl":95},"tests\u002Ftest_api.py",698,"https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002Ftests\u002Ftest_api.py",{"path":97,"resourceType":66,"resourceTypeDesc":67,"sizeBytes":98,"sourceHtmlUrl":99},"tests\u002Ftest_cli.py",969,"https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002Ftests\u002Ftest_cli.py",[101,117,129,146,172,195],{"skillNo":102,"name":103,"nameZh":6,"description":104,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":105,"categories":106,"keywords":110,"publishedAt":35},"01M6DTP4X225Q92RMY8XXHPCTT","demo-skill","A fixture skill for the skill environment tests. Use it for nothing else.","https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Ftests\u002Fskillenv\u002Ffixtures\u002Fskills\u002Fdemo\u002Fdemo-skill\u002FSKILL.md",[107],{"categoryNo":108,"categoryName":109,"taxonomyType":20,"taxonomyTypeDesc":21},"01JBSEEDCAT000000000000023","Skill与智能体开发",[111,112,113,114,115,28,116],"demo skill","demo","tests","fixture","fixture skill","environment",{"skillNo":118,"name":119,"nameZh":6,"description":120,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":121,"categories":122,"keywords":123,"publishedAt":35},"01M6DTP28JTWQK3HHXDNQV8BBV","fake-domains","Test fixture for the golden deployment in tests\u002Fentry. Load never; it has no script.","https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Ftests\u002Fentry\u002Ffake_skills\u002Fspatial\u002Ffake-domains\u002FSKILL.md",[],[124,125,126,113,114,127,128],"domains","fake domains","deployment","never","test",{"skillNo":130,"name":131,"nameZh":6,"description":132,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":133,"categories":134,"keywords":136,"publishedAt":35},"01M6DTNZ4AMWKTME1T18K5C643","replace-me-skill","Load when copying this directory to bootstrap a new OmicsClaw skill. Skip when an existing skill already covers the request.","https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Ftemplates\u002Fskill\u002FSKILL.md",[135],{"categoryNo":108,"categoryName":109,"taxonomyType":20,"taxonomyTypeDesc":21},[137,138,139,140,141,142,143,144,145],"me","replace me skill","template","directory","skill template","existing skill","new skill","bootstrap","scaffold",{"skillNo":147,"name":148,"nameZh":6,"description":149,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":150,"categories":151,"keywords":152,"publishedAt":35},"01M6DTNV63MTD0Q6YRC52F0B1Y","spatial-velocity","Load when estimating RNA velocity on a spatial AnnData with `layers[\"spliced\"]` + `layers[\"unspliced\"]` via scVelo (stochastic \u002F deterministic \u002F dynamical) or veloVI (deep generative). Skip when input lacks the spliced\u002Funspliced layers (must be quantified upstream by velocyto \u002F kb-python \u002F STARsolo); non-spatial scRNA velocity (use sc-velocity).","https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fspatial\u002Fspatial-velocity\u002FSKILL.md",[],[153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,28,170,171],"velocity","spatial velocity","Spatial","scvelo","input","starsolo","time","deep","RNA","kb-python","via","velocyto","rna-velocity","velovi","dynamics","upstream","kb","python","deterministic",{"skillNo":173,"name":174,"nameZh":6,"description":175,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":176,"categories":177,"keywords":178,"publishedAt":35},"01M6DTNPMR227NAT8QFY620YDW","spatial-trajectory","Load when inferring pseudotime \u002F lineage trajectories on a preprocessed spatial AnnData via DPT (default — diffusion pseudotime), CellRank (terminal-state + fate-probability), or Palantir (waypoint branch probabilities). Skip when the data has spliced\u002Funspliced layers and you want velocity-driven dynamics (use spatial-velocity); non-spatial scRNA pseudotime (use sc-pseudotime).","https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fspatial\u002Fspatial-trajectory\u002FSKILL.md",[],[155,179,180,181,182,183,184,185,163,186,187,188,189,190,153,191,28,192,193,194],"trajectory","spatial trajectory","state","terminal","lineage","diffusion","cellrank","palantir","dpt","pseudotime","probability","cell","default","branch","anndata","data",{"skillNo":196,"name":197,"nameZh":6,"description":198,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":199,"categories":200,"keywords":201,"publishedAt":35},"01M6DTNJEYFT33P84DGHDNXW95","spatial-statistics","Load when running spatial autocorrelation \u002F hotspot \u002F co-occurrence \u002F neighbourhood-enrichment \u002F Ripley K stats on a clustered spatial AnnData via squidpy. Skip when ranking spatially variable genes (use spatial-genes); tissue domain detection (use spatial-domains).","https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fspatial\u002Fspatial-statistics\u002FSKILL.md",[],[202,203,155,163,204,205,206,207,208,209,124,210,211,212,213,28,193,214,23,215],"spatial statistics","statistics","nhood-enrichment","co-occurrence","ripley","geary","moran","neighbourhood","ranking","autocorrelation","local","domain","detection","stats"]