load("@crates//:defs.bzl", "aliases", "all_crate_deps")

load("@rules_rust//rust:defs.bzl", "rust_binary", "rust_library", "rust_proc_macro", "rust_test")



filegroup(

    name = "cargo_manifest",

    srcs = ["Cargo.toml"],

    visibility = ["//visibility:public"],

)



filegroup(

    name = "package_runfiles",

    srcs = glob(["Cargo.toml", "**/*"], exclude = ["BUILD", "BUILD.bazel"], allow_empty = True),

    visibility = ["//visibility:public"],

)



rust_binary(
    name = "rkat",
    aliases = aliases(package_name = "meerkat-cli"),
    crate_name = "rkat",
    crate_root = "src/main.rs",
    crate_features = [
        "anthropic",
        "comms",
        "gemini",
        "integration-real-tests",
        "jsonl-store",
        "mcp",
        "mob",
        "openai",
        "schedule",
        "session-store",
        "skills",
        "workgraph",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = glob(["src/**/*.rs"]),
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "rkat",
        "CARGO_MANIFEST_DIR": "meerkat-cli",
    },
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
    ),
    deps = [
        "//meerkat-mob-mcp:meerkat_mob_mcp",
        "//meerkat-mob-pack:meerkat_mob_pack",
        "//meerkat-mob:meerkat_mob",
        "//meerkat-rpc:meerkat_rpc",
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_mcp_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
    ),
)

rust_test(
    name = "auth_binding_single_parser_test",
    aliases = aliases(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
        proc_macro = True,
        proc_macro_dev = True,
    ),
    crate_name = "auth_binding_single_parser",
    crate_root = "tests/auth_binding_single_parser.rs",
    crate_features = [
        "anthropic",
        "comms",
        "gemini",
        "integration-real-tests",
        "jsonl-store",
        "mcp",
        "mob",
        "openai",
        "schedule",
        "session-store",
        "skills",
        "workgraph",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = [
        "tests/auth_binding_single_parser.rs",
    ],
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "auth_binding_single_parser",
        "CARGO_MANIFEST_DIR": "./meerkat-cli",
    },
    tags = [
        "fast",
    ],
    size = "small",
    data = [
        ":package_runfiles",
        "//:workspace_cargo_manifests",
        "//:workspace_metadata",
        "//meerkat-cli:cargo_manifest",
        "//meerkat-cli:rkat",
    ],
    env = {
        "RUST_MIN_STACK": "16777216",
        "CARGO_BIN_EXE_rkat": "$(rootpath //meerkat-cli:rkat)",
    },
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
        proc_macro_dev = True,
    ),
    deps = [
        "//meerkat-mob-mcp:meerkat_mob_mcp",
        "//meerkat-mob-pack:meerkat_mob_pack",
        "//meerkat-mob:meerkat_mob",
        "//meerkat-rpc:meerkat_rpc",
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_mcp_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
    ),
)

rust_test(
    name = "cli_auth_flow_test",
    aliases = aliases(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
        proc_macro = True,
        proc_macro_dev = True,
    ),
    crate_name = "cli_auth_flow",
    crate_root = "tests/cli_auth_flow.rs",
    crate_features = [
        "anthropic",
        "comms",
        "gemini",
        "integration-real-tests",
        "jsonl-store",
        "mcp",
        "mob",
        "openai",
        "schedule",
        "session-store",
        "skills",
        "workgraph",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = [
        "tests/cli_auth_flow.rs",
    ],
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "cli_auth_flow",
        "CARGO_MANIFEST_DIR": "./meerkat-cli",
    },
    tags = [
        "fast",
    ],
    size = "small",
    data = [
        ":package_runfiles",
        "//:workspace_cargo_manifests",
        "//:workspace_metadata",
        "//meerkat:package_runfiles",
        "//meerkat-cli:rkat",
    ],
    env = {
        "RUST_MIN_STACK": "16777216",
        "CARGO_BIN_EXE_rkat": "$(rootpath //meerkat-cli:rkat)",
    },
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
        proc_macro_dev = True,
    ),
    deps = [
        "//meerkat-mob-mcp:meerkat_mob_mcp",
        "//meerkat-mob-pack:meerkat_mob_pack",
        "//meerkat-mob:meerkat_mob",
        "//meerkat-rpc:meerkat_rpc",
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_mcp_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
    ),
)

