This page did not load. You can still read it on the original site — the toolbar below keeps your place in the directory.
import OpenAI import SwiftUI struct ChatView: View { @State var newMessage: String = "" @State var conversation = Conversation(authToken: OPENAI_KEY, using: .gpt4o) var body: some View { VStack(spacing: 0) { ScrollView { VStack(spacing: 12) { ForEach(conversation.messages, id: .self) { message in MessageBubble(message: message) } } } TextField("Chat", text: $newMessage) .frame(height: 40)…
Comments
Nothing yet. Say the first thing.
Sign in to join the conversation.