Actions20
- Assistant Actions
- Embedding Actions
- File Actions
- Report Actions
- Text Actions
- Thread Actions
Report → Generate HTML Report
AI-generatedOverview
The node generates an HTML report by analyzing and visualizing provided text data using OpenAI models. It is designed to create modern, cleanly styled reports that can include charts and UI elements, making it useful for summarizing insights from textual data in a visually appealing format. Typical use cases include generating business or analytics reports, transforming raw text data into structured HTML documents, and automating report creation workflows.
For example, you might input sales data or customer feedback as plain text, provide a prompt instructing the AI to analyze and visualize this data with a modern UI library, and receive a complete HTML report ready for presentation or embedding in dashboards.
Properties
| Name | Meaning |
|---|---|
| Authentication | Choose between "OpenAI Analytics API" (dedicated credentials) or "OpenAI API" (existing credentials) for authentication. |
| Prompt | The instruction prompt sent to the AI to guide how the report should be generated. Example: "Create a one-page A4 sized HTML report analyzing and visualizing the following data using a modern and clean UI library." |
| Input Text | The raw text data to be analyzed and converted into the report. |
| OpenAI Model | The OpenAI model used to generate the report content. Models are loaded dynamically and include options like GPT-4 variants and GPT-3.5 Turbo. |
| Include Default Libraries | Whether to include default UI libraries such as Bootstrap and ChartJS in the generated HTML report. |
| Advanced Settings | Enable detailed control over generation parameters such as temperature, max tokens, and top P. |
| Temperature | Controls randomness of the output (0 = deterministic, 2 = very creative). Only shown if advanced settings enabled. |
| Max Tokens | Maximum number of tokens to generate in the report. Typically, one token corresponds roughly to 3/4 English words or 1-2 Korean characters. Only shown if advanced settings enabled. |
| Top P | Nucleus sampling threshold controlling diversity (e.g., 0.1 means only top 10% probability tokens considered). Not recommended to change simultaneously with temperature. Only shown if advanced settings enabled. |
| Additional CSS Libraries | List of additional CSS library URLs (CDN links) to include in the report. |
| Additional JS Libraries | List of additional JavaScript library URLs (CDN links) to include in the report. |
| Binary Property | The name of the binary property where the generated HTML report will be stored. Defaults to "data". |
Output
The node outputs the generated HTML report as binary data under the specified binary property name (default "data"). This binary data contains the full HTML document including any embedded scripts and stylesheets as per the selected options. The JSON output typically includes metadata or status information related to the operation.
Dependencies
- Requires valid OpenAI API credentials (either dedicated Analytics API credentials or standard OpenAI API credentials).
- Uses OpenAI completion models (e.g., GPT-4, GPT-3.5 Turbo) to generate report content.
- Optionally includes external UI libraries such as Bootstrap and ChartJS via CDN links.
- n8n environment must be configured with appropriate API keys and network access to OpenAI endpoints and any specified CDN resources.
Troubleshooting
- Authentication errors: Ensure that the correct type of API credentials is selected and properly configured in n8n. Missing or invalid API keys will cause failures.
- Model loading issues: If no models appear in the dropdown, verify API key permissions and network connectivity.
- Token limit exceeded: Setting
maxTokenstoo high may cause errors; adjust according to your plan limits and input size. - Invalid prompt or input text: Empty or malformed inputs may lead to unexpected results or errors.
- Binary property conflicts: Make sure the binary property name does not conflict with other nodes' outputs.
- Network or timeout errors: Check internet connectivity and OpenAI service status if requests fail.