Agentclash challenge pack validation publish

From agentclash/agentclash · View interactive version

Agentclash challenge pack validation publish is an AI agent skill from the GitHub repository agentclash/agentclash. Use when validating AgentClash challenge pack YAML, fixing schema/scoring/tool/asset errors, publishing runnable pack versions, recording returned IDs, and preparing next eval commands.

How to use this skill

Skill file

AgentClash Challenge Pack Validation and Publish

Purpose

Validate a complete AgentClash challenge pack against the real workspace-backed parser, fix any source-reported errors, publish a runnable version only when intended, and report the IDs needed to start an eval.

Use When

Do Not Use When

Inputs Needed

Environment

Use hosted production by default unless the user intentionally targets local or self-hosted infrastructure:

export AGENTCLASH_API_URL="https://api.agentclash.dev"

agentclash challenge-pack validate is not an offline-only local parser in the current CLI. It reads the YAML file, requires auth and a workspace, then posts the raw bundle to:

POST /v1/workspaces/<workspace-id>/challenge-packs/validate

agentclash challenge-pack publish posts the same raw bundle to:

POST /v1/workspaces/<workspace-id>/challenge-packs

Use --json for coding-agent workflows because human output intentionally omits several IDs.

CLI Surface

Use the full command names in docs and automation. challenge-pack also has the cp alias, but the full form is clearer for agents.

agentclash challenge-pack validate path/to/pack.yaml --json
agentclash challenge-pack publish path/to/pack.yaml --json
agentclash challenge-pack list --json

Exact command notes from the CLI:

Work with drafts

Create a draft from a composition file, or generate one from an app description.

agentclash challenge-pack draft create --name "Support eval" --composition-file composition.yaml --json
agentclash challenge-pack draft generate --description "Test a support agent" --provider-account <ACCOUNT_ID> --model <MODEL> --json

Draft generation starts a paid model call.

After exit 75, run agentclash challenge-pack draft list before a retry.

The server can create a draft even if the CLI gives exit 75.

Compile the draft with its returned id. Fix any errors before you publish.

Get user approval before you publish.

agentclash challenge-pack draft compile <DRAFT_ID> --yaml-out pack.yaml
agentclash challenge-pack draft publish <DRAFT_ID> --json

Get user approval before you use agentclash challenge-pack draft delete <DRAFT_ID> --yes.

Validation Procedure

  1. Set hosted API URL unless the workflow is explicitly local or self-hosted.
  2. Verify the workspace context before making workspace-backed calls.
  3. Run validation with --json.
  4. If the command fails, inspect both stdout and stderr. Current validation failures use HTTP 400, so the CLI can report the response body through its generic API-error path instead of returning a clean JSON object on stdout.
  5. Fix every field and message pair reported by the API.
  6. Re-run validation until it succeeds.
  7. Only then publish, and only when the user has already approved publishing.
export AGENTCLASH_API_URL="https://api.agentclash.dev"
agentclash auth status
agentclash workspace use <WORKSPACE_ID>
agentclash challenge-pack validate path/to/pack.yaml --json

On success, validate --json returns:

{
  "valid": true,
  "errors": null
}

On validation failure, the API response shape is:

{
  "valid": false,
  "errors": [
    {
      "field": "version.evaluation_spec.validators[0].type",
      "message": "must be one of ..."
    }
  ]
}

Because invalid validation is returned with HTTP 400 today, do not assume a failing CLI invocation will print that object as successful structured stdout. Still use its field and message details when they are present.

What Validation Checks

Validation parses the YAML bundle, normalizes legacy case data, runs bundle validation, validates scoring spec fields, and checks stored artifact IDs against the selected workspace.

Pack and version checks:

Challenge checks:

Input set checks:

Tools, sandbox, and artifact checks:

Scoring checks:

Fix Patterns

Publish Procedure

Publish is a workspace mutation that creates a runnable challenge-pack version. Do it only after validation passes and the user has approved publishing.

agentclash challenge-pack validate path/to/pack.yaml --json
agentclash challenge-pack publish path/to/pack.yaml --json

On success, publish --json returns:

{
  "challenge_pack_id": "<CHALLENGE_PACK_ID>",
  "challenge_pack_version_id": "<CHALLENGE_PACK_VERSION_ID>",
  "evaluation_spec_id": "<EVALUATION_SPEC_ID>",
  "input_set_ids": ["<CHALLENGE_INPUT_SET_ID>"],
  "bundle_artifact_id": "<BUNDLE_ARTIFACT_ID>"
}

bundle_artifact_id is optional. It is present when the backend stores the authored YAML bundle as a workspace artifact.

Without --json, the current CLI only prints the pack ID and version ID. Always use --json when you need evaluation_spec_id, input_set_ids, or bundle_artifact_id.

Publish stores:

Publish Failure Modes

Next Eval Commands

Record the IDs from publish --json before starting a run.

Workflow-first command, with selectors accepted by the CLI:

agentclash eval start \
  --pack <PACK_ID_OR_SLUG_OR_EXACT_NAME> \
  --pack-version <VERSION_ID_OR_VERSION_NUMBER> \
  --input-set <INPUT_SET_ID_OR_KEY_OR_EXACT_NAME> \
  --deployment <DEPLOYMENT_ID_OR_EXACT_NAME> \
  --follow

Lower-level non-interactive command, using IDs:

agentclash run create \
  --challenge-pack-version <CHALLENGE_PACK_VERSION_ID> \
  --input-set <CHALLENGE_INPUT_SET_ID> \
  --deployments <AGENT_DEPLOYMENT_ID> \
  --follow

When the published version has multiple input sets, pass --input-set in non-interactive workflows. agentclash eval start can resolve an input set by ID, key, or exact name; agentclash run create expects the input set ID.

Safety Notes

Report Back Format

Validation: <pass/fail>
Workspace: <workspace-id or configured default>
Pack file: <path>
Errors fixed:
- <field>: <message/fix>
Published: <yes/no>
Challenge pack ID: <id>
Challenge pack version ID: <id>
Evaluation spec ID: <id>
Input set IDs:
- <id> (<key/name if known>)
Bundle artifact ID: <id or not returned>
Next eval command:
Next run command:
Notes: <conflicts, entitlement/auth caveats, skipped publish reason>

Related Skills

Related Docs

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.