heartmula

heartmula is a skill for Claude Code, Codex from math-inc/OpenGauss. It costs 34 tokens per session (1,745 once invoked), scanned A, a copy of heartmula, MIT.

A setup guide for HeartMuLa, an open-source system that creates complete songs from lyrics and descriptive tags. It can run locally and supports multiple languages.

In plain words
What is it for?
Use it to install HeartMuLa, generate songs from text, transcribe lyrics, and configure single- or multi-GPU use.
Why use it?
It gives you a way to generate music without relying on a closed online service. The guide also covers the computer resources and installation steps needed to run the models.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to install HeartMuLa, generate songs from text, transcribe lyrics, and…

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/math-inc/opengauss/heartmula
About the project

OpenGauss is a project-scoped Lean workflow orchestrator that gives coding agents a command-line interface for managing formal proof and formalization tasks. It is used with Lean projects to coordinate agents, tooling, backend sessions, and workflows supplied by lean4-skills. The catalogue add-ons operate these Gauss-native workflows.

math-inc/OpenGauss · 1,261 stars · on GitHub

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add math-inc/OpenGauss --skill heartmula
Clone the repo
git clone --depth 1 https://github.com/math-inc/OpenGauss

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for heartmula

README.md
[![agentmods](https://agentmods.dev/badge/skills/math-inc/opengauss/heartmula.svg)](https://agentmods.dev/skills/math-inc/opengauss/heartmula)
Your own site
<a href="https://agentmods.dev/skills/math-inc/opengauss/heartmula"><img src="https://agentmods.dev/badge/skills/math-inc/opengauss/heartmula.svg" alt="Measured on agentmods" height="20"></a>
Per session 34 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,745 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin 89% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00034 $0.01745
Opus 5 $0.00017 $0.00873
Sonnet 5 $0.00007 $0.00349
Haiku 4.5 $0.00003 $0.00175

Measured 7d ago against content hash 8c904acb1e9a, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

heartmula scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 7d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

This is a copy

89% identical to heartmula — 11 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

skills/media/heartmula/SKILL.md · 171 lines

How it starts

The opening of the file, as written. The whole thing — 171 lines — stays where its author put it; the contents beside it link to each section on GitHub.

HeartMuLa - Open-Source Music Generation

Overview

HeartMuLa is a family of open-source music foundation models (Apache-2.0) that generates music conditioned on lyrics and tags. Comparable to Suno for open-source. Includes:

  • HeartMuLa - Music language model (3B/7B) for generation from lyrics + tags
  • HeartCodec - 12.5Hz music codec for high-fidelity audio reconstruction
  • HeartTranscriptor - Whisper-based lyrics transcription
  • HeartCLAP - Audio-text alignment model

When to Use

  • User wants to generate music/songs from text descriptions
  • User wants an open-source Suno alternative
  • User wants local/offline music generation
  • User asks about HeartMuLa, heartlib, or AI music generation

Hardware Requirements

  • Minimum: 8GB VRAM with --lazy_load true (loads/unloads models sequentially)
  • Recommended: 16GB+ VRAM for comfortable single-GPU usage
  • Multi-GPU: Use --mula_device cuda:0 --codec_device cuda:1 to split across GPUs
  • 3B model with lazy_load peaks at ~6.2GB VRAM

Installation Steps

1. Clone Repository

cd ~/  # or desired directory
git clone https://github.com/HeartMuLa/heartlib.git
cd heartlib

2. Create Virtual Environment (Python 3.10 required)

uv venv --python 3.10 .venv
. .venv/bin/activate
uv pip install -e .

3. Fix Dependency Compatibility Issues

IMPORTANT: As of Feb 2026, the pinned dependencies have conflicts with newer packages. Apply these fixes:

# Upgrade datasets (old version incompatible with current pyarrow)
uv pip install --upgrade datasets

# Upgrade transformers (needed for huggingface-hub 1.x compatibility)
uv pip install --upgrade transformers

4. Patch Source Code (Required for transformers 5.x)

Patch 1 - RoPE cache fix in src/heartlib/heartmula/modeling_heartmula.py:

In the setup_caches method of the HeartMuLa class, add RoPE reinitialization after the reset_caches try/except block and before the with device: block:

# Re-initialize RoPE caches that were skipped during meta-device loading
from torchtune.models.llama3_1._position_embeddings import Llama3ScaledRoPE
for module in self.modules():
    if isinstance(module, Llama3ScaledRoPE) and not module.is_cache_built:
        module.rope_init()
        module.to(device)

Read the full file on GitHub · 171 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 7d ago First seen · 171 lines · 34 tokens per session scan A 8c904acb1e9a

Subscribe to this mod's changes

heartmula is a skill published in the GitHub repository math-inc/OpenGauss (1,261 stars, last pushed 5mo ago), licensed MIT. It adds 34 tokens to every session and 1,745 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. It is 89% identical to heartmula, differing in 11 lines, and is treated as a copy.

Related

Other skills, from other repositories

webgl-holographic-foil

A self-contained WebGL2 hero: thin-film interference over a crushed-foil surface whose palette shifts with the viewing angle; move the cursor to tilt the film.

nexu-io/open-design · 41 tokens

general-video

Author or edit a custom HyperFrames composition when no specialized workflow fits, or when BRIEF.md sets flow: companion. Use for longer or multi-scene pieces, brand and sizzle reels, montages, static loops, static title cards, footage remixes, and freeform builds. Use motion-graphics instead for a short unnarrated…

heygen-com/hyperframes · 92 tokens

html-ppt-hermes-cyber-terminal

OpenDesign + BYOK: choosing and wiring your own model, hands-on — cost, quality, and the routing decision. Built as a decision-grade AI literacy deck for engineers, IT, applied-AI teams.

nexu-io/open-design · 53 tokens

html-ppt-taste-brutalist

16:9 HTML deck in tactical-telemetry / CRT-terminal taste. Deactivated-CRT charcoal slides, white-phosphor monospace, hazard-red accent, scanline overlay, ASCII syntax, density over decoration. Distilled from Leonxlnx/taste-skill brutalist-skill (Tactical Telemetry mode).

nexu-io/open-design · 78 tokens

diagnostic-stem-delivery

Audio production with diagnostic analysis, timecode parsing from documents, and verified export workflow.

HKUDS/OpenSpace · 23 tokens

chengfeng-check-updates

An environment manager for a video-editing system. It checks whether its skills and runtime—the software needed to run them—are installed and compatible.

Agentchengfeng/chengfeng-videocut-skills · 120 tokens