Developing Chatbots, RAG Applications and Agentic AI with Python

  • TTDT09
  • Classroom
  • Fundamental
  • Thai | 0
AI & Data Technology

พัฒนาแอปพลิเคชัน Generative AI ด้วย Python ผ่านโครงงานต่อเนื่อง ตั้งแต่แชตบอตพื้นฐาน ระบบถามตอบจากเอกสารด้วย Retrieval-Augmented Generation (RAG) ไปจนถึง AI Agent ที่เรียกใช้เครื่องมือภายใต้ขอบเขตที่กำหนด เน้นการสร้างต้นแบบ การทดสอบ และการใช้งานอย่างปลอดภัย

Course description

Time
Days :
3 Day(s)
Duration :
18 Hour(s)
Time :
09:00:00 - 16:00:00
Training Date :
วันที่ 16-18 กุมภาพันธ์ 25670
Status :
Open Register
Instructor
Language :
Thai
Venue
Venue :
ห้องอบรมชั้น 3 อาคารซอฟต์แวร์พาร์ค
Type :
Classroom
Developing Chatbots, RAG Applications and Agentic AI with Python

  • เข้าใจการทำงานและข้อจำกัดของ LLM และเลือกใช้ prompting, RAG หรือ tool calling ให้เหมาะกับโจทย์
  • พัฒนาแชตบอตด้วย Python โดยจัดการคำสั่ง ประวัติการสนทนา และผลลัพธ์แบบมีโครงสร้าง
  • สร้างระบบ RAG จากเอกสารภาษาไทยและอังกฤษ พร้อมแหล่งอ้างอิงและการตอบเมื่อข้อมูลไม่เพียงพอ
  • สร้าง AI Agent ที่ใช้เครื่องมือได้อย่างจำกัด ตรวจสอบข้อมูลนำเข้า และขอการอนุมัติจากผู้ใช้ในขั้นตอนที่จำเป็น
  • ทดสอบคุณภาพคำตอบ ความปลอดภัย เวลาในการตอบ และการใช้โทเคนของแอปพลิเคชันต้นแบบ


นักพัฒนาซอฟต์แวร์ นักวิทยาศาสตร์ข้อมูล นักวิเคราะห์ข้อมูล และบุคลากรด้าน IT ที่มีพื้นฐาน Python และต้องการพัฒนาแอปพลิเคชัน Generative AI

Prerequisites and Preparation:
เขียน Python พื้นฐานได้ ได้แก่ functions, lists, dictionaries, JSON และการอ่านไฟล์ โดยไม่จำเป็นต้องมีพื้นฐาน deep learning 

Day 1: Building Chatbots with Python
Goal: Build a working chatbot and understand how to control and test its responses.
Outcome: A runnable Python chatbot with session history, a reusable API wrapper and a small test set. Participants can explain its behavior, limits and basic operating-cost drivers.
Practical Focus: One selected model and one starter application are used throughout the course. Model training, detailed transformer mathematics and a full Python refresher are outside the core workshop scope.
09.00–10.30  หัวข้อ LLM foundations and application design
     • Generative AI, chatbots, RAG and agents: capabilities, limitations and suitable business use cases.
     • Tokens, context windows and generated responses; hallucinations, privacy and model-selection trade-offs.
     • Compare prompting, retrieval and fine-tuning at a conceptual level; define the scope of a document-assistant prototype.
10.45–12.00  หัวข้อ Calling an LLM from Python
     • Prepare the Python project and call a selected model API using its SDK; keep credentials outside source code.
     • Work with instructions and messages; handle responses, timeouts and API errors, and inspect token usage.
     • Lab 1: Implement a reusable model-call function and test it with a small set of Thai and English questions.
13.00–14.30  หัวข้อ Prompting and conversation state
     • Use clear instructions, examples and constraints; compare responses against defined acceptance criteria.
     • Maintain per-session conversation history and limit context growth; distinguish application state from model memory.
     • Introduce schema-based structured output and validate returned data; a valid structure does not guarantee factual accuracy.
14.45–16.00  หัวข้อ Chatbot workshop and testing
     • Lab 2: Build a multi-turn chatbot with a simple interface from a starter project, session reset and basic error handling.
     • Test normal questions, ambiguous requests and out-of-scope prompts; compare prompt revisions on the same questions.
     • Record response quality, latency and token usage; document known limitations and avoid logging secrets or private input.

Day 2: Building RAG Applications
Goal: Extend the chatbot to answer questions from a controlled document collection with traceable evidence.
Outcome: A working RAG prototype over a small Thai/English document collection, with visible source references and a repeatable evaluation worksheet. Participants can identify whether a failure begins in ingestion, retrieval or answer generation.
Practical Focus: Use approved sample documents and a small local or workshop vector store. Production document permissions, large-scale ingestion and managed deployment are design considerations rather than complete implementations.
09.00–10.30  หัวข้อ Preparing a document knowledge base
     • Understand the RAG pipeline: ingest, split, embed, retrieve and generate; distinguish retrieval failures from generation failures.
     • Load sample text files and text-based PDFs; clean text and preserve document names, page references and other source metadata.
     • Handle Thai and English text and chunk boundaries; compare chunk size and overlap. Scanned-PDF OCR is outside the core lab.
