Skip to content

Commit

Permalink
Get rid of default models on some tools (#236)
Browse files Browse the repository at this point in the history
The models I hardcoded were outdated for certain tools so I removed
them. Now the tools will use the model suggestions from the API instead
so we're always up to date.

I left the hardcoded model on `textToSpeech` since the suggested models
in the API don't work for now. (See [this
pr](huggingface/transformers#24952))
  • Loading branch information
nsarrazin authored Jul 27, 2023
1 parent ed07ddb commit 89ea88a
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 3 deletions.
1 change: 0 additions & 1 deletion packages/agents/src/tools/imageToText.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ export const imageToTextTool: Tool = {
await inference.imageToText(
{
data,
model: "nlpconnect/vit-gpt2-image-captioning",
},
{ wait_for_model: true }
)
Expand Down
1 change: 0 additions & 1 deletion packages/agents/src/tools/speechToText.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ export const speechToTextTool: Tool = {
await inference.automaticSpeechRecognition(
{
data,
model: "facebook/wav2vec2-large-960h-lv60-self",
},
{ wait_for_model: true }
)
Expand Down
1 change: 0 additions & 1 deletion packages/agents/src/tools/textToImage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ export const textToImageTool: Tool = {
return await inference.textToImage(
{
inputs: data,
model: "stabilityai/stable-diffusion-2",
},
{ wait_for_model: true }
);
Expand Down

0 comments on commit 89ea88a

Please sign in to comment.