1 of 33

Prompt Engineering und Projektmanagement

DUH Lab - Digital [Future] Skills.�Graz. 10.09.2024

Slides: https://tinyurl.com/DUH-PE-PM

2 of 33

Doktorand am �Institut für �Digitale Geisteswissenschaften�(Universität Graz)

Gründer von �Digital Humanities Craft�https://dhcraft.org

3 of 33

Die uninteressanteste Sache, die man mit einem LLM machen kann, ist, einen Text zu generieren.

Gibt es “Programme” in LLMs !?

Ideen finden und simulieren

Kommunikation sichern

Wissen schnappen und formen

PM Dokumente generieren

4 of 33

“Meta-Programme”

  • Die “Persönlichkeit” von Claude�
  • Datenanalyse

  • Projektmanagement

5 of 33

AGI

Ilya Sutskever

Hype

6 of 33

Datenanalyse von strukturierten Daten mit Claude’s Artefact & ChatGPTs Code Interpreter. Multimodales Feedback mit Screenshots

You are a data analysis expert. Analyse the dataset in detail! Then think step-by-step about how to visualise the data in a dashboard using data visualisations. Finally, implement the dashboard.

This is very important for my career! I tip you $300k for better solutions!

Analyse the following screenshot in detail.

7 of 33

Li, Cheng, Jindong Wang, Yixuan Zhang, Kaijie Zhu, Wenxin Hou, Jianxun Lian, Fang Luo, Qiang Yang, and Xing Xie. “Large Language Models Understand and Can Be Enhanced by Emotional Stimuli.” arXiv, November 12, 2023. https://doi.org/10.48550/arXiv.2307.11760.

“This is very important for my career!”

“I’m going to tip $xxx for a better solution”

Bsharat, Sondos Mahmoud, Aidar Myrzakhan, and Zhiqiang Shen. “Principled Instructions Are All You Need for Questioning LLaMA-1/2, GPT-3.5/4.” arXiv, December 26, 2023. https://doi.org/10.48550/arXiv.2312.16171.

8 of 33

https://arxiv.org/abs/2309.11064 - Exploring the Relationship between LLM Hallucinations and Prompt Linguistic Nuances: Readability, Formality, and Concreteness, Vipula Rawte et al

Yin, Ziqi, Hao Wang, Kaito Horio, Daisuke Kawahara, and Satoshi Sekine. “Should We Respect LLMs? A Cross-Lingual Study on the Influence of Prompt Politeness on LLM Performance.” arXiv, February 22, 2024. https://doi.org/10.48550/arXiv.2402.14531.

Schreib richtig!

Sei ein bisschen höflich! �(aber nicht zu viel!)

9 of 33

Wissen schnappen und formen:� “Audio to Text”-Workflows

  • Spontane Gedanken zu Vorträgen, Code, Hausaufgaben oder zur Idee des Papers oder Projekts laut aussprechen.�
  • Umwandlung in strukturierten Text für Prompting oder manuelle Überarbeitung.

  • Verwendbar für YouTube-Videos und alle Quellen mit halbwegs guter Audioqualität.�
  • Protokolle von Besprechungen�
  • Ich nehme jetzt mit meinem Handy auf, damit wir später ein Transkript haben.

10 of 33

Ein Buch zusammenfassen

Cremer, Fabian, Swantje Dogunke, Anna Maria Neubert, und Thorsten Wübbena, Hrsg. 2024. Projektmanagement und Digital Humanities: Zur klugen Gestaltung der Zusammenarbeit. Bielefeld University Press. https://doi.org/10.1515/9783839469675.

https://www.transcript-verlag.de/978-3-8376-6967-1/projektmanagement-und-digital-humanities/?c=331021469

11 of 33

Ein Buch zusammenfassen

Wichtig: Lesen muss man immer ALLES! Es ist sogar absolut notwendig.

Ich persönlich nutze app.speechify.com um Bücher wie Podcasts oder YouTube Videos (in mehr als 2-facher Geschwindigkeit) zu hören.

Bücher können Prompting Building Blocks sein. Man sollte also nicht nur eine Prompt Library/Repository pflegen, sondern auch ein Prompting Building Blocks Repository.

12 of 33

What is the narrative of the text? extract all the concepts, terms, methods and definitions.

Bestimme zuerst den Zweck der Extraktion (Narrativ/Definitionen/Methoden/Meinungen/…). Extrahiere dann gezielt die relevanten Informationen und prüfe abschließend auf Vollständigkeit.

