@datama/studio-skill-instructions 1.1.8 → 1.1.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/INSTRUCTIONS.md +21 -21
  2. package/package.json +1 -1
package/INSTRUCTIONS.md CHANGED
@@ -37,7 +37,7 @@ Column names are exact tokens from the data: never translate, pluralize, rename
37
37
  **`language`, always:** `fr-FR` when the user writes in French, `de-DE` in German, `es-ES` in Spanish, otherwise `en-US`. It sets the language of the generated titles, comments and labels, not of the data. **`title`:** the user's question, in their language.
38
38
 
39
39
  **`metrics`, ordered.** Studio turns them into steps `metrics[0]`, then `<metrics[i]> per <metrics[i-1]>`, multiplied together, so a change is explained by each link of the chain.
40
- - Which: the ones the user names; otherwise every raw numeric column, without precomputed ratios or averages (`rate`, `avg`, `%`, `ROAS`, `CTR`, `AOV`, …) unless asked for. One metric is fine: the change is then explained by segments only.
40
+ - Which: the ones the user names; otherwise every raw numeric column, without precomputed ratios or averages (`rate`, `avg`, `%`, `ROAS`, `CTR`, `AOV`, …) unless asked for. A question about one KPI ("why did margin fall") also takes the volume columns that lead to it (`Visits` → `Signups` → `Margin`), so the change is split by link. One metric alone explains the change by segments only.
41
41
  - Order: the business flow. Web: sessions → product views → add to cart → checkout → orders → revenue. Acquisition: cost → impressions → clicks → sessions → conversions → revenue. Subscription: expirations → renewals → revenue. Otherwise: column order.
42
42
  - Custom equation, only when the meaning requires it: `steps` (each `{"numerator", "denominator"}`, named `"<numerator> per <denominator>"`) and `formula` over step indices `[1]`…`[N]`. Cost per unit: `[1]+[2]+[3]` over `Cost_x / Units` steps. NPS: `([1]-[2])*100` over `Promoters / Answers`, `Detractors / Answers`. Details: [market-equation.md](references/market-equation.md).
43
43
  - `totalStepName`: the KPI computed, in business words (`Revenue`, `ROAS`, `NPS`), never a step name like `Revenue per Orders`. `totalStepUnit`: `"€"` for money, `"%"` for a percentage, otherwise `""`.
@@ -51,13 +51,13 @@ Column names are exact tokens from the data: never translate, pluralize, rename
51
51
 
52
52
  ## Commands
53
53
 
54
- | Command | What it does |
55
- | --- | --- |
56
- | `python3 scripts/datama.py instructions [references/<file>.md]` | Prints this workflow, or one reference |
57
- | `python3 scripts/datama.py build --data <file> --config '<json>' [--theme '<json>'] [--license '<token>'] --out page.html` | Builds and checks the page. `--from page.html` edits an existing page |
58
- | `python3 scripts/datama.py validate page.html` | Checks a page without rebuilding it |
59
- | `python3 scripts/datama.py settings <topic> [word]` | Lists the settings Studio exposes, then the value of one (below) |
60
- | `python3 scripts/datama.py source '<regex>' [--context 5]` | Searches the readable Studio build. Last resort, after `settings` (see "Changing a setting") |
54
+ | Command | What it does |
55
+ | -------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- |
56
+ | `python3 scripts/datama.py instructions [references/<file>.md]` | Prints this workflow, or one reference |
57
+ | `python3 scripts/datama.py build --data <file> --config '<json>' [--theme '<json>'] [--license '<token>'] --out page.html` | Builds and checks the page. `--from page.html` edits an existing page |
58
+ | `python3 scripts/datama.py validate page.html` | Checks a page without rebuilding it |
59
+ | `python3 scripts/datama.py settings <topic> [word]` | Lists the settings Studio exposes, then the value of one (below) |
60
+ | `python3 scripts/datama.py source '<regex>' [--context 5]` | Searches the readable Studio build. Last resort, after `settings` (see "Changing a setting") |
61
61
 
