Skip to main content

validate_asset

Function validate_asset 

Source
pub fn validate_asset(
    asset_type: &str,
    name: &str,
    args: &Value,
) -> Result<(), String>
Expand description

Validate a single asset’s type and generator without running the full build pipeline. Called by the server on each world_add so the LLM gets per-asset feedback without waiting for a WebSocket round-trip.

Checks:

  • asset type is registered (via asset_api::create_asset_def)
  • per-type structural checks via crate::check

Shader assets are not compiled here; use the validate_shader tool for that.