Skip to content
Merged
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 CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@

## 0.2.4 (prepared; not yet published)

- Bundles the skills from metergraph/skills 93edccd, which use `tools call` for the
loop and start a classification when none is current.
- Bundles the skills from metergraph/skills e376bbd, which use `tools call` for the
model-swap workflow, start a classification when none is current, and offer
`login --role debug` with the `--allow-*` flags when the workflow needs more access.
- One key for an agent. The read commands and `experiments` accept a coding-agent key
with the Debug role and the workflow permissions a workspace owner grants (Allow
evaluation writes, Allow evaluation previews, Allow analysis starts) as well as a
Expand Down
17 changes: 9 additions & 8 deletions assets/skill/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ a command, and never put it in a project file. Ingest setup cannot run over SSH,
in a cloud workspace or in CI; it runs on the person's machine. The Metadata key
is separate from the application's ingest key and never replaces it. A CLI
whose help does not list `tools` refuses Debug and Replay keys rather than
reducing them; a loop-access key needs a newer metergraph CLI there.
reducing them; a key with the Debug role needs a newer metergraph CLI there.

## MCP routes, for clients without a shell

Expand Down Expand Up @@ -232,13 +232,14 @@ Use https://www.metergraph.dev/docs/ for public product documentation and https:
More Metergraph skills are at https://github.com/metergraph/skills. When the
person wants to know whether a workload could use a cheaper or better model, or
asks to run a model-swap analysis, use `metergraph-model-swap` if it is
installed; it walks the whole loop and hands each stage to its own skill. The
loop needs loop access (the Debug role plus Allow evaluation writes, Allow
evaluation previews and Allow analysis starts), which only a workspace owner
grants; that skill checks for it before the loop starts and says how to get it
on each deployment. If it is not installed, offer to install the skills (a separate verified installation from the skills repository, or in
Claude Code and Claude Desktop the plugin marketplace `metergraph/skills`)
rather than improvising the analysis steps.
installed; it walks the whole workflow and hands each stage to its own skill.
It needs the Debug role plus Allow evaluation writes, Allow evaluation previews
and Allow analysis starts, which only a workspace owner grants; that skill
checks for them before it starts and says how to get them on each deployment.
If it is not installed, offer to install the skills (a separate verified
installation from the skills repository, or in Claude Code and Claude Desktop
the plugin marketplace `metergraph/skills`) rather than improvising the
analysis steps.

## When already connected: bounded investigation

