見出し画像

【HuggingChat】英語解説を日本語で読む【2023年4月26日|@Prompt Engineering】

Hugging Chatの解説です。
Open AssistantモデルとHugging Face Inference APIを使用し、ChatGPTの代替手段を提供します。
公開日:2023年4月26日
※動画を再生してから読むのがオススメです。


This is probably one of the biggest developments when it comes to a free and open source alternative to ChatGPT.

これは、ChatGPTに代わるフリーでオープンソースのものということでは、おそらく最も大きな進展の1つでしょう。

The CEO of Hugging Face just announced the release of Hugging Chat, an open source early prototype interface powered by Open Assistant.

Hugging FaceのCEOは、Open Assistantを搭載したオープンソースの初期プロトタイプインターフェースであるHugging Chatのリリースを発表しました。

Hugging Face, if you don't know, is the company that has really democratized access to AI for masses and they are hosting a large number of open source models as well as datasets.

Hugging Faceは、AIへのアクセスを大衆向けに民主化した会社で、多数のオープンソースモデルとデータセットをホストしています。

For applications related to computer vision, natural language processing, audio processing and a whole bunch of multi-model models.

コンピュータビジョン、自然言語処理、音声処理に関連するアプリケーションや、マルチモデルモデルを大量に提供しています。

Just to be clear, it's not a new open source model, but an interface where you can interact with different open source models.

はっきり言って、これは新しいオープンソースモデルではなく、異なるオープンソースモデルと対話できるインターフェースなのです。

Before playing around with this new chat, let's look at some of the distinguishing features.

この新しいチャットで遊ぶ前に、特徴的な機能をいくつか見てみましょう。

So in terms of privacy, according to them, in this v0 of Hugging Chat, we only store messages to display them to the user, not for any other usage, including for research or model training purposes.

プライバシーに関しては、彼らによると、このハグチャットのv0では、ユーザーに表示するためにメッセージを保存するだけで、研究やモデルトレーニングの目的も含め、他の用途には使用しないとのことです。

So they are not collecting any data, unlike ChatGPT or OpenAI.

つまり、ChatGPTやOpenAIと違って、データを収集することはないそうです。

And in order to use this currently, you don't even need to have an account with Hugging Face.

また、現在これを利用するためには、ハグみんのアカウントも必要ありません。

So in this case, you just need to be very careful with your cookies if you want to keep your browser or chat history.

だからこの場合、ブラウザやチャットの履歴を残したいなら、Cookieの扱いに細心の注意を払えばいいだけです。

Because according to them, if you clear your cookies or switch the browser, all your conversations are going to be lost.

彼らによると、Cookieをクリアしたり、ブラウザを切り替えたりすると、すべての会話が消えてしまうそうですから。

As I said before, they're not collecting any data.

先ほども言ったように、彼らはデータを収集しているわけではありません。

But in future, they might introduce a feature in which you can let the authors of the model collect your data and use that for training purposes.

しかし、将来的には、モデルの作者にあなたのデータを収集させ、それをトレーニングの目的で使用できるようにする機能を導入するかもしれません。

But you're going to have the control on the data that you generate.

しかし、自分が生成したデータは自分で管理することになります。

They're interfacing this with Open Assistant.

現在、Open Assistantと連動させています。

But in future, they plan to actually integrate other open source models as well.

しかし、将来的には、他のオープンソースモデルも統合する予定だそうです。

Now here is the best part.

さて、ここが一番いいところです。

It's running in a space.

これは宇宙で動いているのです。

So that means that the code for the UI is open source, which means that you can actually copy this into another space and customize it.

つまり、UIのコードはオープンソースなので、これを他のスペースにコピーしてカスタマイズすることができるのです。

So you can even right now, replace the model with some other model that you want, or you can update the user interface.

つまり、今すぐにでも、モデルを好きな別のモデルに置き換えることができますし、ユーザーインターフェイスを更新することも可能です。

You can add memory to the model if you want to.

必要であれば、このモデルにメモリを追加することもできます。

Here's the chat interface.

こちらはチャットのインターフェースです。

If you want to start a new chat, you can go and click on new chat.

新しいチャットを始めたい場合は、「new chat」をクリックすればOKです。

It looks to be inspired by ChatGPT.

ChatGPTにインスパイアされているようです。

It has a very similar feel to it.

とてもよく似た雰囲気です。

And then there is this button here where you can change a theme.

そして、このボタンをクリックすると、テーマを変更することができます。

So let's say it's a dark theme right now.

例えば、今はダークテーマだとします。

And you can change it the way you want, which is pretty neat.

好きなように変えられるので、とても便利です。

A few things before we play around with the model.

モデルを操作する前に、いくつか確認しておきたいことがあります。

So first thing you will notice is the model is Open Assistant.

まず最初に、モデルがOpen Assistantであることにお気づきでしょうか。

It's a NAMA 30 bin parameter model.

NAMA 30ビン・パラメータ・モデルです。

And then there is a small disclaimer, generated content may be inaccurate or false.

そして、「生成されたコンテンツは不正確または虚偽である可能性があります」という小さな免責事項があります。

