
Building ShikshaMesh: A Policy-Aware Agentic Learning Platform on AWS
ShikshaMesh turns course material into an intelligent learning space using specialized AI agents, grounded retrieval, adaptive learning, and governed web research. This article explores how we designed it around Amazon Bedrock, SageMaker, Cognito, S3, Step Functions, EventBridge, and an AWS-native deployment roadmap.
Building ShikshaMesh: A Policy-Aware Agentic Learning Platform on AWS
What if an AI tutor did more than answer questions?
What if it could understand which course a student belongs to, retrieve only the material they are allowed to access, decide whether a question needs private course knowledge or live research, identify misconceptions, create adaptive practice, and collaborate with teachers — while keeping authorization outside the control of the language model?
That is the idea behind ShikshaMesh.
We built ShikshaMesh as an agentic learning platform where a student's course material becomes an interactive learning environment rather than a collection of static files.
Our goal was not to build another "chat with PDF" application.
We wanted to explore a harder question:
How do you build an AI learning system where multiple agents can use private knowledge, external information, learner context, and cloud tools without giving the AI unrestricted control?
The problem with a single AI tutor
A typical AI education application has a straightforward architecture:
Student → Prompt → LLM → Answer
That works surprisingly well for demonstrations.
But real learning systems quickly become more complicated.
Consider these requests:
- "Explain oxidation using my chemistry notes."
- "Quiz me on the topics I am weak at."
- "Where did my reasoning go wrong?"
- "Find the latest official information about this topic."
- "Find a useful video playlist for this chapter."
- "Let my teacher see which concepts the class is struggling with."
These are not the same task.
They require different data, different permissions, different tools, and sometimes completely different sources of knowledge.
So instead of asking one model to do everything, we designed ShikshaMesh around specialized agents and deterministic policy boundaries.
The ShikshaMesh architecture
At a high level, a request moves through the following pipeline:
Student Request
|
v
Authentication
|
v
Tenant / Class Scope
|
v
RBAC + ABAC Policy
|
v
Intent Router
|
v
Agent Orchestration
/ | \
/ | \
Tutor Research Assessment
Agent Agent Agent
| | |
v v v
Course Live Web Learner
Data Research State
\ | /
\ | /
v v v
Grounded ResponseThe important architectural decision is that authorization happens before agent execution.
The LLM can generate an explanation.
It does not get to decide whether the learner is authorized to access a particular class, document, or tool.
Agent 1: The grounded Tutor Agent
The Tutor Agent handles questions that can be answered from the student's authorized course material.
For example:
"Explain corrosion using the notes from my chemistry class."
The intended AWS-native retrieval flow is:
Student Question
|
v
Authorization
|
v
Course Retrieval
|
v
Amazon Bedrock
Knowledge Bases
|
v
Relevant Course Context
|
v
Amazon Bedrock
|
v
Grounded ExplanationCourse retrieval is scoped using trusted application context such as the institution and class.
This matters because retrieval itself is part of the security boundary.
A good answer is not enough.
It must be an answer generated from the right student's authorized knowledge.
Agent 2: The Research Agent
Private course material has another limitation: it is static.
Students sometimes need information that was not present when their notes were created.
For example:
"What is the latest official guidance related to this topic?"
This should not automatically cause the application to send the student's entire conversation or course context to a search engine.
ShikshaMesh therefore has a separate Research Agent.
Its workflow looks like this:
Research Intent
|
v
Authorization
|
v
Privacy-Safe Query
|
v
Source Policy
|
v
External Search
|
v
Normalized Results
|
v
Cited ResponseFor our live web intelligence layer, we integrated SerpApi.
This gives the agent access to current information while allowing our application to remain responsible for deciding when search is appropriate and what can leave the private learning environment.
External evidence is also kept conceptually separate from institution-provided course evidence.
That distinction is important.
A student's uploaded textbook and a web search result should not silently become the same type of source.
Governed search instead of unrestricted search
One of the most interesting parts of the project was treating search as an agent tool rather than simply attaching Google results to a chatbot.
Our research gateway can apply controls such as approved domains.
For example:
SERPAPI_ALLOWED_DOMAINS=ncert.nic.in,ugc.gov.inThe flow becomes:
Agent requests research
|
v
Is research required?
|
v
Is the user authorized?
|
v
Remove sensitive context
|
v
Apply domain policy
|
v
SerpApi
|
v
Normalize evidence
|
v
Return citations to agentThis design also allowed us to expose a read-only research capability through the Model Context Protocol without allowing an MCP client to bypass the same policy boundary.
SerpApi as a learning-resource discovery engine
We found another useful application for live search.
Sometimes a student does not need another AI-generated explanation.
They need a good external learning resource.
ShikshaMesh can search for topic-specific YouTube playlists using queries such as:
<topic> tutorial site:youtube.com/playlistThe application can then validate and deduplicate the returned playlist identifiers before presenting them as learning resources.
So live search becomes useful in two different ways:
Research intelligence
Question → Research Agent → SerpApi → Sourcesand:
Resource discovery
Topic → SerpApi → Learning ResourcesThis makes search part of the learning workflow rather than a separate browser experience.
Concept X-Ray: finding where reasoning breaks
Answer generation is only one part of learning.
Suppose a student reaches the wrong answer because of an incorrect assumption three steps earlier.
Simply showing the correct answer does not repair that misconception.
That motivated one of our core learning experiences: Concept X-Ray.
The intended flow is:
Student Explanation
|
v
Extract Reasoning
|
v
Retrieve Relevant Concepts
|
v
Find First Likely Misconception
|
v
Explain the Correction
|
v
Recovery Activity
|
v
Explain It BackInstead of only asking:
"Was the answer correct?"
we want the system to ask:
"Where did the learner's mental model first diverge from the concept?"
That information can eventually become useful not only to students but also to teachers.
Adaptive learning and learner state
ShikshaMesh also contains an adaptive assessment path.
Learner interactions can generate pseudonymous mastery signals that can eventually influence:
- question selection;
- difficulty;
- revision recommendations;
- topic sequencing;
- teacher interventions.
For experimentation, the project includes a Deep Knowledge Tracing path based on a GRU model.
We deliberately keep ML training separate from the normal application build.
Starting the web application should never unexpectedly launch an expensive training workload.
For hosted specialized models, our AWS architecture includes an Amazon SageMaker runtime adapter.
This allows components such as multilingual intent classification to eventually move from deterministic development logic to hosted ML inference.
Why Amazon Bedrock and SageMaker serve different roles
An important design decision was not to treat every AI problem as the same type of model problem.
We see Amazon Bedrock and Amazon SageMaker serving complementary roles.
Amazon Bedrock
Bedrock is suited to the generative and retrieval side of ShikshaMesh:
- grounded tutoring;
- explanation generation;
- agent reasoning;
- educational content generation;
- Bedrock Knowledge Bases.
Amazon SageMaker
SageMaker provides a path for specialized ML workloads:
- multilingual intent classification;
- learner modeling;
- mastery prediction;
- custom education models.
The architecture therefore looks roughly like:
User Request
|
v
Intent Classification
SageMaker
|
v
Agent Selection
|
+-------------------+
| |
v v
Private Retrieval External Research
Bedrock KB SerpApi
| |
+---------+---------+
|
v
Agent Generation
Amazon Bedrock
Authentication is not an AI problem
One principle guided a large part of our architecture:
Models generate. Policies authorize.
In production, ShikshaMesh is designed around Amazon Cognito for identity.
Verified claims can establish information such as:
- user identity;
- role;
- institution;
- tenant;
- class membership.
Those trusted claims then feed deterministic RBAC and ABAC rules.
This means a prompt cannot simply convince the model that a student is an administrator.
The model never owns that decision.
Building an AWS-native data layer
Our planned production data architecture combines several AWS services.
Amazon S3
Course documents can be uploaded into S3 and used as the ingestion source for the retrieval pipeline.
Amazon Bedrock Knowledge Bases
Bedrock Knowledge Bases provide the AWS-native RAG path for institution and class-scoped course retrieval.
Amazon RDS for PostgreSQL
The application uses PostgreSQL during development.
The production path uses Amazon RDS for PostgreSQL for structured information such as:
- courses;
- learner state;
- assessments;
- classroom information;
- mastery events;
- teacher analytics.
Qdrant
We also support Qdrant as an external vector-search option during development and experimentation.
The architecture deliberately allows local and cloud-backed implementations to coexist.
Orchestrating long-running workflows
Not every AI operation belongs inside a synchronous HTTP request.
Quiz generation, document processing, notifications, and multi-stage learning workflows may involve several operations.
Our AWS deployment roadmap therefore includes:
AWS Step Functions
For explicit multi-stage workflows such as:
Generate Quiz
|
v
Validate
|
v
Translate
|
v
Store
|
v
ScheduleThe repository already includes an application integration path and Terraform foundation for Step Functions.
AWS Lambda
Lambda is planned as the worker layer for asynchronous operations such as content processing and workflow tasks.
Amazon EventBridge
EventBridge provides a natural boundary for privacy-aware application and audit events.
Amazon SQS and Amazon SNS
SQS and SNS are part of the planned production architecture for buffering, retries, asynchronous jobs, notifications, and decoupled workflows.
Running the application
ShikshaMesh is packaged for containerized development using Docker.
The production runtime path is designed around either:
- Amazon ECS, or
- AWS App Runner.
The realtime classroom service can also run independently from the primary Next.js application.
This separation is useful because realtime collaboration and standard web requests have different scaling characteristics.
Observability and cost are architecture features
AI systems can become expensive surprisingly quickly.
A production ShikshaMesh deployment therefore also needs operational infrastructure.
Our roadmap includes Amazon CloudWatch for:
- application logs;
- workflow metrics;
- errors;
- operational dashboards;
- alarms.
We also plan to use AWS Budgets as a first-class guardrail.
This is especially important when experimenting with services such as generative AI and hosted ML endpoints.
A successful AI architecture should not only answer questions correctly.
It should also make its behavior and cost observable.
Offline-first learning
Connectivity cannot always be assumed in education.
ShikshaMesh therefore contains an offline-first foundation using a PWA, service worker, IndexedDB, and queued requests.
The important security property is that replay does not bypass authorization.
Student Action
|
Offline
|
v
IndexedDB Queue
|
Internet Returns
|
v
Replay
|
v
Server AuthorizationA queued privileged action still has to pass the server's authorization rules when connectivity returns.
What is implemented and what is next?
One thing we wanted to be careful about during the hackathon was distinguishing application integrations from infrastructure that has actually been provisioned.
The repository currently contains working application foundations including:
- LangGraph-oriented agent routing;
- governed SerpApi research;
- course retrieval;
- Cognito integration;
- S3 integration;
- Amazon Bedrock adapter;
- Bedrock Knowledge Base adapter;
- SageMaker runtime adapter;
- Step Functions integration;
- EventBridge integration;
- PostgreSQL persistence;
- Docker packaging;
- Terraform foundations;
- realtime classroom components;
- offline-first support.
Our next production deployment phase focuses on provisioning and connecting:
- Amazon ECS or AWS App Runner;
- Amazon RDS for PostgreSQL;
- production Bedrock Knowledge Bases;
- production SageMaker endpoints;
- Lambda workers;
- SNS/SQS infrastructure;
- CloudWatch dashboards and alarms;
- AWS Budgets.
Keeping these two categories separate matters.
An architecture diagram should describe where the system is going without pretending every cloud resource has already been deployed.
The production architecture
Our target AWS architecture can be summarized as:
Students / Teachers
|
v
Amazon Cognito
|
v
Next.js Application
ECS / App Runner
|
v
Policy + Agents
/ | \
/ | \
v v vBedrock SageMaker SerpApi
|
v
Bedrock Knowledge Bases
|
v
S3
Structured application state
|
v
RDS PostgreSQL
Async / workflow layer
|
+--------+---------+
| | |
Lambda Step Fn EventBridge
|
SNS / SQS
Observability
|
v
CloudWatch
AWS Budgets
What we learned
Building ShikshaMesh changed how we thought about AI application architecture.
The hardest part was not calling an LLM.
It was deciding:
- which agent should act;
- what that agent is allowed to see;
- which source should be trusted;
- when external research is appropriate;
- how evidence should be presented;
- how learner state should affect future actions;
- how asynchronous workflows should operate;
- and how all of this can remain observable.
That led us to a simple architecture principle:
Give agents capabilities, but keep authority in deterministic systems.
What's next
Our next milestone is moving more of the current application foundation into a complete AWS deployment.
We want to continue improving:
- Bedrock-grounded tutoring;
- multilingual intent routing through SageMaker;
- learner mastery models;
- misconception detection;
- adaptive assessments;
- teacher intervention signals;
- SerpApi-powered research;
- realtime classrooms;
- AWS-native observability.
Ultimately, ShikshaMesh is an experiment in what happens when an AI education product stops being a chatbot and starts becoming a learning operating system.
Not:
Student → Chatbot → AnswerBut:
Student
|
v
Policy
|
v
Agent Orchestration
|
+---- Private Knowledge
|
+---- Live Research
|
+---- Learner State
|
+---- Teacher Context
|
v
Personalized LearningThat is the system we are building with ShikshaMesh.
Enjoyed reading this content? Let the author know!
Your likes, comments, shares, and saves help creators reach more builders.
Loading recommendations
Loading article