Commit Graph

529 Commits

Author SHA1 Message Date
Agent Zero 8ee88d9b41 fix: connect 10 unconnected backend modules to real code paths (context_builder→agent_runner, agent_permissions→agent_runner, agent_tools→agent_runner, data_policy→agent_runner, oversight→agent_runner+migration 0128, transparency→agent_runner, agent_stream→agent_routes SSE endpoint, agent_memory AI-module deleted, decision_guard→engine, require_approval→agent_runner), 11 integration tests passing
Check Cross-Plugin Imports / check (push) Has been cancelled
2026-08-19 16:25:20 +02:00
Agent Zero f3fbb5d1e8 fix: remove broken agent_workstream import from agent_loop.py (was deleted in cleanup) 2026-08-19 09:53:12 +02:00
Agent Zero 7d86592e54 cleanup: remove all unconnected Phase I+J scaffold code and unconnected Phase F+H modules (workstream_contract, proactive_feed, dashboard, dsgvo_export, onboarding, mcp_exposure, integration_tools, self_improvement, agent_workstream, workflows/workstream, knowledge_sources, knowledge_extraction, knowledge_lifecycle, platform.py routes, 13 frontend files, 2 test files), restore Dashboard.tsx, tsc clean, backend OK 2026-08-19 09:47:20 +02:00
Agent Zero 9e37c41871 fix: connect all new pages to router + navigation + backend API routes (Workstream, Wiki, Improvement, Onboarding, Dashboard, DSGVO), platform.py with 9 endpoints, tsc clean 2026-08-19 09:23:54 +02:00
Agent Zero 3854a19705 feat(J): J-SIGNAL/J-PATTERN/J-PROP/J-DRAFT/J-EVAL/J-APPROVAL/J-ACTIVATE/J-MEASURE — controlled self-improvement backend (signals, patterns, proposals, drafts, evaluation, approval, activation, rollback, impact measurement), 26 tests passing 2026-08-19 01:58:18 +02:00
Agent Zero 92ac6229d2 feat(I): I-ONB — onboarding backend (setup wizard status, guide, progress tracking), 46 tests passing 2026-08-19 01:27:13 +02:00
Agent Zero 534adc9aaa feat(I): I-DSGVO/I-DSAR/I-COMP-EXPORT — DSGVO data subject access export, DSAR workflow, compliance evidence export (audit, oversight, approval records, technical policies), 43 tests passing 2026-08-19 01:25:18 +02:00
Agent Zero 94c61a439d feat(I): I-DASH/I-COST/I-USE — platform dashboard, cost tracking, usage analytics (agent/workflow/search/knowledge metrics, cost per agent, budget alerts, success rates), 38 tests passing 2026-08-19 01:20:12 +02:00
Agent Zero df261b1b2c feat(I): I-WORK-PROACTIVE — proactive workstream feed (suggestions, cooldown, dedupe, user settings, priority filtering), 34 tests passing 2026-08-19 01:09:08 +02:00
Agent Zero 6feca2ba98 feat(I): I-WORK-BASE/I-WORK-ACTOR/I-WORK-HANDOFF — workstream contract (typed blocks, unified posting path, human-agent handoff with task creation), 25 tests passing 2026-08-19 00:30:30 +02:00
Agent Zero e8060f6259 feat(I): I-MCP — MCP exposure layer (6 tools: search, ask_knowledge, start_workflow, check_workflow_status, list_agents, create_task), permission-checked, 16 tests passing 2026-08-19 00:26:37 +02:00
Agent Zero dc1321c78b feat(I): I-APPR-LOOP — agent loop human-in-the-loop approval integration (require_approval + approval_tools params, ApprovalRequest creation, workstream notification, pause loop), 8 tests passing 2026-08-19 00:20:36 +02:00
Agent Zero 610af39f75 feat(I): I-AW/I-AK — agent integration tools (start_workflow, check_workflow_status, ask_knowledge, search_knowledge), 6 tests passing 2026-08-19 00:18:07 +02:00
Agent Zero a6e593dc40 feat(H): H-EVT/H-DATA-LIFE/H-RET/H-ASK/H-REV — knowledge lifecycle (event-driven extraction, derived-data propagation, retention policy, ask-knowledge with evidence, review queue), 42 tests passing 2026-08-18 23:17:33 +02:00
Agent Zero 70bbfe93e6 feat(H): H-EXT/H-ENT/H-AUTO/H-CONF — LLM knowledge extraction (entities, relationships, auto-create in GraphRAG, confidence scoring with review queue), 31 tests passing 2026-08-18 12:02:33 +02:00
Agent Zero e09e33e225 feat(H): H-SRC/H-CITE — knowledge source adapter (wiki/dms/mail/communication), evidence references with deep-links and workstream blocks, 23 tests passing 2026-08-18 11:59:39 +02:00
Agent Zero 396fdf3c9a feat(H): H-WIKI/H-VER/H-LINK — Wiki plugin (articles, categories, versioning, entity links), migration 0126, 9 routes, 15 tests passing
Check Cross-Plugin Imports / check (push) Has been cancelled
2026-08-18 11:55:43 +02:00
Agent Zero 59f05de621 feat(G): G-WORK/G-HUMAN-DEC/G-UI-TEMPL/G-DOC — workflow workstream, decision guard, template gallery (3 templates), API docs, 43 tests passing 2026-08-18 11:11:50 +02:00
Agent Zero 9866fb2d14 feat(G): G-APPROVAL/G-MAN/G-WEB/G-LOG/G-RUN-resume — workflow routes (resume, manual trigger, webhook trigger, step history, approve/reject), 30 tests passing 2026-08-18 08:31:18 +02:00
Agent Zero db41e60042 feat(G): G-RUN/G-CTX/G-WAIT/G-HTTP/G-MAIL/G-CAL/G-DMS/G-SEARCH/G-AGENT/G-CRM/G-EVT/G-WEB — Durable WorkflowRun, 10 step handlers, resume/wait/lock/retry, SSRF protection, frontend step editor 2026-08-18 00:29:58 +02:00
Agent Zero a323c706bd fix(F): Phase F test fixes — UUID handling, MissingGreenlet, contact_id FK, decompose_goal milestone, success_criteria parent propagation, conftest PermissionsPlugin imports
Check Cross-Plugin Imports / check (push) Has been cancelled
2026-08-17 23:23:40 +02:00
Agent Zero 45ebbee26f fix(audit): P2 frontend any→concrete types (181→61), heroicons→lucide-react, missing type exports, toast API, Select options, TaskStatus types; P2-9 hooks.py type annotations 2026-08-17 22:24:24 +02:00
Agent Zero 680557087e feat(F): F-TEST + F-DOC + F-UI-TRIG — Phase F complete!
- F-TEST: tests/test_phase_f_agents.py (1425 lines, 45 tests, all pass) — ReAct Loop, Permissions, Approvals, Skills, Context Builder, Data Policy, Transparency, Workstream, Budget
- F-DOC: docs/api-documentation.md (Phase F endpoints), docs/plugin-development-guide.md (Agent chapter 32), docs/test-strategy.md (Phase F test conventions)
- F-UI-TRIG: trigger_dispatcher dispatches agents on ui.*/context.* events (already implemented in F-PROACTIVE)
- Bug fix: approval.py metadata reserved attribute renamed to request_metadata
- PROGRESS.md: Phase F marked done, ~155/223 tasks done (70%)
2026-08-17 19:36:42 +02:00
Agent Zero a53dcc38d5 feat(F.14): Unified Task System — F-TASK-MODEL/API/AGENT/WORK/UI/MIG/GOAL/TEST
Check Cross-Plugin Imports / check (push) Has been cancelled
- F-TASK-MODEL: Extended Task model with polymorphic assignee/entity/creator, subtasks, dependencies, task_type, success_criteria, progress
- F-TASK-API: Extended task routes with polymorphic filters, subtasks, dependencies, new lifecycle
- F-TASK-AGENT: ai_tools.py (191 lines) — create_task, assign_task, update_task_status, decompose_goal tools
- F-TASK-WORK: workstream.py — task_card and goal_card blocks in communication system
- F-TASK-UI: TaskBoard.tsx, TaskDetail.tsx, GoalView.tsx frontend components
- F-TASK-MIG: Migration 0124 — new columns, data migration for contact_id/assigned_to
- F-TASK-GOAL: Progress aggregation, success criteria evaluation, parent status propagation
- F-TASK-TEST: test_unified_tasks.py (414 lines)
- i18n updates for task system
2026-08-17 18:51:22 +02:00
Agent Zero 06b281ba74 feat(F): F-PROACTIVE consolidate proactive AI — trigger_dispatcher dispatches agents on context/UI events
Check Cross-Plugin Imports / check (push) Has been cancelled
2026-08-17 18:40:41 +02:00
Agent Zero 8ed6d27885 feat(F): F-WORK agent_workstream + F-EMAIL/CONTACT/FOLLOW/REPORT prebuilt agents
Check Cross-Plugin Imports / check (push) Has been cancelled
- F-WORK: app/ai/agent_workstream.py (201 lines) — post_agent_message, post_agent_step, post_agent_result, post_approval_request
- F-EMAIL: prebuilt/email_triage_agent.py — E-Mail-Triage-Agent with 3 tools, max 10 steps, $0.50 budget
- F-CONTACT: prebuilt/contact_enrichment_agent.py — Contact-Enrichment-Agent with 3 tools, max 8 steps, $0.30 budget
- F-FOLLOW: prebuilt/follow_up_agent.py — Follow-up-Agent with 3 tools, max 8 steps, $0.30 budget
- F-REPORT: prebuilt/report_agent.py — Report-Agent with 2 tools, max 12 steps, $0.50 budget
- All compile checks pass
2026-08-17 18:33:45 +02:00
Agent Zero 158feec374 feat(F): F-MEM agent_memory + frontend agent overview components
Check Cross-Plugin Imports / check (push) Has been cancelled
- F-MEM: app/ai/agent_memory.py (236 lines) — store/retrieve/search agent memory with embeddings
- Frontend: AgentDashboard.tsx (831 lines), AgentsOverview.tsx (35 lines) — agent list and dashboard
- agent_memory plugin models updated
2026-08-17 17:14:51 +02:00
Agent Zero 638e3f3e1e feat(F): F-PERM permissions, F-APPR approval, F-AIUSE metadata, F-TRANS transparency, F-DATA-POL data policy, F-OVERSIGHT decision record, F-DRY dry-run, F-AUDIT audit log
Check Cross-Plugin Imports / check (push) Has been cancelled
- F-PERM: app/ai/agent_permissions.py (230 lines) — AgentPermissionContext, resolve_agent_permissions(), filter_visible_agents(), check_agent_execute_permission(), optimistic locking
- F-APPR: app/core/approval.py (160 lines) + app/routes/approvals.py (305 lines) + migration 0123 — ApprovalRequest model, CRUD API, approve/reject/expire
- F-AIUSE: app/ai/ai_use_case.py (156 lines) — AIUseCaseMetadata Pydantic model, validate_ai_use_case()
- F-TRANS: app/ai/transparency.py (60 lines) — mark_as_ai_generated(), is_ai_participant()
- F-DATA-POL: app/ai/data_policy.py (210 lines) — enforce_data_policy() with SENSITIVE_FIELDS + provider compliance
- F-OVERSIGHT: app/ai/oversight.py (108 lines) — DecisionRecord, create_decision_record()
- F-DRY: agent_loop.py updated with dry_run parameter
- F-AUDIT: agent_loop.py updated with audit log for tool calls
- agent_routes.py: AI use case metadata endpoints added
- main.py: approval routes registered
- All Python compile checks pass
2026-08-17 16:57:50 +02:00
Agent Zero dbeadd8ab1 feat(F): F-CTX context_builder, F-STR agent_stream, F-DEF agent definition fields, F-SKILL skill_registry, F-TOOL agent_tools
Check Cross-Plugin Imports / check (push) Has been cancelled
- F-CTX: app/ai/context_builder.py (282 lines) — build_agent_context() + ReActSystemPromptBuilder
- F-STR: app/ai/agent_stream.py (155 lines) — stream_react_loop() with SSE events (step, status, done, error)
- F-DEF: AgentDefinition fields added (temperature, max_tokens, max_steps, trace_mode, skill_ids, trigger_config, ai_use_case_metadata) + migration 0122
- F-SKILL: app/ai/skill_registry.py (82 lines) — SkillDefinition + SkillRegistry singleton
- F-TOOL: app/ai/agent_tools.py (117 lines) — get_agent_tools() with permission intersection
- Skill CRUD routes: app/plugins/builtins/automation/skill_routes.py
- Tests: test_skill_registry.py (97 lines), test_agent_tools.py (219 lines)
- All Python compile checks pass, tests require PostgreSQL (infra issue, not code bug)
2026-08-17 16:40:55 +02:00
Agent Zero c760b5961c feat(F-LOOP): true ReAct loop with structured Thought/Action/Observation step tracking
Check Cross-Plugin Imports / check (push) Has been cancelled
- app/ai/agent_loop.py: ReActStep + ReActResult dataclasses, run_react_loop()
  with LLM→Tool→Observe loop, max_steps/timeout graceful stop, ErrorCategory
  retry (TRANSIENT→retry, PERMANENT→stop, PARTIAL→continue), cost accumulation,
  agent.step hook, on_step callback