Expand Down
6 changes: 3 additions & 3 deletions assets/skill/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"name": "metergraph",
"file": "SKILL.md",
"source_url": "https://www.metergraph.dev/SKILL.md",
"sha256": "0946db53f82739da9ef2c44501b06b2734786be88fc3d30c84854b034462a8b4",
"size": 27971,
"revision": "sha256-0946db53f827"
"sha256": "f31c24c4074707df0e34502bd9efbfde4fff5703e6fd367e0f60692f9f5878ce",
"size": 27961,
"revision": "sha256-f31c24c40747"
}
44 changes: 22 additions & 22 deletions assets/skills/manifest.json
Original file line number Diff line number Diff line change
@@ -1,25 +1,25 @@
{
"manifest_version": 1,
"repository": "metergraph/skills",
"commit": "93edccdb047d68e55104217269bf66d662611694",
"commit": "e376bbde0d9ae3cf64adde2e08f6cb0cf0f2fee6",
"skills": [
{
"name": "metergraph-analyze",
"sha256": "0288ad9e420ae37dcbee0fd274045dc0fa3ffa674d68495979975e57f13a9b01",
"size": 18668,
"revision": "sha256-0288ad9e420a"
"sha256": "47d6abd05096e6232188e5ee6fb225de87961cdb59a57af0536c14e3b48fe3c5",
"size": 19165,
"revision": "sha256-47d6abd05096"
},
{
"name": "metergraph-candidates",
"sha256": "923b1866587cad563ba42db0ed0406539cf8a4fe513ac8a0642c1bf29eec40d4",
"size": 7118,
"revision": "sha256-923b1866587c"
"sha256": "823d8a1905ce28fd6336208326fbda6196ac4550654614289d4fd3a8cd391582",
"size": 7353,
"revision": "sha256-823d8a1905ce"
},
{
"name": "metergraph-evals",
"sha256": "0a96439daa30d0dcac6b4821bf14f12279cbb793bd3af21b6363fd71b1c14cc6",
"size": 9962,
"revision": "sha256-0a96439daa30"
"sha256": "4a8ccc2fdf7ae6dbd96d52d4595bbd41613296daa1d52cbeb04734f159a07512",
"size": 10232,
"revision": "sha256-4a8ccc2fdf7a"
},
{
"name": "metergraph-investigate",
Expand All @@ -29,9 +29,9 @@
},
{
"name": "metergraph-iterate",
"sha256": "32aaa19b7fce6c365a5935f9eeb69daca357e7e2c99f330ca2d8ac81febb6225",
"size": 7997,
"revision": "sha256-32aaa19b7fce"
"sha256": "6f5824b0bc5852e561c1a37f0c9afee6859d7209f070d1a2651c9ae92d29a707",
"size": 8283,
"revision": "sha256-6f5824b0bc58"
},
{
"name": "metergraph-local-bundle",
Expand All @@ -41,9 +41,9 @@
},
{
"name": "metergraph-model-swap",
"sha256": "7a76b7121a5a0b4312a3e5dec7abe8184ee3f492b980a04f872a9547229c7a5e",
"size": 11863,
"revision": "sha256-7a76b7121a5a"
"sha256": "d4166ece3a0d2b31bf8c6f623315e1b37000987dced71a86cb3d2a9ebabf6ef8",
"size": 12572,
"revision": "sha256-d4166ece3a0d"
},
{
"name": "metergraph-onboarding",
Expand All @@ -53,15 +53,15 @@
},
{
"name": "metergraph-report",
"sha256": "6deb06f24d3c4e7a0e0c19d964b79a4b3278bdc8524776829821897f3e921a18",
"size": 8236,
"revision": "sha256-6deb06f24d3c"
"sha256": "cdf21b4dcc3b11a9a3fad94a6dcfc6596b1c67937e2cf5ea4176b098f7163bdc",
"size": 8471,
"revision": "sha256-cdf21b4dcc3b"
},
{
"name": "metergraph-workloads",
"sha256": "40161aa823a859cc3a1b2a1dd644bb54cf33ac32f82546346da785413abccfa6",
"size": 9607,
"revision": "sha256-40161aa823a8"
"sha256": "83c2b7372ec39d7c59fb2ef148781f321b0511655c5348c9109c9a297bee2be5",
"size": 9842,
"revision": "sha256-83c2b7372ec3"
}
]
}
57 changes: 32 additions & 25 deletions assets/skills/metergraph-analyze/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ description: Take one classified Metergraph workload to a model-swap recommendat

This skill takes one classified workload to a recommendation: should this
workload move to a different model, and what would that do to quality and cost.
It is stage 4 of the `metergraph-model-swap` loop. Choosing the workload,
It is stage 4 of the `metergraph-model-swap` workflow. Choosing the workload,
candidates and eval first (`metergraph-workloads`, `metergraph-candidates`,
`metergraph-evals`) makes the result easier to act on, but is not required.
It adds no tools, scopes or authority, and works the same through the
Expand Down Expand Up @@ -69,15 +69,18 @@ as `metergraph tools call <tool> --args '<json object>' --json` and read
only when this skill's approval rule for that exact call is met. Exit code 18
with reason `confirmation_required` means `--yes` was missing; ask the person.

