|
1 | 1 | # Vertex AI for Firebase Sample App
|
2 | 2 |
|
3 |
| -You can try out the SDK quickly, see a complete implementation of various use |
4 |
| -cases, or use the sample app if you don't have your own Apple platforms app. To |
5 |
| -use the sample app, you'll need to perform the following steps: |
6 |
| -1. Download |
7 |
| - [vertexai-preview-0.1.0.zip](https://github.com/firebase/firebase-ios-sdk/archive/refs/heads/vertexai-preview-0.1.0.zip) |
8 |
| - for the latest release of the SDK |
9 |
| -1. Extract the zip and open `VertexAISample.xcodeproj` in the |
10 |
| - `FirebaseVertexAI/Sample` directory |
11 |
| -1. [Register the sample app](https://firebase.google.com/docs/ios/setup#register-app) |
12 |
| - in your Firebase project |
13 |
| - - The default bundle ID is `com.google.firebase.VertexAISample` |
14 |
| -1. [Download the `GoogleService-Info.plist`](https://firebase.google.com/docs/ios/setup#add-config-file) |
15 |
| - to the `FirebaseVertexAI/Sample` directory, overwriting the placeholder file |
16 |
| - with the same name |
| 3 | +This sample demonstrates how to make calls to the Vertex AI Gemini API directly |
| 4 | +from your app, rather than server-side, using the |
| 5 | +[Vertex AI for Firebase SDK](https://firebase.google.com/docs/vertex-ai/get-started?platform=ios). |
| 6 | + |
| 7 | +## Getting Started |
| 8 | + |
| 9 | +### Clone and open the sample project |
| 10 | + |
| 11 | +1. Clone this repo and checkout the `release-10.26` branch. |
| 12 | +1. Change into the `FirebaseVertexAI/Sample` directory. |
| 13 | +1. Open `VertexAISample.xcodeproj` using Xcode. |
| 14 | + |
| 15 | +```bash |
| 16 | +$ git clone https://github.com/firebase/firebase-ios-sdk.git |
| 17 | +$ cd firebase-ios-sdk |
| 18 | +$ git checkout release-10.26 |
| 19 | +$ cd FirebaseVertexAI/Sample |
| 20 | +$ open VertexAISample.xcodeproj |
| 21 | +``` |
| 22 | + |
| 23 | +### Connect the sample to your Firebase project |
| 24 | + |
| 25 | +- To have a functional application, you will need to connect the Vertex AI for |
| 26 | + Firebase sample app to your Firebase project using the |
| 27 | + [Firebase Console](https://console.firebase.google.com). |
| 28 | +- For an in-depth explanation, see |
| 29 | + [Add Firebase to your Apple project](https://firebase.google.com/docs/ios/setup). |
| 30 | + Below is a summary of the main steps: |
| 31 | + 1. Visit the [Firebase Console](https://console.firebase.google.com). |
| 32 | + 2. Add an iOS+ app to the project. Make sure the `Bundle Identifier` you set |
| 33 | + matches that of the one in the sample. |
| 34 | + - The default bundle ID is `com.google.firebase.VertexAISample` |
| 35 | + 3. Download the `GoogleService-Info.plist` when prompted and save it to the |
| 36 | + `FirebaseVertexAI/Sample` directory, overwriting the placeholder file with |
| 37 | + the same name. |
| 38 | +- Now you should be able to build and run the sample! |
| 39 | + |
| 40 | +## Documentation |
| 41 | + |
| 42 | +To learn more about the Vertex AI for Firebase SDK, check out the |
| 43 | +[documentation](https://firebase.google.com/docs/vertex-ai). |
| 44 | + |
| 45 | +## Support |
| 46 | + |
| 47 | +- [GitHub Issue](https://github.com/firebase/firebase-ios-sdk/issues/new/choose) |
| 48 | + - File an issue in the `firebase-ios-sdk` repo, choosing the Vertex AI product. |
| 49 | +- [Firebase Support](https://firebase.google.com/support/) |
0 commit comments