Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error in accessing TunedGenerativeModel in Android #111

Open
kushalbusiness12 opened this issue Apr 4, 2024 · 8 comments
Open

Error in accessing TunedGenerativeModel in Android #111

kushalbusiness12 opened this issue Apr 4, 2024 · 8 comments
Assignees
Labels
component:android sdk Issue/PR related to Android SDK status:triaged Issue/PR triaged to the corresponding sub-team type:bug Something isn't working

Comments

@kushalbusiness12
Copy link

kushalbusiness12 commented Apr 4, 2024

Im developing an Android chat app using a custom-tuned model from Gemini AI. However, I'm stuck with an error (see screenshot below) Error : models/tuned-test-model-g8tvOuyp9i6i is not found for API version v1 . when trying to integrate the model into my code. Any insights on resolving this issue would be greatly appreciated!
Android code for reference
val generativeModel = GenerativeModel(
modelName = "tuned-test-model-g8tv0uyp9i6i",
apiKey = BuildConfig.apiKey,
generationConfig = config
)
Screen Shot 2024-04-04 at 3 04 35 PM
Screen Shot 2024-04-04 at 3 08 32 PM

@kushalbusiness12 kushalbusiness12 changed the title Problem is accessing TunedGenerativeModel in Android Error in accessing TunedGenerativeModel in Android Apr 4, 2024
@singhniraj08 singhniraj08 added type:bug Something isn't working component:android sdk Issue/PR related to Android SDK status:triaged Issue/PR triaged to the corresponding sub-team labels Apr 5, 2024
@rlazo
Copy link
Collaborator

rlazo commented Apr 5, 2024

Hi @kushalbusiness12 could you try using "tunedModels/tuned-test-model-g8tv0uyp9i6i" as the name of the model? Let me know if that's the issue. I'll be looking at whether this is correctly documented on our end. Thanks!

@kushalbusiness12
Copy link
Author

@rlazo I tried using "tunedModels/tuned-test-model-g8tv0uyp9i6i" But I am facing permission issue : You do not have permission to
access tuned model tunedModels/
tuned-test-model-g8tvOuyp9ibi
Screen Shot 2024-04-05 at 11 24 30 AM

@rlazo
Copy link
Collaborator

rlazo commented Apr 5, 2024

Could you try setting the permissions for "EVERYONE" to "READER" for the model https://ai.google.dev/api/rest/v1beta/corpora.permissions#role ?

@kushalbusiness12
Copy link
Author

@rlazo I am currently using Google Ai Studio Tuned Model. I don't see any option to edit permissions in Google AI studio Console. Can you help with this?

@yujratnesh
Copy link

Hello Team,

I am also facing the same issue. Please let me know if you find any issue.

@jewel22-ace
Copy link

I am also facing same issue.

@manishindiainc
Copy link

Hi Team, facing the same issue. Please help.

@Ayush783
Copy link

Hi, I solved the same issue in my Flutter application. Sharing for your reference, hope you can draw out similarities and incorporate the same in Android natively.
https://medium.com/@Ayush_b58/accessing-tuned-gemini-model-in-flutter-30d07843d2e2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component:android sdk Issue/PR related to Android SDK status:triaged Issue/PR triaged to the corresponding sub-team type:bug Something isn't working
Projects
None yet
Development

No branches or pull requests

7 participants