ConvPE: Convolutional Position Embedding Improves Transformers

Zehao Wang
11/5/2026
cs.LG
transformer-attention

Official code: wzhagi/convpe (1 star, Jupyter Notebook, last commit 2026-11-06).

Abstract

ConvPE (Convolutional Position Embedding) improves both the performance and efficiency of Transformer models in language modeling, long-context extension, and vision. It injects a windowed, content-dependent bias into attention scores through a lightweight causal convolution over a low-dimensional projection of the hidden states.

Show full abstract

As a lightweight plug-in, ConvPE is compatible with RoPE, attention masks, and KV concatenation. It also supports high-dimensional position embeddings via high-dimensional convolutions. In a reproduction, ConvPE outperforms five 1D baselines and eight 2D baselines. The code is publicly available at https://github.com/wzhagi/convpe.

View on arXivView PDF

Code Implementations(1)

wzhagi/convpeOfficial100%

ConvPE improves Transformer performance and efficiency in language modeling, long-context extension, and vision.

10Jupyter Notebook, PythonOct 15, 20263 weeks ago

Similar Papers

Cite this paper

@article{wang2026convpe,
  title  = {ConvPE: Convolutional Position Embedding Improves Transformers},
  author = {Zehao Wang},
  year   = {2026},
  eprint = {2611.07749},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2611.07749v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2611.07749.svg)](https://codeofpaper.com/paper/2611.07749)

Discussion