github VoltAgent/voltagent @voltagent/cli@0.1.21

11 hours ago

Patch Changes

  • #934 12519f5 Thanks @omeraplak! - feat: offline-first local prompts with version + label selection

    What's New

    • Local prompt resolution now supports multiple versions and labels stored as
      .voltagent/prompts/<promptName>/<version>.md.
    • Local files are used first; VoltOps is only queried if the local prompt is missing.
    • If a local prompt is behind the online version, the agent logs a warning and records metadata.
    • CLI pull can target labels or versions; push compares local vs online and creates new versions.

    CLI Usage

    # Pull latest prompts (default)
    volt prompts pull
    
    # Pull a specific label or version (stored under .voltagent/prompts/<name>/<version>.md)
    volt prompts pull --names support-agent --label production
    volt prompts pull --names support-agent --prompt-version 4
    
    # Push local changes (creates new versions after diff/confirm)
    volt prompts push

    Agent Usage

    instructions: async ({ prompts }) => {
      return await prompts.getPrompt({
        promptName: "support-agent",
        version: 4,
      });
    };
    instructions: async ({ prompts }) => {
      return await prompts.getPrompt({
        promptName: "support-agent",
        label: "production",
      });
    };

    Offline-First Workflow

    • Pull once, then run fully offline with local Markdown files.
    • Point the runtime to your local directory:
    export VOLTAGENT_PROMPTS_PATH="./.voltagent/prompts"

Don't miss a new voltagent release

NewReleases is sending notifications on new releases.