Skills
tunables-define
tunables-define makes one change to an app's tunables: a setting, a group, a
preset set, a catalog or a deployment value. It decides where the value
belongs, declares it with everything it needs, and says exactly what happens to
the values already stored in each environment.
What it does
- Starts from the current state. It finds
tunables.config.tsand the definitions, runstunables check, and reports findings that were there before it started rather than fixing them unasked. - Classifies the request: add, change (default, bounds, options, kind, unit, section, effects, fact), rename, move between groups or between the environment and a setting, or remove. For a new value, it decides its home; if the value is code or user data, it says so and stops.
- Finds every read and every dependent: other settings, presets, rows your app keeps, and work a change sets off.
- Settles the meaning. With a pdd-kit Product Model, a new setting or a
change in what one means is a product change: it drafts the fact with
tunables model draftand brings it to/pdd-ideate. Without one, it writes the field'shelpin the product's words. - Designs the field and its checks: key, kind, unit, default, bounds,
section, effects and fact or label; when your app has
scopes, whether a workspace or a person may set their own
(
override, freely or at most or at least what they inherit); therulesit joins, the guard for app data that depends on it and theholdon the write that saves such data, thewithinfor presets it bounds, and theconfirmfor a costly change. Whatever you did not state, it presents for approval first. - Writes the change: the definition, new effects or units, each read
replaced (at the workspace's or person's path,
get(group, { scope }), where their own value applies) and the old constant, fallback or environment read deleted, andtunables explainortunables envwhen they apply. - Plans stored values. A changed definition never changes a stored value,
so for each environment it says what
syncwill do and runs or hands you eachtunables setthe change needs. - Tests and checks: each new rule, guard and confirmation through
savewithtunables/testing, thentunables check, your typecheck, lint and tests.
Stored values, by kind of change
| Change | What happens to stored values |
|---|---|
| Add a field or group | sync stores it at its default. It must run before the new code reads it. |
| Change a default | Existing environments keep their value; set moves one that should change. |
| Tighten bounds, options or kind | A stored value outside them makes get throw. Move it inside with set before the code ships. |
| Rename or move a key | sync adds the new key at its default and keeps the old one. set the new key to the old value in each environment. |
| Remove a field or group | sync reports the stored key as undeclared and keeps it. |
| Environment to setting | Add the field; after sync, set the value each environment ran with; remove the variable. |
| Setting to environment | Read each environment's value first, add the deployment value, remove the field, set the variable where it differed. |
| Allow an override, or loosen its bound | Nothing stored changes; each scope inherits until it sets its own. |
| Stop allowing an override at a scope | Overrides stored there are kept and still read. Clear each with set --scope … --inherit key first, then ship the change. |
| Bound an override that was free | An override outside the new bound stays until the next save at or above its scope is refused, naming it. Move each inside with set --scope first. |
Ask for it
Make the export batch size tunable, between 100 and 5000.
Lower the default Tasks per project to 150, and tell me what happens in production.
Let each person lower their own AI suggestions a day, never above their workspace's.
Move
LOG_LEVELinto a deployment value with a default.
tunables-adopt
Bring tunables into an app that has none yet, from an inventory of every value to a wired, synced app with the old homes removed.
tunables-verify
Audit an app's tunables against their rules, report every finding with where it is and the rule it breaks, and fix only the findings you choose.