Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions agent-skills/skills/kumo-data-science/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ trainer, and `predict` runs against an explicitly rebuilt graph snapshot (see St
- Join, clean, deduplicate, aggregate, create labels, or transform data **as model input**.
Diagnostic scalar aggregates during preflight — reported as proposal evidence, never written and
never fed to training — are not this; they exist so a key can be checked before it silently
discards rows
discards rows, and an interval checked for rows that end before they start
- Search for, rank, or curate tables by business relevance
- Retry or resume jobs, or keep state across sessions. The one execution the agent performs is
Step 3, and only when the user asks.
Expand Down Expand Up @@ -338,7 +338,8 @@ in the same or a later turn. Then, per `kumoai-reference/references/kumo_finetun
- Report the outcome: the training metrics, or the exception and the cell that raised it
- **Read what Kumo said about the data first.** A warning or error about the data — duplicate
primary keys, a foreign key that matched few rows, invalid values read as null, a float or
mismatched key, an empty training table — leads the report, with the table, column and count,
mismatched key, an empty training table, or a nonzero count from a read-only check cell such as
rows whose interval ends before it starts — leads the report, with the table, column and count,
and the decision goes to the user: fix the source, change the key or link, or accept the loss.
A run that finished is not a success until they have decided. Never change the data, a column's
type or the query to make such a message go away
Expand Down
21 changes: 19 additions & 2 deletions agent-skills/skills/kumo-data-science/accept/preflight.md
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,21 @@ Decide by semantic role, never by a fixed column-name list. Record every exclusi
in the proposal. Where the role is genuinely ambiguous, do not invent one — show the column as an
exclusion the user can overturn at the gate, rather than asking the user for column names.

**An interval that ends before it starts.** When a row carries both ends of one interval — its

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Major · Functional Correctness · Quick win

Update the published skill copies.

The Agent Skills pytest run fails because test_the_published_copy_matches_the_source found six stale published files. Run python3 agent-skills/scripts/publish_nvskills.py and commit the updated copies.

Source: Pipeline failures

time column and a later timestamp that closes the same interval (a delivery, resolution, end or
expiry time), decided by semantic role — count the rows whose end precedes their start, whether
Comment on lines +172 to +174

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Major · Functional Correctness · Quick win

Count inverted same-row intervals whose start is not the time column.

The §5 rule counts only rows whose time column opens the interval. A row can carry another interval, such as START_AT and END_AT, while its selected time column is EVENT_AT. The rule does not cover that pair. The notebook fallback reads the same graph-gate scope, so it does not cover the pair either.

Change the rule to count every same-row interval pair that semantic role identifies, whichever column is the time column. Apply the same scope to the graph-gate definition of an interval in SKILL.md lines 187-190, so the notebook fallback reaches these pairs.

or not the end column stays a feature. Kumo accepts such rows without a check.

```sql
SELECT COUNT(*) AS N, SUM(CASE WHEN <END> < <START> THEN 1 ELSE 0 END) AS N_END_BEFORE_START
FROM <DB>.<SCHEMA>.<TABLE>;
```

Report a nonzero count under `Not found` with the table, both columns and the count, and let the
user decide; never correct, filter or drop those rows. When the preflight result in hand did not
run this probe (a host-supplied result that read only key probes), name the pair in the proposal
as not yet counted: the notebook counts it (`kumoai-reference/SKILL.md` Step 4).

## 6. Links

A link is proposed when a column in table A has the **same name** as the primary key of table B
Expand Down Expand Up @@ -220,6 +235,7 @@ Excluded columns
Not found
- payments: no primary key inferred [inferred] — treated as keyless; edge source only unless corrected
- events: no usable time column [inferred] — a time-ranged target cannot reference this table
- fraud_events: 37 of 120,000 rows have RESOLVED_AT before EVENT_AT [inferred] — reported, not corrected
- ...

Confirm, or correct any line (your values take precedence).
Expand All @@ -232,8 +248,9 @@ format.

- Prepare, transform, aggregate or materialize **model inputs** — joining, cleaning,
deduplicating, creating labels. A diagnostic scalar aggregate over source rows is permitted
solely as evidence for the proposal: row, distinct and null counts for a proposed or candidate key. Its
result is reported and then discarded; it is never written anywhere and never reaches training.
solely as evidence for the proposal: row, distinct and null counts for a proposed or candidate key,
and the count of rows whose interval ends before it starts (§5). Its result is reported and then
discarded; it is never written anywhere and never reaches training.
- Rank tables by relevance or drop tables the user did not ask to drop.
- Proceed to PQL before the proposal is confirmed.
- Ask the user for columns, types, keys or joins — with one exception: when §0 finds you cannot
Expand Down
5 changes: 5 additions & 0 deletions agent-skills/skills/kumoai-reference/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,11 @@ Before returning code:
exclusions.
- If the active host adapter restricts a semantic type, confirm the generated code includes the
adapter's runtime type guard before `graph.snapshot()`.
- For every interval the graph gate named but preflight did not count
(`kumo-data-science/accept/preflight.md` §5), the notebook counts the rows that end before they
start, read-only, before `graph.snapshot()` — through the host's own SQL session
(`kumoai-reference/references/kumo_finetuning_sdk.md` §3.3), never the Kumo connector — and
prints the table, both columns and the count. It reports; it never filters.
- Confirm that the output table in the generated code matches the output location from the original request.
- Check against known error patterns in `kumoai-reference/references/troubleshooting_signals.md`.

Expand Down
Loading