On this page
skryba writing-style samples
Work out how many rewritten pairs each kind and length of the person's
writing still needs, have the model write those samples, and keep the
person's rewrite of each one. A pair the person keeps is their text against
the model's on the same subject, which is what
writing-style train --method dpo trains on; the plan
makes those pairs cover the person's writing evenly instead of wherever they
happened to start.
Invocation
skryba [GLOBAL OPTIONS] writing-style samples plan --pairs <N> --length-bands <N>
skryba [GLOBAL OPTIONS] writing-style samples generate --pairs <N> --length-bands <N> --temperature <T> --seed <N>
skryba writing-style samples list
skryba writing-style samples show <ID>
skryba writing-style samples remove <ID> [--yes]
How the plan is worked out — length bands, strata and the largest-remainder share — is the sample plan.
plan
Reads the held passages, the samples already written and the pairs already kept, and reports the plan. It writes nothing and calls no model.
| Flag | Default | Meaning |
|---|---|---|
--pairs <N> |
required | rewritten pairs wanted in total, kept pairs included |
--length-bands <N> |
required | bands the held passages are ranked into by length, each holding an equal share of them |
generate
Works out the same plan, then for every stratum short of its share draws
held passages of that kind and length that seeded no sample yet, in an order
--seed fixes, and asks the Brama model once per passage to write a passage
on the same subject, at about the same length, the way a general-purpose
assistant writes by default, without reusing the person's wording. Each
sample is stored as it lands, so a failure keeps what was already written.
A plan with nothing left to write calls no model and needs no credential.
--temperature is the sampling temperature the model is called with; only
a non-finite or negative value is refused here, and Brama states its own
bound. --brama-url (or BRAMA_URL), --model (or SKRYBA_MODEL) and
BRAMA_TOKEN_ROLE are read as rewrite reads them.
When a stratum has fewer unused passages than samples to write, the rest is
reported in unfilled: harvest or add more writing of that kind.
list, show, remove
list prints every sample without its text: id, the passage that seeded it,
its kind, the seed's words, the model that wrote it, and the kept pair that
rewrote it (absent while it waits). show prints one sample with the
model's text, machine — the text the person rewrites and keeps with
writing-style keep --sample <ID>.
remove deletes one sample nobody rewrote. It is irreversible, so without
--yes it names the sample and removes nothing. A sample a kept pair
rewrote is refused; take the pair back with unkeep first.
Output
The writing-style report, with:
plan {pairs, length_bands, bands: [{lowest_words, highest_words}],
strata: [{kind, band, lowest_words, highest_words, passages, target,
kept, pending, generate, unused_seeds}],
kept, pending, generate, kept_outside_plan}; plan and generate
samples [{id, seed, kind, words, model, created_at, pair}]; list, and what generate wrote
sample {id, seed, kind, words, model, created_at, pair, machine}; show and remove
unfilled samples the plan asked for that no unused passage could seed; generate only
kept_outside_plan counts pairs kept from a rewrite or by hand: they train
the adapter but belong to no stratum.
Example
skryba writing-style samples plan --pairs 200 --length-bands 4
skryba --brama-url "$BRAMA_URL" --model "$SKRYBA_MODEL" \
writing-style samples generate --pairs 200 --length-bands 4 --temperature 0.8 --seed 7
skryba writing-style samples show <ID>
printf '{"sample":"<ID>","kept":"How I would have said it."}' | skryba writing-style keep
Refusals
--pairs must be positive: it is how many rewritten pairs you want.--length-bands must be positive: one band treats every length alike.the writing-style store holds no passages; a plan divides the pairs by the writing you hold, so run `skryba writing-style add` or `skryba writing-style harvest run` first.temperature must be a finite number of at least 0.--brama-url (or BRAMA_URL) is required for this commandand--model (or SKRYBA_MODEL) is required for this command— clap's usage error, exit2, only when the plan has samples to write.BRAMA_TOKEN_ROLE is required for Brama inference: ROLE#FIELD of the vault role holding the client token, and every Brama refusal in its own words (Brama returned <STATUS>: <BODY>).no sample has id <ID> in <STORE>; `skryba writing-style samples list` lists them—showandremove.sample <ID> was rewritten as kept pair <PAIR>; take the pair back with `skryba writing-style unkeep <PAIR>` first.removing sample <ID> would delete the model's text written for a <N>-word <KIND> passage (<SEED>) from <STORE>; repeat with --yes to remove it.creating the samples table in …,adding a sample to …,reading sample <ID> from …carry Postgres's own sentence.
Maintained as part of the website-owned Skryba documentation corpus.