Talk:Community Wishlist Survey 2017/Citations/Develop precision of citation by showing which text span the ref applies to

From Meta, a Wikimedia project coordination wiki

Further comment by Jeblad[edit]

This would be really nice if it were possible to automate it somehow. The problem is that it is quite hard to do it well. First of all there are two models for how to make a reference. Either the reference is placed after the text fragment that needs a reference, usually the text is a completed period, or the reference is before a text that uses that referenced source to build an argument. The first version is the most common at Wikipedia, but the later are also in use. Those two needs different methods to identify the covered text. If the area covered by the referenced text are somehow partly covered by some other markup, then the referenced text must either be shrunk or expanded so the partly covered text (ie extern markup) is closed. The correct strategy are usually the one that fully encloses valid periods from the text.

When the fragment is found, then the easy problem is solved. It is almost trivial compared to the next one. The hard problem is how to verify the correctness of the fragment that has been given a reference. — Jeblad 20:44, 13 December 2017 (UTC)[reply]