Actions41
- Step/Generation Actions
- Thread Actions
- User Actions
- Dataset Actions
- Experiment Actions
- File Actions
- Prompt Actions
- Score Actions
Overview
The node integrates with the Literal AI API to create a new "Score" entity. This operation allows users to record a score associated with a specific step in a project or workflow, capturing metrics such as accuracy, latency, or quality. It is useful for tracking performance or evaluation metrics programmatically within an automation workflow.
Common scenarios:
- Automatically logging evaluation scores after running a machine learning model step.
- Recording quality or latency metrics for different processing steps in a pipeline.
- Adding comments and metadata to scores for audit or review purposes.
Example use case:
After generating predictions in a step of an AI experiment, this node can create a score named "Model Accuracy" of type "accuracy" with a numeric value representing the model's performance, optionally linked to the step ID and including a comment explaining the result.
Properties
| Name | Meaning |
|---|---|
| Name | The name of the score to be created (e.g., "Model Accuracy"). |
| Type | The category/type of the score. Options: Accuracy, Latency, Quality. |
| Value | Numeric value of the score (e.g., 0.95 for 95% accuracy). |
| Step ID | Optional identifier of the step this score is associated with. |
| Comment | Optional textual comment providing additional context about the score. |
Output
The node outputs a JSON object under the json field containing the response from the Literal AI API after creating the score. This typically includes details of the newly created score such as its unique ID, name, type, value, associated step ID, comment, timestamps, and any other metadata returned by the API.
No binary data output is produced by this operation.
Dependencies
- Requires an API key credential for the Literal AI service configured in n8n.
- Depends on the external Literal AI API being accessible and the provided API key having permissions to create scores.
- No additional environment variables are required beyond the API key credential.
Troubleshooting
Common issues:
- Invalid or missing API key will cause authentication failures.
- Providing invalid or missing required properties (e.g., name, type, value) will result in errors from the API.
- Incorrect step ID references may cause association failures if the step does not exist.
Error messages:
- Authentication errors: Check that the API key credential is correctly set up and valid.
- Validation errors: Ensure all required fields are provided and have valid values.
- Network or API errors: Verify network connectivity and Literal AI service status.
To resolve errors, verify input parameters, ensure the API key is correct, and consult Literal AI API documentation for error codes.
Links and References
- Literal AI API Documentation (hypothetical link)
- n8n documentation on Creating Custom Nodes