- app/plugins/builtins/automation/models.py: AgentRunStep model
- alembic/versions/0121_agent_run_steps.py: migration for agent run steps table
- app/plugins/builtins/automation/agent_runner.py: refactored to use run_react_loop(),
  saves steps to DB, updates AgentRun with cost/status/duration
- tests/test_agent_loop.py: 11 tests (all passing, mocked, no DB/LLM needed)
- PROGRESS.md: Phase F started, F-LOOP marked done
2026-08-17 16:11:26 +02:00
Agent Zero 3622022482 fix(dms): add missing FileMetadataResponse import
Check Cross-Plugin Imports / check (push) Has been cancelled
2026-08-17 14:12:40 +02:00
Agent Zero 765d6d3ab4 feat(dms): fix upload response_model, add content_hash migration, storage settings tab, roadmap external storage
Check Cross-Plugin Imports / check (push) Has been cancelled
2026-08-17 14:09:00 +02:00
Agent Zero 371f2a55fe fix(mail): correct indentation for mail.after_create do_action
Check Cross-Plugin Imports / check (push) Has been cancelled
2026-08-17 09:01:28 +02:00
Agent Zero 8de35a24a7 fix(hooks): 9 hook wiring fixes — DMS/Calendar name mismatch, Mail/Contact missing triggers
Check Cross-Plugin Imports / check (push) Has been cancelled
2026-08-17 07:21:39 +02:00
Agent Zero 0a1ba30ed7 fix(imports): agent_runner MailService→Mail model, fix trace_hooks syntax, fix trace_api_contracts warnings
Check Cross-Plugin Imports / check (push) Has been cancelled
2026-08-17 07:17:27 +02:00
Agent Zero 5b0b1e093a fix(imports): 3 broken imports — ENTITY_MODELS path, Room→CommConversation, get_cached_mail_summary→MailService
Check Cross-Plugin Imports / check (push) Has been cancelled
2026-08-17 07:14:29 +02:00
Agent Zero d50615e870 fix(search): GraphRagContract attribute name — graph_rag_search_provider → GraphRAGSearchProvider
Check Cross-Plugin Imports / check (push) Has been cancelled
2026-08-16 23:50:26 +02:00
Agent Zero f265eef5ae fix(auth): useAuth() hook in AppShell/StartLayout + is_system_admin in login response 2026-08-16 23:26:59 +02:00
Agent Zero e25a1b4fec fix(ui): CommandPalette outside Router context — white page fix; remove PWA; fix CSP for Google Fonts 2026-08-16 13:50:39 +02:00
Agent Zero abbe7a18fc fix(audit): P0-P3 audit fixes — 838 ruff errors → 0, 30 F821 bugs fixed, 118 files changed
- P0: hooks.py 3-tuple fix, trigger_dispatcher Contract, contacts/plugin unregister_actions_by_owner
- P0: 5 test files — check_permission mocks removed, hardcoded DB credential → env var
- P1: attachment_service DmsFile via Contract helper, restore_registry/history_hooks dedup
- P1: mail/plugin restore unregister, mcp_client datetime.now(UTC), saved_views/filters patterns
- P1: ProtectedRoute fail-closed, 13 test assertion fixes (bcrypt, DB-URLs, SECRET_KEYs)
- P2: deprecated notifications → post_system_message (3 files), forgejo Base, report_generator lazy import
- P2: webhooks permissions, deps.py/roles.py plugin perms removed, import_export default
- P2: address/tags/entity_links patterns removed, worker.py Contract-Umgehungen fixed
- P2: 28 frontend TODOs (hardcoded constants, deprecated notification API)
- P3: dead code, duplicates, deprecated imports, private attr, __import__ inline
- P3: 8 frontend TODOs (LucideIcons, inline styles, XSS, i18n)
- ruff: 838 → 0 (612 auto-fix + 246 manual + 27 F821 regression fix)
- F821: 30 → 0 (AutomationDefinition, DmsFile, user_id, Path, Any, String)
- Contract-Umgehungen: 2 neue gefunden (worker.py:169, worker.py:280) und gefixt
2026-08-16 01:17:18 +02:00
Agent Zero 3d9b76cea4 feat(E): Unified Search — 24 Tasks complete
Check Cross-Plugin Imports / check (push) Has been cancelled
- SPIKE-E: FTS+Vector+Permission benchmark on 10k records (all <30ms)
- E-PROV: supports_fts/vector/rag/graph capability flags on all providers
- E-FTS/VEC: All 11 providers refactored to BaseSearchProvider with permission filtering
- E-PERM: Over-fetch strategy for vector+permission (15x faster than ANY() filter)
- E-FUSE: rrf_fusion_multi() for N-way RRF over FTS+Vector+RAG+Graph
- E-LLM: Query understanding cleaned up to use central llm_complete()
- E-CHUNK: Document chunking module + document_chunks table with HNSW index
- E-EMB: Chunk embedding ARQ jobs (index_file_chunks, reindex_chunks)
- E-RAG: RAG retrieval via FileSearchProvider.search_rag()
- E-GRAPH: GraphRAG BFS traversal via GraphRAGSearchProvider.search_graph()
- E-IX-EVT: Auto-indexing via outbox events + delete/cleanup handlers
- E-IX-RE: Batch reindex with progress tracking + reindex_all job
- E-DATA-LIFE: Lifecycle module (remove/rebuild/restore/correct) + API endpoints
- E-K-MEM: AgentMemorySearchProvider
- E-P-AI: AIChatSearchProvider
- E-P-WF: WorkflowSearchProvider
- E-P-COMM: ConversationSearchProvider verified (already on BaseSearchProvider)
- E-API: Filter params (date_from/to, tags, sort) + /facets endpoint
- E-TOOL: unified_search AI tool registered in ToolRegistry
- E-MCP: Search tool in MCP server with normal RBAC/tenant checks
- E-UI-CMD: CommandPalette (Cmd+K) with debounced search + recent searches
- E-UI-FAC: SearchFacets, SearchResultCard, SavedSearches components
- E-TEST: 40 new tests in test_unified_search_phase_e.py (105 total green)
- E-DOC: api-documentation.md, plugin-development-guide.md, test-strategy.md updated

