diff --git a/src/llmling/prompts/__init__.py b/src/llmling/prompts/__init__.py index e11571e..3c5e62d 100644 --- a/src/llmling/prompts/__init__.py +++ b/src/llmling/prompts/__init__.py @@ -1,4 +1,3 @@ -from llmling.prompts.manager import PromptManager from llmling.prompts.models import ( ExtendedPromptArgument, Prompt, @@ -10,7 +9,6 @@ __all__ = [ "ExtendedPromptArgument", "Prompt", - "PromptManager", "PromptMessage", "PromptRegistry", "create_prompt_from_callable", diff --git a/src/llmling/prompts/manager.py b/src/llmling/prompts/manager.py deleted file mode 100644 index a4379fb..0000000 --- a/src/llmling/prompts/manager.py +++ /dev/null @@ -1,60 +0,0 @@ -"""Prompt management and composition.""" - -from __future__ import annotations - -from typing import TYPE_CHECKING - -from llmling.core.log import get_logger -from llmling.core.typedefs import Message, MessageContent - - -if TYPE_CHECKING: - from llmling.tools.base import LLMCallableTool - - -logger = get_logger(__name__) - - -class PromptManager: - """Manages prompt composition and system prompts.""" - - def create_messages( - self, - *, - system_content: str | None = None, - user_content: str | None = None, - content_items: list[MessageContent] | None = None, - tools: list[LLMCallableTool] | None = None, - ) -> list[Message]: - """Create message list for LLM interaction. - - Args: - system_content: Optional system message content - user_content: Optional user message content - content_items: Optional list of content items - tools: Optional list of tools being used - - Returns: - List of messages for LLM - """ - messages: list[Message] = [] - - # Add system message if provided - if system_content: - msg = Message(role="system", content=system_content) - messages.append(msg) - - # Add tool system prompts if any - messages.extend( - Message(role="system", content=t.system_prompt, name=t.name) - for t in tools or [] - if t.system_prompt - ) - - # Add user content - if user_content or content_items: - items = content_items or [] - msg = Message(role="user", content=user_content or "", content_items=items) - messages.append(msg) - - return messages