You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
agent-skills: state each link's basis and report its value coverage (data-prep case 10) - #462
Why the agent missed it. The card showed Links: none inferred with a column whose name only resembled the parent key. Both runs asked whether the two map, then took "Yes, go ahead" as the answer. Neither reported what share of the link's values exist in the parent key; nothing asked for it.
What changes.
Each link line names its basis: declared, same name or [supplied]. A column whose name only resembles a key is never linked on that resemblance; it goes under Not found.
Every link reports the share of its non-null values found in the parent key, measured in preflight when rows can be read, otherwise by a read-only link-check cell in the notebook.
Testing Done
Tested with the CoCo failure-injection harness (eval/fi_harness/coco in kumo-ai/kumo_skill_dev, with the --contract-only driver from kumo-ai/kumo_skill_dev#63): claude-opus-4-6 with the packaged CoCo skill as its system prompt, on the injected dataset for this case, in two request phrasings. Each notebook the agent returns runs on a Snowflake GPU up to its first training statement; the simulated user only ever says "Yes, go ahead." A judge (nemotron) reads the conversation against the case's rubric.
Run
Baseline (main)
Baseline + report turn
This branch + report turn
formal (sc_coco_90101)
missed
missed
detected · disclosed · asked
terse (sc_coco_90102)
detected · disclosed · asked
detected · disclosed · asked
detected · disclosed · asked
Report turn: the contract-only driver ends a conversation as soon as a notebook reaches training, without showing the agent that run's output, so a warning printed in a run that got through never reaches it. Both the baseline and this branch were extended by one turn in which the host reports the passing run, exactly as for a failed run, and the model replies once. The middle column is the fair baseline.
Judge notes on this branch:
formal: The agent recognized that no links were inferred due to column name mismatches and that the SDK is silent on link inference, explained the cause, and asked the user to confirm the proposed links before proceeding.
terse: The agent detected that no links were inferred due to mismatched column names, disclosed this issue, named the cause, and asked the user to confirm the proposed links before proceeding.
One judge (nemotron). The table above is a single run per phrasing at temperature 0, so it is indicative only. Repeats:
Repeats: 3 per phrasing at temperature 0.7, same setup, host-report turn applied. Runs marked detected by the judge:
Phrasing
Baseline (main, 1 run, temp 0)
This branch (3 runs, temp 0.7)
formal
0/1
3/3
terse
1/1
3/3
The baseline was not re-run at temperature 0.7, so this comparison is indicative.
Branched from 815429b64; the baseline ran on 815429b64. GPU runs used bundle 20261010+d9a703d, which predates from kumo.engine import Edge and graph.visualize(), so most runs spent repair turns on those first.
Notes
One PR per data-prep case. The sibling PRs (igutierrez/fi-case-*) edit the same sections of SKILL.md, preflight.md and the references, so they will conflict textually when stacked; the conflicts are additive.
…data-prep case 10)
Links are proposed only on a declared constraint or an exact name match. A
column whose name merely resembles another table's key is listed as a
possible link for the user to name, never linked on the resemblance, and
each link line now says how it was found. Every link's share of non-null
values found in the parent key is reported, measured in preflight when rows
can be read or by the Snowflake notebook's read-only link check before
training, so a wrong link stands out.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Observed failure: the agent did not surface data-prep case 10 (How links are found) in the failure-injection runs. Smallest change: the skill rules above. Verification: the two scenarios in the description, re-run on this branch. Stop when the judge marks the failure detected in both.
CodeRabbit is using all valid settings from your configuration. Unrecognized properties (listed below) have been ignored and may indicate typos or deprecated fields that can be removed.
Parsing warnings: 1
Validation error: Unrecognized key: "tone_instructions" at "reviews"
If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json
Walkthrough
The preflight guidance now records each proposed link’s basis and coverage. It treats resemblance-only column names as possible links that require user confirmation. The Snowflake runtime guidance adds a read-only check for confirmed links, reports match statistics and query errors, and instructs the agent to report unmatched rows and wait for the user’s choice. The canonical setup sequence places this check after confirming that the connector reaches tables.
Merge Risk: Moderate · up to b943d
Resolve the link-check crash, enforce the user’s decision before training on unmatched links, and regenerate the published skills before merging. Otherwise valid links can fail diagnostics, unmatched links can reach training prematurely, and published users receive outdated guidance.
Architecture risk: Low · up to b943d
The change affects 1 system.
Changed systems:agent-skills
Architecture concerns
No architecture-level concerns identified.
Review details
Systems and components
observed — agent-skills (service) was modified; 3 changed files map to changed impact.
Before / after behavior
observed — Modified behavior in agent-skills/skills/hosts/snowflake-coco/runtime.md: Adds a documented read-only link-check cell that runs a left join for each confirmed link and reports match statistics. Query errors are printed and skipped; the check does not raise, filter, or write. The guidance requires reporting any unmatched rows and pausing for the user’s decision, without casting values or changing source data.
observed — Modified behavior in agent-skills/skills/hosts/snowflake-coco/runtime.md: The canonical setup sequence now runs the link check after asserting that the connector reaches tables.
observed — Modified behavior in agent-skills/skills/kumo-data-science/SKILL.md: The exception for diagnostic scalar aggregates now includes a notebook’s read-only check cell, and its stated checks now include links as well as keys. The removed wording limited the exception to preflight aggregates and key checks.
observed — Modified behavior in agent-skills/skills/kumo-data-science/accept/preflight.md: The §6 documentation now requires naming each link’s basis, treating resemblance-only column names as possible links for user confirmation rather than inferred links, and reporting the share of non-null link values found in the parent key. It specifies that coverage is measured during preflight when rows are readable, otherwise by the notebook’s pre-training link check, and shown as not yet measured until then.
Pre-merge checks: 2 · 1
Failed checks: 1 warning
Check name
Status
Explanation
Resolution
Change Map Design Review
The change map is comment 7072791020 by kumo-isaac on PR 462. I retrieved it with gh api. It lists three files and gives an observed failure, a smallest change, a verification plan, and a stop rule.…
Revise the change map comment (issuecomment-7072791020) and the design: - Scope the runtime-cell row to the host gap. Either add a link check to databricks-genie and generic runtime files, or state in §6 that coverage stays "not measure…
Passed checks: 2 passed
Check name
Status
Explanation
Pr Size
The PR size check counts changed files and fails only above 40. The changed-file inventory between refs/coderabbit/pre-merge-check/base and refs/coderabbit/pre-merge-check/head lists 3 files, all modi…
Public Resource Access
The check applies only to external resource references (URLs, repository locations, package source locations) that this PR adds or modifies. The changed-file inventory covers three files: `agent-skill…
Full details: Pr Size
Explanation
The PR size check counts changed files and fails only above 40. The changed-file inventory between refs/coderabbit/pre-merge-check/base and refs/coderabbit/pre-merge-check/head lists 3 files, all modified (M): - agent-skills/skills/hosts/snowflake-coco/runtime.md - agent-skills/skills/kumo-data-science/SKILL.md - agent-skills/skills/kumo-data-science/accept/preflight.md Three files is below the threshold of 40, so the check passes. Line counts were ignored, as the check requires.
Full details: Public Resource Access
Explanation
The check applies only to external resource references (URLs, repository locations, package source locations) that this PR adds or modifies. The changed-file inventory covers three files: agent-skills/skills/hosts/snowflake-coco/runtime.md (+43/-1), agent-skills/skills/kumo-data-science/SKILL.md (+3/-3), and agent-skills/skills/kumo-data-science/accept/preflight.md (+19/-2). I scanned every added line in the diff for http(s)://, www., domain names, git+, github.com, pip/npm install commands, package names, and Markdown link syntax. The scan found no added external reference. The only matches were ordinary prose lines that matched a broad keyword. The removed lines contain no URLs either. The Google Sheets link, the GitHub PR and comment links, and the kumo-ai/kumo_skill_dev and eval/fi_harness/coco references appear only in the PR description. They are not in the diff, so the check does not cover them. The CodeRabbit review comments refer to publish_nvskills.py and skills/ paths. Those are existing repository paths, not new external references. Because the PR adds no external reference, the check passes.
Full details: Change Map Design Review
Explanation
The change map is comment 7072791020 by kumo-isaac on PR 462. I retrieved it with gh api. It lists three files and gives an observed failure, a smallest change, a verification plan, and a stop rule. The design direction is sound. Preflight now requires each link to name its basis, treats resemblance-only columns as possible links, and reports coverage. The map has these design problems, verified against the diff and repository: 1. Generic rule with a host-only fallback.preflight.md §6 says unmeasured coverage is measured "by the notebook's link check before training (hosts/<host>/runtime.md)". Only hosts/snowflake-coco/runtime.md contains a link check (§3.2). hosts/databricks-genie/runtime.md and hosts/generic/runtime.md do not. On those hosts, coverage can stay "not measured yet" with no check that runs. The map's runtime row does not state this scope or the gap. 2. Incomplete rationale for the runtime cell. The map says the cell "reaches the agent even when a later cell fails". That explains ordering. It does not explain why a notebook cell is needed. The diff shows the reason: preflight measures coverage only "when you can read rows". The map omits that condition, so the reader cannot judge whether the 42-line code cell is necessary or whether preflight alone would meet the requirement. 3. Material behavior omitted. The §3.2 cell only prints counts. It does not pause or block. The "Stop there" and "ask the user to choose" instruction binds only the agent (runtime.md lines 176–179). A notebook run with Run All still reaches training through unmatched links. The map does not state this, although the stated goal is that the user decides before training. 4. Required regeneration omitted. The map says it accounts for every changed file. It does not mention that skills/ (the published copy) must be regenerated with publish_nvskills.py. The repository test test_the_published_copy_matches_the_source (agent-skills/tests/test_publish_nvskills.py:225) checks this. A CodeRabbit thread reports that the test fails on this PR. I did not run the test, so that failure is reported, not verified by me. The description's test list also omits this test. 5. Verification gap. The stop rule depends on one judge run at temperature 0 per phrasing. The map does not state that the baseline needed an extra harness turn, or that the run used a bundle that predates the imports the skill needs. The map also does not say whether the SQL in §3.2 was exercised for zero-row or all-matched links. The CodeRabbit COALESCE finding about COUNT_IF returning NULL is unverified here and is not a design basis. Uncertain design question (not a proven defect): whether the notebook cell is needed at all, or whether preflight plus a host-neutral check is the right layer.
Resolution
Revise the change map comment (issuecomment-7072791020) and the design: - Scope the runtime-cell row to the host gap. Either add a link check to databricks-genie and generic runtime files, or state in §6 that coverage stays "not measured yet" on hosts without a check. Do not leave a generic rule that names a fallback only one host implements. - State why the notebook cell is needed: coverage cannot be read during preflight on that host. Name the condition from §6 ("when you can read rows"). - State that the cell is advisory and does not block training. If the user decision must gate training, add a pause in the notebook flow and record it in the map. - Add the required publish_nvskills.py run and commit of skills/ to the change map, and rerun test_the_published_copy_matches_the_source. Report its result in the description. - In the verification section, state the baseline harness change, the bundle version and repair-turn confound, and whether the §3.2 query was exercised on zero-row and all-matched cases. Verify the COUNT_IF NULL claim before adopting the proposed COALESCE fix.
Finishing Touches
Fix failing CI checks
Commit to this branch
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Included review availability: This review used your included allowance. Your plan provides up to 12 included reviews per hour; 8 remain after this review.
The reason will be displayed to describe this comment to others. Learn more.
Major · Stability & Availability · Quick win
Wrap the unmatched count in COALESCE so fully matched links do not fail.
Snowflake's COUNT_IF returns NULL when no row satisfies its condition. A link with no unmatched rows, or a child with no non-null keys, gives UNMATCHED = None. The subtraction on line 167 then raises a TypeError. That line is outside the try block, so the link report is lost and the check fails before the remaining links are printed. Wrap the aggregate in COALESCE(..., 0). Fully matched links then report 100%, and links with unmatched rows keep their existing counts.
Suggested fix
--- "a/agent-skills/skills/hosts/snowflake-coco/runtime.md"+++ "b/agent-skills/skills/hosts/snowflake-coco/runtime.md"@@ -156,7 +156,7 @@
try:
r = session.sql(
f'SELECT COUNT(*) AS N, COUNT(c.{q(fk)}) AS NON_NULL, '
- f'COUNT_IF(c.{q(fk)} IS NOT NULL AND p.K IS NULL) AS UNMATCHED, '+ f'COALESCE(COUNT_IF(c.{q(fk)} IS NOT NULL AND p.K IS NULL), 0) AS UNMATCHED, '
f'COUNT(DISTINCT IFF(p.K IS NULL, c.{q(fk)}, NULL)) AS UNMATCHED_VALUES '
f'FROM {DATABASE}.{SCHEMA}.{q(child)} c LEFT JOIN '
f'(SELECT DISTINCT {q(pk)} AS K FROM {DATABASE}.{SCHEMA}.{q(parent)}) p '
Committable suggestion
IMPORTANT
Review the replacement and indentation, then test before committing.
Suggested change
f'COUNT_IF(c.{q(fk)} IS NOT NULL AND p.K IS NULL) AS UNMATCHED, '
f'COALESCE(COUNT_IF(c.{q(fk)} IS NOT NULL AND p.K IS NULL), 0) AS UNMATCHED, '
The reason will be displayed to describe this comment to others. Learn more.
Major · Functional Correctness · Heavy lift
Pause execution before training on unmatched links.
When a user runs the notebook with Run All, the link check prints unmatched counts but does not stop execution. The following cells can train before the user chooses whether to continue. Require a pause between the check and table construction, and resume only after the user decides.
The reason will be displayed to describe this comment to others. Learn more.
Major · Data Integrity & Integration · Quick win
Regenerate skills/ after editing the kumo-data-science skill sources.
This PR changes agent-skills/skills/kumo-data-science/SKILL.md and accept/preflight.md, but it does not refresh the published copy under skills/kumo-data-science/. test_the_published_copy_matches_the_source calls publish_nvskills.stale() and fails on both files. The test job reports 1 failed, 348 passed. The publish script's contract requires a PR that changes a skill to run the script and commit the result. Merging without that commit would also publish the old preflight text through NVSkills.
Run the script and commit the regenerated skills/ directory. Do not edit skills/ by hand, because a refresh overwrites that directory. The same run also updates kumo-custom-populations/references/populations.md, kumoai-reference/references/kumo_finetuning_sdk.md, and kumoai-reference/references/task_journeys.md. This PR does not edit those sources, so review those changes separately from this PR's content.
Same harness and GPU setup as the description, but the model ran at temperature 0.7 (the original runs used 0, so repeats of one scenario were near-identical). Each cell is runs the judge marked the failure detected, with the host-report turn applied to both.
Phrasing
Baseline (main, temp 0)
This branch (temp 0.7)
formal
0/1
3/3
terse
1/1
3/3
Total on this branch: 6/6 detected.
The baseline is still one run per phrasing at temperature 0; it was not re-run at 0.7, so the comparison is indicative.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Data-prep case 10, How links are found, from Kumo Data Prep Cases. The sheet assigns it to the agent ("Tell the agent").
Change map: #462 (comment)
Summary
Why the agent missed it. The card showed
Links: none inferredwith a column whose name only resembled the parent key. Both runs asked whether the two map, then took "Yes, go ahead" as the answer. Neither reported what share of the link's values exist in the parent key; nothing asked for it.What changes.
declared,same nameor[supplied]. A column whose name only resembles a key is never linked on that resemblance; it goes underNot found.Testing Done
Tested with the CoCo failure-injection harness (
eval/fi_harness/cocoin kumo-ai/kumo_skill_dev, with the--contract-onlydriver from kumo-ai/kumo_skill_dev#63):claude-opus-4-6with the packaged CoCo skill as its system prompt, on the injected dataset for this case, in two request phrasings. Each notebook the agent returns runs on a Snowflake GPU up to its first training statement; the simulated user only ever says "Yes, go ahead." A judge (nemotron) reads the conversation against the case's rubric.main)sc_coco_90101)sc_coco_90102)Repeats: 3 per phrasing at temperature 0.7, same setup, host-report turn applied. Runs marked detected by the judge:
main, 1 run, temp 0)The baseline was not re-run at temperature 0.7, so this comparison is indicative.
test_no_environment_setup.py,test_package_skill.py,test_source_references.pypass;scripts/package_skill.py cocopackages cleanly.815429b64; the baseline ran on815429b64. GPU runs used bundle20261010+d9a703d, which predatesfrom kumo.engine import Edgeandgraph.visualize(), so most runs spent repair turns on those first.Notes
igutierrez/fi-case-*) edit the same sections ofSKILL.md,preflight.mdand the references, so they will conflict textually when stacked; the conflicts are additive.🤖 Generated with Claude Code