Design the enterprise AI slice
Design a permission-aware document assistant with source updates, explicit tool boundaries and recovery behavior you can explain during a customer design review.
What you'll be able to do
- Trace a request through identity, retrieval, generation and review
- Explain how document updates and permission changes affect an index and its caches
- Define the boundaries around an agent's external actions
Before this: discovery-and-pilot-scope
Northline's first implementation drafts a warranty answer from approved documents. Retrieval-augmented generation is a reasonable candidate because employees need current policy evidence. First verify that the relevant documents exist and that an employee can find the applicable policy. A prototype should make the source and decision path easy to inspect.
Trace the request
Authenticate the employee and resolve their tenant and current access rights. Retrieve eligible policy passages, attach version identifiers, and ask the model for a draft tied to those passages. Check that cited identifiers came from the supplied evidence. Show the draft and source links to the employee, who can escalate an uncertain case.
Authorization constrains the evidence entering generation. The employee reviews the draft before it becomes a customer response.
| Boundary | A question to answer in the design review |
|---|---|
| Source connector | How are edits, deletions and failed syncs detected? |
| Document index | Which tenant, version and access metadata accompany each passage? |
| Retrieval | How are the user's current rights enforced before evidence reaches the model? |
| Generation | How does the response identify evidence and express missing information? |
| Review interface | Can the employee open the cited policy and report an error? |
| Operations | Can an operator trace one bad response and disable the feature? |
Keep the index aligned with the source
A document connector needs a checkpoint, stable source identifiers and a way to process removals. Make ingestion repeatable so a retry replaces the same document version safely. Record sync age and failed items. An index containing last month's policy can produce a well-cited answer that is still wrong.
Permission changes need an explicit path too. Enforce current authorization at retrieval, and define how cached results are invalidated when rights or source versions change. A shared answer cache needs a key and validity rule covering the tenant, access context and document versions. When fresh authorization cannot be established, return an unavailable or escalation outcome.
Add actions deliberately
If a later version can update a ticket, describe the command separately from the generated draft. Validate its parameters, check authorization in ordinary application code and record the action. Use a durable idempotency key for operations that may be retried. The receiving system must enforce uniqueness or reconcile an uncertain response before a repeat request.
For refunds, the customer also needs an approval policy and a record of who approved which amount. Treat document text and tool responses as untrusted inputs. They should supply facts within their defined scope. The service's authorization and action policy determine what operations are available.
Defend a tradeoff
Prompt. The ticket API is down but document search works. What should the employee see?
Worked answer. Explain that the assistant can show a policy draft while ticket updates are unavailable. Preserve the draft locally in the interface if supported, report the failed operation clearly, and offer the existing manual workflow. When writes resume, reconcile any uncertain operation before retrying it with its original idempotency key.
Practice. Draw the Northline request path. Mark the trust boundaries, then trace a deleted document, a revoked employee permission and a repeated tool call. Name the component responsible for each result.
Practise this stage with ChannelPulse
Use the system-design workbench to explain your architecture and its tradeoffs, then review feedback on your answer. Practise system design.
Reading and attribution
Tech Mahato's enterprise-AI guide and enterprise-RAG project inform the integration topics. bicced's production guide is licensed under CC BY 4.0. The architecture, checks and customer exercise here are ChannelPulse teaching material. Source links are listed above.