[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6DTEMHD3EXD7GMMAWH4EPVN":3,"skill-same:01M6DTEMHD3EXD7GMMAWH4EPVN":95},{"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":17,"publishedAt":30,"linkOnly":31,"markdownContent":32,"markdownBody":33,"frontMatter":34,"refName":37,"commitSha":38,"skillDirectory":39,"forksCount":40,"repositoryHtmlUrl":41,"repositoryHomepageUrl":42,"ownerHtmlUrl":43,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":44,"install":45,"resources":58},"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",[],[18,19,20,21,22,23,24,25,26,27,28,29],"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":35,"trigger":36,"description":7},[19,18],"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":46,"prompt":56,"zipAvailable":57},[47,50,53],{"tool":48,"command":49},"npx","npx skills add TianGzlab\u002FOmicsClaw --skill proteomics-enrichment",{"tool":51,"command":52},"bunx","bunx skills add TianGzlab\u002FOmicsClaw --skill proteomics-enrichment",{"tool":54,"command":55},"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,[59,65,69,73,79,83,87,91],{"path":60,"resourceType":61,"resourceTypeDesc":62,"sizeBytes":63,"sourceHtmlUrl":64},"_api.py","SCRIPT","脚本",4097,"https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002F_api.py",{"path":66,"resourceType":61,"resourceTypeDesc":62,"sizeBytes":67,"sourceHtmlUrl":68},"examples\u002Fexample_step.py",555,"https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002Fexamples\u002Fexample_step.py",{"path":70,"resourceType":61,"resourceTypeDesc":62,"sizeBytes":71,"sourceHtmlUrl":72},"prot_enrichment.py",5866,"https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002Fprot_enrichment.py",{"path":74,"resourceType":75,"resourceTypeDesc":76,"sizeBytes":77,"sourceHtmlUrl":78},"references\u002Fmethodology.md","REFERENCE","参考文档",332,"https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002Freferences\u002Fmethodology.md",{"path":80,"resourceType":75,"resourceTypeDesc":76,"sizeBytes":81,"sourceHtmlUrl":82},"references\u002Foutput_contract.md",272,"https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002Freferences\u002Foutput_contract.md",{"path":84,"resourceType":75,"resourceTypeDesc":76,"sizeBytes":85,"sourceHtmlUrl":86},"references\u002Fparameters.md",307,"https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002Freferences\u002Fparameters.md",{"path":88,"resourceType":61,"resourceTypeDesc":62,"sizeBytes":89,"sourceHtmlUrl":90},"tests\u002Ftest_api.py",698,"https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002Ftests\u002Ftest_api.py",{"path":92,"resourceType":61,"resourceTypeDesc":62,"sizeBytes":93,"sourceHtmlUrl":94},"tests\u002Ftest_cli.py",969,"https:\u002F\u002Fgithub.com\u002FTianGzlab\u002FOmicsClaw\u002Fblob\u002Fmain\u002Fskills\u002Fproteomics\u002Fproteomics-enrichment\u002Ftests\u002Ftest_cli.py",[96,109,121,137,163,186],{"skillNo":97,"name":98,"nameZh":6,"description":99,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":100,"categories":101,"keywords":102,"publishedAt":30},"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",[],[103,104,105,106,107,23,108],"demo skill","demo","tests","fixture","fixture skill","environment",{"skillNo":110,"name":111,"nameZh":6,"description":112,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":113,"categories":114,"keywords":115,"publishedAt":30},"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",[],[116,117,118,105,106,119,120],"domains","fake domains","deployment","never","test",{"skillNo":122,"name":123,"nameZh":6,"description":124,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":125,"categories":126,"keywords":127,"publishedAt":30},"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",[],[128,129,130,131,132,133,134,135,136],"me","replace me skill","template","directory","skill template","existing skill","new skill","bootstrap","scaffold",{"skillNo":138,"name":139,"nameZh":6,"description":140,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":141,"categories":142,"keywords":143,"publishedAt":30},"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",[],[144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,23,161,162],"velocity","spatial velocity","Spatial","scvelo","input","starsolo","time","deep","RNA","kb-python","via","velocyto","rna-velocity","velovi","dynamics","upstream","kb","python","deterministic",{"skillNo":164,"name":165,"nameZh":6,"description":166,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":167,"categories":168,"keywords":169,"publishedAt":30},"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",[],[146,170,171,172,173,174,175,176,154,177,178,179,180,181,144,182,23,183,184,185],"trajectory","spatial trajectory","state","terminal","lineage","diffusion","cellrank","palantir","dpt","pseudotime","probability","cell","default","branch","anndata","data",{"skillNo":187,"name":188,"nameZh":6,"description":189,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":190,"categories":191,"keywords":192,"publishedAt":30},"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",[],[193,194,146,154,195,196,197,198,199,200,116,201,202,203,204,23,184,205,18,206],"spatial statistics","statistics","nhood-enrichment","co-occurrence","ripley","geary","moran","neighbourhood","ranking","autocorrelation","local","domain","detection","stats"]