coding-with-metacat

Query and manipulate Mu2e file metadata using the metacat Python API.

4|Updated Feb 11, 2026
One-click install
npx skills add https://github.com/Mu2e/aitools --skill coding-with-metacat
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: coding-with-metacat
Source: https://github.com/Mu2e/aitools/tree/main/skills/coding-with-metacat
Command: npx skills add https://github.com/Mu2e/aitools --skill coding-with-metacat

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill streamlines the process of interacting with the Mu2e file catalog (metacat), enabling efficient discovery, manipulation, and programmatic access to file metadata.

Core Features & Use Cases

  • Programmatic File Discovery: Find files and datasets using Python code.
  • Metadata Querying: Retrieve detailed information about files and datasets.
  • Data Ingestion & Management: Declare new files and update metadata (with explicit user approval).
  • Use Case: Automatically find all simulation files for a specific run, retrieve their ROOT URLs, and generate an input list for an art job.

Quick Start

Use the coding-with-metacat skill to list all datasets in the 'mu2e' namespace.

Frequently Asked Questions about coding-with-metacat

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I query Mu2e file metadata using the metacat Python API?

You can query Mu2e file metadata by utilizing the metacat Python API to programmatically retrieve detailed information about files and datasets. This facilitates efficient file discovery and metadata access for analysis workflows.

What do I need to set up before using the metacat Python package for file discovery?

Before using the metacat Python package for file discovery, you must configure your environment and authenticate using mu2einit and muse setup ops. This setup is required to access the Mu2e file catalog programmatically.

Can I declare new files and update metadata in the Mu2e data catalog?

Yes, you can declare new files and manage data ingestion by updating metadata in the Mu2e data catalog. The metacat Python API facilitates these manipulations, though explicit user approval is required for metadata updates.

What is the best way to find Mu2e simulation files for a specific run?

The best way to find Mu2e simulation files for a specific run is programmatic file discovery using the metacat Python API. You can query datasets, retrieve ROOT URLs, and generate an input list for an art job.

How do I list all datasets in the mu2e namespace?

To list all datasets in the mu2e namespace, use the coding-with-metacat skill to query the metacat file catalog. This allows you to discover available datasets and retrieve their detailed metadata programmatically.