Network traffic classification is a cornerstone of network management and security. Addressing the challenges of feature extraction in encrypted traffic and the deployment limitations of traditional deep learning models on resource-constrained edge devices due to their large parameter sizes, this paper proposes a lightweight network for encrypted traffic classification, termed CEMA-Net (Convolutional Positional Encoding and Efficient Multi-scale Attention Network). Specifically, the proposed model integrates an Efficient Multi-scale Attention (EMA) mechanism with a Convolutional Positional Encoding (CPE) strategy to jointly capture global dependencies and local contextual information. To enable efficient adaptation to traffic data, an Efficient Multi-scale Attention Adapter (EMAAdapter) is designed, which reconstructs one-dimensional traffic sequences into a pseudo-2D representation and extracts horizontal, vertical, and local features in parallel. This design facilitates effective modeling of complex cross-scale dependencies in encrypted traffic with minimal computational overhead. Experimental results on three public datasets demonstrate that the proposed method, with only 0.66 M parameters, achieves superior classification performance compared with mainstream vision-based models such as ResNet-101, while significantly reducing computational cost. These results highlight the effectiveness of combining convolutional positional encoding with multi-scale attention mechanisms and provide an efficient solution for encrypted traffic classification in resource-constrained environments.
Parameter tuning based adapter methods have achieved notable success in vision-language models (VLMs). However, they face challenges in scenarios with insufficient training samples or limited resources. While leveraging image modality caching and retrieval techniques can reduce resource requirements, these approaches often overlook the significance of textual modality and cross-modal cues in VLMs. To address this, we propose a Conditional Cross-Modal learning model, which is abbreviated as CoCM. CoCM builds separate cache models for both the text and image modalities and embedding textual knowledge conditioned on image information. It dynamically adjusts the cross-modal fusion affinity ratio and disentangles similarity measures across different modalities. Additionally, CoCM incorporates intra-batch image similarity loss as a regularization term to identify hard samples and enhance fine-grained classification performance. CoCM surpasses existing methods in terms of accuracy, generalization ability, and efficiency, achieving a 0.28% accuracy improvement over XMAdapter across 11 datasets and demonstrating 44.79% generalization performance on four cross-domain datasets.
The chain-of-thought technique has been received well in multi-modal tasks. It is a step-by-step linear reasoning process that adjusts the length of the chain to improve the performance of generated prompts. However, human thought processes are predominantly non-linear, as they encompass multiple aspects simultaneously and employ dynamic adjustment and updating mechanisms. Therefore, we propose a novel Aggregation-Graph-of-Thought (AGoT) mechanism for soft-prompt tuning in multi-modal representation learning. The proposed AGoT models the human thought process not only as a chain but also models each step as a reasoning aggregation graph to cope with the overlooked multiple aspects of thinking in single-step reasoning. This turns the entire reasoning process into prompt aggregation and prompt flow operations. Experiments show that our multi-modal model enhanced with AGoT soft-prompting achieves good results in several tasks such as text-image retrieval, visual question answering, and image recognition. In addition, we demonstrate that it has good domain generalization performance due to better reasoning.