Skip to content

Glossary: Multi-Agent Systems

Lock

Also written: threading.Lock

A tool that lets only one thread at a time run a block of code under `with self.lock:`. It stops two agents finishing at once from losing a budget update.

Where the book teaches it

Related terms

ThreadBudgetLost update