Loop Engine and LLM Commerce Gateway integrate to let AI query live commerce data, generate recommendations, and require human approval before write operations execute.
procurement.loop: full implementation with governed approval and post-approval order placement.pricing.change: loop definition with actor stubs.inventory.adjustment: loop definition with actor stubs.
- AI actor (
runProcurementRecommendation) calls read-only Commerce Gateway endpoints:GET /inventory/:skuGET /demand-forecast/:skuGET /suppliers/:sku
- Automation actor (
executeApprovedPurchaseOrder) performs the write:POST /purchase-orders
- Human actor is the only actor allowed to execute
approve_orderandreject_order.
import { getLoopSystem, CommerceGatewayClient } from "./src/index";
const gatewayClient = new CommerceGatewayClient({
baseUrl: process.env.COMMERCE_GATEWAY_URL,
apiKey: process.env.COMMERCE_GATEWAY_API_KEY
});
const { engine } = await getLoopSystem();Pricing and inventory adjustment actor implementations are pending. See docs for roadmap callouts.