About our project

NextChapter is a Malaysia-oriented agentic AI pathway planner that helps users turn their current condition and dream life into realistic, step-by-step life and career pathways.

Users enter two things: where they are now and where they want to be. NextChapter then asks follow-up questions when needed, plans 1-3 possible pathways, calculates financial feasibility in RM/MYR, and shows practical roadmap steps with sacrifices, risks, and reasoning.

Inspiration

We were inspired by how difficult it can be for Malaysian students and young adults to make big life decisions with incomplete information. Many people know their dream, but they do not know the actual pathway, cost, salary expectation, timeline, or sacrifices needed to reach it.

We wanted to build something that does not just say “follow your dream,” but helps users understand:

  • what steps they can take
  • what trade-offs they may face
  • whether their timeline is realistic
  • what financial pressure may appear
  • what assumptions the AI is using

The goal is not to replace human decision-making, but to give users a clearer starting point for their next chapter.

What it does

NextChapter generates personalized pathway plans using a four-agent AI workflow:

  1. CollectInfo Agent understands the user’s current condition and dream life, then asks one follow-up question at a time.
  2. Planning Agent creates 1-3 possible pathways and uses web grounding when fresh career or market context is needed.
  3. Calculation Agent performs deterministic financial and feasibility calculations in RM/MYR.
  4. Output Agent formats the final pathway flowcharts, reasoning, sacrifice notes, and detailed step guidance.

Each pathway includes:

  • step-by-step roadmap
  • estimated feasibility score
  • projected salary
  • expected NPV
  • break-even point
  • sacrifice or mismatch conditions
  • detailed execution steps
  • Malaysia-based assumptions by default

The financial model uses formulas such as:

$$ NPV = \sum_{t=1}^{n} \frac{Salary_t - LivingCost_t - EducationCost_t}{(1 + r)^t} $$

where (r) is the discount rate and (t) is the year.

How we built it

We built NextChapter using:

  • Next.js for the frontend and API routes
  • React for the interface
  • TypeScript for safer data structures
  • FreeLLMAPI as the unified LLM provider layer
  • Gemini Google Search grounding when live web context is useful
  • Supabase for saved pathway history and web-grounding cache
  • Malaysia dataset for local salary, education, cost-of-living, and source assumptions

We designed the app around a simple interface:

  • current condition input
  • dream life input
  • generate pathway button
  • one-at-a-time follow-up questions
  • final pathway flowcharts
  • show details panel

Behind that simple UI, the backend runs a multi-stage agent pipeline. We also added resumable generation using browser localStorage, so if a long AI generation process times out or the page refreshes, the app can continue from the saved stage instead of forcing the user to start over.

Challenges we ran into

One major challenge was balancing AI flexibility with reliability. We wanted the AI to understand open-ended goals like becoming an actor, TCM practitioner, AI engineer, or clinic owner, while still preserving the user's exact intent instead of forcing every dream into a generic career template.

Another challenge was token usage. Web search is useful, but repeatedly searching for similar career information wastes API budget. We solved this by adding a Supabase-backed web-grounding cache with strict intent matching, so cached context supports the planning process without changing what the user actually asked for.

We also faced timeout problems during long pathway generation. Instead of reducing output quality, we split generation into stages:

  • search decision
  • web grounding
  • planning candidates
  • calculation
  • complete

This made the system more resilient without making the final answer shorter or less detailed.

Accomplishments that we're proud of

We are proud that NextChapter became more than a basic AI chatbot. It now has:

  • a clear four-agent architecture
  • Malaysia-first assumptions
  • deterministic financial formulas
  • one-at-a-time follow-up questions
  • web grounding when needed
  • cached search context to reduce API waste
  • Supabase history
  • resumable generation
  • clickable roadmap steps with detailed guidance

We are also proud of keeping the interface simple even though the backend became much more powerful.

What we learned

We learned that agentic AI systems need both creativity and structure. The LLM is good at understanding messy human goals, but formulas, schemas, validation, caching, and guardrails are needed to make the output more reliable.

We also learned that “probability” can be misleading, so we reframed it as an estimated feasibility score. A dream like winning an Oscar should not be treated the same way as a standard local career pathway. The system now accounts for ambition level, rarity, risk, and evidence.

Most importantly, we learned that good AI products are not just about generating answers. They are about asking the right questions, showing assumptions clearly, and helping users think better.

What's next for NextChapter

Next, we want to improve NextChapter with:

  • better career and education datasets
  • appplicable in different country
  • stronger citation quality for web-grounded sources
  • more accurate salary and cost-of-living updates
  • user accounts for cross-device history
  • deeper pathway comparison
  • better support for different language
  • improved recommendation scoring based on real outcomes and user feedback

Our long-term vision is for NextChapter to become a trusted planning companion for Malaysians making education, career, financial, and life-path decisions.

Built With

Share this project:

Updates