Skip to main content

LatentDirichletAllocation

Text Decomposition standalone SDK operation. Source: 4.2.1.ML.Decomposition.Text.cs. Read the complete C# integration test and setup.

1 recorded job(s); 1 have a success/completed status and a saved result. These are API records rather than independently verified test passes.

Recorded scenarios​

Recorded scenarioPartitionLast statusEvidenceJSON trace
Fetch20Newsgroups / TrainTestSplit / SimpleImputer / LatentDirichletAllocationtraincompletedResult recordedrun-0043

Representative execution​

Scenario: Fetch20Newsgroups / TrainTestSplit / SimpleImputer / LatentDirichletAllocation; partition: train; observed status: completed. run-0043 contains all recorded numbered JSON events for this job.

Operation selection in the C# test​

These are matching lines from the parameterized test, not a separate runnable program. See the full source for context.

"IncrementalPCA", "KernelPCA", "LatentDirichletAllocation", "MiniBatchDictionaryLearning",
"LatentDirichletAllocation" => await SendTypedAsync(new LatentDirichletAllocationJobSendRequestModel
ClassifierType = "LatentDirichletAllocation",

Request​

{
"input": {
"input_blob_id": "0c8b3d5d-569b-2101-4ec6-f23e666c53c4",
"classifier_type": "LatentDirichletAllocation",
"classifier_params": {
"n_components": 3,
"max_iter": 15
},
"text_column": "text",
"file_format": "csv",
"vectorizer_params": {
"ngram_range": [
1,
2
],
"max_features": 120,
"min_df": 1
},
"evaluation": {
"test_size": 0.2,
"random_state": 42,
"shuffle": true
},
"generate_graphs": true
},
"output": {
"name": "Fetch20Newsgroups-TrainTestSplit-SimpleImputer-LatentDirichletAllocation.zip",
"description": "Decomposition integration test using the cached imputed text training partition",
"record_type": "Generic",
"access_tier": "Hot",
"tags": [
"decomposition",
"text",
"Fetch20Newsgroups",
"LatentDirichletAllocation"
]
},
"request_timeout_seconds": 300
}

Send response​

{
"start_time": "2026-11-29T12:52:33.9634181+00:00",
"end_time": "2026-11-29T12:52:34.0779665+00:00",
"elapsed_milliseconds": 114.55,
"status": "published",
"job_id": "72a4f110-a80a-1d67-f12a-d63aa0332e0c",
"topic": "pm.topic.ml.decomposition",
"subscription": "cpu.0p5c.1gi",
"send_request_model": {
"job_id": "72a4f110-a80a-1d67-f12a-d63aa0332e0c",
"json": {
"job_id": "72a4f110-a80a-1d67-f12a-d63aa0332e0c",
"model_id": "0092e982-80d0-a014-f4e5-efd5ad4b95a8",
"input": {
"input_blob_id": "0c8b3d5d-569b-2101-4ec6-f23e666c53c4",
"input_encryption_key": "[REDACTED]",
"classifier_type": "LatentDirichletAllocation",
"classifier_params": {
"n_components": 3,
"max_iter": 15
},
"text_column": "text",
"file_format": "csv",
"vectorizer_params": {
"ngram_range": [
1,
2
],
"max_features": 120,
"min_df": 1
}
},
"request_timeout_seconds": 300,
"output": {
"name": "Fetch20Newsgroups-TrainTestSplit-SimpleImputer-LatentDirichletAllocation.zip",
"description": "Decomposition integration test using the cached imputed text training partition",
"record_type": "Generic",
"access_tier": "Hot",
"tags": [
"decomposition",
"text",
"Fetch20Newsgroups",
"LatentDirichletAllocation"
],
"encryption_key": "[REDACTED]"
},
"evaluation": {
"test_size": 0.2,
"random_state": 42,
"shuffle": true
},
"generate_graphs": true
},
"topic": "pm.topic.ml.decomposition",
"subscription": "cpu.0p5c.1gi"
}
}

Final recorded status​

{
"start_time": "2026-11-29T12:54:34.7085988+00:00",
"end_time": "2026-11-29T12:54:35.5437798+00:00",
"elapsed_milliseconds": 835.17,
"job_id": "72a4f110-a80a-1d67-f12a-d63aa0332e0c",
"status": "completed",
"topic": "pm.topic.ml.decomposition",
"subscription": "cpu.0p5c.1gi"
}

Result response​

{
"job_id": "72a4f110-a80a-1d67-f12a-d63aa0332e0c",
"execution": {
"execution_name": "[REDACTED]",
"job_name": "[REDACTED]",
"container": {
"hostname": "[REDACTED]",
"replica_name": "[REDACTED]",
"process_id": 1
}
},
"classifier_type": "LatentDirichletAllocation",
"stats": {
"row_count": 8485,
"column_count": 4,
"feature_count": 120,
"training_row_count": 6788,
"test_row_count": 1697,
"feature_columns": [
"text"
],
"target_columns": [],
"file_format": "csv",
"task_type": "text_decomposition",
"metrics": {
"output_components": 3,
"sparse_nonzero_feature_values": 239889,
"component_variances": [
0.07777669355428593,
0.10624027392343008,
0.056302116918876405
],
"fit_scope": "training"
}
},
"effective_params": {
"decomposition": {
"n_components": 3,
"learning_method": "batch",
"max_iter": 15,
"batch_size": 64,
"learning_decay": 0.7,
"random_state": 42
},
"vectorizer": {
"lowercase": true,
"stop_words": null,
"ngram_range": [
1,
2
],
"max_features": 120,
"min_df": 1,
"max_df": 1.0,
"sublinear_tf": true,
"norm": "l2"
}
},
"learned": {
"text_feature_count": 120,
"component_count": 3,
"has_vocabulary_component_weights": true,
"component_values_file": "predictions.csv",
"vocabulary_weights_file": "components.csv",
"feature_matrix_file": "features.npz",
"reusable_text_vectorizer": "model.joblib"
},
"warnings": [],
"runtime": {
"captured_at_utc": "2026-11-29T12:53:08.579441+00:00",
"python": {
"version": "3.12.16",
"implementation": "CPython"
},
"packages": {
"scikit-learn": "1.9.1",
"numpy": "2.5.4",
"pandas": "3.0.6",
"scipy": "1.18.1",
"pydantic": "2.14.1",
"joblib": "1.6.0",
"matplotlib": "3.11.2",
"azure-servicebus": "7.14.3",
"parallelmodel": "1.0.0"
},
"environment": {
"os": "Linux",
"os_release": "6.6.159.1-2.azl3",
"architecture": "x86_64",
"region": "uk1"
}
},
"artifact_format": "zip",
"artifact_archive": "text-decomposition-output.zip",
"artifact_files": [
"model.joblib",
"predictions.csv",
"components.csv",
"features.npz",
"features.csv",
"feature_names.csv",
"documents.csv",
"result.json",
"graphs/component_projection.png"
]
}

First extract response​

{
"start_time": "2026-11-29T12:54:40.6602712+00:00",
"end_time": "2026-11-29T12:54:41.8433739+00:00",
"elapsed_milliseconds": 1183.09,
"status": "uploaded",
"model_id": "0092e982-80d0-a014-f4e5-efd5ad4b95a8",
"source_blob_id": "edc46253-38c0-4cdc-43bd-9ca4bcfce5d4",
"uploaded_blob_id": "7f90b9fb-65b7-c2a2-bd11-b69d94f7d164",
"filename": "9e3c5601-2d6c-fb5f-224c-b52261840f12.json",
"source_path": "result.json",
"source_format": "json",
"size_bytes": 2595,
"upload_status_code": 200
}

Logs​

The trace includes the saved log response (42 entries).

Reproduce the operation​

dotnet test --filter "FullyQualifiedName~ParallelModel.Sdk.UnitTests.DecompositionText.Run"

The filter runs the class theory; use the recorded scenario values above to identify the corresponding parameter set. For partitioned operations, one theory can submit multiple jobs. The redacted payload identifiers are not usable live credentials or blob IDs.