105 tests passing, TypeScript clean.
2026-08-14 01:34:58 +02:00
Agent Zero a4d0f0c35d feat(D): Phase D — Undo/Restore komplett implementiert
Check Cross-Plugin Imports / check (push) Has been cancelled
- D-GEN: RestoreRegistry mit RestoreConfig (model_class, restore_permission, excluded_fields, special_handler)
- D-HOOK: history_hooks.py mit register_history_hooks() für after_create/update/delete
- D-CORE: Company create+update record_history in companies.py
- D-PLUG: Task/Calendar/DMS record_history in services/routes
- D-SOFT: Alle registrierten Entitäten haben deleted_at + un-delete via Registry
- D-MAIL: Mail special_handler (IMAP Trash-Move, Folder-Verify) + record_history in delete/move
- D-TRASH: GET /entity-history/trash (filterbar, paginiert) + Frontend Trash.tsx
- D-TOAST: UndoToast.tsx (5s Auto-Dismiss, useUndoToast Hook)
- D-HIST-UI: HistoryPanel.tsx (Timeline, Diff-View, Restore-Button)
- D-BULK: POST /entity-history/bulk-restore mit partial_success Semantik
- D-RET: POST /entity-history/retention/archive (GDPR hard-delete >90 Tage)
- D-TEST: 26 Tests in test_restore_registry.py, alle grün
- D-DOC: test-strategy.md + security_kernel.md aktualisiert

