<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;
        mso-fareast-language:EN-US;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:#0563C1;
        text-decoration:underline;}
pre
        {mso-style-priority:99;
        mso-style-link:"HTML Preformatted Char";
        margin:0cm;
        font-size:10.0pt;
        font-family:"Courier New";
        mso-fareast-language:EN-GB;}
span.HTMLPreformattedChar
        {mso-style-name:"HTML Preformatted Char";
        mso-style-priority:99;
        mso-style-link:"HTML Preformatted";
        font-family:Consolas;
        mso-fareast-language:EN-US;}
span.EmailStyle23
        {mso-style-type:personal-reply;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-GB" link="#0563C1" vlink="purple" style="word-wrap:break-word">
<div style="padding-bottom: 10px; padding-top: 5px;">
<div style="padding:12px; border:1px solid #8D3970; background-color:#F7F9FA; color:#8D3970; font-size:14px; line-height:22px; font-family: Calibri, Arial, Helvetica, sans-serif;">
<strong>CAUTION:</strong> This e-mail originated outside the University of Southampton.
</div>
</div>
<div>
<div class="WordSection1">
<p class="MsoNormal">David many thanks for the detail tutorial. Looks good<o:p></o:p></p>
<p class="MsoNormal">The releasetool needs to have “status” as part of the response<o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:10.5pt;font-family:Consolas;color:#D4D4D4;mso-fareast-language:EN-GB"> ]<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.5pt;font-family:Consolas;color:#D4D4D4;mso-fareast-language:EN-GB"> },<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.5pt;font-family:Consolas;color:#D4D4D4;mso-fareast-language:EN-GB"> "status": 200<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.5pt;font-family:Consolas;color:#D4D4D4;mso-fareast-language:EN-GB">}<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.5pt;font-family:Consolas;color:#D4D4D4;mso-fareast-language:EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal">Any ideas ?<o:p></o:p></p>
<p class="MsoNormal">Really appreciate your help will be publishing the releasetool image soon which is connected to eprints, annif, and jena fuseki (for keywords) if anyone wants to use this tool for evaluating automatic subject indexing keywords..<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-GB">Best Regards,</span><span style="mso-fareast-language:EN-GB"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-GB">Phil Stacey<o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-GB"><a href="https://eur03.safelinks.protection.outlook.com/?url=https%3A%2F%2Feprints.buildvoc.co.uk%2F&data=04%7C01%7Ceprints-tech%40ecs.soton.ac.uk%7C6c6d4ddcc75b4c92448308d914a13f5e%7C4a5378f929f44d3ebe89669d03ada9d8%7C0%7C0%7C637563505045973458%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=EzBkidAWtBZSN8dc%2F4BDGaosxupD0fmkIEFG02R8tLw%3D&reserved=0" originalSrc="https://eprints.buildvoc.co.uk/" shash="jxgNeH6WpFMmfhDmNsETgfIEzAz1JnwHLtB03chCanzKUoRoqx5kE+rUBXifk4dyE0/vz/AZMs+g7IHPfkVbCRfIE+2/M2YZhrZN/D7eaAXkRnjFwsMokGSZYchAGsqRUYZAzSqjWUPhhE4y+gyGEcsplmQJYUyAJRLGoZfN49o="><span style="color:black">building regulations guidance for fire safety</span></a><o:p></o:p></span></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US" style="mso-fareast-language:EN-GB">From:</span></b><span lang="EN-US" style="mso-fareast-language:EN-GB"> David R Newman <drn@ecs.soton.ac.uk>
<br>
<b>Sent:</b> 11 May 2021 08:13<br>
<b>To:</b> eprints-tech@ecs.soton.ac.uk; phil@buildvoc.co.uk<br>
<b>Subject:</b> Re: [EP-tech] custom JSON export<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p>Hi Phil,<span style="mso-fareast-language:EN-GB"><o:p></o:p></span></p>
<p>So it sounds like you need to make just a small tweak to the existing JSON export plugin. What you want to do is copy the existing JSON export plugin to your archive:<o:p></o:p></p>
<p> cp EPRINTS_PATH/perl_lib/EPrints/Plugin/Export/JSON.pm EPRINTS_PATH/archives/ARCHIVE_NAME/cfg/plugins/EPrints/Plugin/Export/ReleaseToolJSON.pm<o:p></o:p></p>
<p>Then edit at the top of the file, replacing each occurence of Export::JSON with Export::ReleaseToolJSON and replacing Export::TextFile with Export::JSON. When you get down to the "new" sub remove all the $self->... lines except the one for "name" and update
this to "Release Tool JSON". Then remove all the other subs (functions) except "sub _epdata_to_json". In there you will need to make a small change, removing:<o:p></o:p></p>
<p> $subdata->{$field->get_name} = $value;<o:p></o:p></p>
<p>and replacing with:<o:p></o:p></p>
<p> my $field_name = $field->get_name;<br>
$field_name = "id" if $field_name eq "eprintid";<br>
$subdata->{$field_name} = $value;<o:p></o:p></p>
<p>Once you have done this. Run "epadmin test" to check everything is OK and the reload the webserver (e.g. apachectl graceful). If you now go to an item and look under its available export formats you should now see one labelled "Release Tool JSON". This
will be exactly the same export (as JSON) except wherever eprintid was used before id will be used instead. However, this will mean that where documents use to reference the eprint with "eprintid" they will now use "id", which may not be what you want. If
so, you may need to amend the if statement to take the depth into account:<o:p></o:p></p>
<p>$field_name = "id" if $field_name eq "eprintid" && $depth == 1;<o:p></o:p></p>
<p>Regards<o:p></o:p></p>
<p>David Newman<o:p></o:p></p>
<div>
<p class="MsoNormal">On 11/05/2021 06:13, Phil Stacey via Eprints-tech wrote:<o:p></o:p></p>
</div>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<div>
<div style="border:solid #8D3970 1.0pt;padding:9.0pt 9.0pt 9.0pt 9.0pt">
<p class="MsoNormal" style="line-height:16.5pt;background:#F7F9FA"><strong><span style="font-size:10.5pt;font-family:"Calibri",sans-serif;color:#8D3970;mso-fareast-language:EN-GB">CAUTION:</span></strong><span style="font-size:10.5pt;color:#8D3970;mso-fareast-language:EN-GB">
This e-mail originated outside the University of Southampton. <o:p></o:p></span></p>
</div>
</div>
<div>
<p class="MsoNormal">Good morning, working with an app to carry out reviews of automatic subject indexing created by ZBW called releasetool.
<a href="https://eur03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fzbw%2Freleasetool&data=04%7C01%7Ceprints-tech%40ecs.soton.ac.uk%7C6c6d4ddcc75b4c92448308d914a13f5e%7C4a5378f929f44d3ebe89669d03ada9d8%7C0%7C0%7C637563505045983420%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=S9rMJZEfUV5TSsjw611RsB0ZXVBEk7jNiC04baQXtzM%3D&reserved=0" originalSrc="https://github.com/zbw/releasetool" shash="nV6XB4y4g6qcohP4T3sSXt8T29wx8DGvNj0B3OoqkaVVDFzG4MRYDKQOTMIJ5e3NrO/8WI+Carph9B39utQNMzqvIKvBsCrDWhVhnJIiUtHpTifEX4XjdWJUYmBORGVzvjfyEY2dzc85rCrUxS2VVeJEFE1YJELhthVrrQc6rus=">
https://github.com/zbw/releasetool</a><o:p></o:p></p>
<p class="MsoNormal">For this tool to connect to a catalogue requires a certain format of JSON, for example “id” instead of “eprintid”<o:p></o:p></p>
<p class="MsoNormal">Buildvoc is running eprints version 3.4.1, can anyone advise how to update the configuration to export as shown below. (any help would be much appreciated)<o:p></o:p></p>
<p class="MsoNormal">{<o:p></o:p></p>
<p class="MsoNormal"> "record": {<o:p></o:p></p>
<p class="MsoNormal"> "description": [<o:p></o:p></p>
<p class="MsoNormal"> "Much of the guidance in this document is given in terms of performance classifications in relation to British or European Standards. In such cases, it will be necessary to demonstrate that
a system or product can meet the relevant performance classification. This will be achieved if the system or product complies with one of the following. a. They should be in accordance with a specification or design that has been shown by a specific
test to be capable of meeting that performance classification. b. They should have been designed by using relevant design standards in order to meet that performance classification. c. They should have been assessed by applying relevant test evidence,
in lieu of carrying out a specific test, as being capable of meeting that performance classification. NOTE: Some products are subject to Classification Without Further Testing (CWFT). For the purposes of this approved document, such products can be considered
to have been shown to be able of meeting a performance specification as per paragraph B1a."<o:p></o:p></p>
<p class="MsoNormal"> ],<o:p></o:p></p>
<p class="MsoNormal"> "edition": [<o:p></o:p></p>
<p class="MsoNormal"> "2019"<o:p></o:p></p>
<p class="MsoNormal"> ],<o:p></o:p></p>
<p class="MsoNormal"> "id": "884",<o:p></o:p></p>
<p class="MsoNormal"> "identifier_number": [<o:p></o:p></p>
<p class="MsoNormal"> "hdl:10419/56344 [Handle]"<o:p></o:p></p>
<p class="MsoNormal"> <span lang="FR">],</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="FR"> "identifier_url": [</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="FR">
<a href="https://eur03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.gov.uk%2Fgovernment%2Fpublications%2Ffire-safety-approved-document-b&data=04%7C01%7Ceprints-tech%40ecs.soton.ac.uk%7C6c6d4ddcc75b4c92448308d914a13f5e%7C4a5378f929f44d3ebe89669d03ada9d8%7C0%7C0%7C637563505045983420%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=QvCdmqV4DWC%2FQl0qr6JYg0ATUdNsJwS8FuCYUMp4a3s%3D&reserved=0" originalSrc="https://www.gov.uk/government/publications/fire-safety-approved-document-b" shash="v9zFQjSHfccz0YjHiLRPOzHGjVpQufzm5suLWfA2zby5urARka8HvQY+YBUaCJjMEZpXpyxKrWnw6b/jkM8/2eQX0tUX+m/U9AtoqiNDAVUOy6xtTBPf+HcqTaRf1lYkAhOLW3uJ/EDQ6kGGof9HS6QrlPFDu9O3GF8aXcjT7sQ=">
"https://www.gov.uk/government/publications/fire-safety-approved-document-b"</a></span><o:p></o:p></p>
<p class="MsoNormal"><span lang="FR"> </span>],<o:p></o:p></p>
<p class="MsoNormal"> "series": [<o:p></o:p></p>
<p class="MsoNormal"> "Approved Document B: Fire Safety - Volume 1: Dwellings"<o:p></o:p></p>
<p class="MsoNormal"> ],<o:p></o:p></p>
<p class="MsoNormal"> "subject": [<o:p></o:p></p>
<p class="MsoNormal"> "Appendix B: Performance of materials, products and structures",<o:p></o:p></p>
<p class="MsoNormal"> "Building standards"<o:p></o:p></p>
<p class="MsoNormal"> ],<o:p></o:p></p>
<p class="MsoNormal"> "title": "Para:B1 Introduction",<o:p></o:p></p>
<p class="MsoNormal"> "type": "Book Section",<o:p></o:p></p>
<p class="MsoNormal"> "type_genre": [<o:p></o:p></p>
<p class="MsoNormal"> "Working Paper"<o:p></o:p></p>
<p class="MsoNormal"> ]<o:p></o:p></p>
<p class="MsoNormal"> },<o:p></o:p></p>
<p class="MsoNormal"> "status": 200<o:p></o:p></p>
<p class="MsoNormal">}<o:p></o:p></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-GB">Best Regards,</span><o:p></o:p></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-GB">Phil Stacey</span><o:p></o:p></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-GB"><a href="https://eur03.safelinks.protection.outlook.com/?url=https%3A%2F%2Feprints.buildvoc.co.uk%2F&data=04%7C01%7Ceprints-tech%40ecs.soton.ac.uk%7C6c6d4ddcc75b4c92448308d914a13f5e%7C4a5378f929f44d3ebe89669d03ada9d8%7C0%7C0%7C637563505045993377%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=WpHOYiptdo9e2o90136OGtfury63kDEfiRW8cLxHJAg%3D&reserved=0" originalSrc="https://eprints.buildvoc.co.uk/" shash="MIxpUQ2i5tUQLKz4oe9Nn0e3U4X8KSv9FX4nSDT6FJsLTJSobweClBbPf5eVQHTLkmTBSdo6SRASa+lKlNDl9uTNMP5ICEn6Uee9Ed6nWQ9aedKVSQSOwfkae19HzBfkCEf3u09V7dEDvcQwKN2O9agU3zKz7xb4JguY6ulUpn4="><span style="color:black">building
regulations guidance for fire safety</span></a></span><o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
</div>
<p class="MsoNormal"><span style="mso-fareast-language:EN-GB"><br>
<br>
<o:p></o:p></span></p>
<pre>*** Options: <a href="http://mailman.ecs.soton.ac.uk/mailman/listinfo/eprints-tech">http://mailman.ecs.soton.ac.uk/mailman/listinfo/eprints-tech</a><o:p></o:p></pre>
<pre>*** Archive: <a href="https://eur03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.eprints.org%2Ftech.php%2F&data=04%7C01%7Ceprints-tech%40ecs.soton.ac.uk%7C6c6d4ddcc75b4c92448308d914a13f5e%7C4a5378f929f44d3ebe89669d03ada9d8%7C0%7C0%7C637563505045993377%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=gOEnypLuZzF6bclqYvX5sGs11eXzPcxeeCLeoI8%2BTRs%3D&reserved=0" originalSrc="http://www.eprints.org/tech.php/" shash="QZ6Z0IW7ieqlbhkhswBqwodhMygQUCMAk+YYFHHPWurr/aEh/+Oc/4ilwXBh6Ygkw56RSSGYn4SU6/DM4zDT15uG32ufFg2xxod/FZlL7HCgKLauevaBKSJu9pyZhk99WI/fdOUqqeZvq7A+tuwWrPKocEVW7ksh1kNwTghWPMQ=">http://www.eprints.org/tech.php/</a><o:p></o:p></pre>
<pre>*** EPrints community wiki: <a href="https://eur03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwiki.eprints.org%2F&data=04%7C01%7Ceprints-tech%40ecs.soton.ac.uk%7C6c6d4ddcc75b4c92448308d914a13f5e%7C4a5378f929f44d3ebe89669d03ada9d8%7C0%7C0%7C637563505046003333%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=6tkOupDZLjimTOlyZoCLuHVYc2jXbb3LSyrIBKJJckI%3D&reserved=0" originalSrc="http://wiki.eprints.org/" shash="ZKLdwQ6pAha7DsNQykxdX6ToulcDNqSnmVAcTMBFoBLGUoWqp2gLvfUI4SZoeztqkh/FVo5nYQZdgW+M4E+0y1ngpyByNnrN6f4CRxmTjxkXJoY1lbH128MA8YqxBlxuEVcDS3AQBNfw9Q1fKoN/kV6mKs/6zOZtAPYed3GqRsw=">http://wiki.eprints.org/</a><o:p></o:p></pre>
</blockquote>
<div id="DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2">
<p class="MsoNormal"><span style="mso-fareast-language:EN-GB"><o:p> </o:p></span></p>
<table class="MsoNormalTable" border="1" cellpadding="0" style="border:none;border-top:solid #D3D4DE 1.0pt">
<tbody>
<tr>
<td width="55" style="width:41.25pt;border:none;padding:9.75pt .75pt .75pt .75pt">
<p class="MsoNormal"><a href="https://eur03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.avg.com%2Femail-signature%3Futm_medium%3Demail%26utm_source%3Dlink%26utm_campaign%3Dsig-email%26utm_content%3Demailclient&data=04%7C01%7Ceprints-tech%40ecs.soton.ac.uk%7C6c6d4ddcc75b4c92448308d914a13f5e%7C4a5378f929f44d3ebe89669d03ada9d8%7C0%7C0%7C637563505046003333%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=RAZaJrJPUivDinjbfM3%2FbDvJ6WAzzg6CZJ8jO%2Ff31Y8%3D&reserved=0" originalSrc="http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient" shash="kpfZjdxLGuIUXjrXZXTpKJ62Es9mNMqCzAEbpFFWcEYLC1aKO6PN3d1p6G8H7ajA6WAEl/DGQ8UNoh1kBb8kNor5K2tyAcZOvIwJlxZldh5Gv+04zuhPid63XFh7nY4gqDoS2FFO9XASYjPU1pM5UXw/xa0Qlys10WrrvUojxHk=" target="_blank"><span style="mso-fareast-language:EN-GB;text-decoration:none"><img border="0" width="46" height="29" style="width:.4791in;height:.302in" id="_x0000_i1025" src="https://ipmcdn.avast.com/images/icons/icon-envelope-tick-green-avg-v1.png"></span></a><span style="mso-fareast-language:EN-GB"><o:p></o:p></span></p>
</td>
<td width="470" style="width:352.5pt;border:none;padding:9.0pt .75pt .75pt .75pt">
<p class="MsoNormal" style="line-height:13.5pt"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:#41424E;mso-fareast-language:EN-GB">Virus-free.
<a href="https://eur03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.avg.com%2Femail-signature%3Futm_medium%3Demail%26utm_source%3Dlink%26utm_campaign%3Dsig-email%26utm_content%3Demailclient&data=04%7C01%7Ceprints-tech%40ecs.soton.ac.uk%7C6c6d4ddcc75b4c92448308d914a13f5e%7C4a5378f929f44d3ebe89669d03ada9d8%7C0%7C0%7C637563505046013291%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=KPsFkXuNy3%2FZB8dzs7pg%2BD4LnNOVdHIQyrexQLNEqBA%3D&reserved=0" originalSrc="http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient" shash="ZiVhOFalh+Ar2by+WUsG5SStTZkHdH0EXKTpoa02LDCgfM2Ep653t8PW8GsHhHfRR1KbgygBKyNeuDYy4Jk7TfolRdqbrpW01uU1UKQj4cSisjo+uzvPBgb1GbtBjilzh0LfPx8ggoiFrzKOO2zQ6tsqYF+Hfyw4wKnleRogtvM=" target="_blank">
<span style="color:#4453EA">www.avg.com</span></a> <o:p></o:p></span></p>
</td>
</tr>
</tbody>
</table>
<p class="MsoNormal"><span style="mso-fareast-language:EN-GB"><o:p> </o:p></span></p>
</div>
</div>
</div>
</body>
</html>