Tone tunerPro
Adjust how a customer reply sounds: two sliders (how formal, how detailed) and three voice chips rework the message; only sentences that changed are swapped, words that are new compared with the draft can be highlighted, and Copy grabs whatever is showing.
oxyn add tone-tunerTo Jonah Reyes
Re: Charged twice in October
Hi Jonah,
Thanks for letting us know about the double charge. We've refunded the extra $49 to your Visa ending in 4242. It should appear within 3 to 5 business days.
Let me know if you have any other questions.
Best, Priya
The preview stays free for everyone. Pro opens the code of every Pro component, screen, agent-app template, block and kit, plus the Pro CLI.
Rendered from Rust at build time · goes live when visible
When to use
- Tune a reply to the right voice before sending: formal or casual, brief or detailed, friendly, confident or empathetic.
When not to use
- Replays a multi-agent run on one clock: use Agent timeline instead.
- One model at a glance: use Model card instead.
- A small automation on a single rail: use AI workflow instead.
Installation
Tone tuner is part of Oxyn Pro; the preview is free. Pro items install with the oxyn CLI once your licence is signed in; until then Pro members copy the code from this page.
oxyn add tone-tunerUsage
The preview is free. Pro opens the code of every Pro component, screen and template.
Examples
Tour
Tours the voices until you touch it.
To Jonah Reyes
Re: Charged twice in October
Hi Jonah,
Thanks for letting us know about the double charge. We've refunded the extra $49 to your Visa ending in 4242. It should appear within 3 to 5 business days.
Let me know if you have any other questions.
Best, Priya
Code Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
Formal detailed
Formal and detailed, no tour (Oxyn extra).
To Jonah Reyes
Re: Charged twice in October
Dear Jonah,
Thank you for letting us know about the duplicate charge. A refund of $49 has been issued to your Visa ending in 4242. Please allow 3 to 5 business days for it to appear. The duplicate resulted from an automatic retry during a brief outage at our payment provider; we have since added a safeguard to prevent a recurrence. Your next invoice, due on December 1, remains unchanged.
Please do not hesitate to contact us with any further questions.
Kind regards, Priya Nair, Billing
Code Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
Failed
A failed rewrite keeps the last version.
To Jonah Reyes
Re: Charged twice in October
Hi Jonah,
Thanks for letting us know about the double charge. We've refunded the extra $49 to your Visa ending in 4242. It should appear within 3 to 5 business days.
Let me know if you have any other questions.
Best, Priya
Code Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
API reference
ToneTuner
| Prop | Type | Default | Description |
|---|---|---|---|
nowrequired | ClockMs | — | Host clock. |
formality | usize | 1 | Starting formality (0 casual, 1 neutral, 2 formal). |
detail | usize | 1 | Starting detail (0 brief, 1 standard, 2 detailed). |
voice | usize | Default::default() | Starting voice (0 neutral … 3 empathetic). |
show_changes | bool | true | Highlight words that are new compared with the draft. |
tour | bool | true | Tour the voices until someone touches the card. |
fail | bool | Default::default() | Rewrites fail (error scenario). |
Read from the Rust signature and doc comments.
Keyboard interactions
| Key | Action |
|---|---|
| Tab | Voice chips, both sliders, Changes, Copy |
| ← → · HomeorEnd | Step a focused slider through its three levels |
| EnterorSpace | Press a chip, flip Changes, copy |
Accessibility
- The three voices are pressable chips inside a group labelled Voice.
- Sliders are named and speak their level name (Casual, Neutral, Formal), not a number.
- New words use mark elements and the header counts them, so changes never rely on colour.
From the spec
Chips are toggle buttons with aria-pressed in a group named Voice; sliders are role slider and speak their level name; changes are mark elements. Every action returns the line the polite live region announces. The focus outline shows only for keyboard focus.
Motion & interaction
Changed sentences fade in place while unchanged ones stay put; new words against the original are marked when Changes is on and the header counts them. Pressing an active chip returns to neutral.
Timing
Everything on screen is derived from the host clock now (no timers in the component), so playback, tests and the GPUI view agree.
| Transition | Duration | Easing |
|---|---|---|
| Debounce | 220 ms | — |
| Rewrite | 650 ms | — |
| Sentence swap | 180 ms fade | ease-out |
| Tour | every 3.4 s | — |
Reduced motion: loops and travel stop; each state shows its end pose and its words.
Responsive behaviour
- Up to 640 px; under 520 px the sliders stack and the chips share one row.
- Each sentence keeps its place while it swaps, so the text never jumps.
Edge cases (spec)
The message keeps a minimum height so voices never make the card jump. Under 520 px the sliders stack and the chips share one row; under 400 px chip icons and the count hide. Checked at 1440, 768 and 390 px in light and dark with no text overlap. Chrome is monochrome grey; colour is semantic only (success, warning, danger, info) plus the official coloured brand and model marks.
Notes for AI
- Import
ToneTunerfromoxyn_dioxusand includeSTATUS_INDICATOR_CSSplus the token stylesheet once. - A GPUI version exists:
AiKitViewinoxyn_gpui. - Props to set first:
now. - It reads a clock (
now) for live timers; pass one clock for the whole page rather than one per component. - Keep its states and timings as they ship; restyle it through the CSS variables rather than by hand.