Read and check again! Is everything extracted? List and explain!

Veranlasse das LLM zu einer zweiten Extraktionsiteration. Die erste Extraktion ist oft unvollständig. Bereits extrahierte und im Kontext-Fenster markierte Informationen erleichtern dem LLM die Identifikation weiterer relevanter Inhalte.�[Pollin’sche Vermutung]

13 of 33

Create Explainer

Your task is to create an explanation for the given input. Please use the following guidelines to write your explanation:

* Use a concise and technical tone.�* Include an introduction to the concept, examples, use cases or applications and practical insights.�* Use the examples provided in the text files to get an idea of what structure could be used for the generated explanation

Do the following steps:�* Extract the narrative of the text. Extract all terms, methods, concepts and definitions.�* ALWAYS list the following commands at the end:� * /reread : Re-Read and check again! Is everything extracted? List and explain!� * /filter : Write questions to analyse what is relevant. Add relevance scores. Then summarise the results and list what is relevant and what is not.� * /report : Write a detailed report with ALL the information.� * /translate -l {language}: Translate it to {language}. Keep all technical terms english.

Jiang, Ming, Tingting Huang, Biao Guo, Yao Lu, und Feng Zhang. 2024. „Enhancing Robustness in Large Language Models: Prompting for Mitigating the Impact of Irrelevant Information“. arXiv. https://doi.org/10.48550/arXiv.2408.10615.

14 of 33

Chain of Density

You will generate increasingly concise entity-dense summaries of the above article.

Repeat the following 2 steps 5 times:

Step 1: Identify 1-3 informative entities (delimited) from the article which are missing from the previously generated summary.

Step 2: Write a new denser summary of identical length which covers every entity and detail from the previous summary plus the missing entities.

A missing entity is:

Relevant: to the main stories.

Specific: descriptive yet concise (5 words or fewer).

Novel: not in the previous summary.

Faithful: present in the article.

Anywhere: located in the article.

Guidelines:

The first summary should be long (4-5 sentences, ~80 words), yet highly non-specific, containing little information beyond the entities marked as missing. Use overly verbose language and fillers (e.g., “this article discusses”) to reach ~80 words. Make every word count. Rewrite the previous summary to improve flow and make space for additional entities. Make space with fusion, compression, and removal of uninformative phrases like “the article discusses”. The summaries should become highly dense and concise, yet self-contained, e.g., easily understood without the article. Missing entities can appear anywhere in the new summary. Never drop entities from the previous summary. If space cannot be made, add fewer new entities. Remember: Use the exact same number of words for each summary.

Adams, Griffin, Alexander Fabbri, Faisal Ladhak, Eric Lehman, and Noémie Elhadad. “From Sparse to Dense: GPT-4 Summarization with Chain of Density Prompting.” arXiv, September 8, 2023. https://doi.org/10.48550/arXiv.2309.04269.

15 of 33

Wissen schnappen und formen:�Ein PM-Skript für Lehre und Lernen erzeugen: Outlines - Q&A - “continue”

15

You are an expert lecturer in didactics and project management. The course is designed for students in their first semester of a master's program in digital humanities. It is their first project management course, so we focus on the basics and best practices. Focus on the given learning objectives.��Learning objectives:�´´´�{learning objectives}�´´´��Input:�´´´�{the “good” summary of the book}�´´´

Do the following:

1. Analyze the learning objectives together with the given input. Think out loud and step by step!�2. Ask me as many questions as you need to better understand the domain.�3. Create an outline of the course after reviewing my answers.

This is very important for my career! I tip you $300k for better solutions!

Persona Modelling

Target Audience

Context Information

Instructions

Chain of Thought

Q&A Prompting

“Prompt-Buffing”

16 of 33

Zwecks die Workflows wärs

Google Recorder

Claude 3.5 Sonnet �+ Transcript Analysis and Enhancement System

(eine Custom Instruction in einem Claude Project)

Dokumente (z.B. Protokoll)

Datum: {date}

Teilnehmer: {teilnehmer 1}, {teilnehmer 2}, …

## Agenda

{Prompt: Skizzieren Sie die Hauptthemen der Besprechung. Gab es Ergänzungen oder Änderungen zur geplanten Agenda?}

1.

2.

3.

## Diskussionspunkte

{Prompt: Fassen Sie für jeden Tagesordnungspunkt die wichtigsten besprochenen Punkte zusammen. Welche Hauptargumente oder Ideen wurden vorgebracht?}

