Saved in:
Bibliographic Details
Main Authors: Bystroński, Mateusz, Piotrowski, Grzegorz, Chawla, Nitesh V., Kajdanowicz, Tomasz
Format: Preprint
Published: 2025
Subjects:
Online Access:https://arxiv.org/abs/2508.02452
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866916879803613184
author Bystroński, Mateusz
Piotrowski, Grzegorz
Chawla, Nitesh V.
Kajdanowicz, Tomasz
author_facet Bystroński, Mateusz
Piotrowski, Grzegorz
Chawla, Nitesh V.
Kajdanowicz, Tomasz
contents Recent advances have shown that optimizing prompts for Large Language Models (LLMs) can significantly improve task performance, yet many optimization techniques rely on heuristics or manual exploration. We present LatentPrompt, a model-agnostic framework for prompt optimization that leverages latent semantic space to automatically generate, evaluate, and refine candidate prompts without requiring hand-crafted rules. Beginning with a set of seed prompts, our method embeds them in a continuous latent space and systematically explores this space to identify prompts that maximize task-specific performance. In a proof-of-concept study on the Financial PhraseBank sentiment classification benchmark, LatentPrompt increased classification accuracy by approximately 3 percent after a single optimization cycle. The framework is broadly applicable, requiring only black-box access to an LLM and an automatic evaluation metric, making it suitable for diverse domains and tasks.
format Preprint
id arxiv_https___arxiv_org_abs_2508_02452
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle LatentPrompt: Optimizing Promts in Latent Space
Bystroński, Mateusz
Piotrowski, Grzegorz
Chawla, Nitesh V.
Kajdanowicz, Tomasz
Computation and Language
Recent advances have shown that optimizing prompts for Large Language Models (LLMs) can significantly improve task performance, yet many optimization techniques rely on heuristics or manual exploration. We present LatentPrompt, a model-agnostic framework for prompt optimization that leverages latent semantic space to automatically generate, evaluate, and refine candidate prompts without requiring hand-crafted rules. Beginning with a set of seed prompts, our method embeds them in a continuous latent space and systematically explores this space to identify prompts that maximize task-specific performance. In a proof-of-concept study on the Financial PhraseBank sentiment classification benchmark, LatentPrompt increased classification accuracy by approximately 3 percent after a single optimization cycle. The framework is broadly applicable, requiring only black-box access to an LLM and an automatic evaluation metric, making it suitable for diverse domains and tasks.
title LatentPrompt: Optimizing Promts in Latent Space
topic Computation and Language
url https://arxiv.org/abs/2508.02452