Skip to main content
Version: July 12, 2026

Capstone: Chat2Action

Chat2Action — ERPNext Task Assistant with RAG Helpdesk


Real-World Problem Statement​

Business owners, team leads, and operations managers often don't have time to open ERP dashboards just to assign, update, or review tasks. Tasks are frequently delegated informally (messages/DMs) or kept in memory, which leads to missed deadlines, duplicated work, and miscommunication.

This mini-capstone builds a chat-based assistant that performs real task operations in ERPNext (Frappe) and also provides a RAG-powered helpdesk that answers "how to use ERPNext tasks" questions grounded in official documentation.


Project Scope​

A) Action Mode (ERPNext Integration — Mandatory)​

The chatbot must execute actions in real ERPNext via REST APIs (Frappe).

Task Operations (Doctype: Task)

  • Create task (title, assignee required; due date recommended)
  • Update task (title, due date, status, assignee)
  • Delete/cancel task
  • List tasks:
    • by user (assignee)
    • by status (Open / Working / Completed, etc.)
    • by due date window (today/this week)

User Resolution

  • Mention-based assignee selection (e.g., "Ali") mapped to ERPNext users

ERP Adapter Layer

  • A dedicated service/module wrapping ERPNext calls:
    • create_task(), update_task(), cancel_or_delete_task(), list_tasks()
    • get_users() (for assignee lookup)

B) Knowledge Mode (RAG using ERPNext Docs — Mandatory)​

The chatbot must answer ERPNext workflow questions using Retrieval-Augmented Generation grounded in ERPNext documentation.

RAG Content Source (Required)

  • ERPNext official documentation related to Tasks/Projects (minimum: ~10-20 pages worth of content)

Required RAG Features

  • Document ingestion pipeline (download → clean → chunk)
  • Vector indexing (FAISS/Chroma/Pinecone—any is fine)
  • Retrieval (top-k) + answer generation
  • Citations: every answer must cite doc chunk(s) or source URLs
  • Hallucination control: if not found in docs, refuse safely

C) Interface & System Requirements​

  • REST API backend (FastAPI recommended)
  • Web chat UI (React/Streamlit/Gradio; simple but usable)
  • Dockerized run (ERPNext + backend + UI via docker-compose)
  • Logging + basic error handling
  • Basic auth for your backend (simple token/API key is enough)

Out of Scope (Not Required)​

  • Invoice generation / Sales Invoice integration
  • Training custom ML models
  • Building a full ERP system
  • Payment systems
  • Enterprise SSO
  • Advanced analytics dashboards
  • Complex multi-tenant permissions (optional bonus)

Expected Time to Complete​

Total Duration: 1-2 weeks (7-12 days)

Day 1–2: ERPNext Setup + API Connectivity

  • Run ERPNext via Docker
  • Create API key/secret
  • Verify: list users, create a Task, update a Task

Day 3–4: Action Mode (Chat → Intent → ERP Adapter)

  • Implement intent routing: create/update/delete/list tasks
  • Implement disambiguation (multiple matching tasks)
  • Add input validation (required fields, dates)

Day 5–6: RAG Pipeline

  • Ingest ERPNext doc
  • Chunk + embed + index
  • Implement Knowledge Mode answers with citations + refusal

Day 7–8: UI

  • Chat UI with loading states and clear confirmations
  • Show citations in the UI for RAG answers

Day 9–12: Polish + Tests + Documentation

  • Logging, error handling, retries
  • README + short write-up
  • Demo assets

Deliverables​

1) Working Code (GitHub Repository)​

Repository must include:

  • Backend service (FastAPI)
  • ERP adapter module (ERPNext REST wrapper)
  • RAG ingestion + retrieval module
  • Frontend UI
  • Docker Compose setup to run the full stack

Minimum "one command" run:

  • docker compose up --build

2) README Documentation​

Must include:

  • Project overview (Action Mode + Knowledge Mode)
  • Architecture diagram (image or Mermaid)
  • Setup instructions (ERPNext + backend + UI)
  • Environment variables
  • API examples (curl) for task
  • Example chat commands (5+)
  • RAG explanation (sources, chunking, embeddings, citations)
  • Refusal behavior definition (when docs do not contain answer)

3) Short Technical Write-Up (1–2 pages)​

Include:

  • Architecture decisions
  • ERP integration approach (Task doctype, key endpoints)
  • NLP approach (intent + entities + disambiguation)
  • RAG pipeline details (chunking, vector DB, retrieval)
  • Challenges + solutions
  • Future improvements

4) Demo Assets​

Provide either a short demo video (preferred) or screenshots + transcripts.

Must show:

  1. Create a Task via chat → visible in ERPNext UI
  2. Update a Task via chat → visible in ERPNext UI
  3. List tasks for a user/date range via chat
  4. Ask an ERPNext question → answered with citations (RAG)
  5. Ask an unrelated question → safe refusal ("not found in docs")

Evaluation Rubric​

Sufficient​

  • ERPNext runs locally via Docker
  • Chat can create and list Tasks in ERPNext
  • Basic RAG answers at least some "Task" questions with ≥1 citation
  • Basic UI exists
  • README includes setup steps

Minimum acceptance tests

  • "Assign task to Ali due tomorrow" creates a Task in ERPNext
  • "How do I assign a task in ERPNext?" returns a grounded answer with citation

Good (Competent)​

  • Full Task works reliably (create/update/cancel-or-delete/list)
  • Listing filters work (by user + status + due window)
  • RAG answers are consistently cited and mostly correct
  • Disambiguation implemented (if multiple tasks match)
  • Modular code structure (services)
  • 5+ test scenarios documented

Excellent (Exceptional)​

  • Robust NLP handling (missing fields, multiple intents, better entity extraction)
  • RAG upgrades:
    • hybrid retrieval (BM25 + dense) or reranking
    • strong refusal accuracy (low hallucination)
    • multiple citations when needed
  • Production polish
    • retries/backoff for ERPNext API
    • automated tests + 10 scenarios
    • an additional system command
  • Bonus:
    • voice input STT (optional) integrated cleanly

Good luck with your challenge! This project combines NLP, RAG, and real-world system integration - skills highly valued in modern AI engineering.

Roadmap AssistantRoadmap Assistant