Automate Document Processing with Typhoon OCR and LLM
detail.loadingPreview
Streamline your document handling by leveraging Typhoon OCR for text extraction and a powerful LLM to structure that text into a usable JSON format. This workflow automatically saves extracted information to Google Sheets, saving you manual data entry time.
About This Workflow
This n8n workflow, named 'Typhoon_Submit', is designed to automate the extraction and organization of data from documents. It begins with the manual trigger 'When clicking ‘Test workflow’'. The core processing involves using Typhoon OCR to extract text from a specified document path, which is then fed into an OpenRouter chat model. The LLM is prompted to structure the extracted OCR text into specific JSON fields, including book ID, date, subject, and contact information. Following successful structuring, a code node parses the LLM's JSON output, ensuring clean data ready for storage. Finally, the parsed data is seamlessly saved to a Google Sheet, creating a robust, end-to-end document processing automation solution.
Key Features
- Intelligent Text Extraction: Utilizes Typhoon OCR to accurately extract text from various document types.
- AI-Powered Data Structuring: Employs Large Language Models (LLMs) to parse and organize extracted text into structured JSON format.
- Automated Data Entry: Seamlessly pushes extracted and structured data into Google Sheets for easy access and management.
- Configurable Data Fields: Allows for customization of the JSON output, tailoring it to specific document needs.
- Error Handling: Includes basic JSON parsing error detection to ensure data integrity.
How To Use
- Initiate Workflow: Click the 'Test workflow' button to manually trigger the process.
- Configure Typhoon OCR: Ensure your
TYPHOON_OCR_API_KEYis correctly set in the 'Extract Text with Typhoon OCR' node. Specify the input document path in thecommandparameter, referencing your file name using{{ $json["fileName"] }}if needed. - Set Up LLM: In the 'Structure Text to JSON with LLM' node, configure your preferred OpenRouter chat model (e.g.,
scb10x/llama3.1-typhoon2-70b-instruct) and ensure your OpenRouter credentials are set up. - Customize JSON Prompt: Review and adjust the
textparameter in the 'Structure Text to JSON with LLM' node to define the desired JSON output fields and structure. - Verify JSON Parsing: The 'Parse JSON to Sheet Format' node automatically handles common JSON formatting issues. Review its
jsCodeif custom parsing logic is required. - Connect Google Sheets: In the 'Save to Google Sheet' node, configure your Google Sheets credentials and specify the target spreadsheet and worksheet. Map the parsed JSON fields to the appropriate sheet columns.
Apps Used
Workflow JSON
{
"id": "d32b6b85-ef82-4a58-9bc1-8cb4cf43fe03",
"name": "Automate Document Processing with Typhoon OCR and LLM",
"nodes": 26,
"category": "Operations",
"status": "active",
"version": "1.0.0"
}Note: This is a sample preview. The full workflow JSON contains node configurations, credentials placeholders, and execution logic.
Get This Workflow
ID: d32b6b85-ef82...
About the Author
DevOps_Master_X
Infrastructure Expert
Specializing in CI/CD pipelines, Docker, and Kubernetes automations.
Statistics
Related Workflows
Discover more workflows you might like
Universal CSV to JSON API Converter
Effortlessly transform CSV data into structured JSON with this versatile n8n workflow. Integrate it into any application as a custom API endpoint, supporting various input methods including file uploads and raw text.
Google Sheets to Icypeas: Automated Bulk Domain Scanning
This workflow streamlines the process of performing bulk domain scans by integrating your Google Sheets data directly with the Icypeas platform. Automate the submission of company names from your spreadsheet to Icypeas for comprehensive domain information, saving valuable time and effort.
Instant WooCommerce Order Notifications via Telegram
When a new order is placed on your WooCommerce store, instantly receive detailed notifications directly to your Telegram chat. Stay on top of your e-commerce operations with real-time alerts, including order specifics and a direct link to view the order.