FREE COURSE · 6 MODULES · ADVANCED

AI Agents in Treasury & Finance

From Concept to Implementation — a practical workshop for finance professionals.

What we'll cover: architecture · use cases · technology stack · vendors · implementation. This is a workshop, not a demo — every module ends with something concrete: a comparison to use, a roadmap to plan against, or a checklist to run before you build.

After this course, you will be able to
  • ✓ Explain what actually makes something an "agent" — not a chatbot, not RPA
  • ✓ Name the 4 components of agent architecture and the loop that connects them
  • ✓ Identify where agents add real value in treasury, with 2 worked examples
  • ✓ Compare LLM providers, orchestration frameworks, and build vs buy vs hybrid
  • ✓ Plan an 8-week implementation and name the 5 risks to guard against

treasuryease.com

Not a chatbot. Not RPA. Something new.

Chatbot
  • Responds to questions
  • Single turn or simple dialog
  • No actions, only text
  • No memory between sessions
  • Pre-defined responses
RPA bot
  • Executes scripted tasks
  • Follows exact rules
  • Breaks on UI changes
  • No understanding
  • Deterministic output
AI agent
  • Reasons about goals
  • Chooses tools dynamically
  • Adapts to context
  • Maintains memory
  • Handles ambiguity

AI Agent = LLM + Tools + Memory + Orchestration

The four components that make an agent work

LLM (Brain)
↑
🔧 Tools
APIs, databases, files
Orchestrator
Coordinates the loop
💾 Memory
Context, history, state
↓
User / Trigger

The agent loop: Observe → Think → Act → Repeat

What each component actually does

LLM (Large Language Model)

The "brain" that reasons and decides. Interprets user intent, plans steps, generates responses. Examples: GPT-4, Claude, Gemini.

Tools (Functions)

Actions the agent can take. Query database, call API, read files, send emails, execute calculations. You define what's available.

Memory (Context)

Short-term: current conversation. Long-term: user preferences, past interactions, learned patterns. Stored in vector DBs or simple storage.

Orchestrator (Framework)

Manages the loop: receive input → call LLM → execute tools → return result. Handles errors, retries, timeouts. Examples: LangChain, AutoGen, Semantic Kernel.

Where AI agents add real value today

Cash Positioning

Aggregate balances, calculate exposures, alert on thresholds

Cash Forecasting

Analyze patterns, predict flows, suggest actions

Reconciliation

Match transactions, identify discrepancies, explain gaps

Payment Analysis

Categorize, detect anomalies, optimize timing

Compliance Check

Validate against policies, flag exceptions, document

Report Generation

Create narratives, summarize data, answer questions

Key insight: agents excel where judgment + data access + action are needed together.

How the agent works, step by step

1. Trigger

User asks or schedule runs

2. Fetch

Query bank data, AR/AP, history

3. Analyze

LLM finds patterns, seasonality

4. Forecast

Generate 7/14/30 day projection

5. Act

Alert, report, recommend

Example interaction

User: "What's our cash position for next week? Any concerns?"

[Fetches data from 12 bank accounts, AR aging, scheduled payments]

Agent: "Current position: €2.4M across EUR accounts. Projected Thursday: €890K after €1.2M supplier batch. Recommendation: consider delaying Supplier_Group_B payment by 48h or draw €500K from credit facility. Historical pattern shows receivables spike on Friday (+€600K avg)."

Fuzzy matching, with reasoning attached

Traditional approach
  • Exact match only
  • Manual exception handling
  • No context understanding
  • Hours of manual work
  • Same mistakes repeated
Agent approach
  • Fuzzy matching with reasoning
  • Explains why items match
  • Learns from corrections
  • Handles edge cases
  • Confidence scores per match

Example: agent matches "PYMT-2024-1847" to "Payment #1847-2024" (98% confidence)

Reasoning: "Same amount (€45,230.00), same date (±1 day), reference numbers are transposed format of same ID, counterparty 'Acme Corp' matches 'ACME CORPORATION' in master data."

What you need to build an AI agent

Application
Your treasury solution
Chat interface, scheduled jobs, API endpoints
Orchestration
Agent framework
LangChain, AutoGen, Semantic Kernel, Custom
LLM Provider
The AI model
OpenAI, Anthropic, Azure OpenAI, Google, Local (Ollama)
Data Layer
Databases, file storage, APIs
PostgreSQL, SQLite, REST APIs, SFTP
Infrastructure
Cloud / on-premise / hybrid
Azure, AWS, Local server

Which model provider fits your constraints

ProviderModelsProsCons
OpenAIGPT-4o, GPT-4 TurboBest tooling, widest adoption, strong reasoningUS-based, data concerns, cost at scale
Azure OpenAISame as OpenAIEnterprise compliance, EU data residency, SLAsSetup complexity, approval process
AnthropicClaude 3.5 Sonnet/OpusStrong reasoning, large context, safety focusSmaller ecosystem, fewer integrations
GoogleGemini Pro/UltraMultimodal, Google Cloud integrationLess mature for agents, availability
Local (Ollama)Llama 3, Mistral, etc.Full data control, no API costs, offlineLower quality, needs hardware, maintenance

