Skip to content

[EAGLE-7291] Use PATs for API calls that involve external models, part 2#251

Merged
tiit-clarifai merged 1 commit intomasterfrom
EAGLE-7291-pat-for-general-embedder
Apr 10, 2026
Merged

[EAGLE-7291] Use PATs for API calls that involve external models, part 2#251
tiit-clarifai merged 1 commit intomasterfrom
EAGLE-7291-pat-for-general-embedder

Conversation

@tiit-clarifai
Copy link
Copy Markdown
Contributor

Search and custom predict operations with an image input use the embedder model from the base workflow of the application. The test applications use the general-image-embedding model from clarifai/main, so they need to use a Personal Access Token to access the model from another application.

  • Update all search calls that rank by embeddings (image data) to use a PAT.
  • Update predict calls to embedding-classifier models to use a PAT.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the Python gRPC client test suite to authenticate with Personal Access Tokens (PATs) for requests that implicitly invoke external (cross-application) embedder models via image inputs, ensuring tests can access models from clarifai/main.

Changes:

  • Switched image-embedding-based input search tests to use metadata(pat=True) and added user_app_id=user_app_id() to the affected requests.
  • Updated a model predict call (with image input) in the model CRUD test to use PAT auth and explicit user_app_id.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
tests/client/test_model_crud.py Uses PAT auth + user_app_id for image-based PostModelOutputs that triggers an external embedder.
tests/client/test_inputs_searches.py Uses PAT auth + user_app_id for image-ranking PostInputsSearches queries that require external embeddings.
tests/client/test_input_search_legacy.py Uses PAT auth + user_app_id for legacy image-based PostSearches embedding searches.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@tiit-clarifai tiit-clarifai merged commit 1f6448c into master Apr 10, 2026
14 of 15 checks passed
@tiit-clarifai tiit-clarifai deleted the EAGLE-7291-pat-for-general-embedder branch April 10, 2026 09:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants