<!-- Source: https://docs.squirro.com/en/latest/technical/libnlp/trouble.html -->
# Troubleshooting & FAQ

Something is not working properly. How can I debug it?

You can add debug step before or after the step, which is problematic.

```json
{
    "step": "debugger",
    "type": "log_fields",
    "fields": ["body"],
    "log_level": "warning"
}
```

As a result you will see something similar to:

```
2022-06-21 10:22:37,087 : squirro.lib.nlp.steps.debuggers.fields_debugger : WARNING : ++++++++++++++++++++++++++++++++++++++++++++++++++++
2022-06-21 10:22:37,087 : squirro.lib.nlp.steps.debuggers.fields_debugger : WARNING : Logging fields for Document '0' (skipped=False)
2022-06-21 10:22:37,087 : squirro.lib.nlp.steps.debuggers.fields_debugger : WARNING : 'body' (truncated) ----> '<html><body><p>This is a fake Squirro Item. It is composed of a couple fake sentences.</p></body></h'
```

Note that the list of fields needs to be adjusted based on the steps before and after.

**How can I test my ML Worklflow before uploading to the Squirro Platform?**

- Download the libNLP [here](https://go.squirro.com/downloads) and install it using pip
- Create a python script as described in the [`runner`](base.md#module-squirro.lib.nlp.runner) documentation and execute it

**How can I uploading ML Worklflow to the Squirro Platform?**

- Use the Squirro Client function to [`create and upload a new ML Workflow`](../../api/squirro_client.topic.MachineLearningMixin.md#squirro_client.topic.MachineLearningMixin.new_machinelearning_workflow)
- Example:

```python
client = SquirroClient(None, None, cluster=CLUSTER)
client.authenticate(refresh_token=TOKEN)
client.new_machinelearning_workflow(
    project_id=PROJECT_ID,
    name = NAME_OF_THE_WORKFLOW,
    config=CONFIG,
    ml_models=PATH # this only needs to be set if trained models or custom steps are existing
)
```

**How can I use a ML Workflow in the enrich pipeline?**

- Follow the instructions in [How To Publish ML Models Using the Squirro Client](../ml/models-squirro-client.md#ml-models-squirro-client).

**I have developed my own machine learning approach and would like to use it for data enrichment in Squirro**

- Follow the instructions in [How to Integrate a Custom ML Classifier](../ai-studio/how-to/integrate-ml-class.md#ai-studio-integrate-ml-class).