rust_test(
    name = "cli_mobpack_live_smoke_test",
    aliases = aliases(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
        proc_macro = True,
        proc_macro_dev = True,
    ),
    crate_name = "cli_mobpack_live_smoke",
    crate_root = "tests/cli_mobpack_live_smoke.rs",
    crate_features = [
        "anthropic",
        "comms",
        "gemini",
        "integration-real-tests",
        "jsonl-store",
        "mcp",
        "mob",
        "openai",
        "schedule",
        "session-store",
        "skills",
        "workgraph",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = [
        "tests/cli_mobpack_live_smoke.rs",
    ],
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "cli_mobpack_live_smoke",
        "CARGO_MANIFEST_DIR": "./meerkat-cli",
    },
    tags = [
        "integration",
        "live",
        "required-feature",
    ],
    data = [
        ":package_runfiles",
        "//:workspace_cargo_manifests",
        "//:workspace_metadata",
        "//meerkat-cli:rkat",
    ],
    env = {
        "RUST_MIN_STACK": "16777216",
        "CARGO_BIN_EXE_rkat": "$(rootpath //meerkat-cli:rkat)",
    },
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
        proc_macro_dev = True,
    ),
    deps = [
        "//meerkat-mob-mcp:meerkat_mob_mcp",
        "//meerkat-mob-pack:meerkat_mob_pack",
        "//meerkat-mob:meerkat_mob",
        "//meerkat-rpc:meerkat_rpc",
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_mcp_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
    ),
)

rust_test(
    name = "e2e_system_cli_mobpack_pack_inspect_validate_bazel_test",
    aliases = aliases(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
        proc_macro = True,
        proc_macro_dev = True,
    ),
    crate_name = "cli_mobpack_live_smoke",
    crate_root = "tests/cli_mobpack_live_smoke.rs",
    crate_features = [
        "anthropic",
        "comms",
        "gemini",
        "integration-real-tests",
        "jsonl-store",
        "mcp",
        "mob",
        "openai",
        "schedule",
        "session-store",
        "skills",
        "workgraph",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = [
        "tests/cli_mobpack_live_smoke.rs",
    ],
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "cli_mobpack_live_smoke",
        "CARGO_MANIFEST_DIR": "./meerkat-cli",
    },
    args = [
        "--exact",
        "e2e_smoke_mobpack_pack_inspect_validate",
        "--ignored",
        "--nocapture",
    ],
    tags = [
        "e2e",
        "integration",
        "live",
        "required-feature",
        "system",
    ],
    size = "large",
    data = [
        "//:workspace_cargo_manifests",
        "//:workspace_metadata",
        "//meerkat-cli:rkat",
        ":package_runfiles",
    ],
    env = {
        "RUST_MIN_STACK": "16777216",
        "CARGO_BIN_EXE_rkat": "$(rootpath //meerkat-cli:rkat)",
    },
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
        proc_macro_dev = True,
    ),
    deps = [
        "//meerkat-mob-mcp:meerkat_mob_mcp",
        "//meerkat-mob-pack:meerkat_mob_pack",
        "//meerkat-mob:meerkat_mob",
        "//meerkat-rpc:meerkat_rpc",
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_mcp_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
    ),
)

rust_test(
    name = "e2e_system_cli_wasm_surface_gate_bazel_test",
    aliases = aliases(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
        proc_macro = True,
        proc_macro_dev = True,
    ),
    crate_name = "cli_mobpack_live_smoke",
    crate_root = "tests/cli_mobpack_live_smoke.rs",
    crate_features = [
        "anthropic",
        "comms",
        "gemini",
        "integration-real-tests",
        "jsonl-store",
        "mcp",
        "mob",
        "openai",
        "schedule",
        "session-store",
        "skills",
        "workgraph",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = [
        "tests/cli_mobpack_live_smoke.rs",
    ],
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "cli_mobpack_live_smoke",
        "CARGO_MANIFEST_DIR": "./meerkat-cli",
    },
    args = [
        "--exact",
        "e2e_smoke_wasm_surface_gate",
        "--ignored",
        "--nocapture",
    ],
    tags = [
        "e2e",
        "integration",
        "live",
        "required-feature",
        "system",
    ],
    size = "large",
    data = [
        "//:workspace_cargo_manifests",
        "//:workspace_metadata",
        "//meerkat-cli:rkat",
        ":package_runfiles",
    ],
    env = {
        "RUST_MIN_STACK": "16777216",
        "CARGO_BIN_EXE_rkat": "$(rootpath //meerkat-cli:rkat)",
    },
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
        proc_macro_dev = True,
    ),
    deps = [
        "//meerkat-mob-mcp:meerkat_mob_mcp",
        "//meerkat-mob-pack:meerkat_mob_pack",
        "//meerkat-mob:meerkat_mob",
        "//meerkat-rpc:meerkat_rpc",
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_mcp_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
    ),
)

