An LLM-driven tool for analyzing Excel files and importing their data into SQLite databases. The AI agent handles all analysis, decision-making, and data processing while TypeScript provides simple execution tools.
- LLM-Driven Architecture: AI agent makes all decisions about parsing, data types, and import strategy
- Smart Column Naming: AI proposes meaningful SQL column names that preserve original meaning
- Excel Analysis: Examine file structure, sheets, headers, and data patterns
- Automatic Database Creation: Generate SQLite tables with appropriate data types
- Data Import: Import Excel data with intelligent column mapping
- Interactive Chat Interface: Natural language interaction with the AI agent
# Interactive mode - start a chat session tsx src/analyzeFile.ts <excel-file-path> <workspace-directory> # With initial prompt for direct testing tsx src/analyzeFile.ts <excel-file-path> <workspace-directory> "your prompt here"# Interactive analysis tsx src/analyzeFile.ts "data/social-media-data.xlsx" "output" # Direct workflow with prompt tsx src/analyzeFile.ts "data/social-media-data.xlsx" "output" "Analyze this file and import all data into SQLite"- AI Agent Initialization: The LLM agent starts with access to simple TypeScript tools
- File Analysis: The AI examines Excel files using tools to:
- Get sheet information and structure
- View raw data to understand layouts
- Analyze headers and propose meaningful SQL column names
- Determine appropriate data types and import strategies
- Database Creation: The AI creates SQLite tables with intelligent column mappings
- Data Import: The AI imports Excel data using the proposed column mappings
The tool creates the following files in the workspace directory:
parserConfig.json- Parser configuration for the Excel filedataLoaderMetadata.json- Table configuration with column mappingsdata.db- SQLite database with the imported data
The AI assistant has access to these simple tools:
getSheetsTool- Get list of sheets in the Excel filegetRawDataTool- Get raw data from a specific sheetgetParsedHeadersTool- Get parsed headers and propose meaningful SQL column nameswriteConfigTool- Save parser and table configurationcreateTableTool- Create SQLite table with column mappingsimportDataTool- Import Excel data into SQLite table
- Node.js with TypeScript support
- SQLite3
- Excel files (.xlsx format)
- Open the project in VS Code
- When prompted, click "Reopen in Container" or use Command Palette: "Dev Containers: Reopen in Container"
- The container will automatically set up mise and install all dependencies
# Install mise (if not already installed) curl https://mise.run | sh # Install tools specified in mise.toml mise install # Install project dependencies pnpm installxlsx- Excel file readingsqlite3- SQLite database operationsumwelten- AI framework for agent interactionszod- Schema validation for tool inputs
This tool follows an LLM-driven architecture where:
- The AI agent makes all complex decisions (parsing, data types, column naming)
- TypeScript provides simple, focused tools for execution
- The LLM analyzes Excel structure and proposes meaningful SQL column names
- All analysis logic is handled by the AI, not hardcoded TypeScript
The project includes a Dev Container configuration that provides:
- Consistent Environment: Same Node.js and tool versions across all machines
- mise Integration: Automatic tool installation and management via mise
- VS Code Integration: Pre-configured extensions and settings
- GitHub Copilot Ready: Optimized for AI-assisted development
The dev container ensures that GitHub Copilot and other AI tools have access to the correct mise-managed environment.