Cách backend vận hành
Ba mươi quyết định tạo nên backend agent của chúng tôi — cách hoạt động, lý do chọn và điều chúng tôi học được. Kèm code và ví dụ.
Bộ định tuyến rẻ, người viết mạnh: decision model trong vòng lặp ReAct
Quyền chọn tool call thuộc về decision model, phần viết đối số thuộc về chat call, và fail-closed guard lo chuyện không để sửa đổi bị bỏ rơi.
Mô hình quyết định & điều phối
01–073/7Không phải đối số tool nào cũng cần một mô hình riêng
Cách điền một đối số phụ thuộc vào dạng của nó: code tất yếu, một decision call, hoặc chat model.
Guardrail chỉnh sửa action space
Bỏ end_agent_run khỏi câu hỏi, hỏi lại và nêu rõ lý do. Viết prompt to hơn chẳng ích gì.
A Dedicated DECISION Model Role
Why decisions are their own harness role with separate MANAGED and BYOK semantics.
Decision-Field Extraction Before the Agent
Pre-compute stated choice fields outside the ReAct loop and attribute them to the extractor.
Two Retry Layers, Fresh Checkpoint Namespaces
Model retries and whole-editor-run retries, with |retry-N isolating failed attempts.
Hiding Helper-Model Internals Twice Over
Wire-level reasoning suppression plus the langsmith:nostream tag.
Giao thức agent tùy biến
08–151/8Sự kiện LangGraph v3 chưa đủ làm API: projection, replay và retraction
streamEvents v3 vẫn mang nhãn thử nghiệm và phản ánh cấu trúc bên trong engine. Phía trên nó, chúng tôi dựng protocol có kiểu riêng với Socket.IO rooms, replay và retraction.
Feature Descriptors as the Transport Contract
One descriptor declares the bus channel, WS event, room prefix and scope.
Subagent Attribution From a Namespace Tree
Deepest-prefix matching on checkpoint namespaces attributes nested delegated runs.
Retract Streamed Messages by ID
Accumulate deltas per messageId, discard the abandoned bubble, commit only the keeper.
Live-Only Notices vs Append-Only Replay
What the UI shows is not what the log stores — and both share the same sequence.
Event-Time Stamping for Coherent Replay
Stamp backend-generated events with the last engine timestamp so replay order holds.
Typed Human-in-the-Loop Over Untyped Channels
Resume correlation, decision validation and re-seeded tool calls on interrupt.
Joining Callback Spans to Protocol Events
A one-shot map turns a tool card into a deep link to its exact trace span.
Tính xác định bên ngoài agent
16–200/5A Middleware That Stops Tool Loops
Canonical argument comparison blocks repeated successful calls; failed retries stay legal.
Hiding Internal Pricing From the LLM
Data minimization as a hallucination and exfiltration defense.
Compiled Rules That Can Replace a Model Reply
Plugin hooks return jumpTo and result; side effects are once-guarded and fail open.
Explainability for Non-LLM Decisions
PLUGIN_EFFECT and PLUGIN_OUTCOME events with stable pluginCallId and source path.
Media Understanding as an Honest Pre-Step
Typed skip reasons rendered into the prompt instead of pretending extraction happened.
Phiên bản, tạo mã & môi trường an toàn
21–280/8Git-Like Releases in MongoDB With CAS
Immutable revisions, append-only file maps and a compare-and-swap environment pointer.
Per-Thread Copy-on-Write Workspaces
A conversation owns a pointer map; opening it copies ObjectIds, not bytes.
Commit as an Optimistic Transaction
Source guard, artifact validation, a deterministic test suite, release, CAS, event log.
Mark-and-Sweep GC for Immutable Releases
Reachability-based cleanup with event-log pinning and an in-flight merge cutoff.
Time-Travel Thread Forking
Branch an agent conversation by checkpoint, message or turn index — with rollback.
A VM Sandbox With Two Independent Timeouts
Allow-listed globals, no code generation, and a Promise deadline for async hooks.
The Catalog Accessor as Capability and Audit Log
Every read becomes pricing provenance; direct data access is statically rejected.
One Source of Truth: Zod → TypeScript → JS
Schema interfaces rendered into generated artifacts and validated on write.
Quan sát & tự phục hồi
29–300/2MongoDB as a Drop-In LangSmith Tracer
Keep LangChain run DTOs, swap the backend, derive lean summaries at read time.
Self-Healing Turn State
Lost-run detection, stale interrupt hiding and self-expiring retry notices.
Không có bài nào khớp.