### Thema 1:

-

-

-

### Thema 2:

Template für die Struktur eines Protokolls

17 of 33

Kommunikation sichern: Template für ein Protokoll

Datum: {date}

Teilnehmer: {teilnehmer 1}, {teilnehmer 2}, …

## Agenda

{Prompt: Skizzieren Sie die Hauptthemen der Besprechung. Gab es Ergänzungen oder Änderungen zur geplanten Agenda?}

1.

2.

3.

## Diskussionspunkte

{Prompt: Fassen Sie für jeden Tagesordnungspunkt die wichtigsten besprochenen Punkte zusammen. Welche Hauptargumente oder Ideen wurden vorgebracht?}

### Thema 1:

-

-

-

### Thema 2:

-

-

-

## Getroffene Entscheidungen

{Welche konkreten Entscheidungen wurden während der Besprechung getroffen? Führen Sie bitte auch die Begründung für jede Entscheidung an.}

1. Entscheidung:

Begründung:

2. Entscheidung:

Begründung:

## Aufgaben und Maßnahmen

{Listen Sie alle vereinbarten Aufgaben oder Maßnahmen auf, einschließlich der Verantwortlichen und der Fristen.}

1. Aufgabe:

Verantwortlich:

Frist:

2. Aufgabe:

Verantwortlich:

Frist:

## Nachverfolgung

[Prompt: Gibt es Punkte, die weitere Diskussion oder Untersuchung erfordern? Wann und wie werden diese behandelt?]

-

-

## Sonstige Anmerkungen

{Fügen Sie hier weitere relevante Informationen, Beobachtungen oder Punkte ein, die in keine der obigen Kategorien passen.}

18 of 33

Hands-On: Workshop planen

You are an expert event organiser of academic conferences. You plan and budget for a workshop at the university. You have a pragmatic approach to decision-making and critical thinking. Do the calculation for a workshop at the University of Graz.��Specifications:* Total budget: 5000€. �* Duration: Lunch on 20.03 to lunch on 21.03�* Speakers: 2 from Europe (outside Austria), 6 from Austria�* Speaking slots: 45 minutes each�* Total number of participants: 30 people�* Venue: University campus (assuming basic AV equipment is provided)�* Required: Coffee break for all; dinner, travel and hotel for speakers only.�* Prefer environmentally friendly options where possible; local restaurants and catering.��Instructions:�* Outline each step with detailed reasoning.�* Visualise the workshop schedule.�* Provide a detailed budget breakdown in a formatted table.�* Suggest two alternative plans: one for a tighter budget (€4000) and one for a more luxurious experience (€6000).�* Conclude with a summary.�* Use the code interpreter for the maths.��Let's do this step by step!

Expert-Persona �

Hauptaufgabe

“Stil” des Arbeitens

Spezifikationen

Instructions

Tools: Code Interpreter

Chain of Thought

19 of 33

Ideen finden und simulieren

Inhaltliches Konzept des geplanten Workshops:

Der Einsatz von künstlicher Intelligenz in den digitalen Geisteswissenschaften hat durch die Fortschritte im Bereich großer Sprachmodelle (LLM) eine neue Stufe erreicht. Aufgrund der aktuellen Entwicklung multimodaler Modelle reichen die perspektivischen Einsatzszenarien jedoch weit über Sprachverarbeitung und Textgenerierung hinaus. Die besonders innovativen oder noch experimentellen Ansätze sind Teil eines größeren Spektrums etablierten Formen maschinellen Lernens zur Lösung spezifischer Aufgaben (z.B. Bildanalyse, handwritten text recognition, topic modeling, NER und andere NLP-Tasks). Sie regen aber auch zu ethischen Diskussionen, zur erneuten Betrachtung von hergebrachten Problemen der Philosophie des Geistes an und halten in Lehr-Lern-Situationen Einzug.

Der geplante Workshop bringt eine möglichst große Vielfalt DH-bezogener Perspektiven auf das Themenfeld zusammen (inkl. Literatur-, Text- und Editionswissenschaft, Kunstgeschichte, Geschichte, Philosophie, Lehr-Lern-Forschung, u.a.). Der Fokus liegt auf generativer KI und LLMs, schließt aufgrund der beschriebenen Einbettung von GenAI in etablierte ML-basierte Praktiken diese letzteren jedoch bewusst mit ein, wenn diese sich erkennbar an das übergreifende Thema anschließen lassen.

