Zammad-AI is a GenAI-powered extension for Zammad. The repository contains two separate Python services:
zammad-ai-workflow: the backend service for ticket triage, answer generation, Kafka processing, and the optional embedded frontend.zammad-ai-index: the indexing job that synchronizes Zammad knowledge base content into Qdrant Database.
The services are intentionally separated from the core Zammad application so prompts, retrieval, automation rules, and integrations can evolve independently.
Zammad provides native AI features (for example AI Agents, AI Ticket Summary, and AI Writing Assistant) with flexible operating models like managed AI, bring-your-own-model, or self-hosted LLMs. This repository addresses a different goal: a fully controllable integration layer for project-specific automation and knowledge retrieval workflows.
We keep this component separate from Zammad core to:
- Ship GenAI workflow changes independently from Zammad release cycles.
- Implement organization-specific triage, routing, and answer generation logic.
- Integrate custom retrieval pipelines (Qdrant indexing and domain prompts) beyond built-in defaults.
- Run event-driven processing via Kafka for high-volume and asynchronous support operations.
- Add project-specific observability, tracing, and compliance controls without patching Zammad itself.
- Product scope:
Zammad built-in AI focuses on generic in-product assistance.
zammad-aifocuses on backend orchestration, custom business rules, and external integrations. - Extensibility:
Zammad built-in AI is feature-configurable.
zammad-aiis code-first and designed for custom prompts, adapters, and processing pipelines. - Data flow:
Zammad built-in AI is primarily embedded in UI workflows.
zammad-aiadds event-driven ingest/filter/process/output flows and explicit indexing jobs. - Operations:
Zammad built-in AI is managed as part of Zammad.
zammad-aican be deployed, scaled, monitored, and released as independent services. - Integration boundary:
Zammad built-in AI enhances agent UX directly in Zammad.
zammad-aiacts as a composable AI middleware that can serve Zammad and surrounding systems.
- Consumes ticket events from Kafka and exposes REST endpoints for triage and answer generation.
- Uses Qdrant for knowledge base retrieval.
- Integrates with Langfuse for tracing and prompt management.
- Supports Zammad API and EAI-based integrations.
- Exposes Prometheus metrics and an optional Gradio frontend for local workflows.
- zammad-ai-workflow/ - backend service and API entry point.
- zammad-ai-index/ - knowledge base indexing job.
- docs/ - architecture, configuration, and API documentation.
- compose.yaml - local Kafka, Qdrant, Mailpit, Prometheus, Grafana, and UI stack.
- observability/ - Prometheus and Grafana provisioning files.
For the Digital Citizen Service architecture, see the DBS Architecture documentation.
- Python 3.14.4
- uv
- Docker and Docker Compose
- Start the local infrastructure from the repository root:
docker compose up -dAvailable local services:
- Kafka UI: http://localhost:8089
- Mailpit: http://localhost:8025
- Qdrant: http://localhost:6333
- Prometheus: http://localhost:9091
- Grafana: http://localhost:3000
- Install dependencies for the backend service:
cd zammad-ai-workflow
uv sync- Copy the example configuration and adjust it for your environment:
cp config.example.yaml config.yaml- Start the backend service:
uv run python main.py- Optional: enable the embedded Gradio frontend by setting
frontend.enabled: trueinzammad-ai-workflow/config.yaml. In development mode, the backend exposes:
- Frontend: http://localhost:8080/
- OpenAPI docs: http://localhost:8080/api/docs
- Install dependencies for the indexing job when you need to sync the knowledge base:
cd ../zammad-ai-index
uv sync
cp config.example.yaml config.yaml
uv run python main.pyThe backend exposes the following public routes:
GET /api/v1/healthPOST /api/v1/triagePOST /api/v1/answer
Run the test suite:
cd zammad-ai-workflow # or cd zammad-ai-index
uv run pytestLint and format the code:
cd zammad-ai-workflow # or cd zammad-ai-index
uv run ruff check .
uv run ruff format .Type check the codebase:
cd zammad-ai-workflow # or cd zammad-ai-index
uv run ty check- Configuration is loaded from CLI arguments, environment variables,
.env, andconfig.yamlin that order. - Environment variables use the
ZAMMAD_AI_prefix. - Secrets should stay in
.env, not inconfig.yaml. - The backend and indexing job each have their own
config.example.yamlfile. Defaults are defined in the source code underzammad-ai-workflow/app/settings/.
Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.
See the full guidelines in CONTRIBUTING.md.
If you have a suggestion that would make this better, please open an issue with the tag "enhancement", fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!
- Open an issue with the tag "enhancement"
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature) - Commit your Changes (
git commit -m 'Add some AmazingFeature') - Push to the Branch (
git push origin feature/AmazingFeature) - Open a Pull Request
More about this in the CODE_OF_CONDUCT file.
Distributed under the MIT License. See LICENSE file for more information.
it@M - opensource@muenchen.de