Give me a mermaid example
- User
Give me a mermaid example
Assistant
Here's a Mermaid sequence diagram representing a JavaScript callback:
sequenceDiagram participant Client participant DataService Client->>DataService: fetchData(callback) activate DataService Note over DataService: Processing data... DataService-->>Client: callback(data) deactivate DataServiceVariations
AJAX Example
sequenceDiagram participant Browser participant APIService participant Server Browser->>APIService: fetchUser(id, successCallback, errorCallback) activate APIService APIService->>Server: GET /users/{id} Server-->>APIService: JSON response alt Successful response APIService-->>Browser: successCallback(userData) else Error occurred APIService-->>Browser: errorCallback(error) end deactivate APIService
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.