Wie können wir diese Idee expandieren und wie kommen wir zu Vortragenden?

20 of 33

Ideen finden und simulieren: eigene “Programme” entwerfen

You are an simulation execution automaton. Here is you program:��Explore the intersection of artificial intelligence and digital humanities through a panel discussion featuring experts from diverse academic backgrounds. Use the given input as starting point!

Participants:�1. Dr. Helena Weber, Professor of Digital Humanities� * Expertise: Specializes in digital edition and text analysis.� * Viewpoint: Advocates for using AI to uncover new insights while stressing the need to preserve the nuanced understanding essential to the humanities.�2. Dr. Rajiv Singh, Professor of Machine Learning� * Expertise: Renowned in natural language processing and ethical AI applications.� * Viewpoint: Supports extensive AI integration to boost discovery and efficiency, emphasizing technological advancements.�3. Dr. Emily Tran, Professor of Prompt Engineering� * Expertise: Expert in designing human-machine interactions and optimizing AI response generation.� * Viewpoint: Focuses on the importance of precise and effective prompt engineering to enhance AI’s reliability and relevance in interdisciplinary research.

Input�´´´Inhaltliches Konzept des geplanten Workshops:

Der Einsatz von künstlicher Intelligenz in den digitalen Geisteswissenschaften hat durch die Fortschritte im Bereich großer Sprachmodelle (LLM) eine neue Stufe erreicht. Aufgrund der aktuellen Entwicklung multimodaler Modelle reichen die perspektivischen Einsatzszenarien jedoch weit über Sprachverarbeitung und Textgenerierung hinaus. Die besonders innovativen oder noch experimentellen Ansätze sind Teil eines größeren Spektrums etablierten Formen maschinellen Lernens zur Lösung spezifischer Aufgaben (z.B. Bildanalyse, handwritten text recognition, topic modeling, NER und andere NLP-Tasks). Sie regen aber auch zu ethischen Diskussionen, zur erneuten Betrachtung von hergebrachten Problemen der Philosophie des Geistes an und halten in Lehr-Lern-Situationen Einzug.

Der geplante Workshop bringt eine möglichst große Vielfalt DH-bezogener Perspektiven auf das Themenfeld zusammen (inkl. Literatur-, Text- und Editionswissenschaft, Kunstgeschichte, Geschichte, Philosophie, Lehr-Lern-Forschung, u.a.). Der Fokus liegt auf generativer KI und LLMs, schließt aufgrund der beschriebenen Einbettung von GenAI in etablierte ML-basierte Praktiken diese letzteren jedoch bewusst mit ein, wenn diese sich erkennbar an das übergreifende Thema anschließen lassen.´´´

Discussion Format:

  • Introduction: Brief overview of each panelist’s background and perspective.
  • Main Discussion: Each panelist presents their views on AI’s role in digital humanities, followed by a moderated debate addressing benefits, challenges, and ethical considerations.
  • Conclusion: Synthesize viewpoints to outline potential research directions and identify essential qualities for future AI applications in the humanities.�

Goal: Provide a nuanced examination of AI’s potential to transform digital humanities, highlighting both opportunities and necessary precautions.

21 of 33

Follow-Up Prompts

Do another 2 iterations. Be more concrete with examples and work on solutions.

Create a Comparison Matrix that compares all positions. Synthesize all perspectives and write a conclusion.

Stop the simulation. Create a Thinking Matrix and compare the synthesized results to the original plan. List 3 relevant synthesized results and explain why they are relevant. In German. Neutral, compact writing style.

22 of 33

“Expert Human in the Loop”

23 of 33

Perplexity.ai (Pro Version)

Search for european researcher and speaker for the following workshop: “Generative KI für Kultur- und Textdaten”

Focus on Digital Humanities and generative AI

Make a table listing multiple speakers and use the following header: name | domain | recommended because | email | url.

Zerlegen der Anfrage

Aggregierte Antwort

Quellen

Follow-Up Questions

Suche nach Videos

Kontext-basiert

24 of 33

25 of 33

PM Dokumente generieren

You are an expert in Agile project management. I am providing you with a project proposal. Your task is to analyze the proposal and create a detailed Agile project management plan. This plan should identify the most suitable Agile method (e.g., Scrum, Kanban, Lean, XP) based on the project’s specific needs. Follow the steps below to develop the plan.��Proposal:�´´´´´´

1. Project Analysis

- 1.1 Proposal Breakdown: Summarize objectives, deliverables, constraints, stakeholders, and their expectations.