Name missing access by the job it does. **Read access** is the Metadata role
(`agent:metadata`). **Loop access** is the Debug role (`agent:read`) plus
**Allow evaluation writes** (`agent:eval-write`), **Allow evaluation
previews** (`agent:eval-preview`) and **Allow analysis starts**
(`agent:analysis-run`). On the CLI, `data.jobs.read` and `data.jobs.loop` in
`metergraph status --json` say which this key has (`available`, and the
scopes still `missing`); over MCP, the capabilities' `available` flags do.
Only a workspace owner grants loop access; **Loop access** in
`metergraph-model-swap` says how on each deployment.
Name missing access by its role and permissions. The **Metadata** role
(`agent:metadata`) reads usage, workloads, readiness and reports. Reading and
testing evals, saving them and starting runs need the **Debug** role
(`agent:read`) with **Allow evaluation writes** (`agent:eval-write`), **Allow
evaluation previews** (`agent:eval-preview`) and **Allow analysis starts**
(`agent:analysis-run`). On the CLI, `data.access` in `metergraph status --json`
gives the `role` and one boolean per permission (`allow_evaluation_writes`,
`allow_evaluation_previews`, `allow_analysis_starts`); an older CLI without
`data.access` reports only `scopes`. Over MCP, the capabilities' `available`
flags say what this key can do. Only a workspace owner grants the permissions;
**Granting Debug and the permissions** in `metergraph-model-swap` says how on
each deployment.

## 1. Check the tools and access

Expand All @@ -91,28 +94,32 @@ Only a workspace owner grants loop access; **Loop access** in
`analysis_start` capability with `available: true`. Do not guess a tool name
or substitute a dashboard API, replay, generic SQL or an ad hoc shell
command.
3. Reading needs read access. Starting needs the Debug role plus **Allow
analysis starts** (`agent:read` and `agent:analysis-run`), both part of loop
access. The start capability is classed `replay` because the run sends
captured content to providers, but it does not need `agent:replay`. Do not
request replay, read trace content or report evidence, or replay a trace to
reach a recommendation.
3. Reading needs the Metadata role. Starting needs the Debug role plus
**Allow analysis starts** (`agent:read` and `agent:analysis-run`). The
start capability is classed `replay` because the run sends captured content
to providers, but it does not need `agent:replay`. Do not request replay,
read trace content or report evidence, or replay a trace to reach a
recommendation.

## 2. When start access is missing

`metergraph setup` and the default sign-in grant read access only. Starting
`metergraph setup` and the default sign-in grant the Metadata role only. Starting
needs only the Debug role and **Allow analysis starts**; the evaluation
permissions belong to the full model-swap workflow, not to this step. If
`metergraph_start_analysis` is not listed or `analysis_start` is unavailable,
keep going with the read steps below, then tell the person once what to grant
for their deployment (`deployment_profile`):

