def _process_ts_code(self, code: str) -> str:
        """Process TypeScript code into a more structured text representation.

        This method:
        1. Preserves file-level JSDoc comments
        2. Extracts imports and exports
        3. Extracts class, interface, type, and function definitions with their comments
        4. Preserves TypeScript-specific type annotations
        """
        # Split into lines for processing
        lines = code.splitlines()
        result = []

        # Extract file-level comments
        file_comment = self._extract_file_comment(code)
        if file_comment:
            result.append("FILE COMMENT:")
            result.append(file_comment)
            result.append("")

        # Extract imports and exports
        imports_exports = self._extract_imports_exports(lines)
        if imports_exports:
            result.append("IMPORTS/EXPORTS:")
            result.extend(imports_exports)
            result.append("")

        # Extract definitions (class, interface, type, function)
        definitions = self._extract_definitions(code)
        if definitions:
            result.append("DEFINITIONS:")
            result.extend(definitions)

        return "\n".join(result)
Process TypeScript code into a more structured text representation.

        This method:
        1. Preserves file-level JSDoc comments
        2. Extracts imports and exports
        3. Extracts class, interface, type, and function definitions with their comments
        4. Preserves TypeScript-specific type annotations
        
py/core/parsers/text/ts_parser.py