Backend: 10 Dateien, Frontend: 7 Dateien, Tests: 1 Datei, Docs: 3 Dateien
26/26 Tests passed, TSC 0 errors, App import 492 routes
2026-08-13 23:08:29 +02:00
Agent Zero e7ae0ad5ce feat(C.5): Modularer Import/Export — Shared Helpers, Preview/Mapping, Background Jobs, Partial-Failure
C5-BASE: app/services/import_export_helpers.py (NEU, 352 Zeilen)
- parse_csv/json/xlsx, write_csv/json/xlsx, map_fields, suggest_mapping
- validate_row, build_error_report, build_import_result, detect_format

C5-PREVIEW: POST /import/preview + POST /import/validate
- Preview gibt erste 10 Zeilen + Spalten + Mapping-Vorschlag
- Validate gibt Fehler-Report ohne Import

C5-JOB: app/services/import_export_jobs.py (NEU, 165 Zeilen)
- ARQ Background Job für Files >1000 Zeilen
- Job-Status: pending/processing/completed/partial_success/failed
- GET /import/status/{job_id} — Status + Progress + Fehler-Report
- Partial-Failure: try/except pro Zeile, fehlerhafte gesammelt, erfolgreiche committet

C5-CONTACT+C5-COMPANY: Handler auf Shared Helpers umgestellt
C5-UI: ImportWizard.tsx (5 Steps: Upload→Preview→Validation→Review→Result)
C5-TEST: 45 Tests in test_import_export.py — alle grün
C5-DOC: Plugin-Dev-Guide Kapitel 31 (Import/Export Handler)
2026-08-13 22:43:33 +02:00
Agent Zero b5546ea7bd feat(B.13-B.17+B.16): Error-Handling-Infra, Observability, Graceful Shutdown, Cost-Cap, API Versioning
B.13 Error-Handling-Infrastruktur:
- ErrorCategory Enum (TRANSIENT/PERMANENT/PARTIAL), ApiError erweitert
- Einheitliches Error-Response-Format: {code, detail, field, trace_id, retryable, category}
- 3 FastAPI Exception-Handler (ApiError, HTTPException, unhandled)
- classify_exception() Helper, 6 neue Error-Codes
- 28 Tests in test_error_handling.py

