From 3af983a9553f3a2233188426155c6ff851ad49f8 Mon Sep 17 00:00:00 2001 From: AndreaRigoni Date: Wed, 8 Apr 2026 07:31:47 +0000 Subject: [PATCH] fix skills rules --- .agents/rules/context_exclude_vtk.md | 9 +++++++ .agents/rules/context_gcompose.md | 9 +++++++ .agents/rules/context_vtk.md | 9 +++++++ .agents/rules/micromamba.md | 8 ------ .agents/skills/micromamba_build.md | 39 ++++++++++++++++++++++++++++ 5 files changed, 66 insertions(+), 8 deletions(-) create mode 100644 .agents/rules/context_exclude_vtk.md create mode 100644 .agents/rules/context_gcompose.md create mode 100644 .agents/rules/context_vtk.md delete mode 100644 .agents/rules/micromamba.md create mode 100644 .agents/skills/micromamba_build.md diff --git a/.agents/rules/context_exclude_vtk.md b/.agents/rules/context_exclude_vtk.md new file mode 100644 index 0000000..519e207 --- /dev/null +++ b/.agents/rules/context_exclude_vtk.md @@ -0,0 +1,9 @@ +--- +trigger: manual +--- +# Context Restriction: No VTK +When this rule is active, restrict the operational context to libraries excluding the VTK layer. +- **Exclude Path**: `src/Vtk` +- **Include Paths**: `src/Core`, `src/Math`, `src/HEP`, `src/Root`, `src/Python`, `src/utils` +- **Focus**: Tomographic reconstruction algorithms, data structures in `Core`, and physical modeling in `HEP`. +- **Constraint**: Avoid referencing `Puppet`, `Viewport`, or any VTK-specific headers unless the user overrides this restriction. diff --git a/.agents/rules/context_gcompose.md b/.agents/rules/context_gcompose.md new file mode 100644 index 0000000..a3aedfe --- /dev/null +++ b/.agents/rules/context_gcompose.md @@ -0,0 +1,9 @@ +--- +trigger: manual +--- +# Context Focus: gcompose Application +When this rule is active, prioritize the `gcompose` GUI application. +- **Primary Path**: `app/gcompose` +- **Focus**: `MainPanel`, `ContextPanel`, `PropertiesPanel`, and `ViewportPane`. +- **Integration**: Wiring of Qt signals/slots between the `uLib` core model and the GUI widgets. +- **Dependency**: Reference `src/Vtk` and `src/Core` as the underlying framework for the application. diff --git a/.agents/rules/context_vtk.md b/.agents/rules/context_vtk.md new file mode 100644 index 0000000..c408ccb --- /dev/null +++ b/.agents/rules/context_vtk.md @@ -0,0 +1,9 @@ +--- +trigger: always_on +--- +# Context Inclusion: VTK +When this rule is active, include the VTK visualization layer in the operational context. +- **Priority Path**: `src/Vtk` +- **Focus**: `Puppet` hierarchy, `Viewport` management, and the synchronization between domain objects and VTK props. +- **Key Classes**: `vtkViewport`, `vtkQViewport`, `vtkObjectsContext`, and all classes in `src/Vtk/HEP/Geant`. +- **Logic**: Ensure transformations (TRS) applied to domain objects are correctly mirrored in the visualization layer and vice versa. diff --git a/.agents/rules/micromamba.md b/.agents/rules/micromamba.md deleted file mode 100644 index fd0b4ec..0000000 --- a/.agents/rules/micromamba.md +++ /dev/null @@ -1,8 +0,0 @@ ---- -trigger: always_on ---- - -build in build directory using always micromamba "uLib" env. -build with: - make flag -j$(nproc) - ninja -C build \ No newline at end of file diff --git a/.agents/skills/micromamba_build.md b/.agents/skills/micromamba_build.md new file mode 100644 index 0000000..2337367 --- /dev/null +++ b/.agents/skills/micromamba_build.md @@ -0,0 +1,39 @@ +# Skill: Build uLib with Micromamba + +This skill provides instructions for building the uLib project using the micromamba environment. + +## Context +- **Environment**: micromamba `uLib` +- **Output Directory**: `build` +- **CPU Usage**: All available cores + +## Instructions + +1. **Environment Setup**: + Ensure micromamba is properly initialized and the `uLib` environment is active. + ```bash + export MAMBA_EXE="/home/share/micromamba/bin/micromamba" + export MAMBA_ROOT_PREFIX="/home/share/micromamba" + eval "$(/home/share/micromamba/bin/micromamba shell hook --shell bash)" + micromamba activate uLib + ``` + +2. **Full Rebuild (if needed)**: + If the `build` directory does not exist or a full reconfiguration is required: + ```bash + conan profile detect --force + conan install . --output-folder=build --build=missing + cmake --preset conan-release + ``` + +3. **Incremental Build**: + Run the build command from the root directory, pointing to the `build` folder and using all cores. + ```bash + cmake --build build -j$(nproc) + ``` + +4. **Specific Target Build**: + To build a specific target (e.g., gcompose): + ```bash + cmake --build build --target gcompose -j$(nproc) + ```