Skip to content
SaymonMaster14Public

About

Shred your guitar and any llm will understand it as a prompt

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

2 Commits

Folders and files

Repository files navigation

ShredLang 🎸

A musical programming language for communicating with LLMs through guitar performance.

ShredLang explores a deliberately strange idea: a guitar can be more than an instrument. It can be an input language for AI.

Instead of reducing guitar input to note-to-letter mappings or MIDI macros, ShredLang treats musical structure as a compositional language. Notes, riffs, rhythm, articulation, bends, vibrato, tapping, sweeps and overall performance complexity can encode both what you want an LLM to do and how deeply it should do it.

The more ridiculous the solo, the more ridiculous the prompt.

The idea

Guitar performance
        │
        ▼
Audio / MIDI frontend
        │
        ▼
Normalized musical events
        │
        ▼
ShredLang parser
        │
        ▼
Prompt AST
        │
        ├── semantic intent
        └── performance modifiers
        │
        ▼
Prompt compiler
        │
        ▼
LLM / agent

A performance might compile into an intermediate representation like:

{
  "intent": "research",
  "subject": "transformers",
  "operations": ["compare", "criticize"],
  "performance": {
    "depth": 0.94,
    "creativity": 0.81,
    "intensity": 0.88
  }
}

and then into something conventional models can consume:

Research Transformer architectures in depth. Compare major approaches,
identify limitations, examine alternatives, and include the strongest
counterarguments to the main conclusions.

Not Morse code for guitar

A naive implementation could map every note to a character or command. That works, but it throws away most of what makes musical performance expressive.

The goal is a small, learnable, compositional musical grammar.

Musical feature Candidate semantic role
Notes / motifs symbols, concepts, arguments
Riffs intents / verbs
Chords domains / contexts
Intervals relationships
Rhythm structure / modifiers
Repetition emphasis
Bend intensity
Vibrato variation / creativity
Palm mute concision / constraint
Tapping exploration
Sweep picking depth / expansion
Performance complexity depth / breadth / reasoning budget
Pause / cadence expression boundary

These mappings are hypotheses, not language law. The first versions exist to discover which mappings are actually playable, learnable and robust.

MVP 0.1

The first milestone only needs to prove the central thesis:

  1. Capture guitar input through MIDI or an audio transcription adapter.
  2. Normalize the performance into musical events.
  3. Recognize a tiny vocabulary of riffs / gestures.
  4. Parse those events into a PromptProgram AST.
  5. Calculate deterministic performance metrics.
  6. Compile the AST into a textual prompt.
  7. Send the result through an LLM adapter.
  8. Display what the system heard, parsed and compiled.

Example:

riff: RESEARCH
motif: AI_ARCHITECTURE
modifier: DEEP
modifier: CRITICAL

=>

"Research modern AI architectures in depth. Distinguish established facts
from inference, compare alternatives, and include the strongest contrary
arguments."

A harder version of the same semantic phrase may increase depth, breadth or exploratory behavior without changing the subject itself.

Repository layout

shredlang/
├── apps/
│   └── cli/                  # developer-facing prototype
├── crates/
│   ├── core/                 # shared musical domain types
│   ├── prompt-ast/           # semantic intermediate representation
│   ├── parser/               # musical events -> Prompt AST
│   ├── complexity/           # deterministic performance metrics
│   ├── compiler/             # Prompt AST -> textual prompt
│   ├── midi-frontend/        # MIDI adapter boundary
│   ├── audio-frontend/       # audio transcription adapter boundary
│   └── llm-adapters/         # provider-neutral LLM boundary
├── grammars/
│   └── v0/                   # experimental vocabulary / grammar
├── examples/                 # playable / parseable examples
├── docs/
│   ├── LANGUAGE.md
│   ├── ARCHITECTURE.md
│   ├── ROADMAP.md
│   └── RESEARCH.md
└── tests/
    └── fixtures/

The semantic boundary: Prompt AST

The AST separates music interpretation from model prompting.

PromptProgram
├── intent
├── subject
├── arguments[]
├── operations[]
├── constraints[]
└── performance
    ├── complexity
    ├── intensity
    ├── density
    ├── range
    └── expressiveness

That means the musical language does not need to care whether the destination is ChatGPT, Claude, Gemini, a local model, a coding agent or some future tool.

Complexity is semantics

A core ShredLang experiment is whether performance complexity can act as a useful continuous control signal.

Candidate measurements include:

notes / second
pitch range
interval entropy
rhythmic diversity
phrase length
bend magnitude
vibrato rate
articulation diversity
polyphony
technical-event density

These can be reduced to inspectable controls such as:

depth       0.91
breadth     0.74
creativity  0.83
intensity   0.97

Early versions should keep this mapping deterministic. “AI magically understands how hard the solo was” is not a specification.

What ShredLang is not

  • Not a claim that LLMs inherently understand guitar semantics.
  • Not note-to-ASCII.
  • Not just a MIDI macro launcher.
  • Not a music-generation model.
  • Not a replacement for speech or keyboard input.

It is an experiment in musical human-computer interaction for language models and agents.

Possible frontends

ShredLang's core should not depend on one transcription system.

Potential inputs include direct MIDI, MIDI guitar hardware, automatic music transcription such as Spotify Basic Pitch, guitar-technique classifiers, and future learned audio frontends.

Everything should normalize into the same internal musical-event model before parsing.

Future crimes against software engineering

power chord       -> inspect repository
riff              -> locate bug
sweep             -> go deeper
tapping           -> explore alternatives
harmonic          -> run tests
final cadence     -> commit

Programming by shred.

Status

Pre-alpha / language-design experiment.

The repository currently defines the project boundary and initial architecture. Syntax and musical vocabulary are experimental until validated through playable prototypes.

Contributing

Useful areas include automatic music transcription, guitar-technique classification, MIDI/audio tooling, parser design, programming-language design, HCI research, prompt compilation, real-time visualization and, obviously, guitar playing.

If an idea makes the instrument more expressive without turning it into a keyboard with strings, it probably belongs in the discussion.

About

Shred your guitar and any llm will understand it as a prompt

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages