[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

bad code Re: Subject: ChatGPT results are "subject to

Subject: bad code Re: Subject: ChatGPT results are "subject to review"
From: "Dorothy Hoskins dorothy.hoskins@xxxxxxxxx" <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx>
Date: Fri, 7 Jul 2023 13:26:27 -0000
 bad code Re: Subject: ChatGPT results are "subject to
Hi all, it did not take much investigation to find that there was an
invalidity in the XSLT that was "stupid" (a misplaced attribute constructor
after a child element constructor in a template), and there were various
other things that I improved to get it to produce the same result as my own
XSLT 2 transform that I used for comparison. So at this time, our concern
will be for the people who are just starting out and don't yet understand
why the XSLT is wrong and/or how to fix it.

The more expert of you (I am only middling fair at XSLT) will want to make
your own test cases. My guess is that the more interesting your input and
output and prompts are, the more you will have to draw on your expertise to
decide if the ChatGPT result is correct.

The speed of the results is what is helpful. If you are poking at a
solution bit by bit, you might be able to get some useful code results
quickly to test as you develop. But from what I understand, and what I
experienced myself, writing a good prompt is a science of its own
(well-suited for a number of you experts in the list).

In a way, it walks me back mentally to the development state of
requirements gathering. What is the source content? What do I need to
produce for the client? How can I test my result meets the requirement? It
seems like writing the test cases can also be automated (as I mentioned, I
asked ChatGPT to generate a schematron and an Xspec). I would be interested
in your thoughts about whether using ChatGPT will work better for a
procedural language or a declarative language. (You can ask ChatGPT to
return the generated code in other languages than XSLT. From what I see in
the list of ChatGPT Code languages, it wasn't specifically trained on XSLT,
so someone who builds their own training set will get better results. You
folks probably have the best training examples in the world in the

I don't think there's any going back, so the chances of people creating
code that won't run, that they can't debug themselves and which ChatGPT may
not provide the correction required if prompted, is high.

Michael, I wonder what "nasty accidents" you are thinking of -- some XSLTs
used in particular industries with real-world safety issues? Maybe we can
start to create some advice for clients on QA and testing protocols.
- Dorothy

Current Thread


Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
First Name
Last Name
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.