← GitHub

GitHub·3 min read

KaelLee335/enterprise-support-agent

Learn how the demo wires Dify into a support workflow and what you can reuse for your own enterprise bot.

The KaelLee335/enterprise-support-agent repository showcases a Dify‑based after‑sales support agent, and the most striking fact is that it includes a full evaluation loop for synthetic policies and orders. The demo runs entirely in Python and has already earned 49 stars on GitHub. It is presented as a self‑contained example rather than a production service.

The core of the system is a Dify client that receives a user query, forwards it to a language model, and then applies a set of synthetic policies to shape the response. Policies are stored as JSON rules that filter or rewrite model output, mimicking real‑world compliance checks. Orders are also synthetic objects, generated at runtime to test how the agent would retrieve and summarize purchase data.

Evaluation is handled by a separate script that feeds the agent a batch of test queries, records the responses, and compares them against expected answers derived from the synthetic policies. The script prints precision‑style metrics, letting developers see where the policy layer succeeds or fails. All code lives in a single repository, with clear entry points for the agent, policy loader, and evaluator.

If you are building an internal support chatbot, you can clone this repo to bootstrap your own policy engine and evaluation pipeline. Replace the synthetic policies with your company’s compliance rules, hook the order loader into your real database, and run the evaluator to catch regressions before deployment. The Python structure makes it easy to add custom middleware or integrate with other LLM providers.

TakeawayUse the demo as a template to layer policy enforcement on top of LLM‑driven support bots.

Prodigy briefing — continue on the original for source material, discussion, and updates.

View repository ↗