Graph Prompting
The technique uses graph structures to organize and link the different elements of a prompt. That lets you build more complex, interconnected instructions for an AI model.
| Advantages | Drawbacks |
|---|---|
| Lets you model complex relationships between concepts | Can be harder to design and implement |
| Improves understanding of context and connections | Requires deeper knowledge of the subject area |
| Can lead to more structured and logical answers | Can increase computational cost |
Graph Prompting example:
Build a knowledge graph of the solar system.
The nodes are planets and other celestial bodies, and the edges are the relationships between them (for example, 'orbits', 'is larger than', 'has a moon'). Once the graph is built:
1. Describe the path from the Sun to Jupiter, listing every intermediate node and relationship.
2. Find every celestial body connected to Saturn and explain their relationships.
3. Propose a new node for the graph and justify its links to the existing nodes.