@@ -13,7 +13,7 @@ import { pathContainsDirectorySegment } from './pathUtils';
1313interface ConverterCommand {
1414 command : string ;
1515 args : string [ ] ;
16- usesPythonConverter : boolean ;
16+ supportsConversionOptions : boolean ;
1717 description : string ;
1818 env ?: NodeJS . ProcessEnv ;
1919}
@@ -367,8 +367,9 @@ export class MarkitdownConverter {
367367 try {
368368 let args = [ ...converterCommand . args ] ;
369369
370- if ( converterCommand . usesPythonConverter ) {
371- // Pass extract images configuration to Python converter
370+ if ( converterCommand . supportsConversionOptions ) {
371+ // Both the Windows script path and the packaged macOS binary
372+ // delegate to converter.py and support the same argument contract.
372373 const extractImages = this . configManager . shouldExtractImages ( ) ;
373374 const outputPath = this . getOutputPath ( filePath ) ;
374375 const imageOutputFolder = this . configManager . getImageOutputFolder ( ) ;
@@ -385,9 +386,9 @@ export class MarkitdownConverter {
385386 // Process the markdown content to handle images if needed
386387 let markdownContent = stdout ;
387388
388- if ( this . configManager . shouldExtractImages ( ) && ! converterCommand . usesPythonConverter ) {
389+ if ( this . configManager . shouldExtractImages ( ) && ! converterCommand . supportsConversionOptions ) {
389390 // Only do additional image processing if we didn't use Python converter
390- // Python converter already includes intelligent image extraction
391+ // Integrated converters already include image extraction.
391392 markdownContent = await this . processImages ( filePath , markdownContent ) ;
392393 }
393394
@@ -544,7 +545,7 @@ export class MarkitdownConverter {
544545 commands . push ( {
545546 command : runtime . pythonPath ,
546547 args : [ embeddedConverterPath ] ,
547- usesPythonConverter : true ,
548+ supportsConversionOptions : true ,
548549 description : `${ runtime . pythonPath } ${ embeddedConverterPath } ` ,
549550 env : {
550551 DOCUGENIUS_AUTO_INSTALL_DEPS : '0'
@@ -562,7 +563,7 @@ export class MarkitdownConverter {
562563 commands . push ( {
563564 command : embeddedBinaryPath ,
564565 args : [ ] ,
565- usesPythonConverter : false ,
566+ supportsConversionOptions : true ,
566567 description : embeddedBinaryPath
567568 } ) ;
568569 }
0 commit comments