B.14 Observability & trace_id-Korrelation:
- trace_id pro Request (UUID4 short) in structlog contextvars
- X-Trace-Id Response-Header
- Sensitive Fields structlog processor
- llm_complete()/llm_embed() akzeptieren trace_id kwarg
- 12 Tests in test_observability.py

B.15 Graceful Shutdown & Connection Draining:
- _shutdown_event + _inflight_requests Tracking in main.py
- drain_all_connections() in ws_helpers.py
- Worker on_shutdown pausiert WorkflowInstances (status=paused)
- 8 Tests in test_graceful_shutdown.py

B.16 API Versioning Strategie:
- Plugin-Dev-Guide Kapitel 30: URL-basiertes Versioning, Breaking Change Prozess

B.17 Cost Overrun Protection:
- llm_monthly_budget_usd + llm_hard_cutoff Settings
- _check_tenant_budget() vor jedem LLM-Call
- _track_tenant_cost() in Redis (INCRBYFLOAT)
- _check_cost_alerts() bei 50%/80%/100% -> post_system_message()
- 20 Tests in test_cost_protection.py

Total: 68 neue Tests, alle grün. Keine Regressionen.
2026-08-13 21:33:14 +02:00
Agent Zero 1baa9481a2 feat(B-NOTIF): Notification→Message Konsolidierung — System-Channel, post_system_message(), Migration
Check Cross-Plugin Imports / check (push) Has been cancelled
B-NOTIF-SYS: CommConversation um is_system Feld erweitert, get_or_create_system_channel()
B-NOTIF-EVT: post_system_message() in kommunikation/services.py — erstellt CommMessage im System-Channel
- create_notification() als deprecated Wrapper delegiert auf post_system_message()
- Text-Block + action_card Block mit Deep-Link, Metadata: notification_type/severity/entity_ref
B-NOTIF-PREF: NotificationPreference als Routing-Konfiguration, stumm/disabled respektiert
B-NOTIF-MIG: Migration 0120 — Notifications → CommMessages migriert, notifications_legacy View
B-NOTIF-DEPREC: Notification-Routes als deprecated markiert, keine Routes entfernt
B-NOTIF-TEST: 19 Tests in test_notification_migration.py — alle grün
- System-Channel, post_system_message, create_notification Wrapper, Preferences, Unread-Badge, Migration Mapping, Sensitive Fields
2026-08-13 21:19:41 +02:00
Agent Zero 78963f2ca9 feat(B-TRIG): Trigger-Kern konsolidiert — generischer Dispatcher, UI-Event-Typ, 4 Trigger-Typen
Check Cross-Plugin Imports / check (push) Has been cancelled
B-TRIG-GEN: app/core/trigger_dispatcher.py (NEU) — generischer Event→Automation Dispatcher
- Wildcard EventBus Subscribe → matcht AutomationDefinition mit trigger_type=event
- Keine hardcodierte Event-Liste mehr — alle Outbox Events können Automations triggern
- Registriert in main.py lifespan + worker.py on_startup

