These rules dictate the boundaries for any AI coding assistant or autonomous agent working within the Simulation repository.
autonomy/: You are allowed to create, modify, or delete algorithm plugins in theautonomy/mission/,autonomy/targeting/,autonomy/planning/, andautonomy/control/subdirectories.perception/: You are allowed to build visual trackers and sensor modules here.experiments/: You are allowed to editexperiment_runner.py(and similar scripts) ONLY to update the configuration dictionnary to register and test new plugins.
core/: DO NOT modifysim_engine.py,world_state.py, ormodule_registry.py. These define the immutable pipeline and data structures.aircraft/: DO NOT modify thedynamics_engine.pyoraircraft_params.py. Physics must remain constant for fair evaluation of algorithms.environment/: DO NOT modifyworld.pyorenemy_spawner.py. The generation of targets must remain completely decoupled from the autonomy stack.visualization/: DO NOT modify the PyQt rendering logic unless specifically instructed to add a new visualization layer approved by the core team.
- Immutable State: You must never write code that directly mutates the
WorldStateobject passed to your module'sprocess()method. - No Direct Physics Access: You must never attempt to call
sim.step()or access theDynamicsEnginedirectly from an autonomy module. Your module must only return the designated command object (TargetSelection,TrajectoryCommand,ControlCommand). - Use the Registry: Always use the
@ModuleRegistry.register(...)decorator for any new algorithm class so it can be dynamically loaded by the experiment runner.
- When a user asks you to "implement a new targeting algorithm" or "build a new controller", you should immediately place the code in the appropriate
autonomy/folder and instruct the user how to update theirexperiments/experiment_runner.pyconfig to use it. - If a task requires modifying a restricted directory to succeed, you must stop and ask the user for explicit permission, explaining why the current modular architecture is insufficient for the task.