[HN Gopher] Citations on the Anthropic API
       ___________________________________________________________________
        
       Citations on the Anthropic API
        
       Author : Olshansky
       Score  : 70 points
       Date   : 2025-01-23 19:29 UTC (3 hours ago)
        
 (HTM) web link (www.anthropic.com)
 (TXT) w3m dump (www.anthropic.com)
        
       | Der_Einzige wrote:
       | Shameless self and friend plug, but the world of extractive
       | summarization is to thank for this idea. We've always known that
       | highlighting and citations are important to ground models - and
       | people.
       | 
       | https://github.com/Hellisotherpeople/CX_DB8
       | 
       | https://github.com/neuml/annotateai
        
       | sharkjacobs wrote:
       | I really like this. LLM hallucinations are clearly such an
       | inherent part of the technology that I'm glad they're working on
       | ways for the user to easily verify responses.
        
       | saaaaaam wrote:
       | Very interested to try this.
       | 
       | I've built a number of quite complex prompts to do exactly this -
       | cite from documents, with built-in safeguards to minimise
       | hallucinations as far as possible.
       | 
       | That comes with a cost though - typically the output of one
       | prompt is fed into another API call with a prompt that sense-
       | checks/fact-checks the output against the source, and if there
       | are problems it has to cycle back - with more API cost. We then
       | human review a random selection of final outputs.
       | 
       | That works fine for non-critical applications but I've been
       | cautious about rolling it out to chunkier problems.
       | 
       | Will start building with citations asap and see how it performs
       | against what we already have. For me, Anthropic seems to be
       | building stuff that has more meaningful application than what I'm
       | seeing from Open AI - and by and large I'm finding Anthropic
       | performs way way better for my use cases than Open AI - both via
       | the API and the chatbot.
        
       | htrp wrote:
       | > Our internal evaluations show that Claude's built-in citation
       | capabilities outperform most custom implementations, increasing
       | recall accuracy by up to 15%.1
       | 
       | also helpful when you can see how everyone using your claude api
       | endpoint has been trying to do grounded generation
        
       | WiSaGaN wrote:
       | This is actually good. I expect them to utilize this in code
       | editing as well if there is some real efficiency gain under the
       | hood.
        
       | Destiner wrote:
       | This is great for RAG, but Claude is generally hard to use for
       | many cases due to lack of the built-in structured outputs.
       | 
       | You can try forcing it to output JSON, but that is not 100%
       | reliable.
        
         | maleldil wrote:
         | You can get JSON output with a JSON schema via tool use [1]. Is
         | this not reliable like (e.g.) OpenAI's structured outputs?
         | 
         | [1] https://github.com/anthropics/anthropic-
         | cookbook/blob/main/t...
        
       | esafak wrote:
       | Anthropic upstaging OpenAI, tee hee.
        
       ___________________________________________________________________
       (page generated 2025-01-23 23:00 UTC)