ChatGPT 入門チュートリアル||ChatGPT アプリケーション シナリオ 5: 既存のコンテンツの書き換え||ChatGPT アプリケーション シナリオ 6: 花に着氷—情報解釈

ChatGPT アプリケーション シナリオ 5: 既存のコンテンツの書き換え

シーン紹介

コンテンツを0から生成するだけでなく、すでに書かれたコンテンツをAIに与えてAIに修正させたり、AIにコンテンツの改良を手伝ってもらうこともできます。実際のシーンは以下の通りです。

  1. 翻訳: 中国語の文書を英語に翻訳するか、英語を中国語に翻訳します。翻訳に関しては、ChatGPT は人間の言語を翻訳するだけでなく、Python コードを Haskell コードに翻訳するなど、プログラミング言語も翻訳できることも強調したいと思います。
  2. 変更: コンテンツの文法を変更し、コンテンツ内のタイプミスを特定します。
  3. 研磨: 記事を磨き、内容を別のスタイルに変更すること。

ChatGPTの翻訳機能は既存のGoogle翻訳やBaidu翻訳、bing独自の翻訳よりも優れています!修正・研磨機能も論文修正に大活躍!

この章ではレタッチシーンを中心に、レタッチ例をご紹介します。

プロンプト (Wikipedia からの内容):

Please rewrite the following sentences to make them easier to understand.
OpenAI is an American artificial intelligence (AI) research laboratory consisting of the non-profit OpenAI Incorporated (OpenAI Inc.) and its for-profit subsidiary corporation OpenAI Limited Partnership (OpenAI LP). OpenAI conducts AI research with the declared intention of promoting and developing a friendly AI. OpenAI systems run on the fifth most powerful supercomputer in the world.[5][6][7] The organization was founded in San Francisco in 2015 by Sam Altman, Reid Hoffman, Jessica Livingston, Elon Musk, Ilya Sutskever, Peter Thiel and others,[8][1][9] who collectively pledged US$1 billion. Musk resigned from the board in 2018 but remained a donor. Microsoft provided OpenAI LP with a $1 billion investment in 2019 and a second multi-year investment in January 2023, reported to be $10 billion.[10]

以下の文章を分かりやすく書き直してください。

OpenAI は、非営利団体 OpenAI Incorporated (OpenAI Inc.) とその営利子会社 OpenAI Limited Partnership (OpenAI-LP) で構成される米国の人工知能 (AI) 研究研究所です。OpenAI は、フレンドリーな人工知能の普及と開発を目的として、人工知能の研究を行っています。OpenAI システムは、世界で 5 番目に強力なスーパーコンピューター上で実行されます。[5][6][7] この組織は、サム・アルトマン、リード・ホフマン、ジェシカ・リビングストン、イーロン・マスク、イリヤ・サツコバー、ピーター・ティールらが共同で10億ドルの寄付を約束し、2015年にサンフランシスコで設立された。マスク氏は2018年に取締役を辞任したが、依然として寄付者である。Microsoftは2019年にOpenAI LPに10億ドルの投資を行い、2023年1月には2回目の複数年投資として100億ドルを提供したと伝えられている。[10]

その出力は次のとおりです。

OpenAI is a research organization that focuses on artificial intelligence (AI). It has two parts: a non-profit called OpenAI Incorporated and a for-profit subsidiary called OpenAI Limited Partnership. The organization's goal is to create AI that is friendly and beneficial to humans. OpenAI uses one of the most powerful supercomputers in the world for its research. The organization was founded in San Francisco in 2015 by a group of people who pledged a total of $1 billion, including Sam Altman, Reid Hoffman, Jessica Livingston, Elon Musk, Ilya Sutskever, and Peter Thiel. Musk resigned from the board in 2018 but still supports the organization financially. In 2019, Microsoft invested $1 billion in OpenAI LP, and in January 2023, they made a second investment reported to be $10 billion.
OpenAI は、非営利団体 OpenAI Incorporated (OpenAI Inc.) とその営利子会社 OpenAI Limited Partnership (OpenAI-LP) で構成される米国の人工知能 (AI) 研究研究所です。この組織の目的は、より親しみやすい人工知能の普及と開発を目的として、人工知能の研究を行うことです。OpenAI は、システムの実行に世界で 5 番目に大きいスーパーコンピューターを使用しています。サム・アルトマン、リード・ホフマン、ジェシカ・リビングストン、イーロン・マスク、イリヤ・サツコバー、ピーター・ティールらが共同で10億ドルを寄付し、2015年にサンフランシスコで設立された。マスク氏は2018年に取締役を辞任したが、依然として寄付者である。Microsoftは2019年にOpenAI-LPに10億ドルを投資し、2023年1月には2回目の複数年投資として100億ドルを提供したと伝えられている。

ps: 元のテキストに似ていますが、ChatGPT によって与えられるコンテンツ文法はより口語的で理解しやすいです。

ヒント4:Role(役割)またはキャラクターを追加する

先ほどの書き換え例ではプロンプトにRoleを追加して読みやすくしましたが、この最適化方法でOKです。これも非常によく使われており、例えばメールをビジネスライクにしたい場合は、ビジネス(ビジネス)関連の単語を追加するだけで済みます。

AI によって生成されたコンテンツがよりニーズに応えられるように、プロンプトにロール (役割) 関連のコンテンツを追加する、より効果的なテクニックを紹介します。

