def _create_continuation_offer_response(self, content: str, continuation_data: dict, request) -> ToolOutput:
        """
        Create a response offering Claude the opportunity to continue conversation.

        Args:
            content: The main response content
            continuation_data: Dict containing remaining_turns and tool_name
            request: Original request for context

        Returns:
            ToolOutput configured with continuation offer
        """
        try:
            # Create new thread for potential continuation
            thread_id = create_thread(
                tool_name=self.name, initial_request=request.model_dump() if hasattr(request, "model_dump") else {}
            )

            # Add this response as the first turn (assistant turn)
            request_files = getattr(request, "files", []) or []
            add_turn(thread_id, "assistant", content, files=request_files, tool_name=self.name)

            # Create continuation offer
            remaining_turns = continuation_data["remaining_turns"]
            continuation_offer = ContinuationOffer(
                continuation_id=thread_id,
                message_to_user=(
                    f"If you'd like to continue this analysis or need further details, "
                    f"you can use the continuation_id '{thread_id}' in your next {self.name} tool call. "
                    f"You have {remaining_turns} more exchange(s) available in this conversation thread."
                ),
                suggested_tool_params={
                    "continuation_id": thread_id,
                    "prompt": "[Your follow-up question or request for additional analysis]",
                },
                remaining_turns=remaining_turns,
            )

            return ToolOutput(
                status="continuation_available",
                content=content,
                content_type="markdown",
                continuation_offer=continuation_offer,
                metadata={"tool_name": self.name, "thread_id": thread_id, "remaining_turns": remaining_turns},
            )

        except Exception as e:
            # If threading fails, return normal response but log the error
            logger = logging.getLogger(f"tools.{self.name}")
            logger.warning(f"Conversation threading failed in {self.name}: {str(e)}")
            return ToolOutput(
                status="success",
                content=content,
                content_type="markdown",
                metadata={"tool_name": self.name, "threading_error": str(e)},
            )

        Create a response offering Claude the opportunity to continue conversation.

        Args:
            content: The main response content
            continuation_data: Dict containing remaining_turns and tool_name
            request: Original request for context

        Returns:
            ToolOutput configured with continuation offer
        
tools/base.py