Here it says that this is the v0.

これはv0と書かれています。

So keep in mind, this is a very early version and the model may not be great, but it's just the start.

これは非常に初期のバージョンで、モデルはあまり良くないかもしれませんが、まだ始まったばかりだということを念頭に置いておいてください。

Now the model information is all here.

さて、モデルの情報はすべてここにあります。

So let's say you can click on this.

これをクリックしてみましょう。

You can go and look at the model page.

モデルのページに移動して見ることができます。

Similarly, there is a link regarding the data set that is being used for training the model.

同様に、モデルのトレーニングに使用されるデータセットに関するリンクがあります。

Now this is great to have all the transparency regarding your model as well as the data set.

このように、モデルやデータセットに関するすべての透明性を確保することができるのは素晴らしいことです。

As I said, you actually have the ability to replace this model with another model.

先ほど言ったように、このモデルを別のモデルに置き換えることも可能です。

You just need to copy this UI into your own space and then you can make changes.

このUIを自分のスペースにコピーして、変更することができます。

Another thing is, since Hugging Face is storing all these different open source models, so there is a possibility that you can have different apps in here.

もうひとつは、ハギング・フェイスはさまざまなオープンソースのモデルを保存しているので、ここにさまざまなアプリを入れることができる可能性があります。

So if you recall, there was a paper called Hugging GPT, for which it gets very close to the everything app version that people describe, right?

思い起こせば、Hugging GPTという論文がありましたが、この論文では、人々が説明するアプリのバージョンに非常に近づいていますよね?

So essentially in that paper, Microsoft researcher used models hosted on Hugging Face to perform different operations.

その論文では、マイクロソフトの研究者がHugging Faceにホストされたモデルを使って、さまざまな操作を行ったということです。

Now if somebody wants to do it, it's actually possible in here.

誰かがそれをやろうと思えば、ここでも実際に可能なのです。

Okay.

なるほど。

Let's look at some examples.

では、いくつかの例を見てみましょう。

In here, they are definitely taking inspiration from ChatGPT.

ここでは、ChatGPTからインスピレーションを得ていることは間違いありません。

So let's see, we're going to click on this one, write an email.

では、これをクリックして、メールを書いてみましょう。

Okay.

なるほど。

So as a restaurant owner, write a professional email to the supplier to get these products every week.

レストランのオーナーとして、毎週これらの商品を手に入れるために、サプライヤーにプロフェッショナルなメールを書いてください。

So wine, eggs, and bread, right?

ワイン、卵、パン、ですね。

And here is the email that it wrote.

そして、これがその書いたメールです。

I hope this email finds you well.

このメールがあなたの元に届くことを祈っています。

I'm writing on behalf of our restaurant to inquire about your availability for regular deliveries of certain products that we use in our kitchen, right?

私たちのレストランを代表して、私たちのキッチンで使っているある製品の定期配送の可否を問い合わせるために書いているんですよ。

And so this is the quantity, let's see if it got it correct or not, 10, 24, 12.

で、これが数量なんだけど、これが正しいかどうかは別として、10、24、12。

That's pretty nice.

これはなかなかいい感じです。

The rest of the email is also pretty coherent, right?

メールの残りの部分も、かなり首尾一貫していますね。

Now if you look at here on the left hand side, it actually auto-generated a title for your chat.

左側を見てみると、チャットのタイトルが自動生成されています。

That is pretty neat.

これはとても素晴らしいことです。

It again seems to be inspired from ChatGPT.

これもChatGPTにインスパイアされているようです。

Okay.

なるほど。

Let's click on a new chat.

新しいチャットをクリックしてみましょう。

Okay.

はい。

Let's ask it another question.

別の質問をしてみましょう。

It's an open source model.

これはオープンソースのモデルです。

So give me five reasons why open source large language models are better than closed source models.

では、オープンソースの大規模言語モデルがクローズドソースのモデルよりも優れている理由を5つ教えてください。

So let's see what it comes up with.

では、どんな答えが返ってくるか見てみましょう。

If you look at it, actually the generation speed is pretty good.

見てみると、実は生成速度がかなりいいんです。

It's pretty fast.

かなり速いですね。

Okay.

なるほど。

So here are the five potential advantages of open source or closed source.

では、オープンソースとクローズドソースの潜在的な利点を5つ挙げてみましょう。

So community involvement and contribution, customizability, cost saving, security, freedom of choice.

コミュニティへの参加と貢献、カスタマイズ性、コスト削減、セキュリティ、選択の自由。

There seems to be very valid reasons.

非常に有効な理由があるようです。

So open source project, often a large community of contributors who can provide feedback, report bugs, suggest improvements and contribute code to the project.

オープンソースプロジェクトは、多くの場合、フィードバックを提供し、バグを報告し、改善を提案し、プロジェクトにコードを提供することができる貢献者の大規模なコミュニティを持っています。

This means that the open source project, open source software is likely to be more extensively tested and may receive more frequent updates and bug fixes.