rust_test(
    name = "e2e_system_cli_wasm_forbidden_capability_bazel_test",
    aliases = aliases(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
        proc_macro = True,
        proc_macro_dev = True,
    ),
    crate_name = "cli_mobpack_live_smoke",
    crate_root = "tests/cli_mobpack_live_smoke.rs",
    crate_features = [
        "anthropic",
        "comms",
        "gemini",
        "integration-real-tests",
        "jsonl-store",
        "mcp",
        "mob",
        "openai",
        "schedule",
        "session-store",
        "skills",
        "workgraph",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = [
        "tests/cli_mobpack_live_smoke.rs",
    ],
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "cli_mobpack_live_smoke",
        "CARGO_MANIFEST_DIR": "./meerkat-cli",
    },
    args = [
        "--exact",
        "e2e_smoke_wasm_forbidden_capability_rejected",
        "--ignored",
        "--nocapture",
    ],
    tags = [
        "e2e",
        "integration",
        "live",
        "required-feature",
        "system",
    ],
    size = "large",
    data = [
        "//:workspace_cargo_manifests",
        "//:workspace_metadata",
        "//meerkat-cli:rkat",
        ":package_runfiles",
    ],
    env = {
        "RUST_MIN_STACK": "16777216",
        "CARGO_BIN_EXE_rkat": "$(rootpath //meerkat-cli:rkat)",
    },
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
        proc_macro_dev = True,
    ),
    deps = [
        "//meerkat-mob-mcp:meerkat_mob_mcp",
        "//meerkat-mob-pack:meerkat_mob_pack",
        "//meerkat-mob:meerkat_mob",
        "//meerkat-rpc:meerkat_rpc",
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_mcp_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
    ),
)

rust_test(
    name = "live_smoke_cli_test",
    aliases = aliases(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
        proc_macro = True,
        proc_macro_dev = True,
    ),
    crate_name = "live_smoke_cli",
    crate_root = "tests/live_smoke_cli.rs",
    crate_features = [
        "anthropic",
        "comms",
        "gemini",
        "integration-real-tests",
        "jsonl-store",
        "mcp",
        "mob",
        "openai",
        "schedule",
        "session-store",
        "skills",
        "workgraph",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = [
        "tests/live_smoke_cli.rs",
    ],
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "live_smoke_cli",
        "CARGO_MANIFEST_DIR": "./meerkat-cli",
    },
    tags = [
        "integration",
        "live",
        "required-feature",
    ],
    data = [
        ":package_runfiles",
        "//:workspace_cargo_manifests",
        "//:workspace_metadata",
        "//meerkat-cli:rkat",
    ],
    env = {
        "RUST_MIN_STACK": "16777216",
        "CARGO_BIN_EXE_rkat": "$(rootpath //meerkat-cli:rkat)",
    },
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
        proc_macro_dev = True,
    ),
    deps = [
        "//meerkat-mob-mcp:meerkat_mob_mcp",
        "//meerkat-mob-pack:meerkat_mob_pack",
        "//meerkat-mob:meerkat_mob",
        "//meerkat-rpc:meerkat_rpc",
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_mcp_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
    ),
)

