{
  "schema_version": "2026-05-28.agent-action-bundle.v1",
  "name": "TokRepo Agent Action Bundle",
  "canonical_url": "https://tokrepo.com/agent-action-bundle.json",
  "updated_at": "2026-05-28",
  "generated_by": "node scripts/run_agent_action_bundle.mjs --json",
  "purpose": "Agent-facing action bundle that joins improvement actions to executable repair receipts so agents can choose, run, verify, and roll back the next self-improvement step without scraping the GUI.",
  "source_evidence": {
    "improvement_actions_eval": "https://tokrepo.com/evals/agent-improvement-actions.json",
    "repair_execution_eval": "https://tokrepo.com/evals/agent-repair-execution.json",
    "live_feedback_api": "https://api.tokrepo.com/api/v1/tokenboard/agent/funnel",
    "task_economy_contract": "https://tokrepo.com/agent-task-economy.json",
    "human_review_surface": "https://tokrepo.com/en/agent-stats"
  },
  "action_bundle_contract": {
    "execution_boundary": "An agent action is actionable only when it links a source improvement action to a repair receipt with run_command, expected_artifact, acceptance_oracle, rollback_or_handoff, public entrypoints, and privacy guard.",
    "recommended_agent_flow": [
      "fetch /agent-action-bundle.json",
      "select bundle by observed trigger or source_action.action_id",
      "run or stage repair_receipt.run_command",
      "verify repair_receipt.acceptance_oracle",
      "use rollback_or_handoff when acceptance fails",
      "record only public receipt metadata or private project state"
    ],
    "live_check_command": "WEB_BASE=https://tokrepo.com API_BASE=https://api.tokrepo.com node scripts/run_agent_action_bundle.mjs --check-live",
    "required_entrypoints": [
      "https://tokrepo.com/agent-action-bundle.json",
      "https://tokrepo.com/.well-known/tokrepo.json",
      "https://tokrepo.com/.well-known/agent.json",
      "https://tokrepo.com/mcp.json",
      "https://tokrepo.com/agents.txt",
      "https://tokrepo.com/llms.txt",
      "https://tokrepo.com/llms-full.txt",
      "https://tokrepo.com/en/agent-stats"
    ],
    "required_live_window_days": 14,
    "required_live_event_keys": [
      "mcp_search",
      "mcp_detail",
      "capability_resolve",
      "verify_asset",
      "audit_asset",
      "install_plan",
      "install_dry_run",
      "rollback_plan",
      "agent_handoff",
      "handoff_plan",
      "harvest_plan"
    ]
  },
  "metrics": {
    "bundles_total": 3,
    "bundles_passed": 3,
    "source_action_linkage_pct": 100,
    "execution_field_coverage_pct": 100,
    "public_entrypoint_coverage_pct": 100,
    "privacy_guard_coverage_pct": 100
  },
  "action_bundles": [
    {
      "bundle_id": "action_bundle_01_execute_relevance_resolution_repair",
      "status": "ready_for_agent_execution",
      "source_action": {
        "action_id": "repair_relevance_resolution_gap",
        "trigger": "Search volume exists but useful detail reads or capability resolution are too low for the requested task category.",
        "repair_command": "tokrepo resolve <capability> --target codex --explain --json",
        "expected_artifact": "capability_resolution_note",
        "acceptance_oracle": {
          "type": "relevance_action_oracle",
          "pass_condition": "The action references search, detail, and capability_resolve evidence and produces a non-private capability-resolution note."
        }
      },
      "repair_receipt": {
        "receipt_id": "execute_relevance_resolution_repair",
        "source_action_id": "repair_relevance_resolution_gap",
        "execution_boundary": "stage_and_verify_capability_resolution",
        "run_command": "tokrepo resolve <capability> --target codex --explain --json",
        "expected_artifact": {
          "type": "capability_resolution_note",
          "required_fields": [
            "capability",
            "candidate_uuid_hash",
            "fit_score",
            "missing_capabilities",
            "next_safe_action"
          ]
        },
        "acceptance_oracle": {
          "type": "repair_execution_oracle",
          "pass_condition": "The receipt links the repair action to search, detail, and capability_resolve evidence, and names the next safe action without publishing private task text."
        },
        "rollback_or_handoff": {
          "type": "handoff",
          "trigger": "If no candidate satisfies the capability threshold, emit a private handoff note instead of forcing an install.",
          "command": "tokrepo agent-handoff --json"
        },
        "task_outcome_verdict": "pass",
        "user_effect": "A weak relevance signal now produces a concrete capability-resolution receipt that the next agent can audit or continue."
      },
      "required_live_events": [
        "mcp_search",
        "mcp_detail",
        "capability_resolve"
      ],
      "optional_live_events": [],
      "agent_next_step": {
        "instruction": "Choose the bundle matching the observed quality gap, run or stage the command, then verify the acceptance oracle before claiming improvement.",
        "command": "tokrepo resolve <capability> --target codex --explain --json",
        "verification": "WEB_BASE=https://tokrepo.com API_BASE=https://api.tokrepo.com node scripts/run_agent_repair_execution.mjs --check-live",
        "public_receipt": "https://tokrepo.com/evals/agent-repair-execution.json",
        "rollback_or_handoff": {
          "type": "handoff",
          "trigger": "If no candidate satisfies the capability threshold, emit a private handoff note instead of forcing an install.",
          "command": "tokrepo agent-handoff --json"
        }
      },
      "public_entrypoints": [
        "https://tokrepo.com/agent-action-bundle.json",
        "https://tokrepo.com/evals/agent-improvement-actions.json",
        "https://tokrepo.com/evals/agent-repair-execution.json",
        "https://tokrepo.com/agent-task-economy.json",
        "https://tokrepo.com/en/agent-stats",
        "https://tokrepo.com/.well-known/tokrepo.json",
        "https://tokrepo.com/.well-known/agent.json",
        "https://tokrepo.com/mcp.json",
        "https://tokrepo.com/agents.txt",
        "https://tokrepo.com/llms.txt"
      ],
      "privacy_guard": {
        "publishable_fields_only": [
          "bundle_id",
          "action_id",
          "receipt_id",
          "source_action_id",
          "run_command",
          "expected_artifact",
          "acceptance_oracle",
          "rollback_or_handoff",
          "coverage_metrics",
          "public_entrypoints"
        ],
        "forbidden_fields": [
          "task_text",
          "query_text",
          "file_content",
          "raw_diff",
          "raw_prompt",
          "local_path",
          "credential",
          "cookie",
          "share_token",
          "private_harvest_payload"
        ]
      },
      "evidence_digest": {
        "algorithm": "sha256",
        "digest": "sha256:fc59024fc03638fbd11ee2e458d5576b91e9fb20fb24d18b1fa94d59b8cf9f44"
      }
    },
    {
      "bundle_id": "action_bundle_02_execute_trust_gate_repair",
      "status": "ready_for_agent_execution",
      "source_action": {
        "action_id": "repair_trust_gate_gap",
        "trigger": "A candidate is being considered for use but verification, audit, install-plan, or rollback rehearsal evidence is incomplete.",
        "repair_command": "tokrepo verify <uuid> --target codex --json && tokrepo audit --offline --json && tokrepo install <uuid> --target codex --dry-run --json",
        "expected_artifact": "trust_gate_repair_receipt",
        "acceptance_oracle": {
          "type": "trust_action_oracle",
          "pass_condition": "The action proves the trust gate and rollback path without exposing raw diffs, local project paths, or secret values."
        }
      },
      "repair_receipt": {
        "receipt_id": "execute_trust_gate_repair",
        "source_action_id": "repair_trust_gate_gap",
        "execution_boundary": "stage_trust_gate_with_rollback",
        "run_command": "tokrepo verify <uuid> --target codex --json && tokrepo audit --offline --json && tokrepo install <uuid> --target codex --dry-run --json && tokrepo rollback --last --target codex --dry-run --json",
        "expected_artifact": {
          "type": "trust_gate_repair_receipt",
          "required_fields": [
            "asset_uuid_hash",
            "verification_result",
            "audit_result",
            "install_plan_result",
            "rollback_plan_result"
          ]
        },
        "acceptance_oracle": {
          "type": "trust_gate_execution_oracle",
          "pass_condition": "The receipt proves verify, audit, install dry-run, and rollback dry-run evidence before any write-capable install is counted as safe."
        },
        "rollback_or_handoff": {
          "type": "rollback",
          "trigger": "If verification, audit, or dry-run fails, stop before install_apply and preserve the rollback plan evidence.",
          "command": "tokrepo rollback --last --target codex --dry-run --json"
        },
        "task_outcome_verdict": "pass",
        "user_effect": "A trust warning now becomes a staged execution receipt with rollback proof instead of an unverifiable recommendation."
      },
      "required_live_events": [
        "verify_asset",
        "audit_asset",
        "install_plan",
        "install_dry_run",
        "rollback_plan"
      ],
      "optional_live_events": [
        "install_apply"
      ],
      "agent_next_step": {
        "instruction": "Choose the bundle matching the observed quality gap, run or stage the command, then verify the acceptance oracle before claiming improvement.",
        "command": "tokrepo verify <uuid> --target codex --json && tokrepo audit --offline --json && tokrepo install <uuid> --target codex --dry-run --json && tokrepo rollback --last --target codex --dry-run --json",
        "verification": "WEB_BASE=https://tokrepo.com API_BASE=https://api.tokrepo.com node scripts/run_agent_repair_execution.mjs --check-live",
        "public_receipt": "https://tokrepo.com/evals/agent-repair-execution.json",
        "rollback_or_handoff": {
          "type": "rollback",
          "trigger": "If verification, audit, or dry-run fails, stop before install_apply and preserve the rollback plan evidence.",
          "command": "tokrepo rollback --last --target codex --dry-run --json"
        }
      },
      "public_entrypoints": [
        "https://tokrepo.com/agent-action-bundle.json",
        "https://tokrepo.com/evals/agent-improvement-actions.json",
        "https://tokrepo.com/evals/agent-repair-execution.json",
        "https://tokrepo.com/agent-task-economy.json",
        "https://tokrepo.com/en/agent-stats",
        "https://tokrepo.com/.well-known/tokrepo.json",
        "https://tokrepo.com/.well-known/agent.json",
        "https://tokrepo.com/mcp.json",
        "https://tokrepo.com/agents.txt",
        "https://tokrepo.com/llms.txt"
      ],
      "privacy_guard": {
        "publishable_fields_only": [
          "bundle_id",
          "action_id",
          "receipt_id",
          "source_action_id",
          "run_command",
          "expected_artifact",
          "acceptance_oracle",
          "rollback_or_handoff",
          "coverage_metrics",
          "public_entrypoints"
        ],
        "forbidden_fields": [
          "task_text",
          "query_text",
          "file_content",
          "raw_diff",
          "raw_prompt",
          "local_path",
          "credential",
          "cookie",
          "share_token",
          "private_harvest_payload"
        ]
      },
      "evidence_digest": {
        "algorithm": "sha256",
        "digest": "sha256:4a504330d38dce5d84094678cca75b6961305aebc05366b07dee1b402d5c08f3"
      }
    },
    {
      "bundle_id": "action_bundle_03_execute_reuse_supply_repair",
      "status": "ready_for_agent_execution",
      "source_action": {
        "action_id": "repair_reuse_supply_gap",
        "trigger": "A task produced reusable learning, but the agent has not converted it into a private handoff or harvest plan.",
        "repair_command": "tokrepo agent-handoff --json && tokrepo harvest --changed --json",
        "expected_artifact": "private_handoff_or_harvest_plan",
        "acceptance_oracle": {
          "type": "reuse_action_oracle",
          "pass_condition": "The action creates private reusable supply and keeps publish separate from handoff or harvest planning."
        }
      },
      "repair_receipt": {
        "receipt_id": "execute_reuse_supply_repair",
        "source_action_id": "repair_reuse_supply_gap",
        "execution_boundary": "private_handoff_before_public_harvest",
        "run_command": "tokrepo agent-handoff --json && tokrepo harvest --changed --json",
        "expected_artifact": {
          "type": "private_reuse_supply_receipt",
          "required_fields": [
            "handoff_package_hash",
            "harvest_candidate_count",
            "publish_gate",
            "next_reuse_action"
          ]
        },
        "acceptance_oracle": {
          "type": "reuse_supply_execution_oracle",
          "pass_condition": "The receipt proves private handoff or harvest planning first, and requires an explicit publish gate before public supply creation."
        },
        "rollback_or_handoff": {
          "type": "handoff",
          "trigger": "If the harvest candidate includes private context, keep it as a private handoff package and do not publish.",
          "command": "tokrepo agent-handoff --json"
        },
        "task_outcome_verdict": "pass",
        "user_effect": "A reuse opportunity now leaves a private handoff or harvest receipt that can feed future agents without leaking private work context."
      },
      "required_live_events": [
        "agent_handoff",
        "handoff_plan",
        "harvest_plan"
      ],
      "optional_live_events": [
        "harvest_publish"
      ],
      "agent_next_step": {
        "instruction": "Choose the bundle matching the observed quality gap, run or stage the command, then verify the acceptance oracle before claiming improvement.",
        "command": "tokrepo agent-handoff --json && tokrepo harvest --changed --json",
        "verification": "WEB_BASE=https://tokrepo.com API_BASE=https://api.tokrepo.com node scripts/run_agent_repair_execution.mjs --check-live",
        "public_receipt": "https://tokrepo.com/evals/agent-repair-execution.json",
        "rollback_or_handoff": {
          "type": "handoff",
          "trigger": "If the harvest candidate includes private context, keep it as a private handoff package and do not publish.",
          "command": "tokrepo agent-handoff --json"
        }
      },
      "public_entrypoints": [
        "https://tokrepo.com/agent-action-bundle.json",
        "https://tokrepo.com/evals/agent-improvement-actions.json",
        "https://tokrepo.com/evals/agent-repair-execution.json",
        "https://tokrepo.com/agent-task-economy.json",
        "https://tokrepo.com/en/agent-stats",
        "https://tokrepo.com/.well-known/tokrepo.json",
        "https://tokrepo.com/.well-known/agent.json",
        "https://tokrepo.com/mcp.json",
        "https://tokrepo.com/agents.txt",
        "https://tokrepo.com/llms.txt"
      ],
      "privacy_guard": {
        "publishable_fields_only": [
          "bundle_id",
          "action_id",
          "receipt_id",
          "source_action_id",
          "run_command",
          "expected_artifact",
          "acceptance_oracle",
          "rollback_or_handoff",
          "coverage_metrics",
          "public_entrypoints"
        ],
        "forbidden_fields": [
          "task_text",
          "query_text",
          "file_content",
          "raw_diff",
          "raw_prompt",
          "local_path",
          "credential",
          "cookie",
          "share_token",
          "private_harvest_payload"
        ]
      },
      "evidence_digest": {
        "algorithm": "sha256",
        "digest": "sha256:f98105a27b394bd9e4f564fd34af3f952e6137dfff817d6d7c2cb27a1acd69c3"
      }
    }
  ]
}
