Giter Club home page Giter Club logo

Comments (6)

jgm avatar jgm commented on June 16, 2024 1

OK, I see what is going on.
In order to avoid expensive re-renders in disambiguation, I operate with a DisambData structure that just contains names and dates. This works fine for author-date styles, but not so well when titles are rendered as part of the citation, as in this case. We may need to do an additional render at the last step to avoid this problem.

from citeproc.

jgm avatar jgm commented on June 16, 2024

What should the result be (and why)? (If you can explain this you can save me the trouble of combing through the linked thread.)

from citeproc.

denismaier avatar denismaier commented on June 16, 2024

Sure.
The expected result for the notes is:

  1. Doe, A First Book by John Doe.
  2. Doe, A Second Book by John Doe.
  3. Smith, A First Book by Jane Smith.

The additional year in the Doe citations is not correct. I guess the date is inserted by this macro which is called on line 1353:

<macro name="date-disambiguate">
    <choose>
      <if disambiguate="true" type="personal_communication" match="any">
        <text macro="issued"/>
      </if>
    </choose>
  </macro>

Now, the spec says about disambiguate="true":

When set to “true” (the only allowed value), the element content is only rendered if it disambiguates two otherwise identical citations. This attempt at disambiguation is only made when all other disambiguation methods have failed to uniquely identify the target source.

But in this case, there is clearly no need to disambiguate these citations by adding the date.

from citeproc.

jgm avatar jgm commented on June 16, 2024

Is this rule even getting triggered here? This is not a personal_communication but a book.

from citeproc.

jgm avatar jgm commented on June 16, 2024

Oh, sorry, I guess the match=any matches if EITHER condition is met.
This is definitely getting triggered, because the output changes if I remove it.

from citeproc.

jgm avatar jgm commented on June 16, 2024

Or maybe re-render at every step and measure the performance impact.

from citeproc.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.