Lofi study stream: a 30-second track looped as a Sume soundtrack

A lo-fi study stream needs a bed that repeats cleanly. Generate a 30-second track with Sume's router and loop it under a video with soundtrack.loop.

5 min readSume
All posts

How do you make a lo-fi study video with AI music? Generate one short bed and loop it. The Music Router's own example prompt is a lo-fi hip hop track: 84 BPM, C minor, dusty Rhodes chords, brushed boom-bap drums, a muted trumpet answer at 0:10, 30 seconds, no vocals. Then a Timeline 1.0 render can repeat that file under your picture with soundtrack.loop.

A loop is only as good as its seam. The docs give you a looping flag and a fade-out, not an automatic crossfade, so write the music with a clean end and check the join by ear.

Generate the bed

Keep the prompt tight and ask for a track that ends on a stable chord, since the loop restarts from the top. The example in the router docs is a good template.

import os
import requests

r = requests.post(
    "https://api.sume.com/v1/music-router/generate",
    headers={
        "Authorization": "Bearer " + os.environ["SUME_API_KEY"],
        "Idempotency-Key": "lofi-loop-001",
    },
    json={
        "model": "sume/music-auto",
        "prompt": "Warm lo-fi hip hop, 84 BPM, C minor. Dusty Rhodes chords, brushed boom-bap drums, a muted trumpet answer at 0:10. Ends on a resolved Cmin9 chord. A 30-second track. Instrumental, no vocals.",
        "mode": "sync",
        "wait_timeout_seconds": 30,
    },
    timeout=60,
)
print(r.status_code)
print(r.json())

Loop it under the picture

The soundtrack block takes url, gain_db, loop, fade_out_seconds and duck_db. The render's audio.duration_seconds is 1 to 1800 seconds, so a 30-minute study video is the longest one call can make. The audio.mode of silence declares a length with no spine file, but then soundtrack.duck_db is illegal, since ducking needs a real spine.

Fields from docs.sume.com Timeline 1.0, read 2026-10-04.
FieldValue for a study stream
audio.duration_secondsUp to 1800
audio.modesilence if the bed is the only audio
soundtrack.looptrue
soundtrack.fade_out_secondsUp to 10, so the last repeat ends softly
soundtrack.duck_dbNot with silence, duck_requires_audio_spine

When a loop is the wrong tool

If the track must evolve over a long run, generate several beds and join them gaplessly with timeline audio concat, which takes 1 to 20 parts and returns segments[] offsets. Keep wav for any file you will join again, since the docs say mp3 re-adds priming padding at every edge.

Cost and limits to remember

The Music Router charges the fixed Music price per audio generation; a render's cost comes from the Timeline plan, which POST to the plan route returns before any job is created. Check the live prices in GET /v1/catalog.

Sources

Related posts

More in Use cases

All Use cases posts

Written by Sume