pynydus.cmd.main¶
Nydus CLI: Typer application.
Entry point for nydus commands: spawn, hatch, inspect, extract, diff,
registry operations, and key management. Validation is embedded in
inspect and hatch. There is no standalone validate command.
Module Contents¶
Functions¶
Print LLM refinement status at the start of a pipeline command. |
|
Create an Egg from source artifacts. |
|
Deploy an Egg into a target runtime. |
|
Generate a template .env file from an egg’s secrets. |
|
Print Egg summary with inline validation. |
|
Print a grouped summary table for a list of typed log entries. |
|
Generate a detail string for a group of same-type log entries. |
|
Load an egg, handling errors consistently for all extract subcommands. |
|
Write extracted files to disk and print summary. |
|
Extract MCP server configs (mcp.json). |
|
Extract Agent Skills (SKILL.md files). |
|
Extract A2A agent card (agent-card.json). |
|
Extract APM manifest (apm.yml). Passthrough only. |
|
Extract per-egg AGENTS.md deployment runbook. |
|
Extract embedded spec snapshots. |
|
Extract all standard artifacts at once. |
|
Compare two Eggs. |
|
Delete an Egg. |
|
Generate an Ed25519 keypair for egg signing. |
|
Publish an Egg to the Nest registry. |
|
Download an Egg from the Nest registry. |
|
Register a new account on the Nest registry. |
|
Log in to the Nest registry and store credentials. |
|
Log out from the Nest registry (remove stored credentials). |
Data¶
API¶
- pynydus.cmd.main.app¶
‘Typer(…)’
- pynydus.cmd.main._print_llm_status(llm_config) None¶
Print LLM refinement status at the start of a pipeline command.
- pynydus.cmd.main.spawn(output: Annotated[pathlib.Path, typer.Option('-o', '--output', help='Output Egg path')] = Path('./agent.egg')) None¶
Create an Egg from source artifacts.
Discovers a Nydusfile in the current directory, then runs the spawning pipeline to produce an Egg.
Args: output: Path for the written
.eggarchive (default./agent.egg).
- pynydus.cmd.main.hatch(egg_path: Annotated[pathlib.Path, typer.Argument(help='Path to .egg file')], target: Annotated[str, typer.Option('-t', '--target', help='Target runtime')] = ..., output: Annotated[pathlib.Path | None, typer.Option('-o', '--output', help='Output directory (default: ./<target>/)')] = None, secrets: Annotated[pathlib.Path | None, typer.Option('-s', '--secrets', help='Path to .env substitution file')] = None, passthrough: Annotated[bool, typer.Option('-P', '--passthrough', help="Replay the egg's redacted raw/ snapshot instead of rebuilding from modules")] = False, skip_validation: Annotated[bool, typer.Option('-S', '--skip-validation', help='Skip egg validation before hatching')] = False) None¶
Deploy an Egg into a target runtime.
Args: egg_path: Path to the
.eggfile. target: Destination runtime (e.g.openclaw,letta,zeroclaw). output: Output directory for hatched files (default:./<target>/). secrets: Optional.envpath for placeholder substitution at hatch. passthrough: When set, replay the egg’sraw/snapshot instead of rebuilding. skip_validation: When set, skip structural and per-standard validation.
- pynydus.cmd.main.env(egg_path: Annotated[pathlib.Path, typer.Argument(help='Path to .egg file')], output: Annotated[pathlib.Path, typer.Option('-o', '--output', help='Output .env path')] = Path('./hatch.env')) None¶
Generate a template .env file from an egg’s secrets.
Args: egg_path: Path to the
.eggfile. output: Path for the generated.envtemplate.
- pynydus.cmd.main.inspect(egg_path: Annotated[pathlib.Path, typer.Argument(help='Path to .egg file')], show_secrets: Annotated[bool, typer.Option('-s', '--secrets', help='List all placeholders and occurrences')] = False, show_logs: Annotated[bool, typer.Option('-l', '--logs', help='Show pipeline log summary')] = False, no_validate: Annotated[bool, typer.Option('-n', '--no-validate', help='Skip per-standard validation')] = False) None¶
Print Egg summary with inline validation.
Args: egg_path: Path to the
.eggfile. show_secrets: List placeholders and occurrence counts. show_logs: Print a grouped summary ofspawn_logentries. no_validate: When set, skip per-standard schema validation.
- pynydus.cmd.main._print_log_summary(title: str, entries: list[dict]) None¶
Print a grouped summary table for a list of typed log entries.
- pynydus.cmd.main._log_type_detail(entry_type: str, entries: list[dict]) str¶
Generate a detail string for a group of same-type log entries.
- pynydus.cmd.main.extract_app¶
‘Typer(…)’
- pynydus.cmd.main._load_egg_for_extract(egg_path: pathlib.Path) Egg¶
Load an egg, handling errors consistently for all extract subcommands.
- pynydus.cmd.main._write_extracted(files: dict[str, str], output_dir: pathlib.Path, label: str) None¶
Write extracted files to disk and print summary.
- pynydus.cmd.main.extract_mcp(egg_path: Annotated[pathlib.Path, typer.Option('-f', '--from', help='Path to .egg file')], output: Annotated[pathlib.Path, typer.Option('-o', '--output', help='Output directory')] = Path('.')) None¶
Extract MCP server configs (mcp.json).
- pynydus.cmd.main.extract_skills(egg_path: Annotated[pathlib.Path, typer.Option('-f', '--from', help='Path to .egg file')], output: Annotated[pathlib.Path, typer.Option('-o', '--output', help='Output directory')] = Path('.')) None¶
Extract Agent Skills (SKILL.md files).
- pynydus.cmd.main.extract_a2a(egg_path: Annotated[pathlib.Path, typer.Option('-f', '--from', help='Path to .egg file')], output: Annotated[pathlib.Path, typer.Option('-o', '--output', help='Output directory')] = Path('.')) None¶
Extract A2A agent card (agent-card.json).
- pynydus.cmd.main.extract_apm(egg_path: Annotated[pathlib.Path, typer.Option('-f', '--from', help='Path to .egg file')], output: Annotated[pathlib.Path, typer.Option('-o', '--output', help='Output directory')] = Path('.')) None¶
Extract APM manifest (apm.yml). Passthrough only.
- pynydus.cmd.main.extract_agents(egg_path: Annotated[pathlib.Path, typer.Option('-f', '--from', help='Path to .egg file')], output: Annotated[pathlib.Path, typer.Option('-o', '--output', help='Output directory')] = Path('.')) None¶
Extract per-egg AGENTS.md deployment runbook.
- pynydus.cmd.main.extract_specs(egg_path: Annotated[pathlib.Path, typer.Option('-f', '--from', help='Path to .egg file')], output: Annotated[pathlib.Path, typer.Option('-o', '--output', help='Output directory')] = Path('./specs')) None¶
Extract embedded spec snapshots.
- pynydus.cmd.main.extract_all(egg_path: Annotated[pathlib.Path, typer.Option('-f', '--from', help='Path to .egg file')], output: Annotated[pathlib.Path, typer.Option('-o', '--output', help='Output directory')] = Path('./extracted')) None¶
Extract all standard artifacts at once.
- pynydus.cmd.main.diff(egg_a: Annotated[pathlib.Path, typer.Argument(help='First Egg')], egg_b: Annotated[pathlib.Path, typer.Argument(help='Second Egg')]) None¶
Compare two Eggs.
Args: egg_a: Path to the first
.eggfile. egg_b: Path to the second.eggfile.
- pynydus.cmd.main.delete(egg_path: Annotated[pathlib.Path, typer.Argument(help='Path to .egg file')]) None¶
Delete an Egg.
Args: egg_path: Path to the
.eggfile to remove.
- pynydus.cmd.main.keygen(key_dir: Annotated[pathlib.Path | None, typer.Option('-d', '--dir', help='Directory to write keys to')] = None) None¶
Generate an Ed25519 keypair for egg signing.
Args: key_dir: Directory for
private.pemandpublic.pem(default~/.nydus/keys).
- pynydus.cmd.main.push(egg_path: Annotated[pathlib.Path, typer.Argument(help='Path to .egg file')], name: Annotated[str, typer.Option('-n', '--name', help='Registry name (user/egg-name)')] = ..., version: Annotated[str, typer.Option('-v', '--version', help='Version string (e.g. 0.1.0)')] = ..., author: Annotated[str | None, typer.Option('-a', '--author', help='Author name')] = None) None¶
Publish an Egg to the Nest registry.
Args: egg_path: Path to the
.eggfile to upload. name: Registry-qualified name (e.g.user/my-agent). version: Semver string for this publish. author: Optional author override (otherwise env/default).
- pynydus.cmd.main.pull(name: Annotated[str, typer.Argument(help='Registry name (user/egg-name)')], version: Annotated[str, typer.Option('-v', '--version', help='Version to pull')] = ..., output: Annotated[pathlib.Path, typer.Option('-o', '--output', help='Output path')] = Path('pulled.egg')) None¶
Download an Egg from the Nest registry.
Args: name: Registry-qualified egg name. version: Semver tag to pull. output: Destination path for the downloaded
.egg.
- pynydus.cmd.main.register(username: Annotated[str, typer.Argument(help='Username for the Nest registry')], password: Annotated[str, typer.Option('--password', '-p', prompt=True, hide_input=True, help='Password')] = ...) None¶
Register a new account on the Nest registry.
Args: username: Desired username. password: Password (prompted if omitted).
- pynydus.cmd.main.login(username: Annotated[str, typer.Argument(help='Username for the Nest registry')], password: Annotated[str, typer.Option('--password', '-p', prompt=True, hide_input=True, help='Password')] = ...) None¶
Log in to the Nest registry and store credentials.
Args: username: Registry username. password: Password (prompted if omitted).