<｜begin▁of▁sentence｜>### Instruction:
Generate a JSON object that describes the graph structure of the 4th Mycielski Graph (M4). Include an 'id' and 'label' for each node, and a 'source', 'target', and 'label' for each edge. Use the mycielski_graph function from the NetworkX library to create the graph.
### Response:
import networkx as nx

# Generate the n-th Mycielski Graph (example for n=4)
M = nx.generators.mycielski.mycielski_graph(4)

# Create JSON representation of the Mycielski Graph
graph_data = {'graph_nodes': [], 'graph_edges': []}
for node in M.nodes():
    graph_data['graph_nodes'].append({'id': node, 'label': f'Node {node}'})
for edge in M.edges():
    graph_data['graph_edges'].append({'source': edge[0], 'target': edge[1], 'label': f'Edge from {edge[0]} to {edge[1]}'})

# Convert graph data to JSON format
import json
graph_json = json.dumps(graph_data, indent=2)
print(graph_json)
<|EOT|>
