mirror of
https://github.com/kjanat/livedash-node.git
synced 2026-01-16 10:12:09 +01:00
- Updated environment configuration to include Postgres database settings. - Enhanced import processing to minimize field copying and rely on AI for analysis. - Implemented detailed AI processing request tracking, including token usage and costs. - Added new models for Question and SessionQuestion to manage user inquiries separately. - Improved session processing scheduler with AI cost reporting functionality. - Created a test script to validate the refactored pipeline and display processing statistics. - Updated Prisma schema and migration files to reflect new database structure and relationships.
30 lines
1.4 KiB
Plaintext
30 lines
1.4 KiB
Plaintext
# Copy this file to .env.local and configure as needed
|
|
|
|
# NextAuth.js configuration
|
|
NEXTAUTH_URL="http://localhost:3000"
|
|
NEXTAUTH_SECRET="your_secret_key_here"
|
|
NODE_ENV="development"
|
|
|
|
# OpenAI API key for session processing
|
|
OPENAI_API_KEY="your_openai_api_key_here"
|
|
|
|
# Scheduler Configuration
|
|
SCHEDULER_ENABLED="true" # Set to false to disable all schedulers during development
|
|
CSV_IMPORT_INTERVAL="*/15 * * * *" # Every 15 minutes (cron format)
|
|
IMPORT_PROCESSING_INTERVAL="*/5 * * * *" # Every 5 minutes (cron format) - converts imports to sessions
|
|
IMPORT_PROCESSING_BATCH_SIZE="50" # Number of imports to process at once
|
|
SESSION_PROCESSING_INTERVAL="0 * * * *" # Every hour (cron format) - AI processing
|
|
SESSION_PROCESSING_BATCH_SIZE="0" # 0 = process all sessions, >0 = limit number
|
|
SESSION_PROCESSING_CONCURRENCY="5" # Number of sessions to process in parallel
|
|
|
|
# Postgres Database Configuration
|
|
DATABASE_URL_TEST="postgresql://"
|
|
DATABASE_URL="postgresql://"
|
|
|
|
# Example configurations:
|
|
# - For development (no schedulers): SCHEDULER_ENABLED=false
|
|
# - For testing (every 5 minutes): CSV_IMPORT_INTERVAL=*/5 * * * *
|
|
# - For faster import processing: IMPORT_PROCESSING_INTERVAL=*/2 * * * *
|
|
# - For limited processing: SESSION_PROCESSING_BATCH_SIZE=10
|
|
# - For high concurrency: SESSION_PROCESSING_CONCURRENCY=10
|