1. Link BinahAI Framework
Link BinahAI.framework as a library
- After creating a new project, copy the framework (BinahAI.framework) folder to the same path as your project file (e.g: company.xcodeproj).
- Choose your target, and go to Build Phases tab.
- Expand Link Binary With Libraries.
- Click +.
- In the drop down, select Add Files.
The Finder opens. - Select the framework folder, and click Open.
The BinahAI.framework is now linked to your project. - Go to General tab, and under Framework, Libraries, and Embedded content, change the Embed Method to Embed & Sign.
2. Copy Bundle Resources
Copy bundle resources
Note: If you are in version 3.0.7 or higher, skip to Adding Support for C++ Libraries.
- In the Build Phases tab, expand the Copy Bundle Resource.
- Open the Finder, and search for the BinahAI Framework folder.
The folder is generally located under the same path as your project file. - Click the folder.
- Drag the models.bundle to the Xcode section.
- Choose Create groups.
- Click Finish. The models.bundle is copied into your project as a resource.
3. Add Support for C++ Libraries
Add support for C++ libraries
- Go to the project's Build Settings.
- Expand Apple Clang - Language - C++.
- Set the C++ Language Dialect to C++ 17 [-std=c++17].
4. Additional C++ Linking Support
Additional C++ linking support
- Go to the project's Build Settings.
- Go to Linking > Other Linker Flags.
- Edit this field, and set its value to -lstdc++.
- Click +, and add -ObjC.
- Click Enter.
5. Make Sure Framework is Searchable
Make sure framework can be searched by Xcode
- Choose your target.
- Go to Build Settings.
- Either look for the Search Paths section, or search for paths.
- Inside this section, make sure the Framework Search Paths contains the path where you put the BinahAI Framework (e.g: $(PROJECT_DIR).
6. Add info.plist
Add info.plist to your SDK unique IDs
- Add a new raw with the name: BinahLicenseKey as string, and type the license ID you have.
Note
- Run the application on a real device to test (it does not work on an emulator)
Comments
1 commentPlease sign in to leave a comment.
Hi, From where I can download the sdk or your demo code ?