rust_test(
    name = "e2e_system_cli_capabilities_and_config_bazel_test",
    aliases = aliases(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
        proc_macro = True,
        proc_macro_dev = True,
    ),
    crate_name = "live_smoke_cli",
    crate_root = "tests/live_smoke_cli.rs",
    crate_features = [
        "anthropic",
        "comms",
        "gemini",
        "integration-real-tests",
        "jsonl-store",
        "mcp",
        "mob",
        "openai",
        "schedule",
        "session-store",
        "skills",
        "workgraph",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = [
        "tests/live_smoke_cli.rs",
    ],
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "live_smoke_cli",
        "CARGO_MANIFEST_DIR": "./meerkat-cli",
    },
    args = [
        "--exact",
        "e2e_scenario_28_cli_capabilities_and_config",
        "--ignored",
        "--nocapture",
    ],
    tags = [
        "e2e",
        "integration",
        "live",
        "required-feature",
        "system",
    ],
    size = "large",
    data = [
        "//:workspace_cargo_manifests",
        "//:workspace_metadata",
        "//meerkat-cli:rkat",
        ":package_runfiles",
    ],
    env = {
        "RUST_MIN_STACK": "16777216",
        "CARGO_BIN_EXE_rkat": "$(rootpath //meerkat-cli:rkat)",
    },
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
        proc_macro_dev = True,
    ),
    deps = [
        "//meerkat-mob-mcp:meerkat_mob_mcp",
        "//meerkat-mob-pack:meerkat_mob_pack",
        "//meerkat-mob:meerkat_mob",
        "//meerkat-rpc:meerkat_rpc",
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_mcp_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
    ),
)

rust_test(
    name = "runtime_backed_ingress_test",
    aliases = aliases(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
        proc_macro = True,
        proc_macro_dev = True,
    ),
    crate_name = "runtime_backed_ingress",
    crate_root = "tests/runtime_backed_ingress.rs",
    crate_features = [
        "anthropic",
        "comms",
        "gemini",
        "integration-real-tests",
        "jsonl-store",
        "mcp",
        "mob",
        "openai",
        "schedule",
        "session-store",
        "skills",
        "workgraph",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = [
        "tests/runtime_backed_ingress.rs",
    ],
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "runtime_backed_ingress",
        "CARGO_MANIFEST_DIR": "./meerkat-cli",
    },
    tags = [
        "fast",
    ],
    size = "small",
    data = [
        ":package_runfiles",
        "//:workspace_cargo_manifests",
        "//:workspace_metadata",
        "//meerkat-cli:rkat",
    ],
    env = {
        "RUST_MIN_STACK": "16777216",
        "CARGO_BIN_EXE_rkat": "$(rootpath //meerkat-cli:rkat)",
    },
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
        proc_macro_dev = True,
    ),
    deps = [
        "//meerkat-mob-mcp:meerkat_mob_mcp",
        "//meerkat-mob-pack:meerkat_mob_pack",
        "//meerkat-mob:meerkat_mob",
        "//meerkat-rpc:meerkat_rpc",
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_mcp_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
    ),
)

rust_test(
    name = "sqlite_tools_full_reuse_test",
    aliases = aliases(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
        proc_macro = True,
        proc_macro_dev = True,
    ),
    crate_name = "sqlite_tools_full_reuse",
    crate_root = "tests/sqlite_tools_full_reuse.rs",
    crate_features = [
        "anthropic",
        "comms",
        "gemini",
        "integration-real-tests",
        "jsonl-store",
        "mcp",
        "mob",
        "openai",
        "schedule",
        "session-store",
        "skills",
        "workgraph",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = [
        "tests/sqlite_tools_full_reuse.rs",
    ],
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "sqlite_tools_full_reuse",
        "CARGO_MANIFEST_DIR": "./meerkat-cli",
    },
    tags = [
        "fast",
    ],
    size = "small",
    data = [
        ":package_runfiles",
        "//:workspace_cargo_manifests",
        "//:workspace_metadata",
        "//meerkat-cli:rkat",
    ],
    env = {
        "RUST_MIN_STACK": "16777216",
        "CARGO_BIN_EXE_rkat": "$(rootpath //meerkat-cli:rkat)",
    },
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
        proc_macro_dev = True,
    ),
    deps = [
        "//meerkat-mob-mcp:meerkat_mob_mcp",
        "//meerkat-mob-pack:meerkat_mob_pack",
        "//meerkat-mob:meerkat_mob",
        "//meerkat-rpc:meerkat_rpc",
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_mcp_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
    ),
)