10.45–12.00  หัวข้อ Embeddings and semantic retrieval
     • Create embeddings and a small vector index; retrieve relevant chunks by similarity and inspect the actual retrieved content.
     • Explore top-k retrieval and metadata filtering; discuss keyword or hybrid retrieval and reranking as possible improvements.
     • Lab 3: Build an index and evaluate whether the expected source passages appear for a small question set.
13.00–14.30  หัวข้อ Grounded answers and source references
     • Pass retrieved context to the model, require source references and show the evidence used for each answer.
     • Handle missing or conflicting evidence and out-of-scope questions; define when to abstain or ask for clarification.
     • Treat document text as untrusted data; discuss prompt injection, document permissions and safe handling of confidential information.
14.45–16.00  หัวข้อ RAG workshop and evaluation
     • Lab 4: Extend the Day 1 chatbot into a document Q&A assistant with retrieved sources and an insufficient-evidence response.
     • Use answerable, unanswerable and misleading questions to assess retrieval relevance, groundedness, answer correctness and citation support.
     • Change one retrieval or prompt setting at a time; compare results, latency and token usage against a baseline.

Day 3: Developing Agentic AI Applications
Goal: Combine document retrieval and limited tools into a testable, controlled assistant prototype.
Outcome and Capstone Deliverables:
A runnable Python prototype that combines a chatbot, document-based RAG and a bounded tool-using workflow, accompanied by setup instructions, an evaluation record and a limitations checklist.
Completion criteria: demonstrate a source-supported answer; abstain when evidence is missing; perform a valid tool call; reject invalid tool input; stop at the configured limit; and show that a simulated action does not execute when approval is denied.
The course develops a guided prototype, not an unsupervised or production-ready autonomous system. Multi-agent orchestration, fine-tuning and production deployment are optional follow-on topics.
09.00–10.30  หัวข้อ Tool calling and bounded agent workflows
     • Distinguish a fixed workflow from an agent that selects tools; identify where deterministic code is preferable.
     • Define tool names, descriptions, input schemas and return values; validate arguments before executing Python functions.
     • Lab 5: Add a document-search tool and one safe calculator or read-only lookup tool. The application, not the model, executes each call.
10.45–12.00  หัวข้อ Control, safety and observability
     • Implement a bounded tool-use loop with maximum steps, timeouts, error handling and a clear stopping condition.
     • Restrict allowed tools and inputs; defend against instructions embedded in documents or tool results, and avoid arbitrary code execution.
     • Add a human-approval gate using a simulated action; log tool decisions and results without exposing credentials or sensitive data.
13.00–14.30  หัวข้อ Integrated capstone workshop
     • Lab 6: Integrate chatbot history, RAG and a limited agent workflow into one document-assistant application.
     • Return grounded answers with source references, call a tool only when needed and display approval requests clearly.
     • Package the prototype with configuration instructions, a small test dataset and documented limits; reuse the starter interface.
14.45–16.00  หัวข้อ Evaluation, demonstration and next steps
     • Run tests for grounded Q&A, tool selection and invalid arguments, insufficient evidence, prompt-injection attempts, denied approval and step-limit exhaustion.
     • Review correctness, citation support, tool-call outcomes, latency and token usage; demonstrate the application and explain failures.
     • Outline requirements before real deployment: authentication, access controls, secrets management, monitoring, data governance and regression tests.

Payment can be made by:

  1. Cash or Credit Card or Bank Cheque payable to
    สำนักงานพัฒนาวิทยาศาสตร์และเทคโนโลยีแห่งชาติ or National Science and Technology Development Agency
    (a post-dated cheque is not accepted) on the first day of the service or within the last day of the service.

  2. Account transfer and send the proof of the payment (the deposit slip) via email xxx@swpark.or.th

    • ธนาคารกรุงเทพ สาขาอุทยานวิทยาศาสตร์
      Saving Account Number: 080-0-00001-0
      Account Name: สำนักงานพัฒนาวิทยาศาสตร์และเทคโนโลยีแห่งชาติ

    • ธนาคารกรุงไทย สาขาตลาดไท
      Saving Account Number: 152-1-32668-1
      Account Name: สำนักงานพัฒนาวิทยาศาสตร์และเทคโนโลยีแห่งชาติ

Notes:

  • Withholding tax (3%) is exempt.
  • Should you need to withdraw, you must send the notice of the withdrawal in writing no later than 7 working days before the commencement date. The cancellation less than 7 days will be subject to a fine of 40% of the fee.
  • Software Park Thailand reserves the rights to cancel courses due to unforeseen circumstances.

Contact Person

For more information, contact our course coordinator on:

Juntima  Klumchaun
 : 02 583 9992 Ext. 81424
swp
You are encouraged to use the course schedule as a guide to plan your training. The schedule is accessible at www.swpark.or.th for more information.
เพิ่มเพื่อน

12,000 THB .

วันที่ 16-18 กุมภาพันธ์ 2570 เวลา 09.00-16.00 น.
ณ ห้องอบรม ชั้น 3 อาคารซอฟต์แวร์พาร์ค

Download => เอกสารประชาสัมพันธ์หลักสูตร

สำคัญ!!! กรุณารอการยืนยันเปิดการอบรมจากเจ้าหน้าที่ก่อนการชำระค่าลงทะเบียน

Enroll now

Course Detail :
Days :
3 Day(s)
Duration :
18 Hour(s)
Time :
09:00:00 - 16:00:00
Training Date :
วันที่ 16-18 กุมภาพันธ์ 25670
Status :
Open Register

Instructor info
avatar
Dr.Veerasak Krisanapraphan

CIO