VerityNgn Configuration Reference
Complete reference for all configuration options.Environment Variables
VerityNgn is configured via environment variables in a.env file.
Create .env File
Required Configuration
Google Cloud
GOOGLE_CLOUD_PROJECTandPROJECT_IDare aliases (set both for compatibility)LOCATIONshould be a Vertex AI supported region (us-central1 recommended)GOOGLE_APPLICATION_CREDENTIALSpoints to service account JSON file
Optional APIs
Google Custom Search (Evidence Gathering)
- ✅ Core functionality works
- ⚠️ Limited evidence verification
- ⚠️ Fewer source citations in reports
- Create API key: https://console.cloud.google.com/apis/credentials
- Create CSE: https://programmablesearchengine.google.com/
YouTube Data API v3 (Counter-Intelligence)
- ✅ Core functionality works
- ✅ Uses yt-dlp fallback (automatic)
- ⚠️ Slower metadata extraction
- Enable YouTube Data API v3
- Create API key: https://console.cloud.google.com/apis/credentials
Model Configuration
Vertex AI Model
| Model | Context | Max Output | Speed | Cost | Best For |
|---|---|---|---|---|---|
| gemini-2.5-flash | 1M | 65K | Fast | Low | Default (recommended) |
| gemini-1.5-pro | 2M | 8K | Medium | High | Very long videos |
| gemini-1.5-flash | 1M | 8K | Fastest | Lowest | Budget-conscious |
Output Token Limits
- Higher tokens = more detailed claims extraction
- Don’t exceed model limits (will error)
- 65K is optimal for 2.5 Flash
Thinking Budget
- 0: Fast mode (default) - no internal reasoning tokens
- 10000: Deep analysis mode - model thinks before responding
- Higher = slower but potentially better quality
Video Segmentation
Intelligent Segmentation (Automatic)
- System auto-calculates optimal segment duration
- Maximizes context window utilization (40-60%)
- Minimizes API calls (86% reduction)
- Calculates: 1 segment of 2860 seconds
- Context usage: 58%
- API calls: 1 (vs 7 in v1.0)
Manual Segmentation Override
- Debugging: Use short segments (300-600s)
- API errors: Reduce segment size
- Special requirements: Custom durations
- Shorter segments: More API calls, higher cost
- Longer segments: Risk of timeout, larger memory
Frame Rate
- 1.0 FPS: Optimal balance (default) - captures all visual content
- 0.5 FPS: Slower, cheaper - good for static content
- 2.0 FPS: Higher detail - use only if needed (doubles token cost)
- 1 FPS: 258 tokens/sec video
- 0.5 FPS: 129 tokens/sec video
- 2 FPS: 516 tokens/sec video
Claims Extraction
Enhanced Claims Extraction
ENABLE_ENHANCED_CLAIMS: Multi-pass extraction with specificity scoringENABLE_ABSENCE_CLAIMS: Generate claims about missing evidenceCLAIM_SPECIFICITY_THRESHOLD: Minimum score to keep claim (higher = stricter)
Claim Filtering
Counter-Intelligence
YouTube Review Search
YOUTUBE_REVIEW_IMPACT: How much each review affects truthfulness (-0.35 in v1.0, -0.20 in v2.0)- Negative value = reduces truthfulness score
- Lower magnitude = less aggressive impact
Press Release Detection
- Press releases heavily penalized (promotional bias)
-1.0validation power vs+1.5for peer-reviewed
Storage Configuration
Deployment Mode
| Mode | Storage | Best For |
|---|---|---|
| research | ./outputs/ | Local development |
| container | /var/tmp/ | Docker containers |
| production | GCS | Cloud Run, production |
Storage Backend
Local Storage Paths
Logging
Log Level
- DEBUG: Verbose output, all operations logged
- INFO: Normal operation, important events (default)
- WARNING: Only warnings and errors
- ERROR: Only errors
Log Output
Unbuffered Output
Performance Tuning
Parallel Processing
Rate Limiting
Caching
Development & Debugging
Debug Mode
- Sets
LOG_LEVEL=DEBUG - Disables caching
- Enables request/response logging
- Saves intermediate outputs
Test Mode
Dry Run
Example Configurations
Minimal (Required Only)
Recommended (Optimal Performance)
Debug (Maximum Verbosity)
Production (Cloud Run)
Configuration Validation
Test Configuration
Check Environment
.envfile exists- Required variables set
- Service account file exists
- File permissions correct
Configuration Priority
Variables can be set in multiple places. Priority (highest first):- Environment variables (explicitly set in shell)
.envfile (project root)- Default values (in code)
Security Best Practices
Never Commit Credentials
Restrict File Permissions
Use Environment-Specific Files
Next Steps
- Setup Guide - Complete setup instructions
- Architecture - Technical architecture details
- Testing Guide - Test your configuration
Last Updated: October 28, 2025
Version: 2.0
