Autonomous Agents in Finance
🇹🇭 ภาษาไทย
Autonomous Agents (อ้างอิงจากบทที่ 24 ของหนังสือ Machine Learning for Algorithmic Trading) พูดถึงการประยุกต์ใช้ Agentic Workflows ในสายการเงิน โดยไม่เน้นให้ Agent สั่งซื้อขายอัตโนมัติ (Execution) แต่เน้นไปที่งาน “Read-only” เช่น การวิจัยข้อมูล การสืบค้นเอกสาร และการประเมินความน่าจะเป็น (Forecasting) เพื่อให้มนุษย์ตัดสินใจขั้นสุดท้าย
ประเด็นสำคัญ (Key Takeaways)
- Cognitive Architectures: ไม่ได้ใช้แค่โมเดลสถิติหรือ ML แบบเดิม แต่ใช้ Framework อย่าง ReAct (เน้นหาหลักฐาน), Tree of Thoughts (หาทางเลือกที่แตกแขนง) และ Reflexion (วิจารณ์ผลลัพธ์และเรียนรู้จากข้อผิดพลาด)
- Memory and State: การทำงานในสายการเงินต้องอ้างอิงได้ (Auditability) ดังนั้นหน่วยความจำของ Agent จึงถูกออกแบบอย่างชัดเจน แบ่งเป็น Working Memory, Short-term Session Memory และ Long-term Persistent Memory เพื่อให้สามารถเช็คจุดเซฟ (Checkpointing) และทำซ้ำ (Replay) เพื่อตรวจสอบการตัดสินใจได้เสมอ
- Tool Contracts & Context Engineering: คุณภาพของ Agent ทางการเงินขึ้นอยู่กับเครื่องมือ (Tools) มากกว่าแค่โมเดลที่ดี โดยต้องมีการเขียน Contract ชัดเจน และใช้ “Warden pattern” เพื่อคัดกรองข้อมูลเข้า/ออก ป้องกันการถูกโจมตีแบบ Prompt Injection
- Multi-Agent Forecasting: เมื่อใช้ Agent หลายตัวในการพยากรณ์ร่วมกัน จะต้องมีกลไกปรับเทียบความน่าจะเป็น (Calibration) และจัดการความเบี่ยงเบน เพื่อให้ผลลัพธ์น่าเชื่อถือระดับที่นำไปใช้งานจริง (Production-grade)
🇬🇧 English
Autonomous Agents (from Chapter 24 of Machine Learning for Algorithmic Trading) discusses the application of agentic workflows in finance. The focus is deliberately constrained to “read-only” information actions—such as retrieving data, querying filings, and structured forecasting—rather than direct order execution.
Key Takeaways
- Cognitive Architectures: Moving beyond conventional statistical pipelines, it leverages ReAct (for evidence-grounded loops), Tree of Thoughts (for parallel hypothesis exploration), and Reflexion (for post-run critique).
- Memory and State Design: To meet strict auditability requirements in finance, agent memory is explicitly designed across three tiers: working, short-term, and long-term memory. This enables deterministic validation, checkpoint-based replays, and non-deterministic system debugging.
- Tool Contracts & Security: The quality of financial agents is often determined by their tools. Robust tool contracts, strict source policies, and security patterns (like the “Warden pattern”) are crucial to prevent prompt injection and guarantee reproducible evidence.
- Multi-Agent Forecasting in Production: Transitioning from notebook prototypes to multi-agent forecasting systems requires layers of aggregation, calibration, ablation analysis, and operational health monitoring to ensure the outputs are decision-grade.