Taking digital technology as the core driving force, this paper systematically explores the innovative application of MIDI technology and computer music tools in classroom teaching, and proposes an intelligent retrieval framework based on semantic features and data mining and a resource sharing incentive model, aiming to optimize the efficiency of teaching resource allocation. The study realizes accurate retrieval of educational resources by constructing a music resource data extraction model and a semantic feature distribution structure model, combined with weight division and ontology library matching. The average retrieval time of the semantic feature extractionbased retrieval method for 10 high-frequency keywords is only 30.5ms, which is 75.9% and 55.9% shorter than that of the traditional method (126.4ms) and meta-search engine (69.2ms), respectively. The average optimization of the retrieval path length is 22.6%, which verifies its high efficiency in the massive data environment. Further testing of the system load performance by JMeter tool reveals that in the scenario of 4000 concurrent users, the throughput (TPS) of resource uploading and downloading reaches 268 items/s and 403 items/s, respectively, but the performance decreases after the number of users exceeds 4000, which suggests that it is necessary to optimize the allocation of server resources. Resource sharing tests for different file sizes show that IPFS latency increases significantly with file size, with upload/download latency of 0.24s/0.42s for 1MB files and 16.30s/27.64s for 150MB files, indicating that IPFS+blockchain architecture is more suitable for small and medium-sized file sharing. In addition, blockchain transaction latency is higher for resource uploading, e.g., 100MB file takes 11.58s, while download latency is mainly dominated by IPFS transmission, verifying the complementary advantages of the technical architectures.