๐ Building an AI Immigration Compliance Copilot with AWS Serverless + Amazon Bedrock
Navigating U.S. immigration compliance as an F-1 OPT/STEM OPT student is stressful.
Deadlines, unemployment limits, and reporting rules can feel overwhelmingโand small mistakes can have serious consequences.
So I built an AI-powered system to help simulate scenarios, analyze risk, and provide real-time guidance.
This project was built for the AWS 10,000 AIdeas Competition, and it reached the Top 300 semi-finalists.
๐ก What I Built
AI Immigration Compliance Copilot is an interactive system that helps students:
๐
Generate OPT/STEM OPT timelines
โ ๏ธ Analyze compliance risk (Low / Medium / High)
๐ Simulate โwhat-ifโ scenarios (job loss, unemployment changes, etc.)
๐ค Ask AI questions about their situation in real time
๐ Receive structured recommendations based on USCIS-style rules
๐ง Why I Built It
Most immigration resources are:
static
confusing
or hard to interpret in real-world scenarios
I wanted to build something that could:
Turn complex immigration rules into interactive decision-making support.
Not just informationโbut simulation + reasoning.
๐๏ธ System Architecture
The system is fully serverless on AWS:
๐น Frontend
Amazon S3 Static Website Hosting
TypeScript-based UI
Real-time updates via API calls
๐น Backend
AWS Lambda (Node.js 20.x)
Handles:
timeline calculations
unemployment tracking
risk classification
scenario simulation logic
๐น API Layer
Amazon API Gateway (REST API)
7 endpoints:
POST /timeline โ Generate OPT timeline
POST /scenarios โ Risk analysis
POST /simulator โ Run simulations
GET /sessions/{id} โ Retrieve saved state
POST /ai/explain โ AI explanations
POST /ai/chat โ Q&A assistant
POST /ai/assist โ General guidance
๐น Data Layer
Amazon DynamoDB
Stores:
session state
user inputs
calculated results
30-day TTL for automatic cleanup
๐น AI Layer
Amazon Bedrock (Claude 3 Haiku)
Used for:
natural language explanations of compliance risk
conversational โwhat-ifโ questions
contextual guidance based on user scenario
๐น Orchestration
Kiro (AI development assistant)
Used for:
structured prompting
refining AI responses
enforcing consistency in outputs
๐ How It Works
User enters OPT/STEM OPT details
Frontend sends request to API Gateway
Lambda processes compliance logic
DynamoDB stores session state
Bedrock generates AI explanations
UI updates in real time
๐งช Example Scenario
A student inputs:
OPT start date: June 1
70 days of unemployment used
Recently lost job
The system:
recalculates remaining unemployment allowance
flags HIGH compliance risk
generates AI explanation of consequences
suggests next actions (e.g., secure employment within X days, contact DSO)
โ๏ธ Hybrid Design: Rules + AI
One of the key design decisions was combining:
Deterministic logic (backend)
ensures accuracy for timelines and calculations
AI reasoning (Bedrock)
explains outcomes in human language
helps interpret complex edge cases
This hybrid approach ensures:
โ accuracy
โ clarity
โ flexibility
๐งฉ Key Learnings
Serverless architecture makes scaling this kind of tool simple and cost-efficient
AI is most powerful when paired with deterministic logic
Real-world problems often require simulation, not just answers
Clear UX is just as important as backend logic
๐ Competition Outcome
This project was built for the AWS 10,000 AIdeas Competition and was selected as a:
๐ฅ Top 300 semi-finalist out of thousands of global submissions
๐ Whatโs Next
Planned improvements include:
Amazon EventBridge for compliance reminders
SNS/SES for email alerts
Multi-language support
Deeper multi-turn AI memory
Mobile app via AWS Amplify
โ ๏ธ Disclaimer
This tool is for educational purposes only and does not constitute legal advice.
Users should consult their Designated School Official (DSO) or immigration attorney for official guidance.
๐ Closing Thoughts
This was a great exercise in combining:
cloud architecture
AI reasoning systems
real-world compliance logic
Still building. Still learning.
If youโre building with AWS or working on AI systems, Iโd love to connect and exchange ideas.
Link to the my Build Article here:
Top comments (0)