B-TRIG-UI: UI-Event Trigger-Typ
- trigger_type Pattern um „ui" erweitert (event/schedule/manual/ui)
- UI-Events laufen ephemeral über EventBus → TriggerDispatcher → run_automation
- UI-Events NIEMALS in Outbox (is_ui_event() Guard)

B-TRIG-CRON: Cron/Heartbeat verifiziert — bestehender Pfad funktioniert
B-TRIG-MAN: Manual-Trigger verifiziert — bestehender Pfad funktioniert

B-TRIG-TEST: 10 Tests in test_trigger_core.py — alle grün
- Domain Event, UI Event (ephemeral), Cron, Manual, alle nutzen selben Execution-Kern
B-TRIG-DOC: Plugin-Dev-Guide Kapitel 10 mit Implementierungsdetails erweitert
2026-08-13 21:04:46 +02:00
Agent Zero ae228bb484 feat(B-HOOK): Lifecycle Hooks + Outbox Events — 55 neue Hooks, 10 Domain Events
Check Cross-Plugin Imports / check (push) Has been cancelled
B-HOOK-CORE: Company Hooks (6: before/after create/update/delete)
B-HOOK-MAIL: Mail Hooks (5: after_receive, before/after_delete, before/after_move)
B-HOOK-DMS: DMS Hooks (10: after_upload, before/after_update/delete/restore, folder CRUD)
B-HOOK-CAL: Calendar Hooks (4: before/after update/delete)
B-HOOK-TASK: Task Hooks (6: before/after create/update/delete)
B-HOOK-COMM: Communication Hooks (8: conversation create, message/edit/delete)
B-HOOK-AI: Agent Hooks (2: before/after_run)
B-HOOK-WF: Workflow Hooks (4: before/after_start, after_complete/cancel)
B-HOOK-TAG: Tag Hooks (8: create/assign/unassign/delete)
B-HOOK-SEARCH: Search Filters (2: before/after_search)