つまり、オープンソースプロジェクトやオープンソースソフトウェアは、より広範囲にテストされ、より頻繁にアップデートやバグフィックスを受けられる可能性があるのです。

So these are pretty good responses, I think.

というわけで、これらはかなり良い回答だと思います。

I'll give it at least a B plus or A. Not bad at all.

少なくともBプラスかAをつけたいところですが、まったく悪くありません。

Now if you want to actually play around with the underlying model, this Open Assistant model, I have a video on this.

さて、このOpen Assistantという基礎的なモデルを実際に使ってみたいという方には、ビデオを用意しています。

So I'm going to link it here.

ここにリンクを貼っておきますね。

Now again, if you look here, it created another chat for you.

ここでもまた、あなたのために別のチャットが作成されていることがわかります。

So that's pretty awesome.

これはとても素晴らしいことです。

And then here is a small link, share this conversation.

そして、ここに小さなリンクがあり、この会話を共有することができます。

So let's see what this does.

これが何をするのか見てみましょう。

So it creates a link that you can share on your social media.

ソーシャルメディアに共有するためのリンクが作成されます。

If you want, let me copy this and test it out in another window.

もしよろしければ、これをコピーして別のウィンドウでテストしてみましょう。

Okay, I opened it in incognito window.

シークレットウィンドウで開いてみました。

It seems to be storing that chat.

チャットが保存されているようです。

So you can actually share your chat with other folks.

だから、実際に他の人とチャットを共有することができます。

Keep in mind right now, as I said, you don't really need to make an account so anybody can play around with it.

今言ったように、アカウントを作る必要はないので、誰でも遊べるということを念頭に置いておいてください。

Now let's ask it a programming question.

では、プログラミングの質問をしてみましょう。

So here is a normal font that I used.

ここでは、私が使用した通常のフォントを紹介します。

Create a Python function to write a file to NS3 bucket using the Boto library.

Botoライブラリを使ってNS3のバケットにファイルを書き込むPython関数を作ってください。

Let's see if it can do that.

それが出来るかどうか見てみましょう。

It's a pretty trivial task.

かなり些細なことなんですけどね。

So if it does search online, it should be able to put something together and is able to generate the code.

だから、ネットで検索すれば、何かをまとめることができるはずだし、コードを生成することもできる。

So that's pretty nice.

これはかなりいい感じです。

Now overall, it seems to be working pretty nice, nicely.

さて、全体として、かなりいい感じで動いているようです。

One thing I wanted to highlight is that the focus is not really on the model in this case; but rather, the HuggingChat interface, where you will be able to integrate different models that are either on Hugging Face or potentially your own models, and play around with it.

この場合、焦点はモデルではなく、HuggingChatのインターフェースにあります。

It's probably one of the best open source interface that I have seen so far, which is pretty awesome.

これは、私がこれまでに見たオープンソースのインターフェースの中で、おそらく最も優れたものの1つで、とても素晴らしいものです。

It's pretty neat, pretty simple.

とてもきれいで、とてもシンプルです。

It mimics ChatGPT interface, so it will look very familiar.

ChatGPTのインターフェイスを模倣しているので、とても見慣れたものになるでしょう。

And in my opinion, Hugging Face is in a really good position to actually build some really cool apps on top of their platform, because they already have access to all the open source models you can think of.

私の意見では、Hugging Faceは、彼らのプラットフォームの上に本当にクールなアプリを構築するのにとても良い位置にいます。なぜなら、彼らはすでにあなたが考えることができるすべてのオープンソースモデルにアクセスすることができるからです。

And it could be a really good alternative to ChatGPT or OpenAI models.

そして、ChatGPTやOpenAIのモデルに代わる、とても良い選択肢になるかもしれません。

So we just hit 75,000 subscribers in almost four months.

というわけで、約4ヶ月で75,000人のチャンネル登録者を達成したところです。

If you are new to the channel, I make videos and tutorials related to large language models, image generation models, and anything AI related.

このチャンネルを初めてご覧になる方は、大規模な言語モデルや画像生成モデル、AIに関連するあらゆるものに関連するビデオやチュートリアルを作っています。

Check out all the other videos on the channel.

チャンネルにある他の動画もすべてチェックしてみてください。

And if there are any specific topics you guys want me to create videos or tutorials, let me know in the comment section below.

そして、もし皆さんが私にビデオやチュートリアルを作ってほしい特定のトピックがあれば、下のコメント欄で教えてください。

I'd be happy to make them.

喜んで作りますよ。

Make sure you subscribe to the channel for more updates, and hit that bell notification button so you don't miss any new video here.

また、チャンネル登録をして、新しい動画を見逃さないように、ベル通知ボタンを押してくださいね。

Just wanted to give you a quick update on HuggingChat; a more detailed video containing comparison to ChatGPT is coming soon.

HuggingChatの簡単な最新情報をお伝えしたいと思います。ChatGPTとの比較を含むより詳細なビデオは近日公開予定です。

Thanks for watching.

ご覧いただきありがとうございました。

I'll see you in the next one.

次のビデオでお会いしましょう。

この記事が気に入ったらサポートをしてみませんか?