Conventional communications systems centered on data prioritize maximizing network throughput using Shannon's theory, which is primarily concerned with securely transmitting the data despite limited radio resources. However, in the realm of edge learning, these methods frequently fall short because they depend on traditional source coding and channel coding principles, ultimately failing to improve learning performance. Consequently, it is crucial to transition from a data-centric viewpoint to a taskoriented communications approach in wireless system design. Therefore, in this paper, we propose efficient communications under a task-oriented principle by optimizing power allocation and edge learning-error prediction in an edge-aided non-orthogonal multiple access (NOMA) network. Furthermore, we propose a novel approach based on the ant colony optimization (ACO) algorithm to jointly minimize the learning error and optimize the power allocation variables. Moreover, we investigate four additional benchmark schemes (particle swarm optimization, quantum particle swarm optimization, cuckoo search, and butterfly optimization algorithms). Satisfactorily, simulation results validate the superiority of the ACO algorithm over the baseline schemes, achieving the best performance with less computation time. In addition, the integration of NOMA in the proposed task-oriented edge learning system obtains higher sum rate values than those achieved by conventional schemes.INDEX TERMS task-oriented communication, edge learning, non-orthogonal multiple access (NOMA), learning error, ant colony optimization (ACO).