ワンクリックで
setup
// Check Python environment for required DS/ML libraries and report versions or missing packages. Use when setting up a new project or debugging import errors.
// Check Python environment for required DS/ML libraries and report versions or missing packages. Use when setting up a new project or debugging import errors.
Scikit-learn API patterns for preprocessing, pipelines, model selection, and evaluation. Use when /ds:experiment needs to build sklearn pipelines, tune hyperparameters, or evaluate models.
Hyperparameter tuning workflow reference -- strategy selection, Bayesian optimization with Optuna, search space design, and result analysis. Use when /ds:experiment needs to choose a tuning strategy, design search spaces, or analyze tuning runs.
Pre-model data preparation pipelines for cleaning, validation, transformation, and ETL orchestration. Use when raw data needs deduplication, schema validation, format conversion, or quality assurance before EDA or modeling.
Pandas API patterns for DataFrame operations, data cleaning, aggregation, merging, and performance optimization. Use when generating pandas code for data loading, manipulation, or profiling in /ds:eda, /ds:preprocess, or /ds:experiment.
Polars expression API for high-performance DataFrame operations, lazy evaluation, joins, aggregations, and I/O. Use as a parallel alternative to pandas-pro when working with large datasets or generating Polars code for data loading, manipulation, or profiling in /ds:eda, /ds:preprocess, or /ds:experiment.
Data quality validation with Great Expectations, dbt tests, and data contracts. Use when building formal validation rules, expectation suites, or data contracts for repeatable quality gates.
| name | setup |
| description | Check Python environment for required DS/ML libraries and report versions or missing packages. Use when setting up a new project or debugging import errors. |
Check the current Python environment for libraries required by the ds plugin. Report what is installed, what is missing, and provide install commands.
Run python3 --version and report the result. Require Python 3.9+.
For each required library, run a Python import and version check:
python3 -c "
import importlib
required = {
'pandas': 'pandas',
'scikit-learn': 'sklearn',
'scipy': 'scipy',
'statsmodels': 'statsmodels',
'numpy': 'numpy',
}
for pkg_name, import_name in required.items():
try:
mod = importlib.import_module(import_name)
version = getattr(mod, '__version__', 'installed')
print(f' {pkg_name}: {version}')
except ImportError:
print(f' {pkg_name}: MISSING')
"
Run the same check for optional libraries used in generated experiment code:
python3 -c "
import importlib
optional = {
'matplotlib': 'matplotlib',
'seaborn': 'seaborn',
'aeon': 'aeon',
'xgboost': 'xgboost',
'lightgbm': 'lightgbm',
'shap': 'shap',
'great_expectations': 'great_expectations',
'polars': 'polars',
'optuna': 'optuna',
}
for pkg_name, import_name in optional.items():
try:
mod = importlib.import_module(import_name)
version = getattr(mod, '__version__', 'installed')
print(f' {pkg_name}: {version}')
except ImportError:
print(f' {pkg_name}: not installed')
"
If any required libraries are missing, output the install command:
uv pip install pandas scikit-learn scipy statsmodels numpy
List only the missing packages in the command. If all required libraries are present, report that the environment is ready.
For missing optional libraries, suggest but do not insist:
uv pip install matplotlib seaborn aeon xgboost lightgbm shap great_expectations polars optuna
python3 is not found, suggest the user activate their environment first.