CocoPlus Documentation

repository·main·Indexed 20 days ago

https://github.com/snowflake-labs/cocoplus

An Agentic Operating System for Snowflake Coco that provides structured, multi-agent workflows for data engineering projects. It automates the development lifecycle from requirements capture to production deployment using Coco-native constructs such as Skills, Agents, and Hooks, and utilizes specialized personas like Data Engineers and Data Scientists to decompose work.

Tokens
1.4K
Snippets
9
Records
11
Agent score
22%

What's inside CocoPlus

  1. CocoPlus Specialist Personas

    main

    CocoPlus uses specialized personas to decompose work across different data roles. You can invoke these personas using their respective shortcodes:

    • $de: Data Engineer
    • $ae: Analytics Engineer
    • $ds: Data Scientist
    • $da: Data Analyst
    • $bi: BI Analyst
    • $dpm: Data Product Manager
    • $dst: Data Steward
    • $cdo: Chief Data Officer
  2. Quickstart CocoPlus commands

    main

    Use these commands to initialize and start working with CocoPlus in your project:

    • $pod init: Initialize CocoPlus in your current project.
    • $cocoplus on: Activate all CocoPlus features.
    • $cocoplus console: Open the read-only CocoConsole dashboard.
    • $pilot on: Activate CocoPilot (natural-language orchestration) for the current session.
    • $session status: Inspect multi-session handoff and operator controls.
    • $spec: Start the requirements gathering phase.
    $pod init
    $cocoplus on
    $cocoplus console
    $pilot on
    $session status
    $spec
  3. Install CocoPlus via Coco CLI

    main

    To install CocoPlus as a managed plugin in Coco, use the cortex plugin install command followed by the repository name or the full GitHub URL. After installation, you must enable the plugin.

    Note: You must restart Coco after installation or enabling the plugin to reload the plugin settings.

    cortex plugin install Snowflake-Labs/cocoplus
    cortex plugin enable cocoplus
  4. Upgrade an existing CocoPlus project to v2

    main

    To migrate an older CocoPlus project to the current version, use the $migrate command. It is highly recommended to run with the --dry-run flag first to inspect proposed state changes, validation checks, and cleanup actions before applying them to your project.

    $migrate v2 --dry-run
    $migrate v2
  5. Upgrade existing CocoPlus 1.x projects to v2

    main

    If you are upgrading a project that was previously initialized with CocoPlus 1.x, you must run the migration commands from your project root after restarting Coco.

    1. Run $migrate v2 --dry-run to inspect the existing .cocoplus/ state and see required actions without making changes.
    2. Run $migrate v2 to apply the migration, run validation, archive legacy artifacts, and create a migration commit.
    $migrate v2 --dry-run
    $migrate v2
  6. Install CocoPlus for local development

    main

    If you are developing CocoPlus locally from a checked-out repository, run the following commands from the repository root to install the local version and enable it.

    cortex plugin install . --force
    cortex plugin enable cocoplus
  7. Initialize and start a CocoPlus project

    main

    Once CocoPlus is installed and Coco has been restarted, navigate to your project root and run the following sequence of commands to initialize and activate CocoPlus:

    1. $pod init: Initializes the project.
    2. $cocoplus on: Activates CocoPlus.
    3. $cocoplus console: Opens the read-only local dashboard.
    4. $session status: Verifies the current session state (handoff surface, budget, etc.).
    5. $spec: View project specifications.
    $pod init
    $cocoplus on
    $cocoplus console
    $session status
    $spec
  8. Configure CocoPlus session and flow settings

    main

    CocoPlus uses specific configuration blocks to manage session budgets, harness invariants, and flow complexity. While these are automatically added via $migrate v2, they can be understood through the following schema:

    • [session]: Controls budget_limit, budget_reserve_fraction, and budget_enforcement.
    • [harness]: Manages invariants like trivial_floor_invariant.
    • [flow]: Controls complexity_estimation.
    • [run_policy]: Defines merge_policy, allow_irreversible_actions, and stop_after triggers.
    • [meter]: Manages transcript_adapter_strict, track_coordination_cost, coordination_warning_threshold, and track_acrr.
    [session]
    budget_limit = 0.0
    budget_reserve_fraction = 0.10
    budget_enforcement = "stage-boundary"
    
    [harness]
    trivial_floor_invariant = true
    
    [flow]
    complexity_estimation = true
    
    [run_policy]
    merge_policy = "none"
    allow_irreversible_actions = false
    stop_after = []
    
    [meter]
    transcript_adapter_strict = true
    track_coordination_cost = true
    coordination_warning_threshold = 0.25
    track_acrr = true
  9. Verify CocoPlus installation

    main

    To ensure CocoPlus is correctly installed and recognized by Coco, perform these checks:

    1. Check Directory: Verify the plugin is located at <user-home>/.snowflake/cortex/plugins/cocoplus and contains .cortex-plugin/plugin.json.
    2. Validate Plugin: Run cortex plugin validate <path-to-cocoplus>. It should report: Plugin 'cocoplus' is valid..
    3. List Plugins: Run cortex plugin list to confirm cocoplus appears in the list of installed/enabled plugins.
    cortex plugin validate ~/.snowflake/cortex/plugins/cocoplus
    cortex plugin list
  10. CocoPlus Requirements

    main

    To use CocoPlus, ensure your environment meets the following requirements:

    • Snowflake Coco CLI (cortex): Must be installed with plugin support.
    • Node.js: Required for running hooks (compatible with Windows, Mac, and Linux).
    • Git: Required for version control and repository interactions.