rust_test(
    name = "system_cli_init_test",
    aliases = aliases(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
        proc_macro = True,
        proc_macro_dev = True,
    ),
    crate_name = "system_cli_init",
    crate_root = "tests/system_cli_init.rs",
    crate_features = [
        "anthropic",
        "comms",
        "gemini",
        "integration-real-tests",
        "jsonl-store",
        "mcp",
        "mob",
        "openai",
        "schedule",
        "session-store",
        "skills",
        "workgraph",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = [
        "tests/system_cli_init.rs",
    ],
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "system_cli_init",
        "CARGO_MANIFEST_DIR": "./meerkat-cli",
    },
    tags = [
        "integration",
        "required-feature",
        "system",
    ],
    data = [
        ":package_runfiles",
        "//:workspace_cargo_manifests",
        "//:workspace_metadata",
        "//meerkat-cli:rkat",
    ],
    env = {
        "RUST_MIN_STACK": "16777216",
        "CARGO_BIN_EXE_rkat": "$(rootpath //meerkat-cli:rkat)",
    },
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
        proc_macro_dev = True,
    ),
    deps = [
        "//meerkat-mob-mcp:meerkat_mob_mcp",
        "//meerkat-mob-pack:meerkat_mob_pack",
        "//meerkat-mob:meerkat_mob",
        "//meerkat-rpc:meerkat_rpc",
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_mcp_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
    ),
)

rust_test(
    name = "e2e_system_cli_init_snapshot_bazel_test",
    aliases = aliases(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
        proc_macro = True,
        proc_macro_dev = True,
    ),
    crate_name = "system_cli_init",
    crate_root = "tests/system_cli_init.rs",
    crate_features = [
        "anthropic",
        "comms",
        "gemini",
        "integration-real-tests",
        "jsonl-store",
        "mcp",
        "mob",
        "openai",
        "schedule",
        "session-store",
        "skills",
        "workgraph",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = [
        "tests/system_cli_init.rs",
    ],
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "system_cli_init",
        "CARGO_MANIFEST_DIR": "./meerkat-cli",
    },
    args = [
        "--exact",
        "integration_real_rkat_init_snapshot",
        "--ignored",
        "--nocapture",
    ],
    tags = [
        "e2e",
        "integration",
        "required-feature",
        "system",
    ],
    size = "large",
    data = [
        "//:workspace_cargo_manifests",
        "//:workspace_metadata",
        "//meerkat-cli:rkat",
        ":package_runfiles",
    ],
    env = {
        "RUST_MIN_STACK": "16777216",
        "CARGO_BIN_EXE_rkat": "$(rootpath //meerkat-cli:rkat)",
    },
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
        proc_macro_dev = True,
    ),
    deps = [
        "//meerkat-mob-mcp:meerkat_mob_mcp",
        "//meerkat-mob-pack:meerkat_mob_pack",
        "//meerkat-mob:meerkat_mob",
        "//meerkat-rpc:meerkat_rpc",
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_mcp_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
    ),
)

rust_test(
    name = "system_cli_resume_test",
    aliases = aliases(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
        proc_macro = True,
        proc_macro_dev = True,
    ),
    crate_name = "system_cli_resume",
    crate_root = "tests/system_cli_resume.rs",
    crate_features = [
        "anthropic",
        "comms",
        "gemini",
        "integration-real-tests",
        "jsonl-store",
        "mcp",
        "mob",
        "openai",
        "schedule",
        "session-store",
        "skills",
        "workgraph",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = [
        "tests/system_cli_resume.rs",
    ],
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "system_cli_resume",
        "CARGO_MANIFEST_DIR": "./meerkat-cli",
    },
    tags = [
        "integration",
        "required-feature",
        "system",
    ],
    data = [
        ":package_runfiles",
        "//:workspace_cargo_manifests",
        "//:workspace_metadata",
        "//meerkat-cli:rkat",
    ],
    env = {
        "RUST_MIN_STACK": "16777216",
        "CARGO_BIN_EXE_rkat": "$(rootpath //meerkat-cli:rkat)",
    },
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
        proc_macro_dev = True,
    ),
    deps = [
        "//meerkat-mob-mcp:meerkat_mob_mcp",
        "//meerkat-mob-pack:meerkat_mob_pack",
        "//meerkat-mob:meerkat_mob",
        "//meerkat-rpc:meerkat_rpc",
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_mcp_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
    ),
)