たとえば、上記のリライトされた例では、例の前に次のような段落を追加しました。AI に、私が小学校の教師であり、複雑な内容を 7 歳と 8 歳の子供たちが理解できる言葉に変換するのが非常に得意であると想定してもらいました。理解できる場合は、この文を書き直します。

You are a primary school teacher who can explain complex content to a level that a 7 or 8 year old child can understand. Please rewrite the following sentences to make them easier to understand:

あなたは複雑な内容を7、8歳の子供でも理解できるレベルまで説明できる小学校の先生です。次の文章を分かりやすく書き直してください。

出力はこのようになります。単語にしても文法にしても、理解しやすくなった気がします。

OpenAI is a place where people work on making computers really smart. It's like a lab where they do research to make computers do amazing things! They want the computers to be really friendly and helpful to people. They use one of the most powerful computers in the world to do this research. A bunch of really rich and smart people gave money to start this lab. One of them is Elon Musk, but he left in 2018. Another really big company, Microsoft, gave them a lot of money too.

 OpenAI は、コンピューターをより賢く、より使いやすくすることを目標に人工知能を研究する会社です。彼らは仕事を行うために世界で最も強力なコンピューターを使用しています。この会社は、この活動を支援するために多額の寄付をした本当に賢い人々によって設立されました。彼らの中には、マスク氏のように、この取り組みを支援し続ける人もいる。Microsoft も OpenAI をサポートし、人工知能の研究を続けるために多額の資金を提供しました。

AI は役割を追加するだけでなく、人間をシミュレートすることもできます。たとえば、AI に上記の段落をデビッド フォスター ウォレス風に書き換えさせます。

Imagine you are the famous writer David Foster Wallace, please rewrite this sentences.

あなたが有名な作家デイビッド・フォスター・ウォレスであると想像してください。この文を書き直してください。

出力は次のとおりです。

As David Foster Wallace, I might rewrite these sentences to sound more like this:

OpenAI is a lab that studies something called artificial intelligence, which is like when computers can do things that normally only humans can do. They have a big computer that's one of the most powerful in the world, and they're trying to make sure the AI they create is friendly and helpful. The lab was started in 2015 in a city called San Francisco, and a bunch of important people gave them a lot of money to do their research. One of those people was Elon Musk, who stopped working there but still gives them money, and Microsoft also gave them a lot of money recently.

もし私がデヴィッド・フォスター・ウォレスだったら、この文を次のように書くかもしれません。

人工知能研究機関である OpenAI は 2015 年に設立され、サンフランシスコに本社を置いています。その目標は、世界で 5 番目に高速なスーパーコンピューターで実行されるフレンドリーな人工知能を開発し、促進することです。OpenAI は、イーロン マスクのような著名人を含む愛好家のグループによって設立されました。彼らの努力のおかげで、OpenAI は多くの企業や個人から支援を受けており、2019 年には Microsoft も 10 億ドルを投資しました。

このテクニックの応用と、ライティング スキルを向上させるために AI をより効果的に使用する方法については、Nat Eliason の「 ライティング コーチとして ChatGPT を使用する」を読むことをお勧めします。彼は ChatGPT を使用してライティングを 支援し、上記のテクニックを使用しています。 

ChatGPT アプリケーション シナリオ 6: おまけ - 情報解釈

シーン紹介

おまけに 2 番目に大きなシナリオは、情報の解釈です。これは言い換えに似ていますが、同じではありません。情報の解釈により、元のコンテンツよりも多くの情報が提供される可能性があります。

情報解釈の例をいくつか挙げると、誰もが理解できるはずです。

  1. コードを説明する: たとえば、Python コードの一部を見ても理解できない場合は、AI にコードの意味を説明してもらうことができます。
  2. 論文の解釈: 特定の論文や論文内の特定の段落が理解できない場合は、AI に説明してもらうこともできます。

説明コードを例に挙げると、そのプロンプトは次のようになります (このケースは OpenAIの公式ケースから来ています):

Explanation of what the code does:

Python 3 
def remove_common_prefix(x, prefix, ws_prefix): 
    x["completion"] = x["completion"].str[len(prefix) :] 
    if ws_prefix: 
        # keep the single whitespace as prefix 
        x["completion"] = " " + x["completion"] 
return x

以下は ChatGPT の出力であり、このコードが何に使用されるのかを説明し、各パラメーターの意味も説明しています。

This is a Python function called remove_common_prefix that takes in three parameters: x, prefix, and ws_prefix.

The x parameter is assumed to be a Pandas DataFrame or Series object with a column named "completion", which contains strings that may or may not start with the prefix string.

The prefix parameter is a string that represents the common prefix that needs to be removed from the beginning of each string in the "completion" column of the DataFrame.

The ws_prefix parameter is a Boolean value that indicates whether or not to keep a single whitespace character as a prefix after the common prefix has been removed.

The function modifies the "completion" column of the DataFrame by removing the prefix string from the beginning of each string in that column using the Pandas str method and string slicing. The len(prefix) : syntax is used to slice the string starting from the character that follows the prefix.

If ws_prefix is True, then the function adds a single whitespace character as a prefix to each string in the "completion" column after removing the prefix.

Finally, the modified DataFrame is returned by the function.

おすすめ

転載: blog.csdn.net/m0_69824302/article/details/131494703