B-EVT-OUTBOX: 10 Domain Events (task.completed, file.created/deleted/restored, mail.received, workflow.started/completed/cancelled, agent.run_started/completed)

B-HOOK-TEST: 79 Tests in test_lifecycle_hooks.py — alle grün
B-HOOK-DOC: Plugin-Dev-Guide Kapitel 8 aktualisiert (Hook-Liste + Outbox Event-Liste)
2026-08-13 20:54:15 +02:00
Agent Zero b231c2d0d3 feat(B-SENS): Sensitive Data Boundary + AI/Data Exposure Policy + AIProvider Compliance
Check Cross-Plugin Imports / check (push) Has been cancelled
B-SENS: app/core/sensitive_data.py (NEU) — zentrale Sensitive-Field-Verwaltung
- SENSITIVE_FIELDS dict für contact/user/mail_account/system_settings
- is_sensitive(), sanitize_dict(), register_sensitive_fields()
- Integration: errors.py (Log-Redaction), audit.py (Audit-Masking), export_service.py (Export-Filter), embedding.py (Index-Filter)

B-DATA-POL: AI/Data Exposure Policy
- DATA_EXPOSURE_POLICY: pro Entity+Field welche Systeme erlaubt (llm_context/search/embeddings/rag/agent_memory/export)
- filter_for_llm_context/search/embeddings/export/rag/agent_memory()

