2023年12月11日 星期一

Prompting as a process

提示(Prompt)撰寫其實是一個逐步修正的過程,不要期待第一次就上手

  1. 迭代式提示開發: 創建有效的提示通常需要多次迭代。初始提示可能無法完全符合預期的結果。因此,根據初始輸出對提示進行精煉至關重要。


  2. 清晰和具體: 在提示的指令中清晰和具體很重要。無論是字數、句子結構還是特定所需的詳細資訊,都提供清晰的指導對於模型獲得更準確的結果至關重要。


  3. 調整提示: 如果初始輸出不符合期望(例如,長度過長或缺少特定資訊),則需要修改指令。這可能涉及調整字數、添加或更改特定細節,或改變輸出的焦點。


  4. 複雜的提示: 隨著時間的推移,隨著迭代的進行,提示可能變得更加詳細和複雜。這種複雜性可能包括格式要求(如HTML輸出)或要求特定的數據安排(如表格)。


  5. 應用軟體的成熟度: 隨著應用的成熟,對提示進行評估,應對較大量的示例進行評估變得至關重要,以確保在不同的輸入下具有一致且準確的性能。


  6. 整體而言,透過迭代方法開發提示,從單一示例開始,逐步根據輸出精煉指令,有助於為利用LLM的各種應用程式打造有效的提示。


Example: Test of comprehension 

Version 1: Generate the problems

Prepare 10 multiple choice problems from the paste text above to test comprehension.

  1. Shani Dhanda's activism primarily focuses on:
    A) Raising awareness for mental health issues
    B) Advocating for environmental sustainability
    C) Promoting cultural diversity
    D) Advocating for the rights of people with disabilities
    What year did Shani Dhanda organize the first event supporting disabled individuals and South Asian women?
    A) 2018
    B) 2019
    C) 2020
    D) 2021
    What medical condition does Shani Dhanda have?
    A) Rare genetic disorder
    B) Brittle Bone Disease
    C) Chronic fatigue syndrome
    D) Muscular dystrophy
    The "Diversability Card" app created by Shani Dhanda aims to provide:
    A) Social media networking for disabled individuals
    B) Travel guidance for people with disabilities
    C) Restaurant ratings and food delivery services
    D) Discounts for people with disabilities
    Shani Dhanda's vision for the future primarily revolves around:
    A) Global entrepreneurship programs
    B) Financial independence for disabled individuals
    C) Reducing carbon emissions
    D) Increasing government funding for disability services


Version 2: Making it more interactive

Prepare 10 multiple choice problems from the paste text above to test comprehension. Generate one problem at a time. Then you request an answer. Then generate next problem.

Version 3 Adding the grading 

Prepare 10 multiple choice problems from the paste text above to test comprehension. Generate one problem at a time. Then you request an answer. After you receive one, grade it. Then generate next problem. 

Version 4 Calculating the total score

Prepare 10 multiple choice problems from the paste text above to test comprehension. Generate one problem at a time. Then you request an answer. After you receive one, grade it. Then generate next problem. In the end, tell me out of the 10 questions above, how many questions are correctly answered?


Example: Test of vocabulary

Version 1 Generate the problems

Based on the vocabulary: (Exoskeleton, Myoelectric, Sensors, Hydraulic, Cylinder, Prosthesis, Rehabilitation, Paralysis, Spinal cord, Neural),  prepare 5 fill the blank quiz questions. 

  1. The ___________ system in robotics uses electrical signals generated by muscle contractions to control artificial limbs or devices.
  2. Sensors integrated into exoskeletons enable the detection of motion and force, allowing for precise ___________ control in assisting movements.
  3. A ___________ cylinder is a mechanical device that uses fluid power to perform various tasks, often employed in advanced prosthetic designs for enhanced functionality.
  4. ___________ is a process that aims to restore functions to the body after an injury, commonly employed after amputation to adapt to a new prosthesis.
  5. Damage to the ___________ cord can result in loss of sensation or motor function below the injury site, leading to conditions such as paralysis.

Version 2 One at a time

Based on the vocabulary: (Exoskeleton, Myoelectric, Sensors, Hydraulic, Cylinder, Prosthesis, Rehabilitation, Paralysis, Spinal cord, Neural),  prepare 5 fill the blank quiz questions.  Generate one problem at a time. Then you request an answer.  Then generate next problem. 

Version 3 Grading answer interactively

Based on the vocabulary: (Exoskeleton, Myoelectric, Sensors, Hydraulic, Cylinder, Prosthesis, Rehabilitation, Paralysis, Spinal cord, Neural),  prepare 5 fill the blank quiz questions.  Generate one problem at a time. Then you request an answer. After you receive one, grade it. Then generate next problem. 

Version 4 Total score

Based on the vocabulary: (Exoskeleton, Myoelectric, Sensors, Hydraulic, Cylinder, Prosthesis, Rehabilitation, Paralysis, Spinal cord, Neural), prepare 5 fill the blank quiz questions. Each question has only one missing word. Generate one problem at a time. Then you request an answer. After you receive one, grade it. Then generate next problem. In the end tell me how many are correctly answered.

Version 5 Randomize

Based on the vocabulary: (Exoskeleton, Myoelectric, Sensors, Hydraulic, Cylinder, Prosthesis, Rehabilitation, Paralysis, Spinal cord, Neural), randomize the order of these words and then prepare 5 fill the blank quiz questions.  Generate one problem at a time. Then you request an answer. After you receive one, grade it. Then generate next problem. In the end tell me how many are correctly answered.

