提取聯系信息 - ChatGPT應用實例

從一段文本中提取聯系信息。
提示
從這封電子郵件中提取姓名和郵寄地址:
親愛的凱利,
在研讨會上與你交談很愉快。我覺得簡的演講非常好。
謝謝你送的書。這是我的地址:2111 Ash Lane,Crestview CA 92002
祝好,
瑪雅
姓名:
示例回答
瑪雅
郵寄地址:2111 Ash Lane,Crestview CA 92002
這是 轉換 分類的頁面,點擊下面标題查看詳細文章内容:
從一段文本中提取聯系信息。
提示
從這封電子郵件中提取姓名和郵寄地址:
親愛的凱利,
在研讨會上與你交談很愉快。我覺得簡的演講非常好。
謝謝你送的書。這是我的地址:2111 Ash Lane,Crestview CA 92002
祝好,
瑪雅
姓名:
示例回答
瑪雅
郵寄地址:2111 Ash Lane,Crestview CA 92002
一個簡單的提示用于從文本中提取機場代碼。
提示
從這段文本中提取機場代碼:
文本:"我想從洛杉矶飛往邁阿密。"
機場代碼:LAX,MIA文本:"我想從奧蘭多飛往波士頓。"
機場代碼:
樣本回答
MCO,BOS
2023年7月25日更新:
從文本中提取機場代碼。
提示
系統
您将收到一條文本,您的任務是從中提取機場代碼。
用戶
我想要從 奧蘭多 飛往 波士頓
樣本回答
奧蘭多和波士頓的機場代碼分别是 MCO 和 BOS。
API請求
{
"model": "gpt-3.5-turbo",
"messages": [
{
"role": "system",
"content": "You will be provided with a text, and your task is to extract the airport codes from it."
},
{
"role": "user",
"content": "I want to fly from Orlando to Boston"
}
],
"temperature": 0,
"max_tokens": 256
}
通過在文本段落的末尾添加 'tl;dr:' 來總結文本。這顯示出 API 知道如何執行許多任務,無需指示。
提示
中子星是一顆質量巨大的超巨星坍塌後的核心,其總質量在10到25個太陽質量之間,如果星星特别富含金屬,可能更多。[1] 中子星是最小、最密的恒星對象,除了黑洞和假設的白洞、誇克星和奇異星。[2] 中子星的半徑大約是10公裡(6.2英裡),質量約為1.4個太陽質量。[3] 它們是由一顆質量巨大的星星的超新星爆炸和重力塌陷産生的,這将核心壓縮過白矮星密度,達到原子核的密度。
Tl;dr
示例回應
中子星是超巨星坍塌後的核心,其半徑約為10公裡,質量約為1.4個太陽質量。它們由質量巨大的星星的超新星爆炸和重力塌陷形成,核心被壓縮至超過白矮星的密度。
從一段文本中提取關鍵詞。在較低的溫度(API中設置temperature值較低)下,它從文本中選擇關鍵詞。在較高的溫度(API中設置temperature值較高)下,它将生成相關的關鍵詞,這對于創建搜索索引非常有幫助。
提示
從這段文本中提取關鍵詞:
Black-on-black ware is a 20th- and 21st-century pottery tradition developed by the Puebloan Native American ceramic artists in Northern New Mexico. Traditional reduction-fired blackware has been made for centuries by pueblo artists. Black-on-black ware of the past century is produced with a smooth surface, with the designs applied through selective burnishing or the application of refractory slip. Another style involves carving or incising designs and selectively polishing the raised areas. For generations several families from Kha'po Owingeh and P'ohwhóge Owingeh pueblos have been making black-on-black ware with the techniques passed down from matriarch potters. Artists from other pueblos have also produced black-on-black ware. Several contemporary artists have created works honoring the pottery of their ancestors.
黑上黑瓷器是 20 世紀和 21 世紀的陶器傳統,由新墨西哥州北部的普韋布洛美洲原住民陶瓷藝術家發展起來。 幾個世紀以來,普韋布洛藝術家一直在制作傳統的還原燒制黑器。 上個世紀的黑上黑瓷器具有光滑的表面,通過選擇性抛光或使用耐火泥漿來施加圖案。 另一種風格涉及雕刻或切割設計并選擇性地抛光凸起區域。 Kha'po Owingeh 和 P'ohwhóge Owingeh 村的幾個家庭世代以來一直采用女族長陶藝家傳承下來的技術制作黑底陶器。 其他普韋布洛的藝術家也制作了黑上黑瓷器。 一些當代藝術家創作了一些作品來紀念他們祖先的陶器。
示例回答
關鍵詞:Black-on-black ware, 20th century, 21st century, Puebloan Native American ceramic artists, Northern New Mexico, reduction-fired blackware, pueblo artists, selective burnishing, refractory slip, carving/incising designs, polishing
黑上黑器皿、20 世紀、21 世紀、普韋布洛美洲原住民陶瓷藝術家、新墨西哥州北部、還原燒制黑器、普韋布洛藝術家、選擇性抛光、耐火泥漿、雕刻/切割設計、抛光
來源:Keywords
2022年7月20日補充:
API請求
{
"model": "gpt-3.5-turbo",
"messages": [
{
"role": "system",
"content": "You will be provided with a block of text, and your task is to extract a list of keywords from it."
},
{
"role": "user",
"content": "Black-on-black ware is a 20th- and 21st-century pottery tradition developed by the Puebloan Native American ceramic artists in Northern New Mexico. Traditional reduction-fired blackware has been made for centuries by pueblo artists. Black-on-black ware of the past century is produced with a smooth surface, with the designs applied through selective burnishing or the application of refractory slip. Another style involves carving or incising designs and selectively polishing the raised areas. For generations several families from Kha'po Owingeh and P'ohwhóge Owingeh pueblos have been making black-on-black ware with the techniques passed down from matriarch potters. Artists from other pueblos have also produced black-on-black ware. Several contemporary artists have created works honoring the pottery of their ancestors."
}
],
"temperature": 0.5,
"max_tokens": 256
}
計算函數的時間複雜度。
提示
def foo(n, k):
accum = 0
for i in range(n):
for l in range(k):
accum += i
return accum
"""
該函數的時間複雜度是
示例回答
O(n*k)。這是因為該函數有兩個嵌套的for循環,分别具有O(n)和O(k)的時間複雜度。因此,總的時間複雜度是兩者的乘積,即O(n*k)。
2022年7月20日補充:
API請求
{
"model": "gpt-3.5-turbo",
"messages": [
{
"role": "system",
"content": "You will be provided with Python code, and your task is to calculate its time complexity."
},
{
"role": "user",
"content": "def foo(n, k):\n accum = 0\n for i in range(n):\n for l in range(k):\n accum += i\n return accum"
}
],
"temperature": 0,
"max_tokens": 256
}
将電影标題轉換為表情符号。
提示
将電影标題轉換為表情符号。
回到未來:👨👴🚗🕒
蝙蝠俠:🤵🦇
變形金剛:🚗🤖
星球大戰:
示例回答
⭐️⚔
2023年7月20日更新:
将常規文本翻譯為表情符号文本。
提示
系統
您将獲得文本,您的任務是将其翻譯成表情符号。 不要使用任何常規文本。 僅使用表情符号盡力而為。用戶
人工智能是一項前景廣闊的技術。
示例回答
🤖🧠📈
API請求
{
"model": "gpt-3.5-turbo",
"messages": [
{
"role": "system",
"content": "You will be provided with text, and your task is to translate it into emojis. Do not use any regular text. Do your best with emojis only."
},
{
"role": "user",
"content": "Artificial intelligence is a technology with great promise."
}
],
"temperature": 0.8,
"max_tokens": 256
}
通過指定結構并提供一些示例,從長格式文本創建表格。
提示
關于Goocrux星球上水果的總結表格:
在最近發現的Goocrux星球上有許多水果。那裡生長着紫色的neoskizzles,味道像糖果。還有灰藍色的loheckles,味道很酸,有點像檸檬。綠色明亮的pounits比較鹹而不甜。還有很多loopnovas,味道像霓虹粉色,像棉花糖一樣。最後,還有一種叫做glowls的水果,味道非常酸和苦,具有酸性和腐蝕性,呈淡橙色。
| 水果 | 顔色 | 味道 |
示例響應
| Neoskizzles | 紫色 | 糖果 |
| Loheckles | 灰藍色 | 酸,像檸檬 |
| Pounits | 綠色明亮 | 鹹 |
| Loopnovas | 霓虹粉色 | 棉花糖 |
| Glowls | 淡橙色 | 酸和苦,酸性和腐蝕性 |
2022年7月20日補充:
API請求
{
"model": "gpt-3.5-turbo",
"messages": [
{
"role": "system",
"content": "You will be provided with unstructured data, and your task is to parse it into CSV format."
},
{
"role": "user",
"content": "There are many fruits that were found on the recently discovered planet Goocrux. There are neoskizzles that grow there, which are purple and taste like candy. There are also loheckles, which are a grayish blue fruit and are very tart, a little bit like a lemon. Pounits are a bright green color and are more savory than sweet. There are also plenty of loopnovas which are a neon pink flavor and taste like cotton candy. Finally, there are fruits called glowls, which have a very sour and bitter taste which is acidic and caustic, and a pale orange tinge to them."
}
],
"temperature": 0,
"max_tokens": 256
}
将自然語言翻譯為SQL查詢。
提示
### Postgres SQL表,及其屬性:
#
# Employee(id, name, department_id)
# Department(id, name, address)
# Salary_Payments(id, employee_id, amount, date)
#
### 查詢在過去3個月内雇傭了超過10名員工的部門名稱
SELECT
示例響應
SELECT d.name
FROM Department d
INNER JOIN Employee e ON d.id = e.department_id
INNER JOIN Salary_Payments sp ON e.id = sp.employee_id
WHERE sp.date > NOW() - INTERVAL '3 months'
GROUP BY d.name
HAVING COUNT(*) > 10
創建使用自然語言調用Stripe API的代碼。
提示
"""
Util暴露以下内容:util.stripe() -> 認證并返回Stripe模塊;可用作stripe.Charge.create等
"""
import util
"""
使用用戶的信用卡(卡号:5555-4444-3333-2222,到期日期:12/28,CVC:521)創建Stripe令牌
"""
示例響應
token = stripe.Token.create(
card={
"number": "5555-4444-3333-2222",
"exp_month": 12,
"exp_year": 28,
"cvc": 521
},
)
"""
2002-2023 v11.7 a-j-e-0