B-AIPROV-COMP: AIProvider Compliance Metadata
- Migration 0119: 7 neue Spalten an ai_providers (region, hosting_type, dpa_status, retention_policy, training_on_customer_data, transfer_notice, allowed_data_classes)
- llm_client.py: get_provider_compliance() + check_data_class_allowed()

B-PRIV-TEST: 76 Tests in test_sensitive_data.py — alle grün
- Sensitive Fields, Exposure Policy, Provider Compliance, Secrets-always-blocked
- Keine Regression: 39 LLM-Client Tests grün
2026-08-13 20:39:32 +02:00
Agent Zero bb36378494 feat(B-RL): Rate-Limiting Konsistenz — zentrale Policies für Auth/AI/Upload/Webhook
Check Cross-Plugin Imports / check (push) Has been cancelled
B-RL: Rate-Limiting auf zentrale check_rate_limit() umgestellt
- forgejo_error_reporter: In-Memory → zentrale Redis-Rate-Limit
- ai_proactive: eigene Redis-Logik → zentrale check_rate_limit()
- agent_runner: DB-basiertes Limit bleibt (zählt echte Ausführungen)
- RateLimitPolicy Enum (AUTH/AI/UPLOAD/WEBHOOK) + check_rate_limit_policy()
- 8 neue config.py Settings für Policy-Limits
- 12 Routes mit Policies versehen (login, password-reset, AI, uploads, webhooks)

Tests: 20 Tests in test_rate_limit_policies.py — alle grün
- Policies, check_rate_limit, reset, get_client_ip, forgejo, ai_proactive
- Keine Regression: 116 bestehende Tests grün
2026-08-13 17:51:04 +02:00
Agent Zero 8c04c85d35 feat(B-PLUGIN-MINIAPP-WIRE): MiniApp Registry als Singleton — gemeinsame Registry für alle Plugins
Check Cross-Plugin Imports / check (push) Has been cancelled
B-PLUGIN-MINIAPP-WIRE: MiniAppRegistry Singleton-Pattern
- get_miniapp_registry() / reset_miniapp_registry() in miniapp_registry.py
- Alle 6 MiniAppRegistry() Instanziierungen durch get_miniapp_registry() ersetzt
- automation/plugin.py (on_activate/on_deactivate), automation/routes.py (3x), kommunikation/plugin.py
- contracts.py: get_miniapp_registry + reset_miniapp_registry exportiert
- 0 verbleibende MiniAppRegistry() Instanziierungen außerhalb miniapp_registry.py

Tests: 12 Tests in test_miniapp_registry.py — alle grün
- Singleton, Register/List, UnregisterPlugin, Plugin-Lifecycle-Integration
2026-08-13 17:39:22 +02:00