1
Create a client
You need an API key and project ID from the Reflect console.
2
Run the learning loop
The If no memories exist yet,
client.trace() context manager handles the full loop in one block - it queries memories on entry, and auto-submits the trace with the correct retrieved_memory_ids on exit:ctx.augmented_task returns the original task unchanged.3
Query memories again
The generated reflection now appears in future queries:
Feedback text is typically attached by judge workflows or through the platform review UI. SDK/API calls usually submit only the review result (
pass or fail).