A copyright violation detector running on Wikimedia Cloud Services https://tools.wmflabs.org/copyvios/
Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

pirms 11 gadiem
pirms 11 gadiem
pirms 11 gadiem
pirms 11 gadiem
pirms 11 gadiem
pirms 11 gadiem
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141
  1. <%include file="/support/header.mako" args="environ=environ, cookies=cookies, title='Earwig\'s Copyvio Detector'"/>\
  2. <%namespace module="copyvios" import="main, highlight_delta"/>\
  3. <%namespace module="copyvios.misc" import="urlstrip"/>\
  4. <% query, bot, all_langs, all_projects, page, result = main(environ) %>\
  5. % if query.project and query.lang and query.title and not page:
  6. <div class="red-box">
  7. <p>The given site (project=<b><tt>${query.project | h}</tt></b>, language=<b><tt>${query.lang | h}</tt></b>) doesn't seem to exist. It may also be closed or private. <a href="//${query.lang | h}.${query.project | h}.org/">Confirm its URL.</a></p>
  8. </div>
  9. % elif query.project and query.lang and query.title and page and not result:
  10. <div class="red-box">
  11. <p>The given page doesn't seem to exist: <a href="${page.url}">${page.title | h}</a>.</p>
  12. </div>
  13. % elif query.project and query.lang and query.title and query.url and page and result == "bad URI":
  14. <% result = None %>
  15. <div class="red-box">
  16. <p>Unsupported URI scheme: <a href="${query.url | h}">${query.url | h}</a>.</p>
  17. </div>
  18. % endif
  19. <p>This tool attempts to detect <a href="//en.wikipedia.org/wiki/WP:COPYVIO">copyright violations</a> in articles. Simply give the title of the page you want to check and hit Submit. The tool will then search for its content elsewhere on the web and display a report if a similar webpage is found. If you also provide a URL, it will not query any search engines and instead display a report comparing the article to that particular webpage, like the <a href="//toolserver.org/~dcoetzee/duplicationdetector/">Duplication Detector</a>. Check out the <a href="//en.wikipedia.org/wiki/User:EarwigBot/Copyvios/FAQ">FAQ</a> for more information and technical details.</p>
  20. <p><i>Note:</i> The tool is still in beta. You are completely welcome to use it and provide <a href="//en.wikipedia.org/wiki/User_talk:The_Earwig">feedback</a>, but be aware that it may produce strange or broken results.</p>
  21. <form action="${environ['PATH_INFO']}" method="get">
  22. <table>
  23. <tr>
  24. <td>Site:</td>
  25. <td>
  26. <tt>http://</tt>
  27. <select name="lang">
  28. <% selected_lang = query.orig_lang if query.orig_lang else cookies["CopyviosDefaultLang"].value if "CopyviosDefaultLang" in cookies else bot.wiki.get_site().lang %>\
  29. % for code, name in all_langs:
  30. % if code == selected_lang:
  31. <option value="${code | h}" selected="selected">${name}</option>
  32. % else:
  33. <option value="${code | h}">${name}</option>
  34. % endif
  35. % endfor
  36. </select>
  37. <tt>.</tt>
  38. <select name="project">
  39. <% selected_project = query.project if query.project else cookies["CopyviosDefaultProject"].value if "CopyviosDefaultProject" in cookies else bot.wiki.get_site().project %>\
  40. % for code, name in all_projects:
  41. % if code == selected_project:
  42. <option value="${code | h}" selected="selected">${name}</option>
  43. % else:
  44. <option value="${code | h}">${name}</option>
  45. % endif
  46. % endfor
  47. </select>
  48. <tt>.org</tt>
  49. </td>
  50. </tr>
  51. <tr>
  52. <td>Page title:</td>
  53. % if page:
  54. <td><input type="text" name="title" size="60" value="${page.title | h}" /></td>
  55. % elif query.title:
  56. <td><input type="text" name="title" size="60" value="${query.title | h}" /></td>
  57. % else:
  58. <td><input type="text" name="title" size="60" /></td>
  59. % endif
  60. </tr>
  61. <tr>
  62. <td>URL (optional):</td>
  63. % if query.url:
  64. <td><input type="text" name="url" size="120" value="${query.url | h}" /></td>
  65. % else:
  66. <td><input type="text" name="url" size="120" /></td>
  67. % endif
  68. </tr>
  69. % if query.nocache or (result and result.cached):
  70. <tr>
  71. <td>Bypass cache:</td>
  72. % if query.nocache:
  73. <td><input type="checkbox" name="nocache" value="1" checked="checked" /></td>
  74. % else:
  75. <td><input type="checkbox" name="nocache" value="1" /></td>
  76. % endif
  77. </tr>
  78. % endif
  79. <tr>
  80. <td><button type="submit">Submit</button></td>
  81. </tr>
  82. </table>
  83. </form>
  84. % if page and result:
  85. <div class="divider"></div>
  86. <div id="cv-result-${'yes' if result.violation else 'no'}">
  87. % if result.violation:
  88. <h2 id="cv-result-header"><a href="${page.url}">${page.title | h}</a> is a suspected violation of <a href="${result.url | h}">${result.url | urlstrip, h}</a>.</h2>
  89. % else:
  90. <h2 id="cv-result-header">No violations detected in <a href="${page.url}">${page.title | h}</a>.</h2>
  91. % endif
  92. <ul id="cv-result-list">
  93. % if not result.violation and not query.url:
  94. % if result.url:
  95. <li>Best match: <a href="${result.url | h}">${result.url | urlstrip, h}</a>.</li>
  96. % else:
  97. <li>No matches found.</li>
  98. % endif
  99. % endif
  100. <li><b><tt>${round(result.confidence * 100, 1)}%</tt></b> confidence of a violation.</li>
  101. % if result.cached:
  102. <li>Results are <a id="cv-cached" href="#">cached
  103. <span>To save time (and money), this tool will retain the results of checks for up to 72 hours. This includes the URL of the "violated" source, but neither its content nor the content of the article. Future checks on the same page (assuming it remains unchanged) will not involve additional search queries, but a fresh comparison against the source URL will be made. If the page is modified, a new check will be run.</span>
  104. </a> from ${result.cache_time} (${result.cache_age} ago). <a href="${environ['REQUEST_URI'] | h}&amp;nocache=1">Bypass the cache.</a></li>
  105. % else:
  106. <li>Results generated in <tt>${round(result.time, 3)}</tt> seconds using <tt>${result.queries}</tt> queries.</li>
  107. % endif
  108. % if "CopyviosShowDetails" in cookies and cookies["CopyviosShowDetails"].value == "True":
  109. <li><a id="cv-result-detail-link" href="#cv-result-detail" onclick="copyvio_toggle_details()">Hide details:</a></li>
  110. % else:
  111. <li><a id="cv-result-detail-link" href="#cv-result-detail" onclick="copyvio_toggle_details()">Show details:</a></li>
  112. % endif
  113. </ul>
  114. % if "CopyviosShowDetails" in cookies and cookies["CopyviosShowDetails"].value == "True":
  115. <div id="cv-result-detail" style="display: block;">
  116. % else:
  117. <div id="cv-result-detail" style="display: none;">
  118. % endif
  119. <ul id="cv-result-detail-list">
  120. <li>Trigrams: <i>Article:</i> <tt>${result.article_chain.size()}</tt> / <i>Source:</i> <tt>${result.source_chain.size()}</tt> / <i>Delta:</i> <tt>${result.delta_chain.size()}</tt></li>
  121. % if result.cached:
  122. % if result.queries:
  123. <li>Retrieved from cache in <tt>${round(result.time, 3)}</tt> seconds (originally generated in <tt>${round(result.original_time, 3)}</tt>s using <tt>${result.queries}</tt> queries; <tt>${round(result.original_time - result.time, 3)}</tt>s saved).</li>
  124. % else:
  125. <li>Retrieved from cache in <tt>${round(result.time, 3)}</tt> seconds (originally generated in <tt>${round(result.original_time, 3)}</tt>s; <tt>${round(result.original_time - result.time, 3)}</tt>s saved).</li>
  126. % endif
  127. % endif
  128. % if result.queries:
  129. <li><i>Fun fact:</i> The Wikimedia Foundation paid Yahoo! Inc. <a href="http://info.yahoo.com/legal/us/yahoo/search/bosspricing/details.html">$${result.queries * 0.0008} USD</a> for these results.</li>
  130. % endif
  131. </ul>
  132. <table id="cv-chain-table">
  133. <tr>
  134. <td class="cv-chain-cell">Article: <div class="cv-chain-detail"><p>${highlight_delta(result.article_chain, result.delta_chain)}</p></div></td>
  135. <td class="cv-chain-cell">Source: <div class="cv-chain-detail"><p>${highlight_delta(result.source_chain, result.delta_chain)}</p></div></td>
  136. </tr>
  137. </table>
  138. </div>
  139. </div>
  140. % endif
  141. <%include file="/support/footer.mako" args="environ=environ, cookies=cookies"/>