feat: BreakPilot PWA - Full codebase (clean push without large binaries)
Some checks failed
Tests / Go Tests (push) Has been cancelled
Tests / Python Tests (push) Has been cancelled
Tests / Integration Tests (push) Has been cancelled
Tests / Go Lint (push) Has been cancelled
Tests / Python Lint (push) Has been cancelled
Tests / Security Scan (push) Has been cancelled
Tests / All Checks Passed (push) Has been cancelled
Security Scanning / Secret Scanning (push) Has been cancelled
Security Scanning / Dependency Vulnerability Scan (push) Has been cancelled
Security Scanning / Go Security Scan (push) Has been cancelled
Security Scanning / Python Security Scan (push) Has been cancelled
Security Scanning / Node.js Security Scan (push) Has been cancelled
Security Scanning / Docker Image Security (push) Has been cancelled
Security Scanning / Security Summary (push) Has been cancelled
CI/CD Pipeline / Go Tests (push) Has been cancelled
CI/CD Pipeline / Python Tests (push) Has been cancelled
CI/CD Pipeline / Website Tests (push) Has been cancelled
CI/CD Pipeline / Linting (push) Has been cancelled
CI/CD Pipeline / Security Scan (push) Has been cancelled
CI/CD Pipeline / Docker Build & Push (push) Has been cancelled
CI/CD Pipeline / Integration Tests (push) Has been cancelled
CI/CD Pipeline / Deploy to Staging (push) Has been cancelled
CI/CD Pipeline / Deploy to Production (push) Has been cancelled
CI/CD Pipeline / CI Summary (push) Has been cancelled
ci/woodpecker/manual/build-ci-image Pipeline was successful
ci/woodpecker/manual/main Pipeline failed
Some checks failed
Tests / Go Tests (push) Has been cancelled
Tests / Python Tests (push) Has been cancelled
Tests / Integration Tests (push) Has been cancelled
Tests / Go Lint (push) Has been cancelled
Tests / Python Lint (push) Has been cancelled
Tests / Security Scan (push) Has been cancelled
Tests / All Checks Passed (push) Has been cancelled
Security Scanning / Secret Scanning (push) Has been cancelled
Security Scanning / Dependency Vulnerability Scan (push) Has been cancelled
Security Scanning / Go Security Scan (push) Has been cancelled
Security Scanning / Python Security Scan (push) Has been cancelled
Security Scanning / Node.js Security Scan (push) Has been cancelled
Security Scanning / Docker Image Security (push) Has been cancelled
Security Scanning / Security Summary (push) Has been cancelled
CI/CD Pipeline / Go Tests (push) Has been cancelled
CI/CD Pipeline / Python Tests (push) Has been cancelled
CI/CD Pipeline / Website Tests (push) Has been cancelled
CI/CD Pipeline / Linting (push) Has been cancelled
CI/CD Pipeline / Security Scan (push) Has been cancelled
CI/CD Pipeline / Docker Build & Push (push) Has been cancelled
CI/CD Pipeline / Integration Tests (push) Has been cancelled
CI/CD Pipeline / Deploy to Staging (push) Has been cancelled
CI/CD Pipeline / Deploy to Production (push) Has been cancelled
CI/CD Pipeline / CI Summary (push) Has been cancelled
ci/woodpecker/manual/build-ci-image Pipeline was successful
ci/woodpecker/manual/main Pipeline failed
All services: admin-v2, studio-v2, website, ai-compliance-sdk, consent-service, klausur-service, voice-service, and infrastructure. Large PDFs and compiled binaries excluded via .gitignore.
This commit is contained in:
77
voice-service/bqas/config.py
Normal file
77
voice-service/bqas/config.py
Normal file
@@ -0,0 +1,77 @@
|
||||
"""
|
||||
BQAS Configuration
|
||||
"""
|
||||
import os
|
||||
from dataclasses import dataclass, field
|
||||
from typing import Optional
|
||||
|
||||
|
||||
@dataclass
|
||||
class BQASConfig:
|
||||
"""Configuration for BQAS framework."""
|
||||
|
||||
# Ollama settings
|
||||
ollama_base_url: str = field(
|
||||
default_factory=lambda: os.getenv("OLLAMA_BASE_URL", "http://localhost:11434")
|
||||
)
|
||||
judge_model: str = field(
|
||||
default_factory=lambda: os.getenv("BQAS_JUDGE_MODEL", "qwen2.5:32b")
|
||||
)
|
||||
judge_timeout: float = 120.0
|
||||
|
||||
# Voice service settings
|
||||
voice_service_url: str = field(
|
||||
default_factory=lambda: os.getenv("VOICE_SERVICE_URL", "http://localhost:8091")
|
||||
)
|
||||
|
||||
# Klausur service settings (for RAG tests)
|
||||
klausur_service_url: str = field(
|
||||
default_factory=lambda: os.getenv("KLAUSUR_SERVICE_URL", "http://localhost:8086")
|
||||
)
|
||||
|
||||
# Database settings
|
||||
db_path: str = field(
|
||||
default_factory=lambda: os.getenv("BQAS_DB_PATH", "bqas_history.db")
|
||||
)
|
||||
|
||||
# Thresholds
|
||||
regression_threshold: float = 0.1 # Score drop threshold
|
||||
min_golden_score: float = 3.5 # Minimum acceptable score
|
||||
min_synthetic_score: float = 3.0
|
||||
min_rag_score: float = 3.5 # Minimum acceptable RAG score
|
||||
|
||||
# Weights for composite score (Intent tests)
|
||||
intent_accuracy_weight: float = 0.4
|
||||
faithfulness_weight: float = 0.2
|
||||
relevance_weight: float = 0.2
|
||||
coherence_weight: float = 0.1
|
||||
safety_weight: float = 0.1
|
||||
|
||||
# Weights for RAG composite score
|
||||
rag_retrieval_precision_weight: float = 0.25
|
||||
rag_operator_alignment_weight: float = 0.20
|
||||
rag_faithfulness_weight: float = 0.20
|
||||
rag_citation_accuracy_weight: float = 0.15
|
||||
rag_privacy_compliance_weight: float = 0.10
|
||||
rag_coherence_weight: float = 0.10
|
||||
|
||||
# GitHub integration
|
||||
github_repo: Optional[str] = field(
|
||||
default_factory=lambda: os.getenv("BQAS_GITHUB_REPO")
|
||||
)
|
||||
github_token: Optional[str] = field(
|
||||
default_factory=lambda: os.getenv("GITHUB_TOKEN")
|
||||
)
|
||||
|
||||
# Test generation
|
||||
synthetic_count_per_intent: int = 10
|
||||
include_typos: bool = True
|
||||
include_dialect: bool = True
|
||||
|
||||
# RAG test settings
|
||||
rag_test_suite_path: str = "tests/bqas/golden_tests/golden_rag_correction_v1.yaml"
|
||||
|
||||
@classmethod
|
||||
def from_env(cls) -> "BQASConfig":
|
||||
"""Create config from environment variables."""
|
||||
return cls()
|
||||
Reference in New Issue
Block a user