rust_test(
    name = "e2e_system_cli_resume_tools_bazel_test",
    aliases = aliases(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
        proc_macro = True,
        proc_macro_dev = True,
    ),
    crate_name = "system_cli_resume",
    crate_root = "tests/system_cli_resume.rs",
    crate_features = [
        "anthropic",
        "comms",
        "gemini",
        "integration-real-tests",
        "jsonl-store",
        "mcp",
        "mob",
        "openai",
        "schedule",
        "session-store",
        "skills",
        "workgraph",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = [
        "tests/system_cli_resume.rs",
    ],
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "system_cli_resume",
        "CARGO_MANIFEST_DIR": "./meerkat-cli",
    },
    args = [
        "--exact",
        "integration_real_cli_resume_tools",
        "--ignored",
        "--nocapture",
    ],
    tags = [
        "e2e",
        "integration",
        "required-feature",
        "system",
    ],
    size = "large",
    data = [
        "//:workspace_cargo_manifests",
        "//:workspace_metadata",
        "//meerkat-cli:rkat",
        ":package_runfiles",
    ],
    env = {
        "RUST_MIN_STACK": "16777216",
        "CARGO_BIN_EXE_rkat": "$(rootpath //meerkat-cli:rkat)",
    },
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
        proc_macro_dev = True,
    ),
    deps = [
        "//meerkat-mob-mcp:meerkat_mob_mcp",
        "//meerkat-mob-pack:meerkat_mob_pack",
        "//meerkat-mob:meerkat_mob",
        "//meerkat-rpc:meerkat_rpc",
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_mcp_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
        normal_dev = True,
    ),
)

rust_binary(
    name = "rkat_surface_session_store_bin",
    aliases = aliases(package_name = "meerkat-cli"),
    crate_name = "rkat",
    crate_root = "src/main.rs",
    crate_features = [
        "session-store",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = glob(["src/**/*.rs"]),
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "rkat",
        "CARGO_MANIFEST_DIR": "meerkat-cli",
    },
    tags = [
        "buildbuddy",
        "feature-matrix",
        "surface",
    ],
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
    ),
    deps = [
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
    ),
)

rust_binary(
    name = "rkat_surface_session_store_mcp_bin",
    aliases = aliases(package_name = "meerkat-cli"),
    crate_name = "rkat",
    crate_root = "src/main.rs",
    crate_features = [
        "session-store",
        "mcp",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = glob(["src/**/*.rs"]),
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "rkat",
        "CARGO_MANIFEST_DIR": "meerkat-cli",
    },
    tags = [
        "buildbuddy",
        "feature-matrix",
        "surface",
    ],
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
    ),
    deps = [
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_mcp_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
    ),
)

rust_binary(
    name = "rkat_surface_session_store_comms_mcp_bin",
    aliases = aliases(package_name = "meerkat-cli"),
    crate_name = "rkat",
    crate_root = "src/main.rs",
    crate_features = [
        "session-store",
        "comms",
        "mcp",
        "workgraph",
    ],
    edition = "2024",
    compile_data = [
        "Cargo.toml",
        "src/main.rs",
    ],
    srcs = glob(["src/**/*.rs"]),
    visibility = ["//visibility:public"],
    rustc_env = {
        "CARGO_PKG_VERSION": "0.6.33",
        "CARGO_BIN_NAME": "rkat",
        "CARGO_MANIFEST_DIR": "meerkat-cli",
    },
    tags = [
        "buildbuddy",
        "feature-matrix",
        "surface",
    ],
    proc_macro_deps = all_crate_deps(
        package_name = "meerkat-cli",
        proc_macro = True,
    ),
    deps = [
        "//meerkat:meerkat",
        "//meerkat:meerkat_anthropic_agent_factory_build",
        "//meerkat:meerkat_client_agent_factory_build",
        "//meerkat:meerkat_comms_agent_factory_build",
        "//meerkat:meerkat_contracts_agent_factory_build",
        "//meerkat:meerkat_core_agent_factory_build",
        "//meerkat:meerkat_gemini_agent_factory_build",
        "//meerkat:meerkat_llm_core_agent_factory_build",
        "//meerkat:meerkat_mcp_agent_factory_build",
        "//meerkat:meerkat_openai_agent_factory_build",
        "//meerkat:meerkat_providers_agent_factory_build",
        "//meerkat:meerkat_runtime_agent_factory_build",
        "//meerkat:meerkat_store_agent_factory_build",
        "//meerkat:meerkat_tools_agent_factory_build",
    ] + all_crate_deps(
        package_name = "meerkat-cli",
        normal = True,
    ),
)

test_suite(
    name = "fast_tests",
    tests = [
        ":auth_binding_single_parser_test",
        ":cli_auth_flow_test",
        ":runtime_backed_ingress_test",
        ":sqlite_tools_full_reuse_test",
    ],
)
