HackerTrans
TopNewTrendsCommentsPastAskShowJobs

jayalammar

no profile record

Submissions

A Visual Guide to Mixture of Experts (Moe) LLMs

newsletter.maartengrootendorst.com
3 points·by jayalammar·2 jaar geleden·0 comments

Building a RAG chatbot with query rewriting and citations

txt.cohere.com
4 points·by jayalammar·3 jaar geleden·0 comments

Show HN: Visual intuitive explanations of LLM concepts (LLM University)

303 points·by jayalammar·3 jaar geleden·36 comments

Will AI take away the coding jobs?

noahpinion.substack.com
1 points·by jayalammar·3 jaar geleden·2 comments

Is Generative AI the future or the present?

txt.cohere.ai
1 points·by jayalammar·3 jaar geleden·1 comments

comments

jayalammar
·2 jaar geleden·discuss
We actually just wrote a book with your profile in mind -- especially if by "AI" you're especially interested in LLMs and if you're a visual learner. It's called Hands-On Large Language Models and it contains 300 original figures explaining the main couple hundred intuitions and applications for these models. You can also read it online on the O'Reilly platform. I find that after acquiring the main intuitions, people find it much easier to move on to code implementations or papers.
jayalammar
·3 jaar geleden·discuss
This is my sense as well. Text generation LLMs haven't been the best source of embeddings for other downstream use cases. If you're optimizing for token embeddings (e.g., for NER, span detection, or token classification tasks), then a token training objective is important. If you need text-level embeddings (e.g., for semantic search or text classification), then that training objective is required (e.g., what Sentence BERT did to optimize BERT embeddings for semantic search).

That's a great list of existing embeddings models (in addition the SentenceBERT models https://www.sbert.net/docs/pretrained_models.html).
jayalammar
·3 jaar geleden·discuss
Contribution page: https://sites.google.com/cohere.com/aya-en/home
jayalammar
·3 jaar geleden·discuss
That's beautiful! Hope you're getting to do more of these!
jayalammar
·3 jaar geleden·discuss
Additional ones that come to mind now are:

Transformer Feed-Forward Layers Are Key-Value Memories https://arxiv.org/abs/2012.14913

The Dual Form of Neural Networks Revisited: Connecting Test Time Predictions to Training Patterns via Spotlights of Attention https://arxiv.org/abs/2202.05798

https://github.com/neelnanda-io/TransformerLens
jayalammar
·3 jaar geleden·discuss
Thank you so much (and others for your kind messages). Glad you found them useful! Writing is the best way for me to learn, I find.
jayalammar
·3 jaar geleden·discuss
This is a field I find fascinating. It's generally the research field of Machine Learning Interpretability. The BlackboxNLP workshop is one of the main places for investigating this and is a very popular academic workshop https://blackboxnlp.github.io/

One of the most interesting presentations in the last session of the workshop is this talk by David Bau titled "Direct Model Editing and Mechanistic Interpretability". David and his team locate exact information in the model, and edit it. So for example they edit the location of the Eiffel Tower to be in Rome. So whenever the model generates anything involving location (e.g., the view from the top of the tower), it actually describes Rome

Talk: https://www.youtube.com/watch?v=I1ELSZNFeHc

Paper: https://rome.baulab.info/

Follow-up work: https://memit.baulab.info/

There is also work on "Probing" the representation vectors inside the model and investigating what information is encoded at the various layers. One early Transformer Explainability paper (BERT Rediscovers the Classical NLP Pipeline https://arxiv.org/abs/1905.05950) found that "the model represents the steps of the traditional NLP pipeline in an interpretable and localizable way: POS tagging, parsing, NER, semantic roles, then coreference". Meaning that the representations in the earlier layers encode things like whether a token is a verb or noun, and later layers encode other, higher-level information. I've made an intro to these probing methods here: https://www.youtube.com/watch?v=HJn-OTNLnoE

A lot of applied work doesn't require interpretability and explainability at the moment, but I suspect the interest will continue to increase.
jayalammar
·3 jaar geleden·discuss
The goal is to make the materials as accessible as possible. So we're definitely not limited to the structure of a typical university course and are happy to iterate on it.

I appreciate you elaborating on your feedback. Thank you.
jayalammar
·3 jaar geleden·discuss
The landing page is technically the course overview. I'd love to hear what you think would've made it more engaging for you. We can probably pull up some of the visuals to it as a preview. Let me see what we can do on that front.
jayalammar
·3 jaar geleden·discuss
I'm the author of https://jalammar.github.io/illustrated-transformer/ and have spent years since introducing people to Transformers and thinking of how best to communicate those concepts. I've found that different people need different kinds of introductions, and the thread here includes some often cited resources including:

https://peterbloem.nl/blog/transformers

https://e2eml.school/transformers.html

I would also add Luis Serrano's article here: https://txt.cohere.com/what-are-transformer-models/ (HN discussion: https://news.ycombinator.com/item?id=35576918).

Looking back at The Illustrated Transformer, when I introduce people to the topic now, I find I can hide some complexity by omitting the encoder-decoder architecture and focusing only on one. Decoders are great because now a lot of people come to Transformers having heard of GPT models (which are decoder only). So for me, my canonical intro to Transformers now only touches on a decoder model. You can see this narrative here: https://www.youtube.com/watch?v=MQnJZuBGmSQ
jayalammar
·3 jaar geleden·discuss
How would you add that data? As new columns you mean? Or add the paragraph headings to the text of the paragraphs before embedding them?
jayalammar
·3 jaar geleden·discuss
There's a lot you can do with the vectors themselves without needing to embed any more text (e.g., clustering, exploration, visualization after dimensionality reduction...etc). Here's a previous embeddings exploration of top HN posts: https://txt.cohere.com/combing-for-insight-in-10-000-hacker-... A lot of that code can be used here as well.

If you want to query for a search term, you can use a trial API key which is free to use for prototyping. The embedding model itself is not open source, though. [co-author of the post here]
jayalammar
·3 jaar geleden·discuss
Cohere actually trains its own models and they are not based on models from other providers [I work at Cohere].

Your prompt suggestion is a good one for LLMs as a whole. Any information added to the context informs the model and nudges it towards the expected answer format.
jayalammar
·3 jaar geleden·discuss
For Cohere, make sure you're using Command-Xlarge-Nightly.

Otherwise, you may be prompting a Base LLM expecting the behavior of a different kind of LLM (an instruction-tuned chat model).

Cohere's Command model builds on top of the base model, giving it the capability to follow instructions and user commands.
jayalammar
·3 jaar geleden·discuss
Hi. Author here. This is the first in a series I've been writing for a while to help orient people about useful perspectives to have in catching up to all that's happening in AI/ML. It's based on what I've seen in the industry and the nlp company I work with (Cohere, where the post is hosted).

This article has the first four points (out of thirteen) that are useful to keep in mind. They are:

1- Recent AI developments are awe-inspiring and promise to change the world. But when?

2- Make a distinction between impressive cherry-picked demos, and reliable use cases that are ready for the marketplace

3- Think of models as components of intelligent systems, not minds

4- Generative AI alone is only the tip of the iceberg

---

The article goes into each one with more detail. Welcoming all feedback and perspectives as we collectively figure out this new frontier.
jayalammar
·3 jaar geleden·discuss
They're trained and focused on language data, actually, not code specifically. There are both generation models and multilingual text embedding models (100+ languages, single model).
jayalammar
·3 jaar geleden·discuss
We train and serve large models at cohere.ai. We've shared some optimization techniques here: https://txt.cohere.ai/running-large-language-models-in-produ...