Agentic AI Patterns

Course Content

Agentic AI Patterns

9 sections · 50 lessons

How would you design an Agentic AI system for an investment advisory firm?


What you need to know

Clarify first

  • Who sees the output? Advisors only, or clients directly? Client-facing advice is regulated: by SEBI's investment adviser rules in India, by the SEC and FINRA in the US.
  • Which asset classes and data sources?
  • What records must be kept?

Architecture

ComponentJobHow
RouterClassify: data lookup, research, portfolio review, client draftSmall model
Market data workerPrices, fundamentals, corporate actionsTyped APIs, timestamped
Research workerFilings, earnings calls, internal notesRetrieval with entitlement filters
AnalyticsExposure, risk, performance attributionDeterministic code, not the model
Compliance checkerSuitability, mandate, disclosures, restricted listsRules in code plus model review
Drafting agentAdvisor-ready memo or client draftCites every figure

Flow

  1. Advisor asks — for example, "review Mr Rao's portfolio after the rate cut".
  2. Route — this is a portfolio review.
  3. Run workers in parallel — holdings, prices, recent research.
  4. Compute — exposure and risk in code.
  5. Synthesise — memo with citations and as-of timestamps.
  6. Compliance pass — suitability and mandate checks.
  7. Advisor approves — edits and sends, if appropriate.

Controls

  • Every number from a tool, with a timestamp. The model narrates.
  • Suitability, KYC and mandate limits enforced in code.
  • No autonomous trading; no autonomous client messages.
  • Entitlement filtering: advisors see only their own clients. Information barriers and restricted lists enforced at retrieval.
  • Immutable archive of every recommendation and its inputs.

Failure modes

Stale prices, invented figures, an overfit backtest presented as insight, injection through a filing or forwarded email, and unsupervised client text creating regulatory exposure.

Metrics and first release

Research time saved, factual error rate on figures (close to zero, since figures come from tools), compliance rejection rate, and advisor adoption. Ship internal research summaries with citations first.

A real-life example

A wealth-management firm with 60 advisors builds portfolio review prep.

An advisor asks for a review of a client's portfolio. In about 40 seconds the system returns: holdings with today's prices (as of 3:31 pm), sector exposure computed in code, a 12% concentration in one bank stock above the client's 10% mandate limit (flagged by the compliance rule), and a one-page summary of the bank's latest results with page-cited quotes from the filing.

A draft client email proposes trimming the position. The compliance checker adds the required risk disclosure; the advisor edits the tone and sends it. The agent has no trading tool at all.

Review prep fell from about 90 minutes to about 20 per client. In six months, audits found zero figure errors traced to the model, because it never produced a figure itself. Two issues found were stale data from a delayed price feed, which led to a freshness alert.

Follow-up questions to expect

  • "How do you stop the model from making up numbers?" — Numbers only come from tool results, the draft cites each one, and a validator checks every figure in the text against the tool outputs.
  • "How do you handle insider or restricted information?" — Entitlement and information-barrier filters at the retrieval layer, so restricted documents never reach the model for that user.
  • "Could it trade automatically?" — Not in this design. Execution stays with licensed staff and existing order systems with their own controls.