Prompt-Grounded Architectural Style Retrieval: Matching Building Images with LLM-Generated Design Descriptions
DOI:
https://doi.org/10.69987/AIMLR.2026.70113Keywords:
architectural style, image-text retrieval, large language models, prompt engineering, building recognition, cross-modal embeddingAbstract
Architectural style retrieval requires a model to connect visible design evidence with language that is more specific than a class name. This study evaluates prompt-grounded retrieval on the BuildingStyles corpus, whose labeled manifest contains 456 square RGB images distributed across 24 architectural styles. GPT-5.5 Pro generated three concise, photograph-grounded descriptions for each style, yielding a frozen bank of 72 design descriptions. The Prompt-Grounded Architectural Retrieval (PGAR) pipeline represents every image with a 1,998-dimensional descriptor covering gradient structure, color, local texture, and edge profiles; reduces the descriptor to 128 principal components; and learns a ridge projection into a 64-dimensional text space constructed from word and character TF-IDF features. A training-fold-calibrated hybrid combines the projected prompt score with shrinkage linear discriminant scores. All 456 images were evaluated once as held-out cases through stratified five-fold cross-validation. For image-to-text retrieval, the hybrid reached Recall@1 of 28.73%, Recall@5 of 62.50%, and mean reciprocal rank of 0.4484. Relative to label-only prompts, Recall@5 increased by 7.68 percentage points and mean reciprocal rank by 0.0340; paired bootstrap intervals excluded zero for both differences. For text-to-image retrieval, the hybrid achieved the highest mean average precision, 0.2894, compared with 0.2447 for label-only queries. The experiments also quantify prompt composition, visual-feature contributions, per-style behavior, cluster overlap, dominant confusions, execution time, and robustness to six image perturbations. The results establish that LLM-generated visual descriptions improve deeper retrieval and bidirectional ranking, while architectural families with shared massing and classical vocabularies remain the principal source of error.

