Constants.php
- Pfad:
src/Domain/Constants.php - Namespace: Domain
- Zeilen: 144 | Größe: 4,476 Bytes
- Geändert: 2025-12-28 14:01:23 | Gescannt: 2025-12-31 10:22:15
Code Hygiene Score: 100
- Dependencies: 100 (25%)
- LOC: 100 (20%)
- Methods: 100 (20%)
- Secrets: 100 (15%)
- Classes: 100 (10%)
- Magic Numbers: 100 (10%)
Keine Issues gefunden.
Klassen 1
-
Constantsclass Zeile 15
Funktionen 1
-
__construct()private Zeile 140
Verwendet von 43
- AnthropicClient.php use
- AssignEntityTaxonomyUseCase.php use
- ChunkAnalysisService.php use
- ChunkExplorerRepository.php use
- ChunkExplorerRepositoryInterface.php use
- ChunkSyncService.php use
- ChunkTaxonomyRepository.php use
- ChunkTaxonomyRepositoryInterface.php use
- CodeQualityRepository.php use
- CodeQualityRepositoryInterface.php use
- Confidence.php use
- ContractRepository.php use
- CreatePromptCommand.php use
- Doc2VectorPipeline.php use
- DocsController.php use
- EntityRepository.php use
- EntityRepositoryInterface.php use
- EntityTaxonomyRepository.php use
- EntityTaxonomyRepositoryInterface.php use
- ExecutionDuration.php use
- ExecutionMetrics.php use
- ExplorerController.php use
- ExportChatSessionUseCase.php use
- FileAnalysisRepository.php use
- FileAnalysisRepositoryInterface.php use
- FileBackupRepository.php use
- GetCodeAnalysisUseCase.php use
- GetTaxonomyOverviewUseCase.php use
- InputTrait.php use
- ManageChatSessionsUseCase.php use
- MessageTiming.php use
- OllamaClient.php use
- Pagination.php use
- PipelineRunStatusUseCase.php use
- QdrantSearchResultDTO.php use
- RelationRepository.php use
- RelationRepositoryInterface.php use
- ScoringService.php use
- SendChatMessageCommand.php use
- SessionStatsDTO.php use
- StreamingChatMessageUseCase.php use
- UpdateChatSessionUseCase.php use
- UpdatePromptCommand.php use
Versionen 5
-
v5
2025-12-28 14:01 | claude-code-hook | modified
Claude Code Pre-Hook Backup vor Edit-Operation -
v4
2025-12-28 14:00 | claude-code-hook | modified
Claude Code Pre-Hook Backup vor Edit-Operation -
v3
2025-12-27 23:46 | claude-code-hook | modified
Claude Code Pre-Hook Backup vor Edit-Operation -
v2
2025-12-27 23:19 | claude-code-hook | modified
Claude Code Pre-Hook Backup vor Edit-Operation -
v1
2025-12-27 23:16 | claude-code-hook | modified
Claude Code Pre-Hook Backup vor Edit-Operation
Code
<?php
declare(strict_types=1);
namespace Domain;
// @responsibility: Zentrale benannte Konstanten für Magic Numbers
/**
* Zentrale Konstanten für das KI-System.
*
* Diese Klasse enthält alle häufig verwendeten "Magic Numbers" als
* benannte Konstanten für bessere Lesbarkeit und Wartbarkeit.
*/
final class Constants
{
// =========================================================================
// PAGINATION & LIMITS
// =========================================================================
/** Standard-Limit für Datenbankabfragen */
public const int DEFAULT_LIMIT = 100;
/** Standard-Seitengröße für Pagination */
public const int PAGE_SIZE = 50;
/** Maximum für Batch-Operationen */
public const int BATCH_LIMIT = 1000;
/** Standard-Offset für Pagination */
public const int DEFAULT_OFFSET = 0;
// =========================================================================
// TIME CONVERSIONS
// =========================================================================
/** Millisekunden pro Sekunde */
public const int MS_PER_SECOND = 1000;
/** Sekunden pro Minute */
public const int SECONDS_PER_MINUTE = 60;
/** Minuten pro Stunde */
public const int MINUTES_PER_HOUR = 60;
/** Stunden pro Tag */
public const int HOURS_PER_DAY = 24;
/** Tage pro Jahr */
public const int DAYS_PER_YEAR = 365;
/** Sekunden pro Stunde */
public const int SECONDS_PER_HOUR = 3600;
/** Sekunden pro Tag */
public const int SECONDS_PER_DAY = 86400;
// =========================================================================
// PERCENTAGES
// =========================================================================
/** 100 Prozent (für Berechnungen) */
public const int PERCENT_FULL = 100;
/** 50 Prozent */
public const int PERCENT_HALF = 50;
// =========================================================================
// TIMEOUTS (in Sekunden)
// =========================================================================
/** Standard-Timeout für HTTP-Requests */
public const int HTTP_TIMEOUT = 30;
/** Timeout für LLM-Anfragen */
public const int LLM_TIMEOUT = 120;
/** Health-Check Timeout */
public const int HEALTH_CHECK_TIMEOUT = 5;
// =========================================================================
// FIELD VALIDATION
// =========================================================================
/** Maximale Länge für Name-Felder */
public const int NAME_MAX_LENGTH = 100;
/** Maximale Länge für Titel-Felder */
public const int TITLE_MAX_LENGTH = 200;
/** Minimale Token-Anzahl für LLM-Requests */
public const int MIN_TOKENS = 100;
/** Maximale Token-Anzahl für LLM-Requests */
public const int MAX_TOKENS = 16000;
// =========================================================================
// CHUNKING & TEXT
// =========================================================================
/** Minimale Chunk-Größe in Zeichen */
public const int MIN_CHUNK_SIZE = 100;
/** Maximale Chunk-Größe in Zeichen */
public const int MAX_CHUNK_SIZE = 2000;
/** Chunk-Overlap in Prozent */
public const int CHUNK_OVERLAP_PERCENT = 10;
/** Maximale Länge für Embedding-Text */
public const int EMBEDDING_TEXT_LIMIT = 1000;
/** Maximale Länge für vollständigen Embedding-Payload */
public const int EMBEDDING_PAYLOAD_LIMIT = 1800;
// =========================================================================
// RETRY & BACKOFF
// =========================================================================
/** Maximale Anzahl Wiederholungsversuche */
public const int MAX_RETRIES = 3;
/** Basis für exponentielles Backoff in Sekunden */
public const int RETRY_BACKOFF_BASE = 2;
// =========================================================================
// SCORE THRESHOLDS
// =========================================================================
/** Minimum-Score für "gut" */
public const int SCORE_GOOD = 80;
/** Minimum-Score für "akzeptabel" */
public const int SCORE_ACCEPTABLE = 60;
/** Hard-Fail Score bei kritischen Issues */
public const int SCORE_HARD_FAIL = 20;
// Keine Instanziierung erlaubt
private function __construct()
{
}
}