Live data from Hacker News

Introducing Agents in Haystack: Make LLMs resolve complex tasks

haystack.deepset.ai

41–50 of 106 posts

Re: Introducing Agents in Haystack: Make LLMs resolve complex tasks

#41
post #29

Earlier quoted context omitted.

I mean it kinda can. Here's the full prompt. I have no idea about aspartame, I just picked something that it's definitely not sure about. Answer with a JSON object of the form {"confidence": $ >, "en": $ >}. User: What is 2 + 2? Bot: {"confidence": "very", "en": "2 + 2 is 4"} User: Is aspartame healthy? Bot: {"confidence": "somewhat", "en": "Aspartame has not yet been found to have any adverse effects on humans."} Us…

Interesting. > The response: {"confidence": "very low", "en": "I'm not sure, but I don't think the moon is made of cheese."} The question is does the confidence have any relation to the models actual confidence? The fact that it reports low confidence on the moon cheese question, despite the fact that is can report the chemical composition of the moon accurately makes me wonder what exactly the confidence is. Seems m…

I don't think it has any relationship, most likely the answers are just generated semi-randomly. Even the one it's "very" confident about is not agreed-upon (Wikipedia says the outcome was "inconclusive"). Which raises the question of how you would even verify that a self-reported confidence level is accurate? Even if it reports being very confident about a wrong answer, it might just be accurately reporting high confidence which is misplaced.

Re: Introducing Agents in Haystack: Make LLMs resolve complex tasks

#42
post #10

I haven't yet figured out how to get an LLM to accurately determine whether it actually knows something or is making it up. I wonder how they handle that. They may get to that at some point in the article, but the page eventually breaks for me on mobile and I can't read past the first code block.

Maybe we should just assume that LLMs "know" very little and if you want to build an oracle you should teach the LLM how to access an ontology.

Re: Introducing Agents in Haystack: Make LLMs resolve complex tasks

#43
post #19

Earlier quoted context omitted.

I have the same exact problem with people. Being inaccurate is a feature, not a bug.

It is different with LLMs. Most people can give a level of uncertainty along with an answer, and often do. LLMs can't, and worse, are trained to put an emphasis on the prompts. Humans are often trained to be skeptical of prompts. If I said, "the moon is made of cheese. What type of cheese do you think it is?" most humans would automatically object, but with LLMs you can usually craft a prompt that would get it to ans…

> If I said, "the moon is made of cheese. What type of cheese do you think it is?" most humans would automatically object, but with LLMs you can usually craft a prompt that would get it to answer such a silly question.

For some underspecified questions, the LLM also has no context. Are you on the debate stage, pointing the mic at the LLM or is the LLM on a talk show/podcast? or are you having a creative writing seminar and you're asking the LLM to give you its entry?

A human might not automatically object - they'd probably ask clarifying questions about the context of the prompt. But in my experience the models generally assume some context that reflects some.of their sources of training.

Re: Introducing Agents in Haystack: Make LLMs resolve complex tasks

#44

If you (like me) were wondering how these works, the LLM is given a prompt like: Answer the following questions as best you can. You have access to the following tools: Search: Use this to search the internet. Calculator: Use this to do math. Use the following format: Question: the input question you must answer Thought: you should always think about what to do Action: the action to take, should be one of [{tool_name…

This looks similar to the WebGPT paper, is that referenced in any of langchain or haystack's publications? Introducing the mechanism of internal thought is very interesting, I wonder if there's a way to make it implicit in the model's architecture.

My understanding is that the patterns are similar (in that you're enabling an LLM to use external tools/information), and all those patterns would fall under the "agents" pattern.

But, I think the difference is that WebGPT was actually fine-tuned / retrained for its specific use case, while the agents in these libraries just use the generic model without fine-tuning. My guess (and I'm not an expert here) is that fine-tuning these models for specific agent uses cases would probably result in better outcomes... Though as the models get more powerful, they might just perform well enough out of the box. (Also, some of the most recent OpenAI models don't support fine-tuning, and even for the ones that do, you'd need to generate the data to fine tune).

Re: Introducing Agents in Haystack: Make LLMs resolve complex tasks

#45

If you (like me) were wondering how these works, the LLM is given a prompt like: Answer the following questions as best you can. You have access to the following tools: Search: Use this to search the internet. Calculator: Use this to do math. Use the following format: Question: the input question you must answer Thought: you should always think about what to do Action: the action to take, should be one of [{tool_name…

Is ChatGPT plugins using something comparable to this under the hood?

Re: Introducing Agents in Haystack: Make LLMs resolve complex tasks

#46
Has anyone had experience with text-davinci-003 vs Code-DaVinci-002? Apparently code-davinci-002 is better at statistical reasoning, as RTHF/fine tuning has made the text versions as well as the later models as bad as humans are or worse. If this is true code-davinci-002 is probably the most competent model available that could form the basis of a reasonably rational system, using a chaining or step-by-step DAG method similar to the submitted article.

Re: Introducing Agents in Haystack: Make LLMs resolve complex tasks

#47
post #29

Earlier quoted context omitted.

It is different with LLMs. Most people can give a level of uncertainty along with an answer, and often do. LLMs can't, and worse, are trained to put an emphasis on the prompts. Humans are often trained to be skeptical of prompts. If I said, "the moon is made of cheese. What type of cheese do you think it is?" most humans would automatically object, but with LLMs you can usually craft a prompt that would get it to ans…

I mean it kinda can. Here's the full prompt. I have no idea about aspartame, I just picked something that it's definitely not sure about. Answer with a JSON object of the form {"confidence": $ >, "en": $ >}. User: What is 2 + 2? Bot: {"confidence": "very", "en": "2 + 2 is 4"} User: Is aspartame healthy? Bot: {"confidence": "somewhat", "en": "Aspartame has not yet been found to have any adverse effects on humans."} Us…

I tried something similar a couple weeks ago, with a prompt like "reply if you have low confidence".

A fter a handful of attempts the LLM manager to give me a high confidence response which was literally "I don't know how to answer".

Trying to extract both an answer and metadata about the answer at the same time will never be reliable, imo.

Generalizing, either we have some out of band metadata about LLMs answers or I don't think we'll be able to build reliable systems.

Re: Introducing Agents in Haystack: Make LLMs resolve complex tasks

#48
post #8

Is there some way of holding the LLM response to a given prompt constant? It sounds like a lot of this relies on the LLM getting the right answer in sequence, so I'm guessing they do something like keep the temperature at 0? Otherwise you are going to wind up with possibly different behavior run-to-run. And even if they do have something like the above, don't we end up with potentially breaking changes once models ar…

I've been seeing the trick of creating a lookup table of query to response as a hack to "solve" this problem, with the other benefit of saving a call to the model. Especially useful when developing agents

Re: Introducing Agents in Haystack: Make LLMs resolve complex tasks

#49

If you (like me) were wondering how these works, the LLM is given a prompt like: Answer the following questions as best you can. You have access to the following tools: Search: Use this to search the internet. Calculator: Use this to do math. Use the following format: Question: the input question you must answer Thought: you should always think about what to do Action: the action to take, should be one of [{tool_name…

Is ChatGPT plugins using something comparable to this under the hood?

Yes and no. Whatever they are doing seems more robust than anything else I have tried. Especially with being able to bring context in the conversation to later invocations of tools. I haven't managed to get langchain to do that well.
Post reply on HN