Recommendation: for enterprise treasury, Azure OpenAI or Anthropic for compliance. For experimentation, OpenAI direct.

The glue that makes agents work

LangChain
Python / JS · most popular, huge ecosystem

✓ Many integrations
✓ Active community

✗ Complexity, abstractions

AutoGen (Microsoft)
Python · multi-agent conversations

✓ Agent-to-agent design
✓ Microsoft backing

✗ Newer, less docs

Semantic Kernel
C# / Python · enterprise-focused

✓ .NET integration
✓ Azure native

✗ Smaller community

Other options

CrewAI (role-based agents) · LlamaIndex (data focus) · Haystack (search + RAG) · Custom (full control, more work)

For treasury: LangChain for flexibility, Semantic Kernel if a .NET shop, AutoGen for complex multi-agent workflows.

Three paths to AI agents in treasury

Build
Custom development

✓ Full control
✓ Exact fit to needs
✓ No vendor lock-in

✗ Needs dev resources
✗ Longer time to value
✗ Maintenance burden

Buy
Vendor solution

✓ Fast deployment
✓ Proven features
✓ Vendor support

✗ Generic, not tailored
✗ Expensive (€50K+/yr)
✗ Data leaves your control

Hybrid
Platform + customization

✓ Balance of speed & fit
✓ Own your data layer
✓ Use approved LLM APIs

✗ Still needs some dev
✗ Integration complexity
✗ Two things to maintain

For most treasury teams: hybrid wins. Use proven components, customize the last mile.

A treasury AI agent in production

What is TOSY?

Conversational AI assistant for treasury operations built into TreasuryOS. Users interact naturally: "Show me cash position by currency" or "Generate a forecast for next week."

Architecture

LLM: OpenAI / Azure OpenAI
Orchestration: Custom (TypeScript)
Tools: ReportCore, CalculatorCore, DataCore
Data: Local SQLite, user uploads
Privacy: Confidential AI (Presidio)

Key design decisions
  • • Data sanitization before any API call
  • • Agent generates applications (calculators, reports) — not just answers
  • • Multi-currency aware (EUR, USD, GBP, RON)
  • • User stays in control — agent suggests, human approves

From zero to production agent

Week 1-2 · FoundationDefine use case · Get API access · Choose framework · Set up environment
Week 3-4 · MVP AgentBuild basic agent · Connect 1-2 tools · Test with sample data · Iterate on prompts
Week 5-6 · Data IntegrationConnect real data sources · Implement sanitization · Add error handling · Security review
Week 7-8 · ProductionUser testing · Monitoring setup · Documentation · Go live with limited scope

Total: 8 weeks from start to basic production agent. Plan for iteration after.

Technical, organizational, data, budget

Technical

API key (OpenAI/Azure/Anthropic) · Python or TypeScript basics · A dev environment (local or cloud)

Organizational

IT/Security approval for AI APIs · Clear use case with measurable value · Stakeholder willing to test & iterate

Data

Sample data to start (CSV, Excel) · Access to real data sources (phase 2) · Data classification (what can/cannot leave)

Budget

MVP: $50-200/month (API costs) · Dev time: 1-2 people, 8 weeks · Production: varies by volume

Minimum to start experimenting

1 person with Python basics + 1 OpenAI API key ($20) + 1 clear use case + 1 month of sample data = working prototype in 1 week.

What can go wrong and how to prevent it

Hallucination — agent makes up numbers or facts

Validate outputs, cite sources, human review for critical decisions.

Data leakage — sensitive data sent to LLM provider

Sanitization layer, approved enterprise endpoints, local processing.

Wrong actions — agent executes a harmful operation

Approval workflows, read-only by default, sandbox testing.

Prompt injection — malicious input hijacks the agent

Input validation, system prompt protection, monitoring.

Over-reliance — users trust the agent blindly

Training, confidence scores, "agent suggests, human decides."

Golden rule: agents assist, humans decide. Never automate decisions without oversight.

Who's building AI agent capabilities for finance

Enterprise TMS + AI

Kyriba, ION Treasury, FIS — adding AI features to existing platforms.

Pro: Integrated · Con: Expensive, slow

Cloud AI Platforms

Microsoft Copilot, AWS Bedrock Agents — general purpose, need customization.

Pro: Scalable · Con: Not treasury-specific

Finance AI Startups

Vic.ai, Trullion, Digits, TreasuryOS — purpose-built for finance workflows.

Pro: Domain expertise · Con: Newer, smaller

Build Your Own

LangChain + OpenAI + your data — full control, fits exact needs.

Pro: Tailored · Con: Needs dev capacity

No single vendor does it all. Expect to combine platforms, APIs, and custom work.

✓ Course complete

Key takeaways

AI Agents ≠ chatbots. They reason, use tools, and take actions. This is new.

Four components: LLM (brain) + Tools (actions) + Memory (context) + Orchestrator (coordinator).

Technology is ready. LangChain, OpenAI, Azure — production-grade tools exist today.

Data privacy is solvable. Sanitization + approved endpoints + human oversight.

Start small. One use case, 8 weeks, working prototype. Learn by doing.

The question is not "if" but "how" and "when". Treasury teams that learn this now will lead.

Built by a treasurer, for treasurers. · treasuryease.com