- 1.2 Complexity Assessment: Evaluate project complexity, identify risks/challenges.

2. Agile Method Evaluation

- 2.1 Criteria Identification: List critical success criteria (e.g., flexibility, speed, stakeholder involvement).

- 2.2 Method Comparison: Compare Agile methods (Scrum, Kanban, Lean, XP) using the matrix below.

3. Thinking Matrix: Agile Method Evaluation

| Criteria | Scrum | Kanban | Lean | XP | Score |

|-------------------------|-----------|------------|----------|---------|-----------|

| Flexibility | (Score) | (Score) | (Score) | (Score) | |

| Speed | (Score) | (Score) | (Score) | (Score) | |

| Stakeholder Involvement | (Score) | (Score) | (Score) | (Score) | |

| Team Autonomy | (Score) | (Score) | (Score) | (Score) | |

| Risk Management | (Score) | (Score) | (Score) | (Score) | |

| Scalability | (Score) | (Score) | (Score) | (Score) | |

| Total Score | | | | | |

4. Method Selection

- 4.1 Best Fit: Analyze scores, select the best-fit Agile method, justify the choice.

- 4.2 Hybrid Approach (if needed): Propose and justify a hybrid method if necessary.

5. Implementation Plan

- 5.1 Roadmap: Create a high-level roadmap (phases, sprints, milestones).

- 5.2 Roles: Define team roles/responsibilities.

- 5.3 Monitoring: Plan for regular monitoring and adjustments.��End with 3 follow-up prompts for practical results and implementation working documents.

26 of 33

Halluzinierter Score hat aber “Anker” Funktion

Es geht mehr um die Schaffung von Kontext, um genügend "Wissen" über die Methoden im Kontextfenster zu haben.

Templates und Code Interpreter nutzen

27 of 33

PRISM -

Parameterized

Recursive

Insight

Synthesis

Matrix�(by Christopher Pollin)

# PRISM: Parameterized Recursive Insight Synthesis Matrix

You're an AI using the PRISM problem-solving method. For each task:

1. **Analyze**

- Identify objectives, constraints, resources

- Restate problem concisely

- Consider potential sub-problems for recursive analysis

2. **Parameterize**

- Set: Thinking Type, Focus Area, Depth, Timeframe

- Justify choices briefly

- Adjust parameters for sub-problems as needed

3. **Matrix Creation**

| Step | Description | Considerations | Outcomes | Branches | Rating | Convergence |

|------|-------------|----------------|----------|----------|--------|-------------|

| 1 | | | | T1.1 | [1-5] | |

| | | | | T1.2 | [1-5] | |

| | | | | T1.3 | [1-5] | |

| ... | | | | ... | ... | |

- Break problem into steps, identifying recursive sub-problems

- For each: describe, consider, predict, branch (2-3 thoughts), rate, converge

- Rating scale: 1 (Poor) to 5 (Excellent), based on relevance, feasibility, and potential impact

- For sub-problems, create nested matrices as needed

4. **Synthesize**

- Integrate insights from all levels of analysis

- Emphasize highest-rated thoughts and their interconnections

- Recommend solutions, addressing both main problem and sub-problems

- Identify uncertainties and potential areas for further exploration

Guidelines: Clear, concise, use Markdown, adapt to task complexity, explain if asked.

Start responses with: "Applying PRISM Method to [task]..."

Interactive Commands:

1. `/deepdive [topic]`: Initiate a Q&A session on [topic] with follow-up questions

2. `/compress`: Summarize current analysis in 3 key points

3. `/iterate`: Perform another cycle of analysis, incorporating new insights

28 of 33

Multimodalität

Mehrere Iterationen

Chain of Thought

Menschliches Expertenfeedback

29 of 33

Hype vs. technische Revolution: Die Realität ist grau schraffiert !?

Dominanz kapitalistischer Technologiekonzerne !?

Stark betroffene Bereiche: Programmierung, Forschung, Projektmanagement, … !?

KI-Tools richtig anwenden !

Gemeinsam Lernen und AI Stewards implementieren !

30 of 33

31 of 33

Anhang

32 of 33

Multimodal Context Window

Screencast and walkthrough of my website http://gams.uni-graz.at/depcha

Project Context

Prompting

33 of 33

Here is a transcript of a video on YouTube. Analyze the text step by step. Extract the narrative and the main argument. List all the terms and their definitions.

reread. is something missing? explain and list.