bluk DITA-to-Json conversion

Post here questions and problems related to editing and publishing DITA content.
jeff_hooker
Posts: 18
Joined: Tue Jun 11, 2019 9:01 pm

bluk DITA-to-Json conversion

Post by jeff_hooker »

Hi folks,
I've got a team who wants to convert an immense volume of DITA content into Json for the purposes of using it for a machine learning project. Is there a way of accessing the DITA-to-Json tool from the command line?
Thanks,
Jeff.
chrispitude
Posts: 922
Joined: Thu May 02, 2019 2:32 pm

Re: bluk DITA-to-Json conversion

Post by chrispitude »

Hi Jeff,

If you have a license for Oxygen Scripting, you can run it from the command line as described here:

Scripting Oxygen > Batch Converter

The usage given is as follows:

Code: Select all

sh scripts/batchConverter.sh -i inputFiles -if inputFormat -o outputDirectory 
-of outputFormat [-ss (true|false)] [-csd (true|false)] [-cs converterSettingsFile]
syed
Posts: 78
Joined: Tue Nov 14, 2017 8:34 pm

Re: bluk DITA-to-Json conversion

Post by syed »

Hi,
What would be the free option to convert DITA to JSON?
xephon
Posts: 163
Joined: Mon Nov 24, 2014 1:49 pm
Location: Greven/Germany

Re: bluk DITA-to-Json conversion

Post by xephon »

You can also write your own transformation type and publish the content to JSON. After preprocessing you have a merged XML file and it should be quite easy to convert this to JSON with Saxon. If you don't know how to do it, you can ask a DITA consultant.
stefan-jung.org – Your DITA/DITA-OT XML consultant
Post Reply