62
62
  ## Changing a setting
63
63
 
@@ -65,24 +65,24 @@ Every setting, its allowed values and its default are defined by Studio, not by
65
65
 
66
66
  1. **Find the setting by its description.** Run `settings <topic>` with no word. It prints `name: description` from the index. Keep the name whose description matches the request.
67
67
 
68
- | Request | Topic | Index |
69
- | --- | --- | --- |
70
- | Analysis of a solution | `compare` · `explore` · `detect` · `pivot` | `contract/solutions-settings.json` |
71
- | Colors, palette, style preset, page chrome | `theme` | `contract/ui-settings.json` |
72
- | Story canvas (padding, card, shadow) | `appearance` | `contract/ui-settings.json` |
73
- | Chart title and subtitle, comment and table panes, axis, legend, margins, labels, bars, lines, waterfall, tree cards, table, animations | `plotter` | `contract/ui-settings.json` |
68
+ | Request | Topic | Index |
69
+ | --------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------ | ---------------------------------- |
70
+ | Analysis of a solution | `compare` · `explore` · `detect` · `pivot` | `contract/solutions-settings.json` |
71
+ | Colors, palette, style preset, page chrome | `theme` | `contract/ui-settings.json` |
72
+ | Story canvas (padding, card, shadow) | `appearance` | `contract/ui-settings.json` |
73
+ | Chart title and subtitle, comment and table panes, axis, legend, margins, labels, bars, lines, waterfall, tree cards, table, animations | `plotter` | `contract/ui-settings.json` |
74
74
 
75
75
  2. **Read the value to write.** Run the same command with that name. It prints `default`, `values`, `min` and `max` from `contract/solution/<solution>-settings.json` or `contract/ui/<topic>-settings.json`. Write one of those values. `settings theme <palette>` prints a palette's colors.
76
76
 
77
77
  3. **Write it where the page reads it.**
78
78
 
79
- | Topic | Where | Example |
80
- | --- | --- | --- |
81
- | A solution | `--config`, a top-level key (or one module of `modules`) | `{"waterfallMeasure": "Pts_gap"}` |
82
- | `theme`, `colors.*` | `--theme`, the dotted name as nested keys | `{"colors": {"waterfall": {"Up": "#1E9E6A"}}}` |
83
- | `theme`, `stylePreset` | `--config`, a Compare module input | `{"stylePreset": "presentation"}` |
84
- | `appearance` | `--config`, under `appearance` on the story | `{"appearance": {"radius": 12}}` |
85
- | `plotter` | `--config`, under `plotter`, the dotted name as nested keys | `{"plotter": {"legends": {"position": "bottom"}}}` |
79
+ | Topic | Where | Example |
80
+ | ---------------------- | ----------------------------------------------------------- | -------------------------------------------------- |
81
+ | A solution | `--config`, a top-level key (or one module of `modules`) | `{"waterfallMeasure": "Pts_gap"}` |
82
+ | `theme`, `colors.*` | `--theme`, the dotted name as nested keys | `{"colors": {"waterfall": {"Up": "#1E9E6A"}}}` |
83
+ | `theme`, `stylePreset` | `--config`, a Compare module input | `{"stylePreset": "presentation"}` |
84
+ | `appearance` | `--config`, under `appearance` on the story | `{"appearance": {"radius": 12}}` |
85
+ | `plotter` | `--config`, under `plotter`, the dotted name as nested keys | `{"plotter": {"legends": {"position": "bottom"}}}` |
86
86
 
87
87
  On Explore, any `plotter` replaces Explore's default look: add one only for a precise request. For a color-only request, set `colors.palette` and leave `stylePreset` unset.
88
88
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@datama/studio-skill-instructions",
3
- "version": "1.1.8",
3
+ "version": "1.1.9",
4
4
  "description": "Workflow and references of the datama-studio agent skill, read at run time by its scripts/datama.py.",
5
5
  "files": [
6
6
  "INSTRUCTIONS.md",