- **Hosted** (`managed`). When the agent has a shell and `metergraph help
login` lists `--access`, run `metergraph login --access loop` with the
runtime and approval flags the `metergraph` skill uses for `login`; a
workspace owner approves the request on the consent page. Otherwise a
workspace owner creates a coding-agent key on the **Keys** page with the
**Model-swap loop** access choice. The person saves it in their own editor
login` lists `--role`, run `metergraph login --role debug
--allow-analysis-starts` (adding `--allow-evaluation-writes
--allow-evaluation-previews` only if they also want the agent to write and
test evaluations) with the runtime and approval flags the `metergraph` skill
uses for `login`; a workspace owner approves the request on the consent page.
Otherwise a workspace owner creates a coding-agent key with the Debug role
on the **Keys** page, then ticks **Allow analysis starts** for it under
Connection access and saves, which rotates the key; only the new token
works. The person saves it in their own editor
as `export METERGRAPH_AGENT_TOKEN=…` in a private file outside the project
(for example `~/.config/metergraph/agent.env`), runs
`. ~/.config/metergraph/agent.env` in the shell that starts the agent, and
Expand All @@ -129,9 +136,9 @@ for their deployment (`deployment_profile`):
command or client is a supported-release blocker; never use the local
browser Keys page or host HTTP as fallback. A consent-unavailable start is
not a missing scope and must not trigger key escalation.
- **Customer-owned AWS** (`byoc-core`) **or the open-source server.** Loop
access is not offered there: there are no managed evaluations and no trace
content. Say so once and stop before the start step.
- **Customer-owned AWS** (`byoc-core`) **or the open-source server.** The
workflow permissions are not offered there: there are no managed evaluations
and no trace content. Say so once and stop before the start step.

The same `METERGRAPH_AGENT_TOKEN` serves the CLI and an MCP configuration that
references it; a client without a shell takes the key in its private connector
Expand Down
23 changes: 13 additions & 10 deletions assets/skills/metergraph-candidates/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: metergraph-candidates
description: Choose the traces and candidate models for a Metergraph model-swap analysis - pick the environment and window, check provider readiness, shortlist candidates that fit the workload and the route's residency, and list the route settings (replay opt-out, limits) the person must change in the app. Use for "which models should we test", "set up the analysis", or stage 2 of the metergraph-model-swap loop.
description: Choose the traces and candidate models for a Metergraph model-swap analysis - pick the environment and window, check provider readiness, shortlist candidates that fit the workload and the route's residency, and list the route settings (replay opt-out, limits) the person must change in the app. Use for "which models should we test", "set up the analysis", or stage 2 of the metergraph-model-swap workflow.
---

# Choose traces and candidate models
Expand Down Expand Up @@ -43,15 +43,18 @@ as `metergraph tools call <tool> --args '<json object>' --json` and read
only when this skill's approval rule for that exact call is met. Exit code 18
with reason `confirmation_required` means `--yes` was missing; ask the person.

Name missing access by the job it does. **Read access** is the Metadata role
(`agent:metadata`). **Loop access** is the Debug role (`agent:read`) plus
**Allow evaluation writes** (`agent:eval-write`), **Allow evaluation
previews** (`agent:eval-preview`) and **Allow analysis starts**
(`agent:analysis-run`). On the CLI, `data.jobs.read` and `data.jobs.loop` in
`metergraph status --json` say which this key has (`available`, and the
scopes still `missing`); over MCP, the capabilities' `available` flags do.
Only a workspace owner grants loop access; **Loop access** in
`metergraph-model-swap` says how on each deployment.
Name missing access by its role and permissions. The **Metadata** role
(`agent:metadata`) reads usage, workloads, readiness and reports. Reading and
testing evals, saving them and starting runs need the **Debug** role
(`agent:read`) with **Allow evaluation writes** (`agent:eval-write`), **Allow
evaluation previews** (`agent:eval-preview`) and **Allow analysis starts**
(`agent:analysis-run`). On the CLI, `data.access` in `metergraph status --json`
gives the `role` and one boolean per permission (`allow_evaluation_writes`,
`allow_evaluation_previews`, `allow_analysis_starts`); an older CLI without
`data.access` reports only `scopes`. Over MCP, the capabilities' `available`
flags say what this key can do. Only a workspace owner grants the permissions;
**Granting Debug and the permissions** in `metergraph-model-swap` says how on
each deployment.

## 1. Which traces

Expand Down
36 changes: 20 additions & 16 deletions assets/skills/metergraph-evals/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: metergraph-evals
description: Define or refine the quality bar for a Metergraph workload before or after a model-swap analysis - draft deterministic checks and a graded rubric from good production traces and the person's codebase, test them with the evaluation preview, then save and bind them when the key allows it, or hand a ready-to-enter rubric to the app when it does not. Use for "what should count as a good answer", "write an eval", "tighten the checks", or stage 3 of the metergraph-model-swap loop.
description: Define or refine the quality bar for a Metergraph workload before or after a model-swap analysis - draft deterministic checks and a graded rubric from good production traces and the person's codebase, test them with the evaluation preview, then save and bind them when the key allows it, or hand a ready-to-enter rubric to the app when it does not. Use for "what should count as a good answer", "write an eval", "tighten the checks", or stage 3 of the metergraph-model-swap workflow.
---

# Define or refine the eval
Expand Down Expand Up @@ -64,15 +64,18 @@ as `metergraph tools call <tool> --args '<json object>' --json` and read
only when this skill's approval rule for that exact call is met. Exit code 18
with reason `confirmation_required` means `--yes` was missing; ask the person.

Name missing access by the job it does. **Read access** is the Metadata role
(`agent:metadata`). **Loop access** is the Debug role (`agent:read`) plus
**Allow evaluation writes** (`agent:eval-write`), **Allow evaluation
previews** (`agent:eval-preview`) and **Allow analysis starts**
(`agent:analysis-run`). On the CLI, `data.jobs.read` and `data.jobs.loop` in
`metergraph status --json` say which this key has (`available`, and the
scopes still `missing`); over MCP, the capabilities' `available` flags do.
Only a workspace owner grants loop access; **Loop access** in
`metergraph-model-swap` says how on each deployment.
Name missing access by its role and permissions. The **Metadata** role
(`agent:metadata`) reads usage, workloads, readiness and reports. Reading and
testing evals, saving them and starting runs need the **Debug** role
(`agent:read`) with **Allow evaluation writes** (`agent:eval-write`), **Allow
evaluation previews** (`agent:eval-preview`) and **Allow analysis starts**
(`agent:analysis-run`). On the CLI, `data.access` in `metergraph status --json`
gives the `role` and one boolean per permission (`allow_evaluation_writes`,
`allow_evaluation_previews`, `allow_analysis_starts`); an older CLI without
`data.access` reports only `scopes`. Over MCP, the capabilities' `available`
flags say what this key can do. Only a workspace owner grants the permissions;
**Granting Debug and the permissions** in `metergraph-model-swap` says how on
each deployment.

## 1. Find out what you can do

Expand All @@ -87,11 +90,12 @@ only where the deployment has managed evaluations.
| Attach to the workload | `metergraph_preview_evaluation_assignment` then `metergraph_apply_evaluation_assignment` (pass the preview's `scope_hash` as `expected_scope_hash`); `metergraph_retire_evaluation_assignment` | `agent:eval-write` |
| Reference answers | `metergraph_preview_reference_binding` then `metergraph_bind_reference_cases` | `agent:eval-write` |

None of these calls a model provider or starts a run. Each needs part of loop
access: the Debug role to read, plus the evaluation permissions to preview and
write. If they are not listed, say once which part of loop access is missing
(**Loop access** in `metergraph-model-swap` says how each deployment grants
it), keep going with the draft, and finish with the app handoff in step 5.
None of these calls a model provider or starts a run. Each needs the Debug
role to read, plus Allow evaluation previews to preview and Allow evaluation
writes to write. If they are not listed, say once which role or permission is
missing (**Granting Debug and the permissions** in `metergraph-model-swap` says
how each deployment grants them), keep going with the draft, and finish with
the app handoff in step 5.

## 2. Start from what exists

Expand Down Expand Up @@ -138,7 +142,7 @@ good and bad cases. A check that fails good cases or passes bad ones is wrong;
fix the check, not the model. Report the per-check pass counts in a short
table. Then `metergraph_validate_evaluation_draft`, and, after the person
agrees, `metergraph_save_evaluation_draft` and the assignment pair. Keep the
returned revision and assignment IDs in the loop record. From the CLI, a tool
returned revision and assignment IDs in the model-swap record. From the CLI, a tool
that `tools list` marks as writing takes `--yes` only once that agreement is
given, for example
`metergraph tools call metergraph_save_evaluation_draft --args '<draft>' --yes --json`.
Expand Down
Loading
Loading