DEV Community

Deepika bhuvaneshwaran
Deepika bhuvaneshwaran

Posted on

Building Chain of Custody: Exploring AI Agent Safety with Python and FastAPI

Building Chain of Custody: Exploring AI Agent Safety with Python and FastAPI

As AI agents become more capable, one important question comes to mind:

How can we make AI agent actions safer, more transparent, and easier to review?

As a Computer Science and Engineering student interested in AI agents and cloud technologies, I explored this question by building a project called Chain of Custody — AI Agent Safety and Decision Monitoring.

🚀 What is Chain of Custody?

Chain of Custody is a web-based dashboard designed to help users review proposed AI agent actions, evaluate potential risks, and inspect safety decisions.

The project focuses on three possible outcomes:

  • PROCEED: Allow an action when it meets the applicable safety checks.
  • CONFIRM: Require additional human review before proceeding.
  • DENY: Block an action that fails the applicable safety checks.

These outcomes help demonstrate how a safety-review workflow can make agent actions easier to understand.

🛠️ Technology Stack

I used the following technologies to build the application:

  • Python for backend logic.
  • FastAPI for API endpoints.
  • HTML, CSS, and JavaScript for the web interface.
  • Strands Decider integration to explore AI-assisted action evaluation.
  • Vercel for deployment.
  • GitHub for source control.

🖥️ Key Features

1. Dashboard

Provides an overview of the application's safety-monitoring workflow.

2. Inbox

Provides an interface for reviewing incoming requests.

3. Agent Run

Allows proposed actions to be evaluated and displays a PROCEED, CONFIRM, or DENY outcome.

4. Flight Recorder

Provides an interface for inspecting decision records and improving visibility into the review process.

🧠 What I Learned

Building this project helped me explore how a backend API and frontend dashboard work together. It also gave me practical experience with deployment, API testing, GitHub, and designing interfaces for AI safety workflows.

One important lesson is that an AI-generated decision should not automatically be treated as a guarantee of safety. Real-world systems need appropriate authorization checks, human oversight, testing, and reliable audit records.

🔭 What's Next?

I plan to improve production testing, verify the hosted Decider connection through the deployed application, and explore Amazon Bedrock integration.

These improvements will help me develop a more complete understanding of building and deploying responsible AI applications.

🔗 Try the Project

Live demo: https://chain-of-custody.vercel.app/

Source code: https://github.com/Deepika20053/chain-of-custody

I'm continuing to learn about AI agents, cloud technologies, and responsible software development. I'd love to hear how other developers approach safety and oversight in agentic applications.

AWS #AIAgents #Python #FastAPI #AISafety

Top comments (0)