Version 6 Limiting the # of blanks to one

Based on the vocabulary: (Exoskeleton, Myoelectric, Sensors, Hydraulic, Cylinder, Prosthesis, Rehabilitation, Paralysis, Spinal cord, Neural), randomize the order of these words and then prepare 5 fill the blank quiz questions. Each question has only one missing word. Generate one problem at a time. Then you request an answer. After you receive one, grade it. Then generate next problem. In the end tell me how many are correctly answered.


based on ChatGPT and the course in https://learn.deeplearning.ai/chatgpt-prompt-eng/lesson/3/iterative



AI Workshop 來寫寫Python程式吧 (12/12)

方便的話,可以攜帶筆電或是平板等螢幕比較大的設備,不過只有手機也是沒問題的。

AI工作坊主要內容請參看 https://nptechsl.blogspot.com/2023/12/ai-workshop.html

裡面有七個程式實作單元,12/12第一次工作坊預計進行單元一(Iteration) 與單元二(Summarize)

有任何問題都可以隨時聯絡我

2023年11月13日 星期一

AI tools for self evaluation of comprehension

 Using ChatGPT 3.5 (or Claude)

1. Copy the transcript of the video clip  無人機改變物流:凱勒·里諾多 / Zipline執行長 video 15:00  and paste it on ChatGPT 

2. Enter the prompt: 

Prepare 10 multiple choice problems from the paste text above to test comprehension. Generate one problem at a time. Then you request an answer. After you receive one, grade it. Then generate next problem. In the end, tell me out of the 10 questions above, how many questions are correctly answered?

3. Answer each question. ChatGPT will grade it and generate the next question until 10 questions are generated.


Mail to chang212@gmail.com

2023年11月6日 星期一

AI tools for academic research

這個工具利用AI從論文中自動提取重要內容,生成簡明筆記。只需提供PDF檔,就可獲得涵蓋論文主要部分的提要。

如果有不熟悉的概念,可以讓AI進行通俗解釋。這樣,即使面對陌生領域,也可以快速抓住論文要點。

利用這工具高效掌握內容。你可以持續關注領域裡的最新論文。

這可以成為你學術研讀的一大助力!希望你可以善用這個工具,在學術領域不斷精進!


Guidelines when using generative AI tools

注意 不要將個人資料(例如個人財務,健康狀況),隱私或不可告知他人的資料(例如他人的研究資料)輸入給ChatGPT/Claude,以免危害自己或他人的利益。


Reading a document (pdf)

1. Using Claude, upload the pdf and summarize the paper.

2. Make 10 slides for this paper.

3. Translate the summary and the slides. 請翻譯這篇論文的摘要以及投影片。

4. 輸入「幫我做成筆記好嗎」

5. Comprehension test. Enter the prompt: 

Prepare 10 multiple choice problems from the paste text above to test comprehension. Generate one problem at a time. Then you request an answer. After you receive one, grade it. Then generate next problem. In the end, tell me out of the 10 questions above, how many questions are correctly answered?








11/7 使用AI深入服務設計

 11/7 上課大綱

http://nptechsl.blogspot.com/2023/10/blog-post_70.html?m=1

探索社會企業和社會服務,我們將討論兩個主題:

1. **另類美食餐廳 InGalera** - 一家位於監獄內的餐廳如何改變了囚犯的生活,我們將透過一段15分鐘的影片深入探討,並瞭解其背後的故事。

2. **機器人 x 身障就業** - 身障人士如何透過機器人技術找到就業機會,我們將觀賞一段28分鐘的影片(有效期至11/17/2023),並了解這個數位包容的主題。

除此之外,我們將進行一系列實作練習,使用AI助手來應對不同挑戰,包括編輯服務文件、專業翻譯和編寫紀錄。最後,我們還將練習製作一個10頁的簡報,分享這些服務設計的故事。


Guidelines when using generative AI

 有一些不錯的生成式AI 工具可供使用,例如

There are some excellent generative AI tools available for use, such as:



然而在使用AI時,需要注意以下:

  1. AI 不是永遠正確,請謹慎使用。(你可以想一想為甚麼AI會犯錯)
  2. 使用AI激發創意靈感,而非取代人的思考。
  3. 外文著作若具版權保護,請勿直接使用機器翻譯後進行使用,這可能構成重製並侵害著作權。
  4. 使用AI工具時請謹慎,避免濫用。
  5. 上傳個人、他人隱私資料或專業保密資訊至AI雲端,可能會違反法律,請注意維護個人與當事人權益。
  6. AI能力仍有限,使用時需注意判斷,避免錯誤。


However, when using AI, it is important to be mindful of the following:

  1. AI is not always correct, so please use it cautiously. (Consider what situations AI might make mistakes in.)
  2. Use AI to spark creative inspiration, not to replace human thinking.
  3. If foreign works are protected by copyright, avoid using machine-translated versions directly, as this may constitute reproduction and copyright infringement.
  4. Exercise caution when using AI tools to avoid misuse.
  5. Uploading personal, others' private information, or confidential professional data to AI clouds may violate laws, so be mindful of safeguarding personal and stakeholders' rights.
  6. AI capabilities are still limited, so exercise judgment and be cautious to prevent errors when using it.