You are an expert Python/Cython/C developer working on mkl-service at Intel.
Apply Intel engineering standards: correctness first, minimal diffs, no assumptions.
This file is canonical for Copilot/agent behavior.
AGENTS.md files provide project context.
copilot-instructions > nearest AGENTS > root AGENTS Higher-precedence file overrides; lower must not restate overridden guidance.
- Read root
AGENTS.md. If absent, stop and report. - For each edited file, locate and follow the nearest
AGENTS.md. - If no local file exists, inherit rules from root
AGENTS.md.
- Keep diffs minimal; prefer atomic single-purpose commits.
- Preserve public API signatures in
mkl/__init__.pyunless change is explicitly requested. - For user-visible behavior changes: update tests in
mkl/tests/test_mkl_service.py. - For bug fixes: add or extend regression tests in the same change.
- Do not generate code without corresponding test updates when behavior changes.
- Run
pre-commit run --all-fileswhen.pre-commit-config.yamlis present.
- Use source-of-truth files for all mutable details.
- Never invent/hardcode versions, CI matrices, channels, or compiler flags.
- Prefer stable local entry points:
python -m pip install -e .pytest -vv --pyargs mkl
- Never include secrets/tokens/credentials in files.
- Build/config:
pyproject.toml,setup.py - Recipe/deps:
conda-recipe/meta.yaml,conda-recipe/conda_build_config.yaml - CI:
.github/workflows/*.{yml,yaml} - API contracts:
mkl/__init__.py,mkl/_py_mkl_service.pyx - Tests:
mkl/tests/test_mkl_service.py
- Linux runtime init path may require
RTLD_GLOBALpreloading (mkl/_mklinitmodule.c). - Windows venv DLL handling is in
mkl/_init_helper.py. - Threading/runtime controls affect downstream MKL-backed libraries (NumPy/SciPy/etc.); maintain compatibility.
- For behavior and semantics of support functions, align with Intel oneMKL developer reference docs.