[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M736JP2H0JWRKYAFRS9J1M08":3,"skill-same:01M736JP2H0JWRKYAFRS9J1M08":59},{"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":18,"linkOnly":19,"markdownContent":20,"markdownBody":21,"frontMatter":22,"refName":37,"commitSha":38,"skillDirectory":39,"forksCount":40,"repositoryHtmlUrl":41,"repositoryHomepageUrl":6,"ownerHtmlUrl":42,"ownerBlogUrl":43,"ownerDescription":6,"updatedAt":44,"install":45,"resources":58},"01M736JP2H0JWRKYAFRS9J1M08","annotate-source-files",null,"Add PUT workflow annotations to source files using the correct language-specific comment prefix. Covers annotation syntax, skeleton generation via put_generate(), multiline annotations, .internal variables, and validation. Supports 30+ languages with automatic comment prefix detection. Use after analyzing a codebase and having an annotation plan, when adding workflow documentation to new or existing source files, or when documenting data pipelines, ETL processes, or multi-step computations.","roohe\u002Fagentic-super-skills","roohe","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F99054084?v=4","01M734WCDFP6RZVT5CNM00QR26","01M734WCE4BD0T4NZS5PCV9V5F",10,"MIT","https:\u002F\u002Fgithub.com\u002Froohe\u002Fagentic-super-skills\u002Fblob\u002Fmaster\u002Fskills_library\u002Fannotate-source-files\u002FSKILL.md",[],[],"2026-11-11 15:11:14",false,"---\nname: annotate-source-files\nlocale: caveman-lite\nsource_locale: en\nsource_commit: 82c77053\ntranslator: \"Julius Brussee homage — caveman\"\ntranslation_date: \"2026-04-19\"\ndescription: >\n  Add PUT workflow annotations to source files using the correct\n  language-specific comment prefix. Covers annotation syntax, skeleton\n  generation via put_generate(), multiline annotations, .internal\n  variables, and validation. Supports 30+ languages with automatic\n  comment prefix detection. Use after analyzing a codebase and having an\n  annotation plan, when adding workflow documentation to new or existing\n  source files, or when documenting data pipelines, ETL processes, or\n  multi-step computations.\nlicense: MIT\nallowed-tools: Read Write Edit Bash Grep Glob\nmetadata:\n  author: Philipp Thoss\n  version: \"1.0\"\n  domain: workflow-visualization\n  complexity: intermediate\n  language: multi\n  tags: putior, annotation, workflow, comment-syntax, polyglot, documentation\n---\n\n# Annotate Source Files\n\nAdd PUT workflow annotations to source files so putior can extract structured workflow data and generate Mermaid diagrams.\n\n## When to Use\n\n- After analyzing a codebase with `analyze-codebase-workflow` and having an annotation plan\n- Adding workflow documentation to new or existing source files\n- Enriching auto-detected workflows with manual labels and connections\n- Documenting data pipelines, ETL processes, or multi-step computations\n\n## Inputs\n\n- **Required**: Source files to annotate\n- **Required**: Annotation plan or knowledge of the workflow steps\n- **Optional**: Style preference: single-line or multiline (default: single-line)\n- **Optional**: Whether to use `put_generate()` for skeleton generation (default: yes)\n\n## Procedure\n\n### Step 1: Determine Comment Prefix\n\nEach language has a specific comment prefix for PUT annotations. Use `get_comment_prefix()` to find the correct one.\n\n```r\nlibrary(putior)\n\n# Common prefixes\nget_comment_prefix(\"R\")    # \"#\"\nget_comment_prefix(\"py\")   # \"#\"\nget_comment_prefix(\"sql\")  # \"--\"\nget_comment_prefix(\"js\")   # \"\u002F\u002F\"\nget_comment_prefix(\"ts\")   # \"\u002F\u002F\"\nget_comment_prefix(\"go\")   # \"\u002F\u002F\"\nget_comment_prefix(\"rs\")   # \"\u002F\u002F\"\nget_comment_prefix(\"m\")    # \"%\"\nget_comment_prefix(\"lua\")  # \"--\"\n```\n\n**Got:** A string like `\"#\"`, `\"--\"`, `\"\u002F\u002F\"`, or `\"%\"`.\n\n> **Line and block comments:** putior detects annotations in both line comments (`\u002F\u002F`, `#`, `--`) and C-style block comments (`\u002F* *\u002F`, `\u002F** *\u002F`). For JS\u002FTS, both `\u002F\u002F` and `\u002F* *\u002F` blocks are scanned. Python triple-quote strings (`''' '''`) are **not** detected — use `#` for Python annotations.\n\n**If fail:** If the extension is not recognized, the file language may not be supported. Check `get_supported_extensions()` for the full list. For unsupported languages, use `#` as a conventional default.\n\n### Step 2: Generate Annotation Skeletons\n\nUse `put_generate()` to create annotation templates based on auto-detected I\u002FO.\n\n```r\n# Print suggestions to console\nput_generate(\".\u002Fsrc\u002Fetl\u002F\")\n\n# Single-line style (default)\nput_generate(\".\u002Fsrc\u002Fetl\u002F\", style = \"single\")\n\n# Multiline style for complex annotations\nput_generate(\".\u002Fsrc\u002Fetl\u002F\", style = \"multiline\")\n\n# Copy to clipboard for pasting\nput_generate(\".\u002Fsrc\u002Fetl\u002F\", output = \"clipboard\")\n```\n\nExample output for an R file:\n```r\n# put id:'extract_data', label:'Extract Customer Data', input:'customers.csv', output:'raw_data.internal'\n```\n\nExample output for SQL:\n```sql\n-- put id:'load_data', label:'Load Customer Table', output:'customers'\n```\n\n**Got:** One or more annotation comment lines per source file, pre-filled with detected function names and I\u002FO.\n\n**If fail:** If no suggestions are generated, the file may not contain recognizable I\u002FO patterns. Write annotations manually based on your understanding of the code.\n\n### Step 3: Refine Annotations\n\nEdit the generated skeletons to add accurate labels, connections, and metadata.\n\n**Annotation syntax reference:**\n\n```\n\u003Cprefix> put id:'unique_id', label:'Human Readable Label', input:'file1.csv, file2.rds', output:'result.parquet, summary.internal'\n```\n\nFields:\n- `id` (required): Unique identifier, used for node connections\n- `label` (required): Human-readable description shown in diagram\n- `input`: Comma-separated list of input files or variables\n- `output`: Comma-separated list of output files or variables\n- `.internal` extension: Marks in-memory variables (not persisted between scripts)\n- `node_type`: Controls Mermaid node shape and class styling. Values:\n  - `\"input\"` — stadium shape `([...])` for data sources and configuration\n  - `\"output\"` — subroutine shape `[[...]]` for generated artifacts\n  - `\"process\"` — rectangle `[...]` for processing steps (default)\n  - `\"decision\"` — diamond `{...}` for conditional logic\n  - `\"start\"` \u002F `\"end\"` — stadium shape `([...])` for entry\u002Fterminal nodes\n\nExample with `node_type`:\n```r\n# put id:'config', label:'Load Config', node_type:'input', output:'config.internal'\n# put id:'transform', label:'Apply Rules', node_type:'process', input:'config.internal', output:'result.rds'\n# put id:'report', label:'Generate Report', node_type:'output', input:'result.rds'\n```\n\n**Multiline syntax** (for complex annotations):\n```r\n# put id:'complex_step', \\\n#   label:'Multi-line Label', \\\n#   input:'data.csv, config.yaml', \\\n#   output:'result.parquet'\n```\n\n**Block comment syntax** (for `\u002F\u002F`-prefix languages only: JS, TS, Go, Rust, C, C++, Java, etc.):\n\nLanguages that use `\u002F\u002F` for line comments also support PUT annotations inside `\u002F* *\u002F` and `\u002F** *\u002F` block comments. Use `* put` as the line prefix inside the block body:\n\n```javascript\n\u002F* put id:'init', label:'Initialize Config', output:'config.internal' *\u002F\n\n\u002F**\n * put id:'process', \\\n *   label:'Process Records', \\\n *   input:'config.internal, records.json', \\\n *   output:'results.json'\n *\u002F\nfunction processRecords(config, records) {\n  \u002F\u002F ...\n}\n```\n\nJSDoc-style annotations are particularly useful when documenting workflow steps alongside API documentation:\n\n```typescript\n\u002F**\n * Transform raw sensor data into normalized readings.\n * put id:'normalize', label:'Normalize Sensor Data', input:'raw_readings.json', output:'normalized.parquet'\n *\u002F\nexport function normalizeSensorData(readings: SensorReading[]): NormalizedData {\n  \u002F\u002F ...\n}\n```\n\n> **Note:** Block comment annotations are **not** supported for `#`-prefix languages (R, Python, Shell) or `--`-prefix languages (SQL, Lua). Use only line comments for those languages. Block-originated annotations do not support backslash continuation across lines.\n\n**Cross-file data flow** (connecting scripts via file-based I\u002FO):\n```r\n# Script 1: extract.R\n# put id:'extract', label:'Extract Data', output:'raw_data.internal, raw_data.rds'\ndata \u003C- read.csv(\"source.csv\")\nsaveRDS(data, \"raw_data.rds\")\n\n# Script 2: transform.R\n# put id:'transform', label:'Transform Data', input:'raw_data.rds', output:'clean_data.parquet'\ndata \u003C- readRDS(\"raw_data.rds\")\narrow::write_parquet(clean, \"clean_data.parquet\")\n```\n\n**Got:** Annotations refined with accurate IDs, labels, and I\u002FO fields that reflect actual data flow.\n\n**If fail:** If unsure about I\u002FO, use `.internal` extension for in-memory intermediates and explicit file names for persisted data.\n\n### Step 4: Insert Annotations into Files\n\nPlace annotations at the top of each file or immediately above the relevant code block.\n\n**Placement conventions:**\n1. **File-level annotation**: Place at the top of the file, after any shebang line or file header comment\n2. **Block-level annotation**: Place immediately above the code block it describes\n3. **Multiple annotations per file**: Use for files with distinct workflow phases\n\nExample placement in an R file:\n```r\n#!\u002Fusr\u002Fbin\u002Fenv Rscript\n# ETL Extract Script\n#\n# put id:'read_source', label:'Read Source Data', input:'raw_data.csv', output:'df.internal'\n\ndf \u003C- read.csv(\"raw_data.csv\")\n\n# put id:'clean_data', label:'Clean and Validate', input:'df.internal', output:'clean.rds'\n\ndf_clean \u003C- df[complete.cases(df), ]\nsaveRDS(df_clean, \"clean.rds\")\n```\n\nUse the Edit tool to insert annotations into existing files without disturbing surrounding code.\n\n**Got:** Annotations inserted at appropriate locations in each source file.\n\n**If fail:** If annotations break syntax highlighting in the editor, ensure the comment prefix is correct for the language. PUT annotations are standard comments and should not affect code execution.\n\n### Step 5: Validate Annotations\n\nRun putior's validation to check annotation syntax and connectivity.\n\n```r\n# Scan annotated files\nworkflow \u003C- put(\".\u002Fsrc\u002F\", validate = TRUE)\n\n# Check for validation issues\nprint(workflow)\ncat(sprintf(\"Total nodes: %d\\n\", nrow(workflow)))\n\n# Verify connections by checking input\u002Foutput overlap\ninputs \u003C- unlist(strsplit(workflow$input, \",\\\\s*\"))\noutputs \u003C- unlist(strsplit(workflow$output, \",\\\\s*\"))\nconnected \u003C- intersect(inputs, outputs)\ncat(sprintf(\"Connected data flows: %d\\n\", length(connected)))\n\n# Generate diagram to visually inspect\ncat(put_diagram(workflow, theme = \"github\", show_source_info = TRUE))\n\n# Merge with auto-detected for maximum coverage\nmerged \u003C- put_merge(\".\u002Fsrc\u002F\", merge_strategy = \"supplement\")\ncat(put_diagram(merged, theme = \"github\"))\n```\n\n**Got:** All annotations parse without errors. The diagram shows a connected workflow. `put_merge()` fills in any gaps from auto-detection.\n\n**If fail:** Common validation issues:\n- Missing closing quote: `id:'name` → `id:'name'`\n- Using double quotes inside: `id:\"name\"` → `id:'name'`\n- Duplicate IDs across files: each `id` must be unique across the entire scanned directory\n- Backslash continuation on the wrong line: the `\\` must be the last character before newline\n\n## Validation\n\n- [ ] Every annotated file has syntactically valid PUT annotations\n- [ ] `put(\".\u002Fsrc\u002F\")` returns a data frame with the expected number of nodes\n- [ ] No duplicate `id` values across the scanned directory\n- [ ] `put_diagram()` produces a connected flowchart (not all isolated nodes)\n- [ ] Multiline annotations (if used) parse correctly with backslash continuation\n- [ ] `.internal` variables appear only as outputs, never as cross-file inputs\n- [ ] Files excluded via `exclude` parameter do not appear in the workflow (e.g., `put(\".\u002Fsrc\u002F\", exclude = \"test_\")` skips test helpers)\n\n## Pitfalls\n\n- **Quote nesting errors**: PUT annotations use single quotes: `id:'name'`. Double quotes cause parsing issues when the annotation is inside a string context.\n- **Duplicate IDs**: Every `id` must be globally unique within the scanned scope. Use a naming convention like `\u003Cscript>_\u003Cstep>` (e.g., `extract_read`, `transform_clean`).\n- **.internal as cross-file input**: `.internal` variables exist only during script execution. To pass data between scripts, use a persisted file format (`.rds`, `.csv`, `.parquet`) as the output of one script and input of the next.\n- **Missing connections**: If the diagram shows disconnected nodes, check that output filenames in one annotation exactly match input filenames in another (including extensions).\n- **Wrong comment prefix**: Using `#` in a SQL file or `\u002F\u002F` in Python will cause the annotation to be treated as code, not a comment. Always verify with `get_comment_prefix()`.\n- **Forgetting multiline continuation**: When using multiline annotations, every continued line must end with `\\` and the next line must start with the comment prefix.\n- **Python triple-quote strings**: putior does not scan Python triple-quote strings (`''' '''`, `\"\"\" \"\"\"`). Always use `#` for Python PUT annotations.\n- **Meta-pipeline annotations**: If you annotate a build script that also scans for annotations (e.g., a script that calls `put()` and `put_diagram()`), the script's own annotations will appear in the generated diagram. Either exclude the file from scanning (see `generate-workflow-diagram` Common Pitfalls) or avoid placing PUT annotations in the build script itself.\n\n## Related Skills\n\n- `analyze-codebase-workflow` — prerequisite: produces the annotation plan this skill follows\n- `generate-workflow-diagram` — next step: generate the final diagram from annotations\n- `install-putior` — putior must be installed before annotating\n- `configure-putior-mcp` — MCP tools provide interactive annotation assistance\n","# Annotate Source Files\n\nAdd PUT workflow annotations to source files so putior can extract structured workflow data and generate Mermaid diagrams.\n\n## When to Use\n\n- After analyzing a codebase with `analyze-codebase-workflow` and having an annotation plan\n- Adding workflow documentation to new or existing source files\n- Enriching auto-detected workflows with manual labels and connections\n- Documenting data pipelines, ETL processes, or multi-step computations\n\n## Inputs\n\n- **Required**: Source files to annotate\n- **Required**: Annotation plan or knowledge of the workflow steps\n- **Optional**: Style preference: single-line or multiline (default: single-line)\n- **Optional**: Whether to use `put_generate()` for skeleton generation (default: yes)\n\n## Procedure\n\n### Step 1: Determine Comment Prefix\n\nEach language has a specific comment prefix for PUT annotations. Use `get_comment_prefix()` to find the correct one.\n\n```r\nlibrary(putior)\n\n# Common prefixes\nget_comment_prefix(\"R\")    # \"#\"\nget_comment_prefix(\"py\")   # \"#\"\nget_comment_prefix(\"sql\")  # \"--\"\nget_comment_prefix(\"js\")   # \"\u002F\u002F\"\nget_comment_prefix(\"ts\")   # \"\u002F\u002F\"\nget_comment_prefix(\"go\")   # \"\u002F\u002F\"\nget_comment_prefix(\"rs\")   # \"\u002F\u002F\"\nget_comment_prefix(\"m\")    # \"%\"\nget_comment_prefix(\"lua\")  # \"--\"\n```\n\n**Got:** A string like `\"#\"`, `\"--\"`, `\"\u002F\u002F\"`, or `\"%\"`.\n\n> **Line and block comments:** putior detects annotations in both line comments (`\u002F\u002F`, `#`, `--`) and C-style block comments (`\u002F* *\u002F`, `\u002F** *\u002F`). For JS\u002FTS, both `\u002F\u002F` and `\u002F* *\u002F` blocks are scanned. Python triple-quote strings (`''' '''`) are **not** detected — use `#` for Python annotations.\n\n**If fail:** If the extension is not recognized, the file language may not be supported. Check `get_supported_extensions()` for the full list. For unsupported languages, use `#` as a conventional default.\n\n### Step 2: Generate Annotation Skeletons\n\nUse `put_generate()` to create annotation templates based on auto-detected I\u002FO.\n\n```r\n# Print suggestions to console\nput_generate(\".\u002Fsrc\u002Fetl\u002F\")\n\n# Single-line style (default)\nput_generate(\".\u002Fsrc\u002Fetl\u002F\", style = \"single\")\n\n# Multiline style for complex annotations\nput_generate(\".\u002Fsrc\u002Fetl\u002F\", style = \"multiline\")\n\n# Copy to clipboard for pasting\nput_generate(\".\u002Fsrc\u002Fetl\u002F\", output = \"clipboard\")\n```\n\nExample output for an R file:\n```r\n# put id:'extract_data', label:'Extract Customer Data', input:'customers.csv', output:'raw_data.internal'\n```\n\nExample output for SQL:\n```sql\n-- put id:'load_data', label:'Load Customer Table', output:'customers'\n```\n\n**Got:** One or more annotation comment lines per source file, pre-filled with detected function names and I\u002FO.\n\n**If fail:** If no suggestions are generated, the file may not contain recognizable I\u002FO patterns. Write annotations manually based on your understanding of the code.\n\n### Step 3: Refine Annotations\n\nEdit the generated skeletons to add accurate labels, connections, and metadata.\n\n**Annotation syntax reference:**\n\n```\n\u003Cprefix> put id:'unique_id', label:'Human Readable Label', input:'file1.csv, file2.rds', output:'result.parquet, summary.internal'\n```\n\nFields:\n- `id` (required): Unique identifier, used for node connections\n- `label` (required): Human-readable description shown in diagram\n- `input`: Comma-separated list of input files or variables\n- `output`: Comma-separated list of output files or variables\n- `.internal` extension: Marks in-memory variables (not persisted between scripts)\n- `node_type`: Controls Mermaid node shape and class styling. Values:\n  - `\"input\"` — stadium shape `([...])` for data sources and configuration\n  - `\"output\"` — subroutine shape `[[...]]` for generated artifacts\n  - `\"process\"` — rectangle `[...]` for processing steps (default)\n  - `\"decision\"` — diamond `{...}` for conditional logic\n  - `\"start\"` \u002F `\"end\"` — stadium shape `([...])` for entry\u002Fterminal nodes\n\nExample with `node_type`:\n```r\n# put id:'config', label:'Load Config', node_type:'input', output:'config.internal'\n# put id:'transform', label:'Apply Rules', node_type:'process', input:'config.internal', output:'result.rds'\n# put id:'report', label:'Generate Report', node_type:'output', input:'result.rds'\n```\n\n**Multiline syntax** (for complex annotations):\n```r\n# put id:'complex_step', \\\n#   label:'Multi-line Label', \\\n#   input:'data.csv, config.yaml', \\\n#   output:'result.parquet'\n```\n\n**Block comment syntax** (for `\u002F\u002F`-prefix languages only: JS, TS, Go, Rust, C, C++, Java, etc.):\n\nLanguages that use `\u002F\u002F` for line comments also support PUT annotations inside `\u002F* *\u002F` and `\u002F** *\u002F` block comments. Use `* put` as the line prefix inside the block body:\n\n```javascript\n\u002F* put id:'init', label:'Initialize Config', output:'config.internal' *\u002F\n\n\u002F**\n * put id:'process', \\\n *   label:'Process Records', \\\n *   input:'config.internal, records.json', \\\n *   output:'results.json'\n *\u002F\nfunction processRecords(config, records) {\n  \u002F\u002F ...\n}\n```\n\nJSDoc-style annotations are particularly useful when documenting workflow steps alongside API documentation:\n\n```typescript\n\u002F**\n * Transform raw sensor data into normalized readings.\n * put id:'normalize', label:'Normalize Sensor Data', input:'raw_readings.json', output:'normalized.parquet'\n *\u002F\nexport function normalizeSensorData(readings: SensorReading[]): NormalizedData {\n  \u002F\u002F ...\n}\n```\n\n> **Note:** Block comment annotations are **not** supported for `#`-prefix languages (R, Python, Shell) or `--`-prefix languages (SQL, Lua). Use only line comments for those languages. Block-originated annotations do not support backslash continuation across lines.\n\n**Cross-file data flow** (connecting scripts via file-based I\u002FO):\n```r\n# Script 1: extract.R\n# put id:'extract', label:'Extract Data', output:'raw_data.internal, raw_data.rds'\ndata \u003C- read.csv(\"source.csv\")\nsaveRDS(data, \"raw_data.rds\")\n\n# Script 2: transform.R\n# put id:'transform', label:'Transform Data', input:'raw_data.rds', output:'clean_data.parquet'\ndata \u003C- readRDS(\"raw_data.rds\")\narrow::write_parquet(clean, \"clean_data.parquet\")\n```\n\n**Got:** Annotations refined with accurate IDs, labels, and I\u002FO fields that reflect actual data flow.\n\n**If fail:** If unsure about I\u002FO, use `.internal` extension for in-memory intermediates and explicit file names for persisted data.\n\n### Step 4: Insert Annotations into Files\n\nPlace annotations at the top of each file or immediately above the relevant code block.\n\n**Placement conventions:**\n1. **File-level annotation**: Place at the top of the file, after any shebang line or file header comment\n2. **Block-level annotation**: Place immediately above the code block it describes\n3. **Multiple annotations per file**: Use for files with distinct workflow phases\n\nExample placement in an R file:\n```r\n#!\u002Fusr\u002Fbin\u002Fenv Rscript\n# ETL Extract Script\n#\n# put id:'read_source', label:'Read Source Data', input:'raw_data.csv', output:'df.internal'\n\ndf \u003C- read.csv(\"raw_data.csv\")\n\n# put id:'clean_data', label:'Clean and Validate', input:'df.internal', output:'clean.rds'\n\ndf_clean \u003C- df[complete.cases(df), ]\nsaveRDS(df_clean, \"clean.rds\")\n```\n\nUse the Edit tool to insert annotations into existing files without disturbing surrounding code.\n\n**Got:** Annotations inserted at appropriate locations in each source file.\n\n**If fail:** If annotations break syntax highlighting in the editor, ensure the comment prefix is correct for the language. PUT annotations are standard comments and should not affect code execution.\n\n### Step 5: Validate Annotations\n\nRun putior's validation to check annotation syntax and connectivity.\n\n```r\n# Scan annotated files\nworkflow \u003C- put(\".\u002Fsrc\u002F\", validate = TRUE)\n\n# Check for validation issues\nprint(workflow)\ncat(sprintf(\"Total nodes: %d\\n\", nrow(workflow)))\n\n# Verify connections by checking input\u002Foutput overlap\ninputs \u003C- unlist(strsplit(workflow$input, \",\\\\s*\"))\noutputs \u003C- unlist(strsplit(workflow$output, \",\\\\s*\"))\nconnected \u003C- intersect(inputs, outputs)\ncat(sprintf(\"Connected data flows: %d\\n\", length(connected)))\n\n# Generate diagram to visually inspect\ncat(put_diagram(workflow, theme = \"github\", show_source_info = TRUE))\n\n# Merge with auto-detected for maximum coverage\nmerged \u003C- put_merge(\".\u002Fsrc\u002F\", merge_strategy = \"supplement\")\ncat(put_diagram(merged, theme = \"github\"))\n```\n\n**Got:** All annotations parse without errors. The diagram shows a connected workflow. `put_merge()` fills in any gaps from auto-detection.\n\n**If fail:** Common validation issues:\n- Missing closing quote: `id:'name` → `id:'name'`\n- Using double quotes inside: `id:\"name\"` → `id:'name'`\n- Duplicate IDs across files: each `id` must be unique across the entire scanned directory\n- Backslash continuation on the wrong line: the `\\` must be the last character before newline\n\n## Validation\n\n- [ ] Every annotated file has syntactically valid PUT annotations\n- [ ] `put(\".\u002Fsrc\u002F\")` returns a data frame with the expected number of nodes\n- [ ] No duplicate `id` values across the scanned directory\n- [ ] `put_diagram()` produces a connected flowchart (not all isolated nodes)\n- [ ] Multiline annotations (if used) parse correctly with backslash continuation\n- [ ] `.internal` variables appear only as outputs, never as cross-file inputs\n- [ ] Files excluded via `exclude` parameter do not appear in the workflow (e.g., `put(\".\u002Fsrc\u002F\", exclude = \"test_\")` skips test helpers)\n\n## Pitfalls\n\n- **Quote nesting errors**: PUT annotations use single quotes: `id:'name'`. Double quotes cause parsing issues when the annotation is inside a string context.\n- **Duplicate IDs**: Every `id` must be globally unique within the scanned scope. Use a naming convention like `\u003Cscript>_\u003Cstep>` (e.g., `extract_read`, `transform_clean`).\n- **.internal as cross-file input**: `.internal` variables exist only during script execution. To pass data between scripts, use a persisted file format (`.rds`, `.csv`, `.parquet`) as the output of one script and input of the next.\n- **Missing connections**: If the diagram shows disconnected nodes, check that output filenames in one annotation exactly match input filenames in another (including extensions).\n- **Wrong comment prefix**: Using `#` in a SQL file or `\u002F\u002F` in Python will cause the annotation to be treated as code, not a comment. Always verify with `get_comment_prefix()`.\n- **Forgetting multiline continuation**: When using multiline annotations, every continued line must end with `\\` and the next line must start with the comment prefix.\n- **Python triple-quote strings**: putior does not scan Python triple-quote strings (`''' '''`, `\"\"\" \"\"\"`). Always use `#` for Python PUT annotations.\n- **Meta-pipeline annotations**: If you annotate a build script that also scans for annotations (e.g., a script that calls `put()` and `put_diagram()`), the script's own annotations will appear in the generated diagram. Either exclude the file from scanning (see `generate-workflow-diagram` Common Pitfalls) or avoid placing PUT annotations in the build script itself.\n\n## Related Skills\n\n- `analyze-codebase-workflow` — prerequisite: produces the annotation plan this skill follows\n- `generate-workflow-diagram` — next step: generate the final diagram from annotations\n- `install-putior` — putior must be installed before annotating\n- `configure-putior-mcp` — MCP tools provide interactive annotation assistance\n",{"name":5,"locale":23,"license":14,"metadata":24,"translator":31,"description":32,"allowed-tools":33,"source_commit":34,"source_locale":35,"translation_date":36},"caveman-lite",{"tags":25,"author":26,"domain":27,"version":28,"language":29,"complexity":30},"putior, annotation, workflow, comment-syntax, polyglot, documentation","Philipp Thoss","workflow-visualization","1.0","multi","intermediate","Julius Brussee homage — caveman","Add PUT workflow annotations to source files using the correct language-specific comment prefix. Covers annotation syntax, skeleton generation via put_generate(), multiline annotations, .internal variables, and validation. Supports 30+ languages with automatic comment prefix detection. Use after analyzing a codebase and having an annotation plan, when adding workflow documentation to new or existing source files, or when documenting data pipelines, ETL processes, or multi-step computations.\n","Read Write Edit Bash Grep Glob","82c77053","en","2026-04-19","master","f483e54f3ad5f202a77d45f2e57f8d970b71195f","skills_library\u002Fannotate-source-files",2,"https:\u002F\u002Fgithub.com\u002Froohe\u002Fagentic-super-skills","https:\u002F\u002Fgithub.com\u002Froohe","yoou.link","2026-05-19 15:56:07",{"source":8,"skillName":5,"commands":46,"prompt":56,"zipAvailable":57},[47,50,53],{"tool":48,"command":49},"npx","npx skills add roohe\u002Fagentic-super-skills --skill annotate-source-files",{"tool":51,"command":52},"bunx","bunx skills add roohe\u002Fagentic-super-skills --skill annotate-source-files",{"tool":54,"command":55},"pnpm","pnpm dlx skills add roohe\u002Fagentic-super-skills --skill annotate-source-files","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Froohe\u002Fagentic-super-skills\u002Fblob\u002Fmaster\u002Fskills_library\u002Fannotate-source-files\u002FSKILL.md",true,[],[60,67,74,81,88,95],{"skillNo":61,"name":62,"nameZh":6,"description":63,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":64,"categories":65,"keywords":66,"publishedAt":18},"01M73D865CZME2FCMKA4PQM348","zarr-python","Chunked N-D arrays for cloud storage. Compressed arrays, parallel I\u002FO, S3\u002FGCS integration, NumPy\u002FDask\u002FXarray compatible, for large-scale scientific computing pipelines.","https:\u002F\u002Fgithub.com\u002Froohe\u002Fagentic-super-skills\u002Fblob\u002Fmaster\u002Fskills_library\u002Fzarr-python\u002FSKILL.md",[],[],{"skillNo":68,"name":69,"nameZh":6,"description":70,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":71,"categories":72,"keywords":73,"publishedAt":18},"01M73D7Z64J4ABWZJD7P44XBBF","youtube-downloader","Download and process YouTube content for research. Use when: downloading competitor videos for analysis; extracting audio for podcasts; getting transcripts for content repurposing; archiving webinars; research content curation","https:\u002F\u002Fgithub.com\u002Froohe\u002Fagentic-super-skills\u002Fblob\u002Fmaster\u002Fskills_library\u002Fyoutube-downloader\u002FSKILL.md",[],[],{"skillNo":75,"name":76,"nameZh":6,"description":77,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":78,"categories":79,"keywords":80,"publishedAt":18},"01M73D7K8778TGZV3GJFR3703D","yc-pitch-deck","Create a compelling startup pitch deck that follows the structure proven to raise billions from top investors. Master the YC and Sequoia formats that get founders funded. Use when: **Fundraising** to create investor pitch decks; **YC application** to structure your narrative; **Demo Day prep** to craft your 2-minute pitch; **Angel investors** to communicate your opportunity; **Partnership pitches** to structure compelling asks","https:\u002F\u002Fgithub.com\u002Froohe\u002Fagentic-super-skills\u002Fblob\u002Fmaster\u002Fskills_library\u002Fyc-pitch-deck\u002FSKILL.md",[],[],{"skillNo":82,"name":83,"nameZh":6,"description":84,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":85,"categories":86,"keywords":87,"publishedAt":18},"01M73D70KJSE0E8Z28YMNNRT04","x-twitter-scraper","Use when the user needs X (Twitter) data or confirmation-gated X actions through Xquik: tweet search, user lookup, follower extraction, media download, monitoring, webhooks, MCP, SDKs, posting, likes, DMs, and profile updates. Requires a Xquik API key. Never ask for X login material.","https:\u002F\u002Fgithub.com\u002Froohe\u002Fagentic-super-skills\u002Fblob\u002Fmaster\u002Fskills_library\u002Fx-twitter-scraper\u002FSKILL.md",[],[],{"skillNo":89,"name":90,"nameZh":6,"description":91,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":92,"categories":93,"keywords":94,"publishedAt":18},"01M73D6ED01GV077R7K4NZNFZJ","write-vignette","Create R package vignettes using R Markdown or Quarto. Covers vignette setup, YAML configuration, code chunk options, building and testing, and CRAN requirements for vignettes. Use when adding a Getting Started tutorial, documenting complex workflows spanning multiple functions, creating domain-specific guides, or when CRAN submission requires user-facing documentation beyond function help pages.","https:\u002F\u002Fgithub.com\u002Froohe\u002Fagentic-super-skills\u002Fblob\u002Fmaster\u002Fskills_library\u002Fwrite-vignette\u002FSKILL.md",[],[],{"skillNo":96,"name":97,"nameZh":6,"description":98,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":99,"categories":100,"keywords":101,"publishedAt":18},"01M73D69YJR0BK3NFHE0CYG3EF","write-validation-documentation","Write IQ\u002FOQ\u002FPQ validation documentation for computerized systems in regulated environments. Covers protocols, reports, test scripts, deviation handling, and approval workflows. Use when validating R or other software for regulated use, preparing for a regulatory audit, documenting qualification of computing environments, or creating and updating validation protocols and reports for new or re-qualified systems.","https:\u002F\u002Fgithub.com\u002Froohe\u002Fagentic-super-skills\u002Fblob\u002Fmaster\u002Fskills_library\u002Fwrite-validation-documentation\u002FSKILL.md",[],[]]