yaml-configuration-loading-yaml-in-python

Sub-skill of yaml-configuration: Loading YAML in Python (+3).

5 stars

Best use case

yaml-configuration-loading-yaml-in-python is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Sub-skill of yaml-configuration: Loading YAML in Python (+3).

Teams using yaml-configuration-loading-yaml-in-python should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/loading-yaml-in-python/SKILL.md --create-dirs "https://raw.githubusercontent.com/vamseeachanta/workspace-hub/main/.agents/skills/_archive/data/scientific/yaml-configuration/loading-yaml-in-python/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/loading-yaml-in-python/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How yaml-configuration-loading-yaml-in-python Compares

Feature / Agentyaml-configuration-loading-yaml-in-pythonStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Sub-skill of yaml-configuration: Loading YAML in Python (+3).

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

# Loading YAML in Python (+3)

## Loading YAML in Python


```python
import yaml
from pathlib import Path

def load_config(config_file: str) -> dict:
    """Load YAML configuration file."""
    with open(config_file, 'r') as f:
        config = yaml.safe_load(f)
    return config


*See sub-skills for full details.*

## Writing YAML from Python


```python
import yaml

def save_config(config: dict, output_file: str):
    """Save configuration to YAML file."""
    with open(output_file, 'w') as f:
        yaml.dump(config, f, default_flow_style=False, sort_keys=False)

# Create configuration
config = {

*See sub-skills for full details.*

## Validation


```python
import yaml
from jsonschema import validate, ValidationError

def validate_config(config_file: str, schema_file: str) -> bool:
    """Validate YAML against JSON schema."""
    with open(config_file) as f:
        config = yaml.safe_load(f)

    with open(schema_file) as f:

*See sub-skills for full details.*

## Merging Configs


```python
def merge_configs(base_config: dict, override_config: dict) -> dict:
    """Deep merge two configuration dictionaries."""
    import copy

    result = copy.deepcopy(base_config)

    for key, value in override_config.items():
        if key in result and isinstance(result[key], dict) and isinstance(value, dict):
            result[key] = merge_configs(result[key], value)

*See sub-skills for full details.*

Related Skills

python-import-path-mismatch-debugging

5
from vamseeachanta/workspace-hub

Diagnose and fix ModuleNotFoundError when a package is installed but imports still fail due to environment/path mismatches

python-import-path-debugging

5
from vamseeachanta/workspace-hub

Diagnose ModuleNotFoundError when a package is installed but still fails to import

portable-baseline-configuration-pattern

5
from vamseeachanta/workspace-hub

Separate portable/universal config from machine-specific settings to enable safe template reuse across environments

python-debugpy

5
from vamseeachanta/workspace-hub

Debug Python: pdb REPL + debugpy remote (DAP).

orcaflex-yaml-gotchas

5
from vamseeachanta/workspace-hub

Production-proven OrcaFlex YAML traps and solutions covering dormant properties, boolean mismatches, section ordering, Pydantic integration, and section name aliases.

hermes-local-configuration

5
from vamseeachanta/workspace-hub

Class-level Hermes local configuration and setup workflows, including config audit gotchas and Windows installation.

yaml-workflow-executor

5
from vamseeachanta/workspace-hub

Execute configuration-driven analysis workflows from YAML files. Use for running analysis pipelines, data processing tasks, and automation workflows defined in YAML configuration.

python-project-template

5
from vamseeachanta/workspace-hub

Generate standardized Python project structure with pyproject.toml, UV environment, pytest configuration, and workspace-hub compliance. Creates production-ready project scaffolding.

xlsx-to-python

5
from vamseeachanta/workspace-hub

Convert Excel calculation spreadsheets to Python code — extract formulas, build dependency graphs, generate pytest tests using cell values as assertions, and produce dark-intelligence archive YAMLs.

excel-workbook-to-python-v2

5
from vamseeachanta/workspace-hub

Convert engineering Excel workbooks to Python code using Codex Desktop cowork on Windows. Proven superior quality vs Linux openpyxl extraction (24 vs 7 functions, 81 vs 53 tests). Validated on Ballymore jumper installation analysis.

mkdocs-integration-with-python-package

5
from vamseeachanta/workspace-hub

Sub-skill of mkdocs: Integration with Python Package (+2).

mkdocs-8-plugin-configuration

5
from vamseeachanta/workspace-hub

Sub-skill of mkdocs: 8. Plugin Configuration (+4).