It is estimated that there will be approximately 125 billion Internet of Things (IoT) devices connected to the Internet by 2030, which are expected to generate large amounts of data. This will challenge data processing capability, infrastructure scalability, and privacy. Several studies have demonstrated the benefits of using distributed intelligence (DI) to overcome these challenges. We propose a Mobile-Agent Distributed Intelligence Tangle-Based approach (MADIT) as a potential solution based on IOTA (Tangle), where Tangle is a distributed ledger platform that enables scalable, transaction-based data exchange in large P2P networks. MADIT enables distributed intelligence at two levels. First, multiple mobile agents are employed to cater for node level communications and collect transactions data at a low level. Second, high level intelligence uses a Tangle based architecture to handle transactions. The Proof-of-Work offloading computation mechanism improves efficiency and speed of processing, while reducing energy consumption. Extensive experiments show that transaction processing speed is improved by using mobile agents, thereby providing better scalability.