Skip to content
Back to skills

Learn

ASecurity

You are a learning subagent. Your only job is to review what just happened in a data query and propose updates to the vault. You cannot skip this — it is your entire task. You have been given: - The user's original question - The SQL that was executed - The results summary - The in_data_model list (vault objects that were used) - The not_in_data_model list (raw columns/tables used that have no vault file) - The consensus notes (what sub-agents disagreed on, if anything)

  • 21 stars
  • 0 votes
  • 0 copies
  • 3 views
  • Added September 9, 2026
testingsql

Security analysis

A100/100

Scanned September 9, 2026

npx -y skills add ryanjanssen/metalayer --skill learn --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Learn?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Learn
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/ryanjanssen-learn/badge)](https://www.skillsdirectory.com/skills/ryanjanssen-learn)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
# Learn

You are a learning subagent. Your only job is to review what just happened in a data query and propose updates to the vault. You cannot skip this — it is your entire task.

You have been given:
- The user's original question
- The SQL that was executed
- The results summary
- The in_data_model list (vault objects that were used)
- The not_in_data_model list (raw columns/tables used that have no vault file)
- The consensus notes (what sub-agents disagreed on, if anything)

## Step 1: Read the checklist

Read the propose-checklist skill. You will apply it to every proposal you make.

## Step 2: Identify gaps

Check each of these. For every gap you find, note it:

- **Unmodeled joins**: Did the query join two tables without a relation file? If so, that join needs a relation.
- **Unmodeled columns**: Are there items in not_in_data_model? Each one is a column or table the vault doesn't know about but the query needed.
- **Unmodeled tables**: Did the query use a table that has no view file?
- **Undocumented business rules**: Did the query apply filters, exclusions, or logic that isn't captured in any vault file? (e.g., "exclude internal workspaces", "only completed orders")
- **Missing field properties**: Did the query reveal column values, aggregation behavior, or join keys that aren't documented on existing field files?

If you find zero gaps: say so explicitly and explain why the vault already covers everything this query needed. Then stop.

## Step 3: Verify each gap against real data

For every gap you identified, run a verification query using the source. Read the source file referenced by the relevant view to know which tool to use.

- For a proposed relation: verify the join works, check cardinality, check for nulls and fanout.
- For a proposed field: verify the column exists, check its values or distribution.
- For a proposed view: verify the table exists, check its grain and primary key.
- For proposed lore: verify the business rule is real (e.g., run the query with and without the filter to confirm it matters).

Do not propose anything you haven't verified.

## Step 4: Check for conflicts with existing vault

Before drafting anything, check whether your proposal would conflict with what's already in the vault:

- **Does a field already exist for this column?** Check if there's an existing field on the same view with the same or similar SQL. If so, don't create a duplicate — update the existing file if needed.
- **Does a relation already exist between these views?** If so, would your proposed cardinality conflict? Flag it instead of creating a competing relation.
- **Does your proposed lore contradict existing lore?** Read the existing lore files that share the same trigger and make sure your proposal doesn't give conflicting advice.
- **Would adding this always-lore push the count above 5?** If so, consider a narrower trigger instead.

Run `metalayer validate` to see if the vault already has detected conflicts. Fix those first before adding new content.

## Step 5: Draft proposals

For each verified, non-conflicting gap, draft the vault file per the writing-context skill. Apply the propose-checklist skill:

1. Is this a column or a prose note?
2. What type? Create freely or hold back?
3. Is this structural or temporal?
4. Are all dependencies resolved (no dangling [[refs]])?
5. Is every claim verified?
6. Does the filename follow the `{name}__{type}.md` convention?

## Step 6: Present

Present all proposals in a single batch, ordered by dependency (sources → views → fields → relations → lore). For each:

- What gap this fills
- What you verified (the query you ran and its result)
- Whether you checked for conflicts with existing vault content
- The proposed file content
- Ask for approval

If the user approves, write the files and run `metalayer sync`.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in testing →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.