{
"event": "PreToolUse",
"tool_name": "Edit",
"tool_input": {
"file_path": "\/var\/www\/dev.campus.systemische-tools.de\/src\/Domain\/Repository\/StopwordRepositoryInterface.php",
"old_string": "\/**\n * Get statistics by category.\n *\n * @return array<string, int>\n *\/\n public function getStats(): array;",
"new_string": "\/**\n * Get statistics by category.\n *\n * @return array{total: int, active: int, by_category: array<string, array{count: int, active: int}>}\n *\/\n public function getStats(): array;"
}
}
{
"tool_response": {
"filePath": "\/var\/www\/dev.campus.systemische-tools.de\/src\/Domain\/Repository\/StopwordRepositoryInterface.php",
"oldString": "\/**\n * Get statistics by category.\n *\n * @return array<string, int>\n *\/\n public function getStats(): array;",
"newString": "\/**\n * Get statistics by category.\n *\n * @return array{total: int, active: int, by_category: array<string, array{count: int, active: int}>}\n *\/\n public function getStats(): array;",
"originalFile": "<?php\n\ndeclare(strict_types=1);\n\nnamespace Domain\\Repository;\n\n\/\/ @responsibility: Interface für Stopword-Persistenz (Entity-Extraction Filter)\n\ninterface StopwordRepositoryInterface\n{\n \/**\n * Find all stopwords with optional filtering.\n *\n * @return array<int, array<string, mixed>>\n *\/\n public function findAll(bool $activeOnly = true, ?string $category = null): array;\n\n \/**\n * Find stopword by ID.\n *\n * @return array<string, mixed>|null\n *\/\n public function find(int $id): ?array;\n\n \/**\n * Get all canonical forms for fast lookup.\n *\n * @return array<string> List of canonical stopword forms\n *\/\n public function getCanonicalForms(bool $activeOnly = true): array;\n\n \/**\n * Check if a word is a stopword.\n *\/\n public function isStopword(string $word): bool;\n\n \/**\n * Create a new stopword.\n *\n * @param array<string, mixed> $data\n *\/\n public function create(array $data): int;\n\n \/**\n * Update a stopword.\n *\n * @param array<string, mixed> $data\n *\/\n public function update(int $id, array $data): bool;\n\n \/**\n * Delete a stopword.\n *\/\n public function delete(int $id): bool;\n\n \/**\n * Toggle active status.\n *\/\n public function toggleActive(int $id): bool;\n\n \/**\n * Get statistics by category.\n *\n * @return array<string, int>\n *\/\n public function getStats(): array;\n}\n",
"structuredPatch": [
{
"oldStart": 61,
"oldLines": 7,
"newStart": 61,
"newLines": 7,
"lines": [
" \/**",
" * Get statistics by category.",
" *",
"- * @return array<string, int>",
"+ * @return array{total: int, active: int, by_category: array<string, array{count: int, active: int}>}",
" *\/",
" public function getStats(): array;",
" }"
]
}
],
"userModified": false,
"replaceAll": false
}
}