ATA56 – SDL Trados Studio Advanced

01I ran a beginners and an advanced workshop at the ATA56 pre-conference day in Miami this year.  A really fun day for me as we start the day with no specific agenda or pre-defined course and then try to shape the session to suit the needs of the attendees.  The beginner tends to be a little more prescribed, to start off with at least, and the intention is to try and cover the basics of how Studio and MultiTerm work.

The advanced is a lot different… after all, what is advanced?

I had an interesting twitter discussion while waiting for the plane on the way home from the ATA on how we should have a Studio manual that has no gaps.  Of course this is a worthy ambition, but in my opinion not at all achievable because once you move away from the basics the subject matter you could cover is huge.  How advanced do you go in filling gaps?  Even the excellent manual written by Mats Linder which is some 500 pages long is full of holes once you start asking the right questions.  A manual is great… but it’s not enough, in fact it may never be enough!!  Translation technology today needs to cover a lot of areas and a tool like Studio opens a real pandora’s box of things you could put in the advanced category.  The solution is a flexible online help with live links to other resources and an opportunity to keep it dynamic.  It would be nice to be able to print out pages and topics for sure, but the old style manuals are simply inadequate today.  SDL do provide a lot of help already… summarised here and SDL are always very willing to take feedback to help this get better and more relevant.

But I digress… I wanted to talk about the advanced workshop at the ATA and what we covered, so more to the point what is advanced?  This of course depends on who you ask?  So this is what we did… we asked the question and had a series of things to start with like this (I added some useful links for each topic here just for additional information):

I don’t intend to repeat everything we covered in three hours… plus a bit… particularly as the sessions were recorded so all attendees will be able to play these back on the ATA website as a reminder of what we covered.  So I just added a few links above that might be helpful as a reminder of where to find additional information on some of the things we discussed.  But there was one thing in particular that I didn’t complete on the day that played on my mind afterwards, so I’m going to share this with you here.  If I missed something please feel free to let me know in the comments and I’ll address it.  I added most of the bigger things we discussed into the powerpoint and then didn’t save the file… doh!!

Markdown Filetype

The creation of a Markdown filetype.  For those of you who aren’t familiar with this is it’s a lightweight markup language that can be written by anyone using a text editor.  A good explanation can be found here in Wikipedia.  It’s quite popular today in online tools like github and those provided through Atlassian.  You can also find tools like MarkdownPad, which I just happened to have installed, so we knocked up a quick test file to see how to create the filetype.

The creation of the filetype itself was simple.  We created a custom filetype using the Regular Expression Delimited Text option and knocked up a simple test file using MarkdownPad something like this:

02

So, nothing complicated but on the day I did run into a short problem that needed more thought later on.  Creating the filetype itself was simple, but when I added the inline tags to show how to mimic the formatting in a wysiwyg style I ran into this error:

03

The reason of course was because I tried to use ** as my opening and closing tags to pick up the markdown being used for bold for example and this created overlap as we discussed.  So to resolve this I tried something else later on and used a lookaround in order to be more specific with the regular expression and not cause any overlap which was invalidating the rule.  This worked… I used these as the opening and closing tags for bold as in **sample**

(?<=s)*{2}(?=w+*)
(?<!*)*{2}(?=s)

The opening tag says find two stars exactly, but only when you find a space first, and then some text followed by a star afterwards.  So a positive lookbehind at the start and a positive lookahead at the end.  The closing tag says find two stars exactly but not if there any stars before this, and only if there is a space after it.  So a negative lookbehind at the start and a positive lookahead at the end.  These are not perfect and won’t be the solution in every single permutation of markdown for bold, but they did prove it could be done if you ensure that the expressions don’t cause any overlap between the tags.

So I was able to make Studio render this example text as follows which is quite nice:

04

Obviously I’ve hidden the tags to make this look nicer by using the advanced tag properties so Ctrl+Shift+H toggles the display of the formatting tags on and off.  But it’s quite nice, and I think you can handle Markdown easily, represented in a smart way through Studio.  The complete set of rules I used for this file were these… the formatting was controlled through editing the rule and using the format button… but that was the easy part 🙂

05

I could of course have used ** as a placeholder instead of trying to make the opening and closing tags work, or perhaps this *{1,} as a catch all for markdown using the star symbol, but that would have been too easy 😉  I’m looking forward to any suggestions for a better solution from anyone interested in regex or anyone who might have tackled this particular filetype before.  If nobody has then I hope this helps you get started.

0 thoughts on “ATA56 – SDL Trados Studio Advanced

  1. Hi, it would be great if you could update this article with links that work 🙂 it seems that some of the links point to old locations (I was interested to see more info on the dependency file error).

    Thanks
    Jouni

    1. Thanks Jouni, the KB was changed a couple of years ago and most articles migrated. I found the first two and have amended them, but the third one is lost – so the support team will recreate it and I’ll update the link when it’s done.
      Thanks for picking this one up!

Leave a Reply