Tag: llm

  • 셀프로 모든걸 다 하는 LLM

    Self-Rewarding Language Models: Human feedback은 bottleneck일수밖에 없고, reward 모델은 human feedback을 받은다음 frozen 되서 policy 개선 중에는 함께 개선되지 못한다.그러지말고 이 모두를 합친다. Response 도 만들고, reward 도 정하고, 그 둘로부터 트레이닝까지. 물론 방향을 잡아주는 몇개 훈련데이터는 넣음. Self-Instruct: Our *pipeline generates instructions, input, and output samples from a language model*, then filters invalid or…

  • LLM의 툴 사용

    Andrew Ng가 다음 트윗을 올렸다 그래서 위 트윗에 나온 세 논문을 정리해 보았다 여기서 언급된 첫번째 논문인 Gorilla는 self instruct (GPT4로 instruct fine tuning data 만듦)를 통해 만든 데이타로 llama 를 파인 튜닝했더니, 주어진 문제에 맞는 api call을 잘 만들더라하는 것. RAG도 가능하고 zero shot 도 됨. arxiv.org/abs/2305.15334 두번째 논문인 MM React 는 멀티모달 (비디오,…

  • How to reliably use llm to get json outputs

    When using LLM, esp., for getting json output, there are many things that go wrong. I’ll explain some of them in this post. Prompt First is to ask LLM to generate json as output. I use the following: Every LLM generates all the different errors. Tweak the above as necesary. Parsing Even with a strong…

  • Better prompt formatting for LLM uses

    One of the typical way to format prompt is using { … } like the below: But it fails as soon as JSON is involved in the input or output. Then, what should we do? My proposal is using string.Template. Its primary purpose is i18n, but it also provides a much more safe formatting, e.g.,…

  • Map reduce pattern in LLM

    One of the primary patterns of using LLM is map reduce. For example, process multiple docs in mappers and then reduce them as a single result in the reducer. LLM mapreduce sounds very intuitive and simple, but in reality it isn’t. One of the problem is hallucinations. When hallucinate, LLM fails unexpectedly in an obvious…

  • How to print intermediate values in the langchain chain

    I don’t know why this isn’t documented anywhere. Let’s say there are two prompts. And then you add RunnableLambda.

  • LLM의 한계에 대하여

    LLM이 인간의 모든 지식을 담을 수 없다는 흥미로운 글을 읽었다. 인공지능이 인간의 지식을 다 표현할 수 있는가 아닌가는 상당히 오래된 주제이지만, 이 글의 열정적인 톤과 풍부한 사례는 무척 재미있었다. 예를들어 글에서는 performer (예를들어 피겨 스케이팅 선수) 의 perform 하는 기술은 글로 기술되지 않으며 글로 기술된다 하였다고 해도 그것이 그대로 그 퍼포먼스를 따라할 수 있단 이야기는…

  • Prompt Engineering 코스

    Andrew Ng 와 Open AI 엔지니어가 함께 만든 코스가 있어서 올립니다. ChatGPT Prompt Engineering for Developers