Recipes¶
Location: inception_recipes/
Recipes are complete, end-to-end AI agent implementations for specific business use cases — ready to customize and deploy. They show how core libraries, accelerator patterns, and MCP servers combine into production systems.
Invoice Automation (invoice_automation/)¶
What it does¶
Automates the Oracle EBS Accounts Payable invoice lifecycle using a multi-agent pipeline:
- Daily trigger — a scheduled job runs before 8 AM, connects to EBS via OIC MCP, and retrieves pending invoices
- Classification agent — analyzes each invoice and routes it: auto-approved → Auto Pay Agent, exceptions → Review Agent
- Auto Pay Agent — processes approved invoices directly
- Review Agent — surfaces flagged invoices to an AP Manager dashboard with approve/hold actions
- Supplier Analysis Agent — spawns a 3-agent chain (Assessment → Preparation → Execution) to analyze cash flow, develop negotiation strategy, and email suppliers
Agent chain for supplier negotiation¶
Negotiate Terms Agent
└─ spawns: Contract Assessment Sub-Agent (cash flow analysis)
└─ spawns: Contract Preparation Sub-Agent (strategy development)
└─ spawns: Contract Execution Sub-Agent (email generation → Email MCP)
Episodic memory for replay¶
Agents store every action in Oracle 26ai with vector embeddings:
SELECT memory_id, content, context, timestamp
FROM episodic_memories
WHERE VECTOR_DISTANCE(embedding, :query_vector) < 0.3
AND timestamp >= SYSDATE - 7
ORDER BY timestamp DESC
FETCH FIRST 10 ROWS ONLY
This enables natural-language replay queries like: "How and what invoice got auto-paid on Feb 01 at 9 AM?"
Technology stack¶
| Layer | Technology |
|---|---|
| Frontend | React + Vite + Tailwind CSS |
| Backend API | FastAPI (port 8001) |
| MCP server | ADW MCP (port 8003) |
| Database | Oracle Autonomous Data Warehouse |
| Auth | IDCS SSO → API Gateway → IAM DB token exchange |
| Integration | OIC MCP Server for EBS write-back |
| Memory | Oracle 26ai vector store (episodic + semantic) |
Security model (defence in depth)¶
- SSO via IDCS — no anonymous access
- IAM group verification — role gate before any tool runs
- IAM DB token exchange — short-lived, user-scoped token; no shared credentials
- VPD row-level security —
AP_SUPPLIERS_SLIMfiltered byAP_Clerkrole - EBS shielded via OIC — agents never access EBS directly; all writes via OIC workflow
Running locally¶
cd inception_recipes/invoice_automation
mkdir -p src/backend/logs
source src/backend/venv3.13/bin/activate
# Start MCP server (port 8003)
nohup python src/backend/mcp_adw_server.py > src/backend/logs/mcp_server.log 2>&1 &
# Start FastAPI backend (port 8001)
nohup python src/backend/fastapi_app.py > src/backend/logs/fastapi.log 2>&1 &
# Start React frontend (port 5173)
npm run dev
Smart Dispatch (smart_dispatch/)¶
What it does¶
A multi-agent field service dispatch system that automates call intake, signal triage, and technician dispatch using a coordinated LangGraph agent fleet backed by Oracle ADB and OCI GenAI. A caller describes a device issue; the system identifies the service record, diagnoses the root cause, surfaces KB guidance, and recommends a governed next action — with full cross-turn memory.
Agent topology¶
Customer
→ Call-Intake Agent (llama-4-scout-17b) — conversational triage + entity extraction
→ Memory Agent — Oracle Store cache hit/miss router (~2s)
HIT → answer from memory
MISS → Contract Agent (gemini-2.5-pro) — MCP SQL deep research (up to 20 calls)
→ [HITL: "Would you like to schedule a dispatch?"]
YES → Dispatch Agent — Fusion Studio ping + dispatch report
NO → Farewell node — session summary
Authentication model¶
Two complementary login flows:
| Client | Flow | Token location |
|---|---|---|
| Web UI | IDCS OAuth2 Authorization Code | Server-side session + HttpOnly sd_session cookie |
| CLI | OCI API key → token exchange (RFC 8693) | In-memory cache, auto-refreshed |
The web login redirects to IDCS, exchanges the code server-side, stores the token in a Map<sessionId, {...}>, and sets an HttpOnly cookie — the token never touches the browser. The CLI signs a POST to the IDCS token endpoint with the machine's OCI API key and caches the resulting Bearer token for the session.
CLI¶
cd inception_recipes/smart_dispatch/smart_dispatch_agents
uv run python -m src.cli.smart_dispatch # login via OCI API key
uv run python -m src.cli.smart_dispatch --session <id> # resume session
Startup sequence: OCI API key exchange → MCP SQLcl probe (connect + ALTER SESSION + SELECT * FROM DUAL) → "Connected to SIDECARADB_HIGH" → REPL.
Technology stack¶
| Layer | Technology |
|---|---|
| Frontend | React + Vite (:8000) |
| API Gateway | Node.js / Express (:7002) + OCI API key token exchange |
| AI Orchestration | LangGraph StateGraph |
| Agents | create_oci_agent (intake), create_deep_research_agent (contract) |
| LLM | llama-4-scout-17b (intake/memory/dispatch) · gemini-2.5-pro (contract) |
| Data access | FastMCP SQLcl server (:3001) |
| Memory | OracleDBSaver (conversation) + OracleStore (structured + vector) |
| Python backend | FastAPI (:7001) |
| Observability | LangFuse tracing |
Business value¶
| Metric | Before | After |
|---|---|---|
| Handle time per claim | 15–30 min | < 3 min |
| Availability | Business hours | 24/7 self-service |
| Cost per claim | Baseline | 40–60% reduction |
| Customer satisfaction | Baseline | 30–50% improvement |
See the Smart Dispatch Architecture page for full details: LangGraph workflow, auth flows, memory namespaces, MCP integration, and the
create_deep_research_agentmiddleware stack.
Meridian Bank (meridian_bank/)¶
What it does¶
A loan intake and underwriting system built around a 3-peer swarm (concierge / products / loan_application) — the platform's flagship swarm example. A customer chats freely between general questions, product/rate questions, and applying for a loan, all within one session; the approve/decline/refer decision itself is a plain deterministic Python function, never an LLM call, so the highest-stakes boundary in the recipe has zero model non-determinism.
Two independent frontend deployments sharing one backend — a Meridian customer website (username/password, no IDCS) and a Meridian admin console (IDCS SSO, Officer Queue with a live conversation-trail view) — because the two actors have genuinely different identity models, not because of an oversight.
Technology stack¶
| Layer | Technology |
|---|---|
| Frontend | React + Vite (×2 — customer + admin) |
| Gateways | Node.js/Express (×2), one per UI |
| Orchestration | LangGraph swarm — concierge/products (create_oci_agent), loan_application (deterministic pipeline wrapper) |
| Agents | intake, memory-cache, underwriting-research, decision, customer-auth, transcript |
| LLM | llama-4-scout-17b (fast tier) · gemini-2.5-pro (underwriting, products) |
| Data access | FastMCP SQLcl |
| Memory | OracleDBSaver (conversation) + OracleStore (application/decision cache) |
| Observability | LangFuse tracing + durable LOAN_AUDIT_LOG + officer-facing live activity log |
| Evaluation | metro.evals (AE-09) — 4 case files, CI-gated |
See the Meridian Bank Architecture page for the full swarm topology, authentication model, memory namespaces, and evaluation suite.
EBS Invoice Reconciliation (ebs_invoice_reconciliation/)¶
What it does¶
An agent-assisted three-way match pipeline for supplier invoices: detects a new invoice in an OCI Object Storage inbox, extracts it via real OCI Document Understanding, validates it against approved suppliers/purchase orders/goods receipts, and prepares a reconciliation draft — never posting to EBS or releasing a payment autonomously. The matching engine is deterministic Python with zero LLM calls, which doubles as its own prompt-injection defense: the classifier has no code path that reads a line item's free-text description at all.
This platform's own architecture shields EBS behind Oracle Integration Cloud — no direct EBS tool exists — so the recipe's oic_client.py names that eventual boundary today as a stub against its own stand-in tables, swappable for a real OIC call later with no interface change.
Technology stack¶
| Layer | Technology |
|---|---|
| Backend API | FastAPI (Exception Queue + Approval Queue routes) |
| Orchestration | LangGraph — a fixed pipeline (Prompt Chaining + one Routing step), not a swarm |
| Agents | extraction, deterministic matching, draft, exception |
| Extraction | OCI Document Understanding (tools/dus2_tool.py), called directly — never via a model tool-call loop |
| Data access | FastMCP SQLcl (own AP_* schema) + FastMCP Object Storage (inbox polling) |
| Database | Shared Oracle ADB, AP_* tables coexisting with LOAN_*/CANON_* by prefix |
| Evaluation | metro.evals (AE-09) — 4 case files, CI-gated |
See the EBS Invoice Reconciliation Architecture page for the full matching-rules table, the live end-to-end validation writeup, and the real bugs it surfaced.
Why recipes matter¶
- Translate patterns into systems — shows exactly how accelerator patterns wire together with real data and real auth
- Reusable conventions — folder structure, agent topology, and integration patterns are copy-paste ready
- Onboarding accelerator — new team members see a working system, not abstract diagrams
- Contribute your own — the recipe backlog is community-driven; every recipe on this page after Invoice Automation and Smart Dispatch was built with Inception Skills's
recipe-builderskill from a one-paragraph use case, not hand-scaffolded — see that page for how to submit the next one