[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6KHWH97VDFAK5KRCPQYHM6V":3,"skill-same:01M6KHWH97VDFAK5KRCPQYHM6V":64},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":22,"publishedAt":32,"linkOnly":33,"markdownContent":34,"markdownBody":35,"frontMatter":36,"refName":37,"commitSha":38,"skillDirectory":39,"forksCount":13,"repositoryHtmlUrl":40,"repositoryHomepageUrl":6,"ownerHtmlUrl":41,"ownerBlogUrl":6,"ownerDescription":42,"updatedAt":43,"install":44,"resources":57},"01M6KHWH97VDFAK5KRCPQYHM6V","audio-track-production",null,"End-to-end audio production workflow with stems, effects, archiving, and verification","AG064\u002FOpenSpace","AG064","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F184930299?v=4","01M6KHVFG7TB73NHX3RDYSTMH2","01M6KHVFMM7XA2PZA9Z83PHS3V",0,"MIT","https:\u002F\u002Fgithub.com\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fgdpval_bench\u002Fskills\u002Faudio-track-production\u002FSKILL.md",[17],{"categoryNo":18,"categoryName":19,"taxonomyType":20,"taxonomyTypeDesc":21},"01JBSEEDCAT000000000000016","图像与多媒体","SCENARIO","使用场景",[23,24,25,26,27,28,29,30,31],"Production","Audio","audio track production","track","workflow","verification","end","with","effects","2026-11-10 10:12:30",false,"---\nname: audio-track-production\ndescription: End-to-end audio production workflow with stems, effects, archiving, and verification\n---\n\n# Audio Track Production Workflow\n\nThis skill provides a reusable pattern for executing audio production tasks that require generating a master track and multiple stems, applying effects, and delivering verified outputs in an archive.\n\n## Overview\n\nFollow these steps in order to ensure consistent, verifiable audio production outputs:\n\n1. Verify reference audio file\n2. Calculate timing parameters from BPM and duration\n3. Generate stems with explicit sample type specifications\n4. Apply audio effects via signal processing\n5. Export master track and all stems\n6. Archive deliverables in zip format\n7. Verify all outputs match specifications\n\n## Step 1: Verify Reference File\n\nBefore processing, verify the reference audio file is valid and readable:\n\n```python\nimport soundfile as sf\n\n# Verify reference file exists and is readable\ninfo = sf.info('reference_track.wav')\nprint(f\"Sample rate: {info.samplerate} Hz\")\nprint(f\"Duration: {info.frames \u002F info.samplerate:.2f} seconds\")\nprint(f\"Channels: {info.channels}\")\nprint(f\"Subtype: {info.subtype}\")\n```\n\n## Step 2: Calculate Timing Parameters\n\nDerive timing for key section transitions from BPM and total duration:\n\n```python\ndef calculate_section_transitions(bpm, total_duration_sec, sections):\n    \"\"\"Calculate beat-aligned transition points for song sections.\"\"\"\n    beats_per_second = bpm \u002F 60.0\n    total_beats = total_duration_sec * beats_per_second\n    \n    # Distribute sections proportionally or by specified ratios\n    section_durations = {}\n    cumulative_time = 0\n    \n    for section_name, beat_count in sections.items():\n        duration = beat_count \u002F beats_per_second\n        section_durations[section_name] = {\n            'start': cumulative_time,\n            'end': cumulative_time + duration,\n            'beats': beat_count\n        }\n        cumulative_time += duration\n    \n    return section_durations\n\n# Example usage\nsections = calculate_section_transitions(\n    bpm=120,\n    total_duration_sec=137,\n    sections={'intro': 16, 'verse': 32, 'chorus': 32, 'bridge': 16, 'outro': 16}\n)\n```\n\n## Step 3: Generate Stems with Explicit Sample Type\n\nAlways specify sample type explicitly when generating stems to ensure bit-depth consistency:\n\n```python\nimport numpy as np\nimport soundfile as sf\n\ndef generate_stem(name, duration_sec, sample_rate, subtype='FLOAT'):\n    \"\"\"Generate a stem with explicit sample type specification.\"\"\"\n    frames = int(duration_sec * sample_rate)\n    \n    # Generate audio content (replace with actual synthesis\u002Fprocessing)\n    t = np.linspace(0, duration_sec, frames)\n    audio_data = np.sin(2 * np.pi * 440 * t)  # Example: 440Hz tone\n    \n    # Ensure proper data type for specified subtype\n    if subtype == 'FLOAT':\n        audio_data = audio_data.astype(np.float32)\n    elif subtype == 'PCM_24':\n        audio_data = np.clip(audio_data, -1, 1) * (2**23 - 1)\n        audio_data = audio_data.astype(np.int32)\n    \n    sf.write(\n        f'{name}_stem.wav',\n        audio_data,\n        sample_rate,\n        subtype=subtype,  # Explicit subtype for 24-bit float or other\n        format='WAV'\n    )\n    return audio_data\n\n# Example: Generate 4 stems at 48kHz, 137s, 24-bit float\nsample_rate = 48000\nduration = 137\nstems = ['guitars', 'synths', 'bridge', 'bass']\n\nfor stem_name in stems:\n    generate_stem(stem_name, duration, sample_rate, subtype='FLOAT')\n```\n\n## Step 4: Apply Effects via scipy.signal\n\nUse scipy.signal for applying audio effects and processing:\n\n```python\nfrom scipy import signal\nimport numpy as np\n\ndef apply_lowpass_filter(audio_data, sample_rate, cutoff_freq=5000):\n    \"\"\"Apply a lowpass filter using scipy.signal.\"\"\"\n    nyquist = sample_rate \u002F 2\n    normalized_cutoff = cutoff_freq \u002F nyquist\n    \n    # Design Butterworth filter\n    b, a = signal.butter(4, normalized_cutoff, btype='low')\n    \n    # Apply filter\n    filtered_data = signal.filtfilt(b, a, audio_data)\n    return filtered_data\n\ndef apply_reverb_simple(audio_data, sample_rate, decay=0.5, delay_samples=1000):\n    \"\"\"Apply simple reverb effect.\"\"\"\n    reverbed = np.copy(audio_data)\n    decay_factor = decay\n    \n    for i in range(1, 6):\n        delayed = np.zeros_like(audio_data)\n        if len(audio_data) > delay_samples * i:\n            delayed[delay_samples * i:] = audio_data[:-delay_samples * i]\n        reverbed += delayed * (decay_factor ** i)\n    \n    return np.clip(reverbed, -1, 1)\n\n# Apply effects to stems\nfor stem_name in stems:\n    data, sr = sf.read(f'{stem_name}_stem.wav')\n    processed = apply_lowpass_filter(data, sr, cutoff_freq=8000)\n    processed = apply_reverb_simple(processed, sr, decay=0.3)\n    sf.write(f'{stem_name}_stem_processed.wav', processed, sr, subtype='FLOAT')\n```\n\n## Step 5: Export Master and Stems\n\nExport all final deliverables with consistent specifications:\n\n```python\ndef export_audio(filepath, audio_data, sample_rate, subtype='FLOAT'):\n    \"\"\"Export audio file with verified specifications.\"\"\"\n    sf.write(\n        filepath,\n        audio_data,\n        sample_rate,\n        subtype=subtype,\n        format='WAV'\n    )\n    # Verify export\n    info = sf.info(filepath)\n    assert info.samplerate == sample_rate, f\"Sample rate mismatch: {info.samplerate}\"\n    assert info.subtype == subtype, f\"Subtype mismatch: {info.subtype}\"\n    print(f\"Exported: {filepath} ({info.duration:.2f}s, {info.samplerate}Hz)\")\n\n# Export master (mix of all stems)\nmaster_audio = np.zeros_like(stem_audio)  # Replace with actual mix\nfor stem_name in stems:\n    stem_data, _ = sf.read(f'{stem_name}_stem_processed.wav')\n    master_audio += stem_data * 0.5  # Simple mix with gain staging\n\nmaster_audio = np.clip(master_audio, -1, 1)\nexport_audio('master_track.wav', master_audio, sample_rate=48000, subtype='FLOAT')\n\n# Export final stems\nfor stem_name in stems:\n    stem_data, sr = sf.read(f'{stem_name}_stem_processed.wav')\n    export_audio(f'{stem_name}.wav', stem_data, sample_rate=48000, subtype='FLOAT')\n```\n\n## Step 6: Archive Deliverables\n\nPackage all outputs in a zip archive:\n\n```python\nimport zipfile\nimport os\n\ndef create_archive(archive_name, file_list):\n    \"\"\"Create zip archive of deliverables.\"\"\"\n    with zipfile.ZipFile(archive_name, 'w', zipfile.ZIP_DEFLATED) as zipf:\n        for filepath in file_list:\n            if os.path.exists(filepath):\n                zipf.write(filepath, os.path.basename(filepath))\n                print(f\"Added to archive: {filepath}\")\n            else:\n                print(f\"WARNING: File not found: {filepath}\")\n    \n    # Verify archive\n    with zipfile.ZipFile(archive_name, 'r') as zipf:\n        contents = zipf.namelist()\n        print(f\"Archive contains {len(contents)} files: {contents}\")\n    \n    return archive_name\n\n# Archive master and stems\ndeliverables = ['master_track.wav'] + [f'{stem}.wav' for stem in stems]\ncreate_archive('audio_deliverables.zip', deliverables)\n```\n\n## Step 7: Verify All Outputs\n\nFinal verification that all outputs match specifications:\n\n```python\ndef verify_outputs(expected_specs):\n    \"\"\"Verify all output files match expected specifications.\"\"\"\n    results = {'passed': 0, 'failed': 0, 'details': []}\n    \n    for filepath, specs in expected_specs.items():\n        if not os.path.exists(filepath):\n            results['failed'] += 1\n            results['details'].append(f\"MISSING: {filepath}\")\n            continue\n        \n        info = sf.info(filepath)\n        errors = []\n        \n        if specs.get('sample_rate') and info.samplerate != specs['sample_rate']:\n            errors.append(f\"sample_rate: expected {specs['sample_rate']}, got {info.samplerate}\")\n        \n        if specs.get('subtype') and info.subtype != specs['subtype']:\n            errors.append(f\"subtype: expected {specs['subtype']}, got {info.subtype}\")\n        \n        if specs.get('min_duration') and info.duration \u003C specs['min_duration']:\n            errors.append(f\"duration: expected >= {specs['min_duration']}s, got {info.duration}s\")\n        \n        if errors:\n            results['failed'] += 1\n            results['details'].append(f\"FAILED: {filepath} - {'; '.join(errors)}\")\n        else:\n            results['passed'] += 1\n            results['details'].append(f\"PASSED: {filepath} ({info.duration:.2f}s, {info.samplerate}Hz, {info.subtype})\")\n    \n    return results\n\n# Verification specifications\nexpected_specs = {\n    'master_track.wav': {'sample_rate': 48000, 'subtype': 'FLOAT', 'min_duration': 137},\n    'guitars.wav': {'sample_rate': 48000, 'subtype': 'FLOAT', 'min_duration': 137},\n    'synths.wav': {'sample_rate': 48000, 'subtype': 'FLOAT', 'min_duration': 137},\n    'bridge.wav': {'sample_rate': 48000, 'subtype': 'FLOAT', 'min_duration': 137},\n    'bass.wav': {'sample_rate': 48000, 'subtype': 'FLOAT', 'min_duration': 137},\n}\n\nverification = verify_outputs(expected_specs)\nprint(f\"\\nVerification: {verification['passed']} passed, {verification['failed']} failed\")\nfor detail in verification['details']:\n    print(detail)\n\nassert verification['failed'] == 0, \"Output verification failed!\"\n```\n\n## Complete Workflow Example\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"Complete audio production workflow execution.\"\"\"\n\nimport soundfile as sf\nimport numpy as np\nfrom scipy import signal\nimport zipfile\nimport os\n\n# Configuration\nSAMPLE_RATE = 48000\nDURATION = 137\nBPM = 120\nSTEM_NAMES = ['guitars', 'synths', 'bridge', 'bass']\nSUBTYPE = 'FLOAT'\n\ndef run_workflow():\n    # Step 1: Verify reference\n    ref_info = sf.info('reference.wav')\n    print(f\"Reference: {ref_info.duration}s @ {ref_info.samplerate}Hz\")\n    \n    # Step 2: Calculate timing\n    bpm = BPM\n    beats_per_sec = bpm \u002F 60\n    \n    # Step 3-4: Generate and process stems\n    for stem in STEM_NAMES:\n        frames = int(DURATION * SAMPLE_RATE)\n        t = np.linspace(0, DURATION, frames)\n        audio = np.sin(2 * np.pi * 220 * t)  # Example content\n        \n        # Apply effects\n        audio = apply_lowpass_filter(audio, SAMPLE_RATE, 8000)\n        \n        # Export with explicit subtype\n        sf.write(f'{stem}.wav', audio, SAMPLE_RATE, subtype=SUBTYPE)\n    \n    # Step 5: Export master\n    master = np.zeros(int(DURATION * SAMPLE_RATE))\n    for stem in STEM_NAMES:\n        data, _ = sf.read(f'{stem}.wav')\n        master += data * 0.5\n    master = np.clip(master, -1, 1)\n    sf.write('master_track.wav', master, SAMPLE_RATE, subtype=SUBTYPE)\n    \n    # Step 6: Archive\n    files = ['master_track.wav'] + [f'{s}.wav' for s in STEM_NAMES]\n    with zipfile.ZipFile('deliverables.zip', 'w') as zf:\n        for f in files:\n            zf.write(f)\n    \n    # Step 7: Verify\n    specs = {f: {'sample_rate': SAMPLE_RATE, 'subtype': SUBTYPE} for f in files}\n    results = verify_outputs(specs)\n    assert results['failed'] == 0\n    print(\"Workflow complete!\")\n\nif __name__ == '__main__':\n    run_workflow()\n```\n\n## Key Principles\n\n- **Explicit sample types**: Always specify `subtype` parameter (e.g., `subtype='FLOAT'` for 24-bit float WAV)\n- **Verify at each step**: Check file properties after each major operation\n- **Consistent specifications**: Maintain same sample rate, bit depth, and duration across all outputs\n- **Archive for delivery**: Package all deliverables together for easy distribution\n- **Final verification**: Assert all outputs meet specifications before declaring success","# Audio Track Production Workflow\n\nThis skill provides a reusable pattern for executing audio production tasks that require generating a master track and multiple stems, applying effects, and delivering verified outputs in an archive.\n\n## Overview\n\nFollow these steps in order to ensure consistent, verifiable audio production outputs:\n\n1. Verify reference audio file\n2. Calculate timing parameters from BPM and duration\n3. Generate stems with explicit sample type specifications\n4. Apply audio effects via signal processing\n5. Export master track and all stems\n6. Archive deliverables in zip format\n7. Verify all outputs match specifications\n\n## Step 1: Verify Reference File\n\nBefore processing, verify the reference audio file is valid and readable:\n\n```python\nimport soundfile as sf\n\n# Verify reference file exists and is readable\ninfo = sf.info('reference_track.wav')\nprint(f\"Sample rate: {info.samplerate} Hz\")\nprint(f\"Duration: {info.frames \u002F info.samplerate:.2f} seconds\")\nprint(f\"Channels: {info.channels}\")\nprint(f\"Subtype: {info.subtype}\")\n```\n\n## Step 2: Calculate Timing Parameters\n\nDerive timing for key section transitions from BPM and total duration:\n\n```python\ndef calculate_section_transitions(bpm, total_duration_sec, sections):\n    \"\"\"Calculate beat-aligned transition points for song sections.\"\"\"\n    beats_per_second = bpm \u002F 60.0\n    total_beats = total_duration_sec * beats_per_second\n    \n    # Distribute sections proportionally or by specified ratios\n    section_durations = {}\n    cumulative_time = 0\n    \n    for section_name, beat_count in sections.items():\n        duration = beat_count \u002F beats_per_second\n        section_durations[section_name] = {\n            'start': cumulative_time,\n            'end': cumulative_time + duration,\n            'beats': beat_count\n        }\n        cumulative_time += duration\n    \n    return section_durations\n\n# Example usage\nsections = calculate_section_transitions(\n    bpm=120,\n    total_duration_sec=137,\n    sections={'intro': 16, 'verse': 32, 'chorus': 32, 'bridge': 16, 'outro': 16}\n)\n```\n\n## Step 3: Generate Stems with Explicit Sample Type\n\nAlways specify sample type explicitly when generating stems to ensure bit-depth consistency:\n\n```python\nimport numpy as np\nimport soundfile as sf\n\ndef generate_stem(name, duration_sec, sample_rate, subtype='FLOAT'):\n    \"\"\"Generate a stem with explicit sample type specification.\"\"\"\n    frames = int(duration_sec * sample_rate)\n    \n    # Generate audio content (replace with actual synthesis\u002Fprocessing)\n    t = np.linspace(0, duration_sec, frames)\n    audio_data = np.sin(2 * np.pi * 440 * t)  # Example: 440Hz tone\n    \n    # Ensure proper data type for specified subtype\n    if subtype == 'FLOAT':\n        audio_data = audio_data.astype(np.float32)\n    elif subtype == 'PCM_24':\n        audio_data = np.clip(audio_data, -1, 1) * (2**23 - 1)\n        audio_data = audio_data.astype(np.int32)\n    \n    sf.write(\n        f'{name}_stem.wav',\n        audio_data,\n        sample_rate,\n        subtype=subtype,  # Explicit subtype for 24-bit float or other\n        format='WAV'\n    )\n    return audio_data\n\n# Example: Generate 4 stems at 48kHz, 137s, 24-bit float\nsample_rate = 48000\nduration = 137\nstems = ['guitars', 'synths', 'bridge', 'bass']\n\nfor stem_name in stems:\n    generate_stem(stem_name, duration, sample_rate, subtype='FLOAT')\n```\n\n## Step 4: Apply Effects via scipy.signal\n\nUse scipy.signal for applying audio effects and processing:\n\n```python\nfrom scipy import signal\nimport numpy as np\n\ndef apply_lowpass_filter(audio_data, sample_rate, cutoff_freq=5000):\n    \"\"\"Apply a lowpass filter using scipy.signal.\"\"\"\n    nyquist = sample_rate \u002F 2\n    normalized_cutoff = cutoff_freq \u002F nyquist\n    \n    # Design Butterworth filter\n    b, a = signal.butter(4, normalized_cutoff, btype='low')\n    \n    # Apply filter\n    filtered_data = signal.filtfilt(b, a, audio_data)\n    return filtered_data\n\ndef apply_reverb_simple(audio_data, sample_rate, decay=0.5, delay_samples=1000):\n    \"\"\"Apply simple reverb effect.\"\"\"\n    reverbed = np.copy(audio_data)\n    decay_factor = decay\n    \n    for i in range(1, 6):\n        delayed = np.zeros_like(audio_data)\n        if len(audio_data) > delay_samples * i:\n            delayed[delay_samples * i:] = audio_data[:-delay_samples * i]\n        reverbed += delayed * (decay_factor ** i)\n    \n    return np.clip(reverbed, -1, 1)\n\n# Apply effects to stems\nfor stem_name in stems:\n    data, sr = sf.read(f'{stem_name}_stem.wav')\n    processed = apply_lowpass_filter(data, sr, cutoff_freq=8000)\n    processed = apply_reverb_simple(processed, sr, decay=0.3)\n    sf.write(f'{stem_name}_stem_processed.wav', processed, sr, subtype='FLOAT')\n```\n\n## Step 5: Export Master and Stems\n\nExport all final deliverables with consistent specifications:\n\n```python\ndef export_audio(filepath, audio_data, sample_rate, subtype='FLOAT'):\n    \"\"\"Export audio file with verified specifications.\"\"\"\n    sf.write(\n        filepath,\n        audio_data,\n        sample_rate,\n        subtype=subtype,\n        format='WAV'\n    )\n    # Verify export\n    info = sf.info(filepath)\n    assert info.samplerate == sample_rate, f\"Sample rate mismatch: {info.samplerate}\"\n    assert info.subtype == subtype, f\"Subtype mismatch: {info.subtype}\"\n    print(f\"Exported: {filepath} ({info.duration:.2f}s, {info.samplerate}Hz)\")\n\n# Export master (mix of all stems)\nmaster_audio = np.zeros_like(stem_audio)  # Replace with actual mix\nfor stem_name in stems:\n    stem_data, _ = sf.read(f'{stem_name}_stem_processed.wav')\n    master_audio += stem_data * 0.5  # Simple mix with gain staging\n\nmaster_audio = np.clip(master_audio, -1, 1)\nexport_audio('master_track.wav', master_audio, sample_rate=48000, subtype='FLOAT')\n\n# Export final stems\nfor stem_name in stems:\n    stem_data, sr = sf.read(f'{stem_name}_stem_processed.wav')\n    export_audio(f'{stem_name}.wav', stem_data, sample_rate=48000, subtype='FLOAT')\n```\n\n## Step 6: Archive Deliverables\n\nPackage all outputs in a zip archive:\n\n```python\nimport zipfile\nimport os\n\ndef create_archive(archive_name, file_list):\n    \"\"\"Create zip archive of deliverables.\"\"\"\n    with zipfile.ZipFile(archive_name, 'w', zipfile.ZIP_DEFLATED) as zipf:\n        for filepath in file_list:\n            if os.path.exists(filepath):\n                zipf.write(filepath, os.path.basename(filepath))\n                print(f\"Added to archive: {filepath}\")\n            else:\n                print(f\"WARNING: File not found: {filepath}\")\n    \n    # Verify archive\n    with zipfile.ZipFile(archive_name, 'r') as zipf:\n        contents = zipf.namelist()\n        print(f\"Archive contains {len(contents)} files: {contents}\")\n    \n    return archive_name\n\n# Archive master and stems\ndeliverables = ['master_track.wav'] + [f'{stem}.wav' for stem in stems]\ncreate_archive('audio_deliverables.zip', deliverables)\n```\n\n## Step 7: Verify All Outputs\n\nFinal verification that all outputs match specifications:\n\n```python\ndef verify_outputs(expected_specs):\n    \"\"\"Verify all output files match expected specifications.\"\"\"\n    results = {'passed': 0, 'failed': 0, 'details': []}\n    \n    for filepath, specs in expected_specs.items():\n        if not os.path.exists(filepath):\n            results['failed'] += 1\n            results['details'].append(f\"MISSING: {filepath}\")\n            continue\n        \n        info = sf.info(filepath)\n        errors = []\n        \n        if specs.get('sample_rate') and info.samplerate != specs['sample_rate']:\n            errors.append(f\"sample_rate: expected {specs['sample_rate']}, got {info.samplerate}\")\n        \n        if specs.get('subtype') and info.subtype != specs['subtype']:\n            errors.append(f\"subtype: expected {specs['subtype']}, got {info.subtype}\")\n        \n        if specs.get('min_duration') and info.duration \u003C specs['min_duration']:\n            errors.append(f\"duration: expected >= {specs['min_duration']}s, got {info.duration}s\")\n        \n        if errors:\n            results['failed'] += 1\n            results['details'].append(f\"FAILED: {filepath} - {'; '.join(errors)}\")\n        else:\n            results['passed'] += 1\n            results['details'].append(f\"PASSED: {filepath} ({info.duration:.2f}s, {info.samplerate}Hz, {info.subtype})\")\n    \n    return results\n\n# Verification specifications\nexpected_specs = {\n    'master_track.wav': {'sample_rate': 48000, 'subtype': 'FLOAT', 'min_duration': 137},\n    'guitars.wav': {'sample_rate': 48000, 'subtype': 'FLOAT', 'min_duration': 137},\n    'synths.wav': {'sample_rate': 48000, 'subtype': 'FLOAT', 'min_duration': 137},\n    'bridge.wav': {'sample_rate': 48000, 'subtype': 'FLOAT', 'min_duration': 137},\n    'bass.wav': {'sample_rate': 48000, 'subtype': 'FLOAT', 'min_duration': 137},\n}\n\nverification = verify_outputs(expected_specs)\nprint(f\"\\nVerification: {verification['passed']} passed, {verification['failed']} failed\")\nfor detail in verification['details']:\n    print(detail)\n\nassert verification['failed'] == 0, \"Output verification failed!\"\n```\n\n## Complete Workflow Example\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"Complete audio production workflow execution.\"\"\"\n\nimport soundfile as sf\nimport numpy as np\nfrom scipy import signal\nimport zipfile\nimport os\n\n# Configuration\nSAMPLE_RATE = 48000\nDURATION = 137\nBPM = 120\nSTEM_NAMES = ['guitars', 'synths', 'bridge', 'bass']\nSUBTYPE = 'FLOAT'\n\ndef run_workflow():\n    # Step 1: Verify reference\n    ref_info = sf.info('reference.wav')\n    print(f\"Reference: {ref_info.duration}s @ {ref_info.samplerate}Hz\")\n    \n    # Step 2: Calculate timing\n    bpm = BPM\n    beats_per_sec = bpm \u002F 60\n    \n    # Step 3-4: Generate and process stems\n    for stem in STEM_NAMES:\n        frames = int(DURATION * SAMPLE_RATE)\n        t = np.linspace(0, DURATION, frames)\n        audio = np.sin(2 * np.pi * 220 * t)  # Example content\n        \n        # Apply effects\n        audio = apply_lowpass_filter(audio, SAMPLE_RATE, 8000)\n        \n        # Export with explicit subtype\n        sf.write(f'{stem}.wav', audio, SAMPLE_RATE, subtype=SUBTYPE)\n    \n    # Step 5: Export master\n    master = np.zeros(int(DURATION * SAMPLE_RATE))\n    for stem in STEM_NAMES:\n        data, _ = sf.read(f'{stem}.wav')\n        master += data * 0.5\n    master = np.clip(master, -1, 1)\n    sf.write('master_track.wav', master, SAMPLE_RATE, subtype=SUBTYPE)\n    \n    # Step 6: Archive\n    files = ['master_track.wav'] + [f'{s}.wav' for s in STEM_NAMES]\n    with zipfile.ZipFile('deliverables.zip', 'w') as zf:\n        for f in files:\n            zf.write(f)\n    \n    # Step 7: Verify\n    specs = {f: {'sample_rate': SAMPLE_RATE, 'subtype': SUBTYPE} for f in files}\n    results = verify_outputs(specs)\n    assert results['failed'] == 0\n    print(\"Workflow complete!\")\n\nif __name__ == '__main__':\n    run_workflow()\n```\n\n## Key Principles\n\n- **Explicit sample types**: Always specify `subtype` parameter (e.g., `subtype='FLOAT'` for 24-bit float WAV)\n- **Verify at each step**: Check file properties after each major operation\n- **Consistent specifications**: Maintain same sample rate, bit depth, and duration across all outputs\n- **Archive for delivery**: Package all deliverables together for easy distribution\n- **Final verification**: Assert all outputs meet specifications before declaring success",{"name":5,"description":7},"main","ff671ef61ed6587c49bd54c81cdc751c0b99e363","gdpval_bench\u002Fskills\u002Faudio-track-production","https:\u002F\u002Fgithub.com\u002FAG064\u002FOpenSpace","https:\u002F\u002Fgithub.com\u002FAG064","AG064, E.Mi.\r\n\r\nA person who thinks all the time, yet all they have to think about is nothing. I want to improve the world and work on open source projects","2026-10-08 06:53:48",{"source":8,"skillName":5,"commands":45,"prompt":55,"zipAvailable":56},[46,49,52],{"tool":47,"command":48},"npx","npx skills add AG064\u002FOpenSpace --skill audio-track-production",{"tool":50,"command":51},"bunx","bunx skills add AG064\u002FOpenSpace --skill audio-track-production",{"tool":53,"command":54},"pnpm","pnpm dlx skills add AG064\u002FOpenSpace --skill audio-track-production","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fgdpval_bench\u002Fskills\u002Faudio-track-production\u002FSKILL.md",true,[58],{"path":59,"resourceType":60,"resourceTypeDesc":61,"sizeBytes":62,"sourceHtmlUrl":63},".skill_id","OTHER","其他",36,"https:\u002F\u002Fgithub.com\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fgdpval_bench\u002Fskills\u002Faudio-track-production\u002F.skill_id",[65,89,104,113,143,159],{"skillNo":66,"name":67,"nameZh":6,"description":68,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":69,"categories":70,"keywords":71,"publishedAt":32},"01M6KKMPWA0B5SCCH766F8M5EA","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\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fshowcase\u002Fskills\u002Fwrite-special-chars-ts-check\u002FSKILL.md",[],[72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88],"write special chars ts check","check","write","filters","Existing","type-checking","for","errors","script","output","type","files","only","template","file","python","typescript",{"skillNo":90,"name":91,"nameZh":6,"description":92,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":93,"categories":94,"keywords":95,"publishedAt":32},"01M6KKMJXVBNVEY3TRK055F4A7","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\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fshowcase\u002Fskills\u002Fwrite-special-chars-readback\u002FSKILL.md",[],[96,97,74,85,98,99,86,87,100,28,101,102,103,78,80,30],"readback","write special chars readback","cleanup","read","scripts","via","post","helper",{"skillNo":105,"name":106,"nameZh":6,"description":107,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":108,"categories":109,"keywords":110,"publishedAt":32},"01M6KKMEGX9M9NC105J0W3Q5B9","write-special-chars-heredoc","Workaround for write_file failures caused by special characters (apostrophes, backticks, template literals) by using a Python heredoc script executed via shell.","https:\u002F\u002Fgithub.com\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fshowcase\u002Fskills\u002Fwrite-special-chars-heredoc\u002FSKILL.md",[],[74,111,87,78,101,85,112,86,80],"write special chars heredoc","shell",{"skillNo":114,"name":115,"nameZh":6,"description":116,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":117,"categories":118,"keywords":124,"publishedAt":32},"01M6KKM8EJ2AATVHZBNB916WT0","worldmonitor-reference","Curated architecture index of the WorldMonitor open-source dashboard. Reference for extracting patterns — vanilla TypeScript, Panel class hierarchy, service layer, CSS grid, API edge functions, refresh scheduler, and 60+ data source integrations.","https:\u002F\u002Fgithub.com\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fshowcase\u002Fskills\u002Fworldmonitor-reference\u002FSKILL.md",[119],{"categoryNo":120,"categoryName":121,"taxonomyType":122,"taxonomyTypeDesc":123},"01JBSEEDCAT000000000000033","数据分析师","PROFESSION","适用职业",[125,126,127,128,88,129,130,131,132,133,78,134,135,136,137,138,139,140,141,142],"reference","worldmonitor","worldmonitor reference","dashboard","css","architecture","extracting","hierarchy","source","layer","panel","patterns","edge functions","integrations","open","api","data","scheduler",{"skillNo":144,"name":145,"nameZh":6,"description":146,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":147,"categories":148,"keywords":149,"publishedAt":32},"01M6KKM39PHYK627F19GE2B9XN","virtual-list","Implement efficient virtual scrolling for rendering large lists with DOM recycling, chunk-based rendering, and performance optimizations","https:\u002F\u002Fgithub.com\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fshowcase\u002Fskills\u002Fvirtual-list\u002FSKILL.md",[],[150,151,152,153,78,154,30,155,156,157,158],"virtual list","list","virtual","chunk","dom","rendering","recycling","implement","performance",{"skillNo":160,"name":161,"nameZh":6,"description":162,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":163,"categories":164,"keywords":165,"publishedAt":32},"01M6KKKY7T2P61Y0JH54CDEJKQ","verify-directory-structure","Diagnose and resolve file access issues by first verifying the directory structure.","https:\u002F\u002Fgithub.com\u002FAG064\u002FOpenSpace\u002Fblob\u002Fmain\u002Fshowcase\u002Fskills\u002Fverify-directory-structure\u002FSKILL.md",[],[166,167,168,169,170,171,86,172,173,174],"directory","verify","structure","verify directory structure","access","first","issues","diagnose","file access"]