Created
June 15, 2025 12:16
-
-
Save mertozseven/8105a32a358b9748cbbee7e6febf665e to your computer and use it in GitHub Desktop.
FoundationModel Example
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
do { | |
let prompt = "Create a basic plan for trip to Istanbul" | |
let session = LanguageModelSession() | |
let response = try await session.respond(to: prompt) | |
print(response) | |
} catch { | |
print("Error from LanguageModelSession: \(error)") | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment