Spaces:
Running on Zero
Agentic Machine Learning Engineer (Traditional ML Engineering) - Qwen3-Coder-30B-A3B-Instruct
Note 1: Do not upload confidential, regulated, proprietary, customer, or personally identifiable production data into a public Hugging Face Space
Note 2: This project is an automated traditional machine learning engineering experiment focused on supervised classification and regression workflows
Note 3: This project uses a bounded single-agent function-calling / tool-use loop rather than an unlimited autonomous agent
(this) Bounded Tool-Calling Agent vs Open-Ended Autonomous Agent
Bounded Tool-Calling Agent (my agent)
βReason about the task, call the available ML tools when needed, and stop within a controlled number of steps.β
Open-Ended Autonomous Agent
βContinue deciding and acting until the broader goal is achieved.β
| Bounded Tool-Calling Agent | Open-Ended Autonomous Agent | |
|---|---|---|
| Consistency | higher because tools and loop limits are controlled | can vary more between runs |
| Traceability | tool calls and observations are exposed | can become harder to trace across long runs |
| Resource control | hard max agent-step limit | may require additional stopping logic |
| Decision-making | dynamic tool selection within a constrained toolset | can make broader autonomous decisions |
| Flexibility | controlled | higher |
| Risk of runaway loops | reduced through MAX_AGENT_STEPS param |
higher without explicit limits |
bounded agent decides which ML operation to perform inside a controlled tool loop, while a fully open-ended autonomous agent may continue planning and acting without the same fixed execution boundary.
Agent Goals:
agentic machine learning engineering app for profiling datasets, automated supervised-learning modeling, preprocessing data, training baseline models, comparing algorithms, evaluating real model performance, and generating reusable scikit-learn pipelines
agent loads a real-world dataset, creates the modeling context, gives a Qwen3-Coder agent access to machine-learning tools, and allows the model to decide which tools to call before producing a final ML assessment and reusable pipeline code
reduce repetitive setup work when starting supervised machine learning experiments
ground model-performance claims in actual scikit-learn execution
expose tool calls and observations for auditability
demonstrate how an LLM can orchestrate traditional machine learning workflows without performing the numerical fitting itself
Machine Learning Agent - Tasks
Machine Learning Agent can analyze datasets and execute supervised-learning workflows by first understanding the dataset, target, feature types, and modeling objective.
Dataset inspection
inspect_dataset tool can analyze:
- Shape: number of rows and columns
- Columns: available feature / target candidates
- Types: pandas data types
- Numeric features: identified numerical columns
- Categorical features: identified categorical columns
- Nulls: missing-value information
- Cardinality: number of unique values per column
- Examples: representative values from each column
- Targets: possible prediction-target columns
Modeling tasks
the ML workflow can:
- inspect the dataset
- identify a prediction target
- infer classification vs regression
- separate numeric and categorical features
- construct preprocessing transformations
- train baseline estimators
- calculate holdout metrics
- compare compatible algorithms
- inspect feature importance / coefficients where supported
- generate reusable scikit-learn pipeline code
- export fitted pipelines as Joblib artifacts
findings can then be converted into:
Dataset assessment
β
Recommended modeling setup
β
Preprocessing pipeline
β
Model training
β
Holdout evaluation
β
Algorithm comparison
β
Reusable scikit-learn pipeline
What, Why, and General Objectives
What
Tool-using Machine Learning Engineering AI agent that profiles datasets, determines supervised-learning setup, trains real scikit-learn models, compares algorithms, evaluates model performance, and generates reusable ML pipelines.
Why
Machine learning engineers repeatedly perform the same early-stage workflow when starting supervised learning related tasks/projects:
load dataset
β
inspect features + target
β
determine problem type
β
build preprocessing
β
select algorithm
β
train model
β
evaluate performance
β
compare alternatives
β
generate reusable pipeline
automating this workflow reduces repetitive machine learning setup, baseline experimentation, preprocessing, evaluation, and pipeline-generation work
General Objectives
automate traditional ML modeling
make model evaluation traceable through tool outputs
provide a consistent preprocessing and model-training workflow
compare baseline algorithms quickly
calculate metrics from real fitted models rather than LLM estimates
generate reusable scikit-learn pipeline code
expose tool calls and observations for auditability
demonstrate how an LLM agent can orchestrate traditional machine learning tools
keep local ML execution lightweight enough for Hugging Face Spaces
LLM / Agent Stack
Agent LLM: Qwen/Qwen3-Coder-30B-A3B-Instruct
Inference:
huggingface_hub.InferenceClientProvider routing: Hugging Face Inference Providers using
provider="auto"by defaultAgent pattern: bounded single-agent function-calling / tool-use loop
Tool routing:
tool_choice="auto"Maximum agent steps:
4by defaultPrevent Infinite Loops: keeps the agent from repeatedly calling the same tool or getting stuck in an unsuccessful reasoning loop
Control Costs: limits unnecessary inference-provider requests and token usage
Manage Context Windows: prevents tool observations from growing indefinitely inside the conversation context
Reduce Latency: prevents unnecessarily long tool-calling runs
Improve Debuggability: provides a predictable execution boundary when analyzing the tool trace
Local ML execution: scikit-learn
Dataset processing: pandas
Model artifact export: Joblib
Parquet support: PyArrow
Excel support: OpenPyXL
HF sample dataset:
scikit-learn/adult-census-income
Goal:
machine learning engineering is not only model generation
a usable supervised ML workflow requires:
understanding the dataset
selecting a prediction target
deciding whether the task is classification or regression
identifying numerical and categorical features
preprocessing missing and categorical data
selecting an estimator
training models on real data
calculating ML evaluation metrics
comparing alternatives options (ML models)
packaging preprocessing + model logic into reusable code
doing this manually for every new dataset creates repetitive experimentation and setup work.
this Machine Learning Engineering Agent is designed to:
reduce time spent manually inspecting new datasets
establish a consistent supervised-learning baseline workflow
identify numerical and categorical feature requirements
infer or use a selected classification / regression problem type
allow the LLM to call machine-learning execution functions
train real models through scikit-learn
calculate real holdout evaluation metrics
compare compatible baseline algorithms
generate production-oriented scikit-learn pipelines
export fitted pipelines as Joblib artifacts
expose the agent's tool calls through a trace for auditability
goal of the app is to combine:
LLM reasoning
+
ML execution
+
tool calling
+
reusable pipeline generation
Agentic Workflow:
Dataset
β
app.py
β
Dataset loading + session state
β
Dataset profile
β
Target selection
β
Problem-type inference / selection
β
Algorithm selection
β
MachineLearningAgent
β
Qwen3-Coder-30B-A3B-Instruct
β
HF InferenceClient
β
tool_choice="auto"
β
Agent decides which ML tool(s) to call
β
ββββββββββββββββββββββββββββββββββββββββββββββββ
β inspect_dataset β
β recommend_modeling_setup β
β train_candidate_model β
β compare_algorithms β
β generate_pipeline_code β
ββββββββββββββββββββββββββββββββββββββββββββββββ
β
Tool observations returned to Qwen
β
Agent evaluates whether another tool is needed
β
Bounded tool-use loop
β
ML assessment
β
Modeling risks
β
Recommended modeling setup
β
Evaluation findings
β
Model comparison
β
Generated scikit-learn pipeline
β
Tool Trace + Diagnostics
Agent Loop Type
Bounded Single-Agent Function-Calling / Tool-Use Loop
agentic pattern where one AI agent can autonomously choose from external ML tools, process their outputs, and repeat the process inside a strictly defined step limit
unlike open-ended agents that can continue indefinitely, this bounded loop places a hard-fixed limit on execution
the project uses a single agent, not a multi-agent architecture
Architecture:
observe task β choose tool β execute ML operation β return observation β repeat if needed β synthesize final answer
the LLM does not directly calculate every machine learning result itself
MachineLearningAgent exposes Python / scikit-learn tools to Qwen through Hugging Face function calling
the model receives:
system instructions
user machine learning task
dataset profile
selected target
inferred or selected problem type
selected algorithm
available tool definitions
the model can then request one or more tool calls.
Example Input Workflow
Qwen
β
inspect_dataset()
β
dataset profile returned to Qwen
β
recommend_modeling_setup()
β
recommended setup returned to Qwen
β
train_candidate_model()
β
real training metrics returned to Qwen
β
compare_algorithms()
β
algorithm leaderboard returned to Qwen
β
generate_pipeline_code()
β
scikit-learn pipeline code returned to Qwen
β
Final ML response
loop is bounded by:
MAX_AGENT_STEPS = 4
if the model does not finish within the configured tool loop, the application moves toward final response synthesis rather than allowing unlimited additional tool calls.
this makes the architecture a controlled bounded tool-calling machine learning agent.
Agent Architecture:
USER
β
βΌ
βββββββββββββββββββ
β app.py β
β Gradio UI β
β Session state β
β Dataset loading β
ββββββββββ¬βββββββββ
β
β task + dataset + target
βΌ
ββββββββββββββββββββββββββ
β MachineLearningAgent β
β agent.py β
ββββββββββββββ¬ββββββββββββ
β
βΌ
ββββββββββββββββββββββββββ
β Qwen3-Coder 30B A3B β
β HF InferenceClient β
β tool_choice="auto" β
ββββββββββββββ¬ββββββββββββ
β
decides which tool
to execute
β
βββββββββββββββββββββΌβββββββββββββββββββββ
β β β
βΌ βΌ βΌ
inspect_dataset recommend_modeling_setup train_candidate_model
β β β
βββββββββββββββββββββΌβββββββββββββββββββββ
β
βΌ
compare_algorithms
β
βΌ
generate_pipeline_code
β
βΌ
Tool observation
β
βΌ
ββββββββββββββββββββββββββ
β Observation added back β
β to LLM context β
ββββββββββββββ¬ββββββββββββ
β
βΌ
More tools needed?
/ \
yes no
β β
ββββββββ β
β β
βΌ βΌ
Tool loop Final synthesis
β
βΌ
ML assessment
Modeling risks
Recommended setup
Evaluation findings
Model comparison
Pipeline code
Tool trace
Core Architectural Pattern:
app.py
β
agent.py
β
MachineLearningAgent
β
Qwen3-Coder + HF tool calling
β
ml_engine.py
β
ML operations
β
tool observations
β
agent.py
β
final ML assessment + pipeline code
Agent Tools
1. inspect_dataset
analyzes the loaded dataset and returns structural information used by the agent before modeling
typical outputs include:
source
row count
column count
column names
feature types
pandas dtypes
null information
unique-value information
possible target columns
example values
used when the agent needs to understand the structure of the dataset before recommending a modeling approach
2. recommend_modeling_setup
evaluates the dataset and selected target to recommend a supervised-learning configuration
recommendation can include:
target column
inferred problem type
candidate algorithms
dataset characteristics relevant to modeling
preprocessing expectations
numerical feature information
categorical feature information
goal: setup a reasonable baseline modeling configuration before training
3. train_candidate_model
builds and trains the selected scikit-learn pipeline using the actual loaded dataset
training workflow:
dataset
β
feature / target split
β
train / holdout split
β
numeric preprocessing
β
categorical preprocessing
β
selected estimator
β
fit
β
holdout prediction
β
holdout evaluation
the agent receives metrics produced by the trained model
the agent is instructed not to invent performance values
4. compare_algorithms
trains compatible baseline algorithms and returns a comparison leaderboard based on real holdout results.
classification, candidate algorithms include:
Logistic Regression
Random Forest Classifier
SGD Classifier
Linear SVM Classifier
for regression, candidate algorithms include:
Ridge Regression
Random Forest Regressor
SGD Regressor
this allows the agent to compare alternatives using actual evaluation results instead of guessing which model performs best.
5. generate_pipeline_code
generates reusable scikit-learn pipeline code grounded in:
loaded dataset
target column
problem type
selected algorithm
numeric features
categorical features
generated code includes preprocessing and estimator construction so the workflow can be moved beyond the interactive application.
App Fallback
app also includes a non-agent fallback path.
HF_TOKEN configured?
β
βββββ΄ββββ
β β
yes no
β β
βΌ βΌ
Qwen agent fallback
tool loop β
β βββ inspect dataset
β βββ infer modeling setup
β βββ train baseline model
β βββ calculate real metrics
β βββ generate pipeline code
β
ββββββββββββ¬ββββββββββ
βΌ
UI output
fallback can also be used if the Hugging Face model request fails.
this means the application can still:
profile the dataset
infer a modeling setup
train the selected baseline
calculate real holdout metrics
generate scikit-learn pipeline code
without requiring the Qwen agent to successfully complete the tool-calling workflow.
Dataset Support
app can preload a public Hugging Face dataset or accept a user-uploaded dataset.
uploaded dataset files can include:
- CSV
- Parquet
- JSON
- JSONL
- XLSX
- XLS
the app profiles the dataset before exposing it to the ML workflow.
Hugging Face Example Dataset
default public example dataset:
scikit-learn/adult-census-income
default prediction target:
income
the sample dataset is intended for binary classification.
users can replace the preloaded example with their own supported dataset through the upload interface.
Preprocessing Pipeline
the scikit-learn workflow separates numerical and categorical processing.
numeric features
β
median imputation
β
scaling when appropriate
categorical features
β
most-frequent imputation
β
one-hot encoding
numeric + categorical features
β
ColumnTransformer
β
selected estimator
β
trained Pipeline
this keeps preprocessing and model inference inside the same reusable scikit-learn pipeline.
Model Lab
Classification Algorithms
Logistic Regression
Random Forest Classifier
SGD Classifier
Linear SVM Classifier
Regression Algorithms
Ridge Regression
Random Forest Regressor
SGD Regressor
the selected algorithm is trained locally through automated scikit-learn pipelines.
Evaluation
Classification Metrics
classification evaluation can include:
Regression Metrics
regression evaluation includes:
-
- ml regression evaluation metric used to measure the average magnitude of prediction errors in machine learning regression models
-
- ml regression evaluation metric used to measure the average magnitude of error in regression machine learning models
-
- ml regression evaluation metric that measures the goodness of fit for a regression model by showing the proportion of variance in the dependent target variable that is explained by the independent features
note: evaluation values are produced by the local scikit-learn execution layer rather than estimated by the LLM.
Agent Outputs
final agent response is designed to contain:
- ML assessment
- Modeling risks
- Recommended modeling setup
- Evaluation findings
- Model comparison
- Pipeline recommendation
- Generated scikit-learn code
- Tool trace
app separately exposes structured modeling outputs such as:
metrics
leaderboard
feature importance / coefficients
pipeline code
model artifact
tool trace
runtime diagnostics
Agent Metrics / UI
1. Dataset Workspace
dataset workspace shows:
Dataset source
Hugging Face example-dataset loading
local file upload
Data preview
- preview of the currently loaded dataset
Inferred schema / feature information
column
pandas dtype
numeric / categorical feature information
null information
unique-value information
example values
possible target columns
2. Model Lab
model workspace allows the user to configure:
Target column
- selected prediction target
Problem type
classification
regression
Algorithmic Selection:
classification:
-
- classification based supervised ML algorithm used to predict the probability of a categorical target variable
-
- ensemble ML algorithm that builds multiple decision trees and combines their predictions to improve accuracy and reduce overfitting
-
- efficient ML estimator that optimizes regularized linear models using a first-order optimization routine. Instead of a distinct machine learning algorithm itself, it represents an optimization methodology used to train traditional linear models like Support Vector Machines (SVM) or Logistic Regression
-
- supervised ML algorithm used to sort data into discrete categories by drawing a straight decision boundary
regression:
-
- L2 regularization, is a modified version of linear regression designed to improve a model's stability and prevent overfitting.
- standard linear regression only focuses on minimizing the difference between predicted and actual values, it often becomes unstable when dealing with highly correlated variables (multicollinearity) or a large number of features. Ridge regression fixes this by penalizing the model for having excessively large coefficients, forcing them to shrink toward zero.
-
- ensemble machine learning algorithm used to predict continuous numerical values (e.g. housing prices, temperatures, or stock trends). algorithm works by building multiple independent decision trees at training time and outputting the average prediction of all the individual trees. this method, known as Bootstrap Aggregating (Bagging), reduces overfitting and improves model accuracy
-
- linear regression model trained using Stochastic Gradient Descent (SGD), an iterative optimization technique that updates model parameters one sample at a time rather than using the entire dataset at once
- how SGD Regressor Works
- Sample-by-Sample Updates: estimates the gradient of the loss function using a single randomly chosen data point (or a small mini-batch) per step, then adjusts the weights immediately.
- Loss Functions: supports ordinary least squares (squared_error), robust regression (huber), and linear support vector regression (epsilon_insensitive).
- Regularization: includes penalties like L2 (ridge), L1 (lasso), or a mix of both (elasticnet) to shrink weights and avoid overfitting.
- Key Advantages:
- Speed with Big Data: trains much faster than traditional batch gradient descent when dealing with massive datasets containing over 10,000 samples.
- Online Learning: supports partial_fit, meaning it can continuously learn from real-time data streams as new information arrives.
- Escaping Local Minima: inherent noise in single-sample updates helps the algorithm jump out of shallow local minimums in complex cost surfaces.
app can then expose:
fitted model metrics
feature importance or coefficients
generated pipeline artifact
generated pipeline code
3. Model Comparison
comparison workflow trains compatible baseline estimators and returns a leaderboard using real holdout results.
this provides a comparison layer that the LLM can reference during final synthesis.
the comparison values are derived from actual model execution instead of LLM-generated estimates.
4. Machine Learning Agent
agent workspace accepts a natural-language ML engineering task.
Qwen agent can then:
inspect the dataset
recommend a modeling setup
train a candidate model
compare algorithms
generate pipeline code
synthesize findings from tool observations
5. Tool Trace
every agent tool invocation is appended to the tool trace.
Example trace:
[
{
"tool": "inspect_dataset",
"arguments": {},
"result": {
"rows": 32561,
"columns": 15
}
},
{
"tool": "train_candidate_model",
"arguments": {
"target": "income",
"algorithm": "Logistic Regression"
},
"result": {
"metrics": "holdout metrics"
}
}
]
trace allows the user to analyze / inspect:
which tools were called
arguments passed to each tool
tool observations
number of tool calls
modeling operations performed during the agent loop
6. Diagnostics
runtime diagnostics can include:
model
provider
HF token configured
tool-call count
tools used
selected algorithm
problem type
target
Example:
{
"model": "Qwen/Qwen3-Coder-30B-A3B-Instruct",
"provider": "HF automatic routing",
"hf_token_configured": true,
"tool_calls": 4,
"tools_used": [
"inspect_dataset",
"recommend_modeling_setup",
"train_candidate_model",
"compare_algorithms"
],
"target": "income",
"problem_type": "classification",
"algorithm": "Logistic Regression"
}
the provider can appear as:
HF automatic routing
when a specific inference provider is not explicitly configured.
Local ML Execution Model
model training is performed directly inside the application with scikit-learn.
Loaded dataset
β
pandas DataFrame
β
feature / target split
β
scikit-learn preprocessing
β
scikit-learn estimator
β
local CPU training
β
holdout predictions
β
evaluation metrics
β
Joblib artifact
Qwen3-Coder does not perform the numerical model fitting itself.
Qwen3-Coder
β
reasoning + tool selection + synthesis
scikit-learn
β
preprocessing + training + prediction + evaluation
this keeps model-performance claims grounded in real execution.
Machine Learning Execution Separation
Qwen3-Coder
responsible for:
understanding the user's ML task
selecting appropriate tools
interpreting dataset observations
reasoning about modeling risks
deciding whether additional tools are required
synthesizing the final response
scikit-learn
responsible for:
preprocessing
train / holdout splitting
fitting estimators
making predictions
calculating evaluation metrics
model comparison
fitted-pipeline generation
conceptually:
User task
β
Qwen3-Coder
β
Select ML operation
β
scikit-learn tool
β
Real execution result
β
Qwen3-Coder
β
Interpret result / select next tool
β
Final ML assessment
File Descriptions
agent.py
main agent implementation.
contains the logic for:
system prompt
tool schemas
MachineLearningAgenttool dispatch
fallback
bounded agent loop
HF InferenceClientrequeststool_choice="auto"tool observations
final response synthesis
architecturally:
agent.py
β
decides WHAT ML action is needed
β
ml_engine.py
β
executes the ML operation
ml_engine.py
machine learning execution layer.
contains:
dataset loading
dataset profiling
target inference
problem-type inference
feature separation
preprocessing construction
algorithm construction
train / holdout splitting
model fitting
prediction
evaluation
model comparison
feature importance / coefficients
pipeline-code generation
Joblib artifact generation
architecturally:
agent.py
β
decides WHAT ML action is needed
β
ml_engine.py
β
executes preprocessing / training / evaluation
β
returns structured observation
app.py
responsibilities include:
session state
Hugging Face sample loading
local dataset upload
dataset preview
target controls
problem-type controls
algorithm controls
training callbacks
comparison callbacks
generated-code display
downloadable model artifact
agent execution
tool-trace display
runtime diagnostics
config.py
agent and application runtime configuration.
controls values such as:
HF_MODEL_ID
HF_PROVIDER
HF_TOKEN
MAX_UPLOAD_MB
MAX_PROFILE_ROWS
MAX_TRAIN_ROWS
MAX_AGENT_STEPS
DEFAULT_MAX_TOKENS
RANDOM_STATE
Modeling Guardrails
application separates LLM reasoning from numerical machine learning execution.
Qwen agent can decide which operation should be performed, but:
training
prediction
evaluation
metric calculation
model comparison
are handled by scikit-learn execution tools.
this architecture helps prevent fabricated model-performance claims.
additional controls include:
bounded agent steps
configurable maximum model tokens
fixed random state by default
controlled algorithm list
maximum training-row limit
deterministic / structured preprocessing behavior
fallback execution path
tool trace
structured model observations
Model Performance Grounding
the system is designed so the LLM does not invent model metrics.
Dataset
β
scikit-learn model training
β
Prediction
β
Metric calculation
β
Structured tool observation
β
Qwen3-Coder
β
Final interpretation
performance values should only be presented as real model results when the associated training / evaluation tool successfully executes.
if the tool does not run successfully, the final response should not claim that a model was trained or evaluated.
Model Artifact
trained preprocessing + estimator pipelines can be serialized through Joblib.
Numeric preprocessing
+
Categorical preprocessing
+
Estimator
β
scikit-learn Pipeline
β
fit
β
Joblib serialization
β
.joblib artifact
this allows the fitted pipeline to be reused later without manually rebuilding preprocessing and estimator logic.
Agent Pattern Workflow:
Single Agent
+
Function Calling
+
Machine Learning Tools
+
Bounded Tool Loop
+
Tool Observations
+
Final LLM Synthesis
full execution:
USER
β
Gradio / app.py
β
MachineLearningAgent / agent.py
β
Qwen3-Coder
β
tool_choice="auto"
β
ML Tool
β
ml_engine.py
β
Observation
β
Qwen3-Coder
β
repeat up to MAX_AGENT_STEPS
β
Final ML Assessment
β
Recommended modeling setup
β
Evaluation findings
β
Model comparison
β
Pipeline code
β
Tool Trace
Core Runtime Components
scikit-learn
What it is:
scikit-learn ml framework used to build preprocessing pipelines, estimators, training workflows, predictions, and evaluation metrics.
Why it is used in this project:
the application needs a real ML execution layer so model-performance values come from fitted models rather than LLM estimates.
How it is used here:
Dataset
β
Preprocessing
β
Estimator
β
scikit-learn Pipeline
β
Training
β
Holdout prediction
β
Holdout evaluation
β
Metrics + fitted artifact
scikit-learn is used to:
build numeric preprocessing
build categorical preprocessing
combine transformations through
ColumnTransformerbuild estimator pipelines
split datasets into train and holdout sets
fit models
generate predictions
calculate classification metrics
calculate regression metrics
compare candidate estimators
expose supported feature importance / coefficient values
produce reusable fitted model pipelines
pandas
Why it is used in this project:
the application needs a lightweight in-memory tabular representation before datasets can be profiled and passed into scikit-learn.
How it is used here:
load supported dataset formats
hold the active dataset in memory
inspect columns and pandas data types
determine numerical and categorical features
analyze null values
inspect unique values
separate prediction target from model features
provide training data to scikit-learn
workflow:
Uploaded / HF dataset
β
pandas DataFrame
β
Dataset profiling
β
Feature + target identification
β
scikit-learn
Joblib
What it is:
Joblib is used to serialize fitted Python machine learning objects
Why it is used in this project:
a trained model is more useful when the complete preprocessing + estimator pipeline can be reused outside the interactive session.
How it is used here:
Fitted preprocessing
+
Fitted estimator
β
scikit-learn Pipeline
β
Joblib
β
.joblib model artifact
after training, the fitted preprocessing + estimator pipeline can be exported as a .joblib artifact for later reuse.
PyArrow
What it is:
PyArrow provides support for Apache Arrow / Parquet-based data interchange.
How it is used here:
PyArrow supports loading Parquet datasets into the application's pandas-based dataset workflow.
Parquet file
β
PyArrow support
β
pandas DataFrame
β
ML workflow
OpenPyXL
What it is:
OpenPyXL provides Python support for reading Excel workbook formats used by the dataset upload workflow.
How it is used here:
XLSX dataset
β
OpenPyXL
β
pandas
β
Dataset profile
β
ML workflow
HF Automatic Routing
What it is:
Hugging Face automatic routing allows InferenceClient to route the Qwen model request through an available Hugging Face Inference Provider when a specific provider is not explicitly configured.
Why it is used:
it avoids coupling the application to one inference backend and simplifies deployment of the agent.
How it is used here:
MachineLearningAgent
β
huggingface_hub.InferenceClient
β
provider="auto"
β
Hugging Face Inference Provider
β
Qwen3-Coder
β
tool request or final synthesis
model configuration is controlled through:
HF_MODEL_ID
HF_PROVIDER
HF_TOKEN
within this project:
HF_MODEL_IDidentifies the Qwen modelHF_PROVIDERcan configure provider behaviorautomatic routing can be used when a specific backend is not forced
the routed model performs tool selection, reasoning, and final synthesis
scikit-learn performs the actual numerical ML operations
Training / Evaluation Architecture
Dataset
β
pandas
β
Feature / target split
β
Train / holdout split
β
ColumnTransformer
β
ββββββββββββββββββββββββββββββ
β Numeric preprocessing β
β β
β median imputation β
β optional scaling β
ββββββββββββββββββββββββββββββ
+
ββββββββββββββββββββββββββββββ
β Categorical preprocessing β
β β
β most-frequent imputation β
β one-hot encoding β
ββββββββββββββββββββββββββββββ
β
Estimator
β
scikit-learn Pipeline
β
fit
β
holdout prediction
β
evaluation metrics
β
Agent observation
Classification Workflow
Classification Dataset
β
Target Selection
β
Preprocessing
β
Candidate classifier
β
Training
β
Holdout predictions
β
accuracy
weighted precision
weighted recall
weighted F1
ROC-AUC where supported
β
Agent interpretation
supported baseline classifiers include:
Logistic Regression
Random Forest Classifier
SGD Classifier
Linear SVM Classifier
Regression Workflow
Regression dataset
β
Target selection
β
Preprocessing
β
Candidate regressor
β
Training
β
Holdout predictions
β
MAE
RMSE
RΒ²
β
Agent interpretation
supported baseline regressors include:
Ridge Regression
Random Forest Regressor
SGD Regressor