Inspiration

Across Nigeria, thousands of community associations, credit cooperatives, and small non-profits operate on tight budgets and thin administrative staff. In organizations like the Ikeja Community Cooperative, the treasurer routinely loses productive morning hours manually cross-referencing messy NIBSS bank alerts against paper or spreadsheet dues records. Worse, office prepaid electricity meters frequently run out mid-meeting, halting operations.

We built EquiTrade Guardian to take these two repetitive, error-prone burdens entirely off their shoulders.


What it does

EquiTrade Guardian is an autonomous, local-first agent built with the Strands Agents SDK that handles routine administrative busywork in the background and only interrupts humans when a genuine decision is required:

  • Automated Payment Reconciliation: Ingests incoming transfer alerts modeled on ISO 20022 / NIBSS transaction formats (EndToEndId, debtor name, amount) and cross-references them with open invoices. It reconciles automatically only when the invoice reference is unique, the amount is exact, and debtor identity matches.
  • Deterministic Human-in-the-Loop Safeguards: When an alert is missing a reference, has an amount discrepancy (e.g., partial payment), or has an unrecognizable payer, the agent never guesses. Instead, it flags the issue with clear rationale and queues it for human review.
  • Prepaid Power Guard: Continuously monitors the office IKEDC prepaid electricity meter balance. When power falls below critical safety thresholds (₦1,000), it initiates a top-up through a simulated VendPower API. If the required amount exceeds the safe auto-approval limit (₦2,000), it explicitly pauses and requests treasurer consent before executing.

How we built it

  • Strands Agents SDK: Orchestrates reasoning, step-by-step planning, and tool execution using an open-source local model (qwen2.5:7b via Ollama) for zero-cloud-cost, privacy-preserving community deployment.
  • Deterministic Policy Engine (engine.py): Financial matching rules and spend limit caps are enforced directly in Python tool logic. The LLM orchestrates and explains, but cannot hallucinate a match or bypass financial thresholds.
  • Operations Dashboard (dashboard.py): A lightweight, responsive web interface that allows the treasurer to inspect live status, resolve flagged exceptions, and approve or deny utility purchases.
  • Realistic Local Fixtures: Built with simulated Nigerian payment switch (NIBSS) and disco vending (VendPower) data so the entire system runs offline and reliably end-to-end.

Architecture

[NIBSS / ISO 20022 Alerts] & [IKEDC Meter Telemetry] │ ▼ Strands Agent Orchestrator │ ▼ [Deterministic Policy & Spend Guard] ├── Exact Match? ────► [Reconciled Dues Ledger] ├── Ambiguity? ────► [Human Exception Queue] └── Low Power? ────► [VendPower API / Token Top-Up]


Challenges we ran into

  • Bridging Probabilistic AI and Financial Precision: Large language models are probabilistic by nature, but financial ledgers and utility budgets require 100% deterministic accuracy. We resolved this by giving the Strands agent tool-level guardrails: the model proposes and explains, but the tool code strictly validates and executes.
  • Designing for Resource-Constrained Environments: Small local cooperatives often lack reliable cloud budgets and constant internet connectivity. We prioritized lightweight, local inference using Ollama so the solution can run directly on an office laptop.

Accomplishments that we're proud of

  • Zero-Hallucination Safety: Complete separation of concerns between model reasoning and financial policy execution—no phantom dues matches or unauthorized spending.
  • Seamless Dual Interface: Users can run the autonomous Strands agent in the terminal or use the clean web operations dashboard to inspect matches and review exceptions.
  • Realistic Localization: Accurately reflecting the day-to-day workflow and pain points of Nigerian grassroots cooperatives (NIBSS payment references, IKEDC prepaid tokens, and communal dues).

What we learned

  • Tool-Level Constraints Over Prompting: Prompt engineering can express intent, but hard code constraints in agent tools are the only dependable way to guarantee safety in financial and procurement workflows.
  • Autonomous Agents for the "Good Neighbor" Space: While enterprise agents often focus on corporate sales and analytics, community organizations benefit immensely from agents that automate low-glamour, high-friction chores like ledger reconciliation and utility top-ups.

What's next for EquiTrade Guardian

  • Live Webhook Ingestion: Direct integrations with Paystack, Flutterwave, and Monnify sandboxes for live transaction webhooks.
  • Two-Way WhatsApp Bot: An interactive WhatsApp/Telegram integration enabling treasurers to approve over-limit electricity purchases with a single reply text.
  • Solar & Inverter Telemetry: Extending meter monitoring to hybrid solar inverters and battery storage for community facilities.

Built With

Share this project:

Updates

Submission history